Uplink client
sponsorTokenWithERC20
Sponsor a token intent with ERC20.
This function will revert under the following conditions:
- The channel does not allow ERC20 minting.
- The caller does not fulfill any of the channel
creatorLogic[]
rules. - The caller does not fulfill any of the channel
minterLogic[]
rules. - The caller does not have the required ERC20 balance to mint the tokens.
- The caller has not approved the channel to spend the required ERC20 balance.
Usage
Returns
Parameters
channelAddress
- type:
string
The target channel address
to
- type:
string
The recipient of the minted tokens
tokenId
- type:
bigint
The token ID to mint
amount
- type:
bigint
The amount to mint
mintReferral (optional)
- type:
string
The referral address for the mint
data (optional)
- type:
string
Additional data for the mint
transactionOverrides (optional)
- type:
TransactionOverrides
Overrides for the transaction
Calldata
generate calldata for the transaction
Returns
Gas Estimation
Estimate gas for the transaction