Skip to main content

Query Order

You can use the “Query Order” API to query an order and check the order status in real time.

End Point#
POST   /binancepay/openapi/v2/order/query
Request Example#

For full API specification, please go to API Request Reference.

You can either use “merchantTradeNo” or “prepayId” to search for the specific order. Please input at least one of them.

{  "merchantId": "987321472",  "subMerchantId": "987321472",  "merchantTradeNo": "9825382937292",  "prepayId": "29383937493038367292"}
Response Example#

For full API specification, please go to API Request Reference.

{  "status": "SUCCESS",  "code": "000000",  "data": {    "merchantId": "987321472",    "prepayId": "29383937493038367292",    "transactionId": "23729202729220282",    "merchantTradeNo": "9825382937292",    "tradeType": "APP",    "status": "PAID",    "currency": "BUSD",    "totalFee": 10.88,    "productName": "Ice Cream",    "productDetail": "Green Tea ice cream cone",    "transactTime": "1425744000123",    "createTime": "1425744000000"  },  "errorMessage": ""}

You can monitor the payment status using the parameter “status”.

StatusDescription
INITIALThe transaction has been initiated. Return this status after calling “Create Order” API successfully.
PENDINGThe transaction is pending for payment.
PAIDThe transaction has been paid.
ERRORThe transaction has been canceled.
REFUNDINGThe transaction is under a refund process.
REFUNDEDThe transaction is under a refund process.
EXPIREDThe transaction is expired. By default, the QR code will expire after 1 hour.
Status
INITIAL
Description
The transaction has been initiated. Return this status after calling “Create Order” API successfully.
Status
PENDING
Description
The transaction is pending for payment.
Status
PAID
Description
The transaction has been paid.
Status
ERROR
Description
The transaction has been canceled.
Status
REFUNDING
Description
The transaction is under a refund process.
Status
REFUNDED
Description
The transaction is under a refund process.
Status
EXPIRED
Description
The transaction is expired. By default, the QR code will expire after 1 hour.