...
Smart contract on Ethereum Chain.
Custodians
The smart contract owner key will be destroyed after deployment
Starting set of 10 custodian keys will be hard-coded into contract
Custodians will be able to:
Register Oracle
Request
Ethereum public address
Processing
Oracle is added after 2/3 + 1 custodians have registered the same public address
Unregister Oracle
Request
Ethereum public address
Processing
Oracle is removed after 2/3 + 1 custodians have unregistered the same public address
Register Custodian
Request
Ethereum public address
Processing
Custodian is added after 2/3 + 1 custodians have registered the same public address
Unregister Custodian
Request
Ethereum public address
Processing
Custodian is removed after 2/3 + 1 custodians have unregistered the same public address
Oracles will
MINT: Once Oracles detect that a user on FIO Chain wants to wrap FIO Domain or FIO Tokens, they will submit their observation to this Ethereum smart contract. Once all Oracles have submitted their observation, the wrapped FIO Domain or wrapped FIO Tokens will be minted and transferred to designated Ethereum public address.
Oracle can trigger minting of wrapped tokens
FIO tokens: mint WFIO ERC-20 token
FIO Domains: mint ERC-721 token
Must be compatible with OpenSeas
BURN: Once Oracles detect that a FIO Domain has been burned on the FIO Chain, they will submit their observation to this Ethereum smart contract. Once all Oracles have submitted their observation, the wrapped FIO Domain will be burned.
Oracle can trigger burning of ERC-721 tokens
Users will
SEND: Send ERC-721 FIO Domain or WFIO ERC-20 to this Ethereum smart contract without additional fee other than Ethereum gas passing:
ERC-721
ERC-721 Domain - previously minted on Ethereum
FIO Address where FIO Domain should be delivered on FIO Chain
Basic regex validation should be enforced
ERC-20
Amount of WFIO - previously minted on Ethereum
FIO Address where FIO Tokens should be delivered on FIO Chain
Basic regex validation should be enforced
Automatic generation of ERC-721 Data storagemetadataAnchor 721 721 ERC-721 requires that a url to a json file be provided.
Storage The metadata should be determined by the Oracles.Recommended served by a service hosted by the Foundation, which will dynamically generate it based on the query parameter in the url, e.g. https://metadata.fioprotocol.io/domainnft/sampledomain.json
Response meta data:
Code Block | ||
---|---|---|
| ||
{ "name": "FIO Domain: sampledomain", "description": "CreateOwners of FIO Domains can create unlimited number of human-readable FIO Addresses on your custom to be used to receive or request crypto using FIO DomainProtocol.", "image": "url to FIO icon" }https://metadata.fioprotocol.io/domainnft/sampledomain.svg" } |
Automatic generation of NFT image
The NFT image should be dynamically generate it based on the query parameter in the url, e.g. https://metadata.fioprotocol.io/domainnft/sampledomain.json
Response image will include the base image with text overlay as follows:
TBD
Oracle functionality
Customized solution based on Alien Teleport developed by Michael Yeates.
Oracle code will be ran by designated FIO Chain BPs with access to:
Oracle will:
FIO Chain
Monitor specific account by inspecting every block and looking for wrapdomain or wraptokens action
TRANSFER FIO Domains or FIO Tokens
Ethereum Chain
Monitor Ethereum smart contract for inbound transfers of ERC-721s or ERC-20s
MINT ERC-721 or ERC-20
Possible exceptions (exception handling should not be automated at this stage):
FIO Chain
Chain passed to wrapdomain or wraptokens actions is not Ethereum (this restriction is not enforced on the FIO Chain level to allow for wrapping chain expansion without deployment of code)
Oracles can trigger unwrapdomain or unwraptokens actions to originating address
Public address passed to wrapdomain or wraptokens actions is not a valid Ethereum address (this restriction is not enforced on the FIO Chain level to allow for wrapping chain expansion without deployment of code)
Oracles can trigger unwrapdomain or unwraptokens actions to originating address
Ethereum Chain
FIO Address passed in with ERC-20 is not valid or does not exist
Oracles can trigger a refund deducting amount to cover gas
FIO Address passed in with ERC-721 is not valid or does not exist
Oracle can at their discretion trigger a refund or manually resolve the issue with sender
Other options considered
FIO Chain wrapping functionality | Oracle functionality | Ethereum Chain wrapping functionality | ||||
---|---|---|---|---|---|---|
|
|
|