Paying Teleporter fees with native tokens #283
Closed
minghinmatthewlam
started this conversation in
Ideas
Replies: 1 comment
-
This will be tackled in issue #292 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Problem
Right now
TeleporterMessenger
only takes ERC20s as a fee, and none of the functions as marked aspayable
to allow for paying fees to relayers. This means that any apps built on top of Teleporter needs to handle fees through ERC20s, but often this can be an extra step for users to require an ERC20, and it needs to be an ERC20 that relayers will accept.Proposal
Instead we should allow the option to pay with the native assets of the chain, but
TeleporterMessenger
has already gone through multiple audits and we want to avoid major changes to the contract right before launch. A separate wrapping contract would help handle this case, which takes in the native asset, converts into a standard ERC20 like WAVAX, then performs the subsequent call to Teleporter. This contract should supply the need for any Teleporter app to pay for Teleporter fees through the native assets of the chain, and still provide ERC20 tokens that will be desired by relayers for incentives.I'm thinking to use a Solidity library, that way the
msg.sender
values will remain the same when depositing native asset for ERC20 token, and also can make the call to Teleporter to maintain the samemsg.sender
value. The library should include:sendCrossChainMessage
but no need forfeeTokenAddress
since we're using native assetpayable
deposit()
to get returned ERC20 token amountQuestions
Beta Was this translation helpful? Give feedback.
All reactions