Query Payment Status
Request Method and Path
POST /payin/v1/getPaymentStatus
Request Headers
| Field Name | Type | Required | Description |
|---|---|---|---|
| content-type | string | Yes | application/json |
| x-api-key | string | Yes | Provided by Paydify, same as appId |
| x-api-timestamp | string | Yes | Timestamp in milliseconds |
| x-api-signature | string | Yes | Signature, see Signature Algorithm |
Request Body
| Field Name | Type | Required | Description |
|---|---|---|---|
| mchTxnId | string | No | Merchant order ID, either mchTxnId or txnId must be provided |
| txnId | string | No | Paydify order ID, either mchTxnId or txnId must be provided |
Response Headers
| Field Name | Type | Required | Description |
|---|---|---|---|
| x-api-key | string | Yes | Provided by Paydify, same as appId |
| x-api-timestamp | string | Yes | Timestamp in milliseconds |
| x-api-signature | string | Yes | Signature, see Signature Algorithm |
Response
| Field Name | Type | Description |
|---|---|---|
| code | string | Response code, SYS_SUCCESS indicates success |
| message | string | Response message |
| messageDetail | string | Detailed response message |
| success | boolean | Whether the request was successful |
| data[i].txnId | string | Paydify order ID |
| data[i].mchTxnId | string | Merchant order ID |
| data[i].txnHash | string | Blockchain transaction hash |
| data[i].txnAmount | string | Order amount, if currency is USDT, then 1.23 means 1.23 USDT |
| data[i].paidAmount | string | Actual paid amount, if currency is USDT, then 1.23 means 1.23 USDT |
| data[i].mchReceivedAmount | string | Amount merchant should receive, if currency is USDT, then 1.23 means 1.23 USDT |
| data[i].mchFee | string | Fee charged by Paydify, if currency is USDT, then 0.23 means 0.23 USDT |
| data[i].mchFeeRate | string | Fee rate charged by Paydify, 1 means 1% |
| data[i].currency | string | Payment currency |
| data[i].gasFee | string | Blockchain gas fee |
| data[i].gasFeeCurrency | string | Gas fee currency |
| data[i].payMethod1 | string | Payment wallet, enum values see Supported Blockchains and Currencies |
| data[i].payMethod2 | string | Payment blockchain, enum values see Supported Blockchains and Currencies |
| data[i].appId | string | Provided by Paydify |
| data[i].state | string | Payment status, enum values see Payment Status |
| data[i].refundType | string | Refund identifier, note distinction from refund status |
| data[i].mchExtInfo | string | Merchant extension information, JSON string |
| data[i].errorMsg | string | Payment failure reason description |
| data[i].envType | string | |
| data[i].fromAddress | string | Payer address |
| data[i].checkoutMode | int | Checkout mode, possible values: MERCHANT (merchant-specified payment amount), CUSTOMER (customer input payment amount) |
| data[i].paidTime | int | Payment success timestamp in milliseconds, only has value when payment is successful |
| data[i].failedTime | int | Payment failure timestamp in milliseconds, only has value when payment fails/times out |
| data[i].expiredTime | int | Expected payment timeout timestamp in milliseconds |
| data[i].createdTime | int | Payment initiation timestamp in milliseconds |
Request Example
shell
# Request
# Successful response
{
"code": "SYS_SUCCESS",
"message": null,
"messageDetail": null,
"data": [{
"txnId": "2209141130105863014",
"mchTxnId": "220914xxx",
"state": "pending",
"errorMsg": "xxx",
"paidTime": 1756725871000,
"failedTime": 0,
"expiredTime": 1756729471000,
"createdTime": 1756697092000
}],
"success": true
}
# Failed response
{
"code": "SYS_ERROR",
"message": "System error",
"messageDetail": "Error details",
"data": null,
"success": false
}# Request
# Successful response
{
"code": "SYS_SUCCESS",
"message": null,
"messageDetail": null,
"data": [{
"txnId": "2209141130105863014",
"mchTxnId": "220914xxx",
"state": "pending",
"errorMsg": "xxx",
"paidTime": 1756725871000,
"failedTime": 0,
"expiredTime": 1756729471000,
"createdTime": 1756697092000
}],
"success": true
}
# Failed response
{
"code": "SYS_ERROR",
"message": "System error",
"messageDetail": "Error details",
"data": null,
"success": false
}