This mutation allows transfers of ERC721 or ERC1155 token to another address.
Sample Mutation
Transfer a token to another contract address:
mutation{
transferToken(walletId:"4da9ac9c-4b9a-4c3b-b95e-cce96eca0d34"
contractAddress:"0xa49A3F5CfbEE17508AE2b3A842d9254E163aF85f"
tokenType:ERC721
tokenOnChainId:4
amount:1
transferTo:"0x39FdF1C23206Ac44f8991a3C3b7c9441f0123e48"
)
}
Sample Response
{
"data": {
"transferToken": "79bc2156-fa39-480a-88e8-733c4f962b4e"
}
}
Arguments
Name | Type | Description | Required |
---|---|---|---|
walletId | UUID1 | The wallet ID. | Yes |
contractAddress | String | The contract address. | Yes |
tokenOnChainId | Integer | The ID of the token in the smart contract. | Yes |
transferTo | String | The transfer destination. | Yes |
tokenType | Enum | The type of the token. The value can be either ERC721 or ERC1155. | Yes |
amount | Integer | The transfer amount. | Yes |
Return
Name | Type | Description |
---|---|---|
N/A | String | The returned value of the transferred token. |
Example
Transfer a token to a certain destination using Wallet ID, contract address, token on chain ID, and transfer destination: