Skip to content

Query UPI ​

POST /v1/api/collection/query_upi

  • Successful responses do not use success/code/data. body.status=1 means found in this merchant’s queryable orders; 2 means not found. This is not beneficiary bank-account validation.

Request fields ​

FieldTypeRequirementDescription
tenant_idstringRequiredMerchant ID; must belong to the same merchant as app_key. Maximum 20 characters.
app_keystringRequiredApplication key, maximum 16 characters; sign using the secret of this exact application.
timestampstring / integerRequiredCurrent Unix timestamp in seconds. Timestamps older than 60 seconds are rejected; do not send milliseconds.
signstringRequired32-character lowercase MD5 calculated using the signature rules.
upistringRequiredUPI to query, maximum 128 characters.

For algorithm details, see signature rules.

Request example · cURL ​

bash
curl --request POST 'https://api.trpay2024.com/v1/api/collection/query_upi' \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "tenant_id": "DEMO0001",
  "app_key": "demo_app_key",
  "timestamp": "1791199800",
  "upi": "demo@upi",
  "sign": "57903d6d8a92ac0e763c9bf98ad0f2f8"
}'

Response example ​

json
{
  "status": "200",
  "timestamp": "2026-10-05 17:00:00",
  "message": "成功",
  "body": {
    "status": 1
  }
}

Response fields ​

FieldTypeRequirementDescription
statusstringRequiredOuter "200" indicates query success.
timestampstringRequiredQuery time.
messagestringRequiredDescription; not a payment result.
body.statusintegerRequired1 found; 2 not found.

Error handling ​

See HTTP handling, request errors and error codes.

OpenAPI v1 · Merchant integration