curl --request POST \
--url https://openplatform.gateapi.io/v1/pay/withdraw/query \
--header 'Content-Type: application/json' \
--header 'X-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>' \
--header 'X-GatePay-Nonce: <x-gatepay-nonce>' \
--header 'X-GatePay-Signature: <x-gatepay-signature>' \
--header 'X-GatePay-Timestamp: <x-gatepay-timestamp>' \
--data '
{
"batch_id": "237394559478075555",
"detail_status": "ALL"
}
'{
"status": "SUCCESS",
"code": "000000",
"errorMessage": "",
"data": {
"batch_id": "237394559478075350",
"merchant_id": 10002,
"client_id": "mZ96D37oKk-HrWJc",
"status": "FAIL",
"create_time": 1726055849126,
"channel_id": "123456",
"withdraw_list": [
{
"id": 35,
"batch_id": "237394559478075350",
"merchant_id": 10002,
"suborder_id": "268830764354768896",
"chain": "ETH",
"address": "0x1234567890abcdef",
"currency": "USDT",
"amount": "1",
"fee": "0",
"tx_id": "",
"timestamp": 0,
"memo": "Payment for services-1",
"status": "FAIL",
"merchant_withdraw_id": "M137394559478075550",
"err_msg": "unexpected http code error",
"create_time": 1726055848856,
"update_time": 1726055856011,
"channel_id": "123456",
"fee_type": 1,
"done_amount": "1"
},
{
"id": 36,
"batch_id": "237394559478075350",
"merchant_id": 10002,
"suborder_id": "268830764354768897",
"chain": "ETH",
"address": "1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa",
"currency": "USDT",
"amount": "0.001",
"fee": "0",
"tx_id": "",
"timestamp": 0,
"memo": "Payment for services-1",
"status": "FAIL",
"merchant_withdraw_id": "M137394559478075551",
"err_msg": "unexpected http code error",
"create_time": 1726055848856,
"update_time": 1726055856010,
"channel_id": "123456",
"fee_type": 1,
"done_amount": "0.001"
}
]
}
}根据批次 ID 和明细状态查询提现批次及子单详情。
curl --request POST \
--url https://openplatform.gateapi.io/v1/pay/withdraw/query \
--header 'Content-Type: application/json' \
--header 'X-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>' \
--header 'X-GatePay-Nonce: <x-gatepay-nonce>' \
--header 'X-GatePay-Signature: <x-gatepay-signature>' \
--header 'X-GatePay-Timestamp: <x-gatepay-timestamp>' \
--data '
{
"batch_id": "237394559478075555",
"detail_status": "ALL"
}
'{
"status": "SUCCESS",
"code": "000000",
"errorMessage": "",
"data": {
"batch_id": "237394559478075350",
"merchant_id": 10002,
"client_id": "mZ96D37oKk-HrWJc",
"status": "FAIL",
"create_time": 1726055849126,
"channel_id": "123456",
"withdraw_list": [
{
"id": 35,
"batch_id": "237394559478075350",
"merchant_id": 10002,
"suborder_id": "268830764354768896",
"chain": "ETH",
"address": "0x1234567890abcdef",
"currency": "USDT",
"amount": "1",
"fee": "0",
"tx_id": "",
"timestamp": 0,
"memo": "Payment for services-1",
"status": "FAIL",
"merchant_withdraw_id": "M137394559478075550",
"err_msg": "unexpected http code error",
"create_time": 1726055848856,
"update_time": 1726055856011,
"channel_id": "123456",
"fee_type": 1,
"done_amount": "1"
},
{
"id": 36,
"batch_id": "237394559478075350",
"merchant_id": 10002,
"suborder_id": "268830764354768897",
"chain": "ETH",
"address": "1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa",
"currency": "USDT",
"amount": "0.001",
"fee": "0",
"tx_id": "",
"timestamp": 0,
"memo": "Payment for services-1",
"status": "FAIL",
"merchant_withdraw_id": "M137394559478075551",
"err_msg": "unexpected http code error",
"create_time": 1726055848856,
"update_time": 1726055856010,
"channel_id": "123456",
"fee_type": 1,
"done_amount": "0.001"
}
]
}
}商户客户端ID,在 GatePay 平台申请获得
"4186d0c6-6a35-55a9-8dc6-5312769dbff8"
HMAC-SHA256签名,用于验证请求合法性
"672d5650dcc9bb22ebf25fa16c28d03c0e159d742a9176d4340a5da326d75dc8a2ec24c97fa6fc5d1533dd6e968863747e1d86a45e562cbe899f9ed7e9ca7f77"
时间戳(毫秒),与服务器时间差不能超过5分钟
"1672905655498"
随机数,用于防止重放攻击
"3525756760"