# 3、Order Inquiry

# Inquiry for Payment Orders

API Description

This API allows you to query the details and status of an encrypted payment order by using the platform order ID and merchant order ID.

Request Method

POST

Request URL

/api/v3/wallet/query/pay

Request Header

Content-Type: application/json;charset=utf-8
Parameter Description Example Value
access_key Obtained from the merchant backend pFqV75X3
timestamp Unix timestamp (13 digits) 1679724896223
nonce UUID V4 794c26b0-d33c-4394-b2bb-c485eca16d9e
sign HMAC-SHA1 signature kAXyh+eerqrefyaF8dyFB0M4FVo=

Request Parameters (JSON)

{
  "externalOrderId": "402297358314559082",
  "orderId": "OCRYPPAID202307310902391690794159441DOCKER020000000400001108"
}

Parameter Description

Parameter Type Description Required
externalOrderId String Merchant Order ID Yes
orderId String Platform Order ID Yes

Response Type

Content-Type: application/json;charset=utf-8

Response Example

{
  "code": "200",
  "success": true,
  "msg": "成功",
  "msgEn": "SUCCESS",
  "data": [{
    "orderId": "OCRYPPAID202307310902391690794159441DOCKER020000000400001108",
    "cashierId": "OCRYPPAID202307310902391690794159250DOCKER020000000200001107",
    "orderType": 1,
    "orderResourceType": 1,
    "userId": "1663371399710216194",
    "orderStatus": 1,
    "orderTime": 1690794159000,
    "externalOrderId": "402297358314559082",
    "orderAmount": "1",
    "currencyType": "USD",
    "tokenType": "USDT",
    "chainType": "ETH",
    "exchangeRate": "0.983",
    "addressTo": "0xe072c63c1e04f8c6f36133f6629f66778147d5d8",
    "orderTypeCode": "Pay",
    "orderResourceTypeCode": "Crypto",
    "orderStatusCode": "Wait pay"
  }]
}

Response Parameter Description

Parameter Type Description
orderId String Platform Order ID
cashierId String Cashier ID
orderType int64 Order type, enum values: 1 - Payment
orderTypeCode String Order type description
orderResourceType int64 Business type, enum values: 1 - Crypto order
orderResourceTypeCode String Business type description
userId String User ID who initiated the order
orderTime int64 Order creation time (timestamp)
externalOrderId String Merchant Order ID
orderAmount String Order amount
currencyType String Fiat currency type (e.g., USD)
tokenType String Cryptocurrency type (e.g., USDT)
chainType String Blockchain type (e.g., ETH)
exchangeRate String Exchange rate at the time the order was created
addressTo String Payment address (platform-generated receiving address)
orderStatusCode String Status code description
orderStatus int64 Status code, enum values: 1, 2, 4, 8, 16 (see details below)

Order Status Code Description

Status Code Status Description Is Final State Explanation
1 Waiting for Payment No The order has been created, and the user has not yet paid. No action needed.
2 On-chain Confirmation No The user clicked "Payment Completed", and the system is checking if the payment has been received on the blockchain. No action needed.
4 Completed Yes Payment successful. The system will trigger a callback. The merchant should adjust balances or complete delivery according to business logic.
8 Payment Amount Mismatch Yes The user's payment amount ≠ the expected amount. The system will trigger a callback. It is recommended to record the actual paid amount.
16 Payment Timeout Yes The user’s payment has timed out. The system will not callback. The merchant should manually process if payment has been received.
32 Not Paid (Address Released) Yes The user has not paid for a long time, and the address is released. If paid later, a new order will be created.

# Inquiry for Transfer Orders

API Description

The merchant can use this API to query the details of a specific on-chain transfer order, including order status, amount, fees, and on-chain transaction hash.

Request Method

POST

Request URL

/api/v3/wallet/query/transfer

Request Header

Content-Type: application/json;charset=utf-8
Parameter Description Example Value
access_key Obtained from the merchant backend pFqV75X3
timestamp Unix timestamp (13 digits) 1679724896223
nonce UUID V4 794c26b0-d33c-4394-b2bb-c485eca16d9e
sign HMAC-SHA1 signature kAXyh+eerqrefyaF8dyFB0M4FVo=

Request Parameters (JSON)

{
  "externalOrderId": "622257420681202921",
  "orderId": "OCRYPDRAW202307310902401690794160841DOCKER020000000200001109"
}

Parameter Description

Parameter Type Description Required
externalOrderId String(64) Merchant Order ID Yes
orderId String Platform Order ID Yes

Response Type

Header:

Content-Type: application/json;charset=utf-8

Response Example

{
  "code": "200",
  "success": true,
  "msg": "成功",
  "msgEn": "SUCCESS",
  "data": [{
    "orderId": "OCRYPDRAW202307310902401690794160841DOCKER020000000200001109",
    "cashierId": "",
    "orderType": 2,
    "orderResourceType": 1,
    "userId": "1663371399710216194",
    "orderStatus": 1,
    "orderTime": 1690794160000,
    "externalOrderId": "622257420681202921",
    "orderAmount": "1",
    "orderActualAmount": "1.01",
    "orderFee": "0.01",
    "currencyType": "USD",
    "tokenType": "USDT",
    "chainType": "ETH",
    "exchangeRate": "0.983",
    "addressTo": "0xa8666442fA7583F783a169CC9F5449ec660295E8",
    "tradeHash": "0xe9d043c9cbdb96ed7a71c5a0923baabe9e23316b3f1b0a01975bcd6d69b41fa3",
    "orderTypeCode": "Transfer",
    "orderResourceTypeCode": "Crypto",
    "orderStatusCode": "Accepted"
  }]
}

Response Parameter Description

Parameter Type Description
orderId String Platform Order ID
orderType int64 Order type (2 = Transfer)
orderResourceType int64 Business type (1 = Crypto order)
userId String User ID who initiated the order
orderTime int64 Order creation time (timestamp)
externalOrderId String Merchant custom order ID
orderAmount String Order amount (merchant preset)
orderActualAmount String Actual amount deducted (including fees)
orderFee String Platform fee amount
currencyType String Fiat currency type (e.g., USD)
tokenType String Cryptocurrency type (e.g., USDT)
chainType String Blockchain type (e.g., ETH, TRON, BSC)
exchangeRate String Exchange rate used at the time of order creation
addressTo String Transfer target address (user wallet address)
tradeHash String Blockchain transaction hash (can be checked on-chain)
orderTypeCode String Order type description (e.g., Transfer)
orderResourceTypeCode String Business type description (e.g., Crypto)
orderStatusCode String Status code description (e.g., Accepted)
orderStatus int64 Order status code, see the "Status Code Definitions" below

orderStatus Status Code Definitions

Status Code Description Is Final State Explanation
1 Accepted No Order has been submitted, waiting for execution on-chain
2 Completed Yes Transfer successful, confirmed on-chain, check via hash
4 Payment Failed Yes Transfer failed, no retries will be attempted
8 Pending Approval No Waiting for manual review due to risk/control issues
16 Transfer Denied Yes Review denied, order canceled