This API used to redeem the minted Token from Redeemable Collection
Sample mutation
mutation OnchainRedeemToken($redeemCollectionAddress:String!,
$tokenId:BigInt!,
$walletAddress:String!,
$quantity:BigInt,
$tokenURI:String,
$orgId:UUID1!,
$networkId:UUID1!,
$tokenType:TokenType!,
$gating:GateInput){
OnchainRedeemToken(
redeemCollectionAddress: $redeemCollectionAddress
tokenId: $tokenId
walletAddress: $walletAddress
quantity: $quantity
tokenURI: $tokenURI
orgId: $orgId
networkId: $networkId
tokenType: $tokenType
gating:$gating
)
}
Sample variable
{
"redeemCollectionAddress": "0x9e90b5eFA76487Ac803572AE92AfA1e622145FD5",
"tokenId": "2",
"walletAddress": "0x825e6ce1855ed046F19A384ea6F1498e47fD405F",
"quantity": "2",
"tokenURI": "",
"orgId": "8fb128bd-f55d-4bcc-8b6c-0beb684e4d4e",
"networkId": "b260424b-bb37-4a3e-86d0-0866175e5e68",
"tokenType": "ERC721",
"gating":{
"ruleId":"49f57168-b4b6-4d38-8ed8-88195351b2f5",
"ownerWallet":"0x454d25d3f512ADe0f1C488ADaEcCC334759D211E",
"contractAddress":"0x3ef0af9f7eff469597be9ae63e64c27de0f8eeff",
"tokenId":"2"
}
}
Sample Response
{
"data": {
"OnchainRedeemToken": {
"Token redeeming started, will reflect in wallet shortly"
}
}
}
Arguments
Name | Type | Description | Required |
---|---|---|---|
redeemCollectionAddress | String | Redeem Collection Address | Yes |
tokenId | BigInt | Token ID to be Redeemed | Yes |
walletAddress | String | Wallet Address | Yes |
quantity | BigInt | Quantity of token | No |
tokenURI | String | Token URI | No |
orgID | UUID | The Organization ID | Yes |
networkId | UUID | Redeemable NFT Contract ID | Yes |
tokenType | TokenType | The Contract Deployment Type | Yes |
gating | GateInput | Gating Rule Input | No |
Field
Name | Type | Description |
---|---|---|
status | String | Will return the status of redeem token process on completion otherwise error message |
signerInfo | SignerResponse | Will return the Signer details which needed to pass it to blockchain Transaction |