更多资源
查询单笔交易的详情

查询单笔交易的详情#

查询单笔交易的详情数据。

请求地址#

GET https://www.okx.com/api/v5/waas/transaction/get-transaction-detail

请求参数#

ParameterTypeRequiredDescription
walletIdStringYes钱包唯一标识
orderIdStringNo交易唯一标识
txHashStringNo交易哈希,不能和 orderId 同时为空
chainIdStringYes链唯一标识

响应参数#

ParameterTypeDescription
chainIdString链唯一标识
orderIdString交易唯一标识
txhashString交易哈希
addressString钱包地址
fromAddrString发送地址,适用于 EVM 和 UTXO 网络交易
toAddrString接收地址,适用于 EVM 和 UTXO 网络交易
inAddrListArray<String>输入地址列表,仅适用于 UTXO 网络
>addressString地址
>coinAmountString代币数量
outAddrListArray<String>输出地址列表,仅适用于 UTXO 网络
>addressString地址
>coinAmountString代币数量
txTypeString交易类型
1:接收代币
2:发送代币
3:合约交互
50:BRC20_MINT
51:BRC20_INSCRIBE
52:BRC20_TRADE
53:BRC20_SEND
54:BRC20_RECEIVE
60:BRC20_DEPLOY
txTimeString交易时间,时间戳
txStatusString交易状态
1、2 排队中
3 失败
4 成功
exploreUrlStringURL
gasPriceStringgas 价格
priorityFeeString小费
gasLimitStringgas 限额
nonceStringnonce
assetChangeArray<Object>资产变动
>coinIdString币种唯一标识
>brc20Coinboolean是否 BRC-20 代币
>directionString交易方向
>coinAmountString交易币种数量
>coinAmountNumString交易币种整数
>precisionString精度
>coinSymbolString币种简称
>coinNameString币种名称
>currencyAmountString法币金额 (美元)
>coinLogoUrlString币种 logo 图片 URL

请求示例#

shell
curl --location --request GET 'https://www.okx.com/api/v5/waas/transaction/get-transaction-detail?walletId=13886e05-1265-4b79-8ac3-b7ab46211001&orderId=469356614923743232&txHash=79c06b829866217e7a5843def7c5ceaa8451971044e35616330ac3b37c3c7854&chainId=1' \
--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'

响应示例#

200
{
  "code": "0",
  "msg": "success",
  "data": [{
    "chainId": "1",
    "orderId": "469356614923743232",
    "txhash": "79c06b829866217e7a5843def7c5ceaa8451971044e35616330ac3b37c3c7854",
    "address": "0xdf54b6c6195ea4d948d03bfd818d365cf175cfc2",
    "fromAddr": "0xdf54b6c6195ea4d948d03bfd818d365cf175cfc2",
    "toAddr": "0x1e80c39051f078ee34763282cbb36ffd88b40c65",
    }],
    "txType": "2",
    "txTime": "1697547606177",
    "txStatus": "3",
    "exploreUrl": "",
    "gasPrice": "null",
    "priorityFee": "null",
    "gasLimit": "null",
    "nonce": "null",
    "assetChange": [{
      "coinId": "3",
      "brc20Coin":true;
      "direction": "2",
      "coinAmount": "0.00012300000000000",
      "coinAmountNum": "123000000000000",
      "precision": "18",
      "coinSymbol": "ETH",
      "coinName": "ETH",
      "currencyAmount": null,
      "coinLogoUrl": "https://static.coinall.ltd/cdn/wallet/logo/ETH-20220328.png"
    }]
  }]
}