Query the transaction history under the address dimension, sorted in descending chronological order.
GET https://www.okx.com/api/v5/wallet/post-transaction/transactions-by-address
Parameter | Type | Required | Description |
---|---|---|---|
address | String | Yes | Address to query the transaction history for |
chainIndex | String | No | Unique identifier for the chain, e.g. ETH=3 |
tokenAddress | String | No | Token contract address. Used to filter transactions for a specific token |
begin | String | No | Start time, queries transactions after this time. Unix timestamp, in milliseconds |
end | String | No | End time, queries transactions before this time. If both begin and end are not provided, queries transactions before the current time. Unix timestamp, in milliseconds |
cursor | String | No | Cursor |
limit | String | No | Number of records to return, defaults to the most recent 20 records, up to a maximum of 20 records |
Parameter | Type | Description |
---|---|---|
transactionList | Array | List of transactions |
>chainIndex | String | Chain ID |
>txHash | String | Transaction hash |
>iType | String | EVM Transaction tier type 0 : Outer main chain coin transfer 1 : Contract inner main chain coin transfer 2 : Token transfer |
>methodId | String | Contract Function Call |
>nonce | String | The nth transaction initiated by the sender address |
>txTime | String | Transaction time in Unix timestamp format, in milliseconds, e.g., 1597026383085 |
>from | Array | Transaction input |
>>address | String | Sending/input address, comma-separated for multi-signature transactions |
>>amount | String | Input amount |
>to | Array | Transaction output |
>>address | String | Receiving/output address, comma-separated for multiple addresses |
>>amount | String | Output amount |
>tokenAddress | String | Token contract address |
>amount | String | Transaction amount |
>symbol | String | Currency symbol corresponding to the transaction amount |
>txFee | String | Transaction fee |
>txStatus | String | Transaction status: success for successful transactions, fail for failed transactions, pending for pending transactions |
>hitBlacklist | Boolean | false : Not in blacklist, true : In blacklist |
>tag | String | Tag type for blacklisted addresses, including phishing, contract vulnerabilities, etc. |
cursor | String | Cursor |
curl --location --request GET 'https://www.okx.com/api/v5/wallet/post-transaction/transactions-by-address?addresses=0x50c476a139aab23fdaf9bca12614cdd54a4244e4&chains=1' \
--header 'Content-Type: application/json' \
--header 'OK-ACCESS-PROJECT: 86af********d1bc' \
--header 'OK-ACCESS-KEY: 37c541a1-****-****-****-10fe7a038418' \
--header 'OK-ACCESS-SIGN: leaV********3uw=' \
--header 'OK-ACCESS-PASSPHRASE: 1****6' \
--header 'OK-ACCESS-TIMESTAMP: 2023-10-18T12:21:41.274Z'
{
"code": "0",
"msg": "success",
"data": [
{
"cursor": "1706197403",
"transactionList": [
{
"chainIndex": "1",
"txHash": "0x963767695543cfb7804039c470b110b87adf9ab69ebc002b571523b714b828ca",
"methodId": "",
"nonce": "",
"txTime": "1724213411000",
"from": [
{
"address":
"0xae7ab96520de3a18e5e111b5eaab095312d7fe84"
"amount": ""
}
],
"to": [
{
"address":
"0x50c476a139aab23fdaf9bca12614cdd54a4244e4"
"amount": ""
}
],
"tokenAddress": "0xe13c851c331874028cd8f681052ad3367000fb13",
"amount": "1",
"symbol": "claim rewards on stethdao.net",
"txFee": "",
"txStatus": "success",
"hitBlacklist": true,
"tag": "Risk Airdrop",
"iType": "2"
}
]
}
]
}