Transfer an ERC20 token
How to transfer an ERC20 token from wallet to another.
Request Endpoint: reference
POST /api/transactions/execute
Parameter | Param Type | Value | Description | Example Value |
---|---|---|---|---|
Signing-Method | Header | id:value | id : This is the ID of the signing methodvalue : This is the value of the signing method | 756ae7a7-3713-43ee-9936-0dff50306488:123456 |
Parameter | Param Type | Description | Data Type | Mandatory |
---|---|---|---|---|
transactionRequest | Body | This object includes the transaction information | Object | ✅ |
transactionRequest.type | Body | This will be TOKEN_TRANSFER | String | ✅ |
transactionRequest.walletId | Body | The id of the wallet that will initiate the tx | String | ✅ |
transactionRequest.to | Body | Destination Address (can be a blockchain address or email address) | String | ✅ |
transactionRequest.secretType | Body | On which blockchain the tx will be executed | String | ✅ |
transactionRequest.tokenAddress | Body | The address of the ERC20 token | String | ✅ |
transactionRequest.value | Body | The amount you want to transfer | Integer | ✅ |
pincode (Deprecated) | Body | PIN related to the wallet ID | String | ❌ |
Request Body
{
"transactionRequest": {
"type": "TOKEN_TRANSFER",
"walletId": "c4c97f87-8e00-4f3a-8647-2f24ac9b73cb",
"to": "0x2D24b9DE4F963d1Cfac1a65b6F1a85945d3e92F5",
"secretType": "MATIC",
"tokenAddress": "0xe11a86849d99f524cac3e7a0ec1241828e332c62",
"value": "1"
}
}
Response Body
{
"success": true,
"result": {
"id": "994c43ab-c2bf-41d2-a230-73027b4131bc",
"transactionHash": "0xc57dd7ec9cf40c9c61abcde7942840d81b66477a911f867c74ed85278195a550"
}
}
Updated 7 months ago