MEP ERC20 Contracts
In section 2.2, we introduced the example of a project owner who wants his token supported on multiple chains – for instance, Ethereum and BSC. The project owner would be able to deploy on each chain a MEP ERC20 contract, which is a standard ERC20 contract with two additional functions for adding and deleting assets – burn and mint.
function burn(address account, uint256 toChainId, uint256 amount) function mint (address account, uint256 amount, uint256 fromChainId, uint256 nonce, bytes memory signature)
When a user wants to transfer some MEP ERC20 token from chain A to chain B:
• The user calls the burn function on chain A.
• MEP monitors and reaches consensus on the event.
• The user requests authentication for the event from MEP.
• The user takes this authentication and the relevant information to call the mint function of the token contract on chain B to claim the token.
• During the mint process MEP will internally call the signature verification function to verify the validity of the signature.
• This model offers asset transfer natively and does not require the provision of a resource pool. Using this model, other resources can be directly transferred among chains.