Chuyển tới nội dung chính

Truy vấn trạng thái giao dịch

API cho phép Merchant chủ động truy vấn trạng thái giao dịch trên Transfer Service.

  • URL: https://api-transfer.zaloplatforms.com/v1/order/query
  • Method: POST
  • Response Type: application/json

Parameters

TrườngKiểu dữ liệuBắt buộcMô tảYêu cầu
app_idStringtrueID ứng dụng merchant đăng ký với Transfer ServicePhải là app_id đã đăng ký với Transfer Service
ts_order_idStringtrueMã giao dịch do Transfer Service cấp (trả về khi tạo đơn)Mã hợp lệ, tồn tại trên hệ thống
timestampLongtrueThời điểm tạo request (timestamp)Dùng để validate request
signatureStringtrueThông tin xác thực requestChữ ký dùng để xác thực request. Xem tài liệu

Sample request

{
"app_id": "0752a0528b1762493b06",
"ts_order_id": "9a03a90382466b183257",
"app_time": 0,
"timestamp": 1764041335432,
"signature": "81d0afa7b1c4754d7db7703726159c697cbd74cdeafced0aa8c039854becfac7"
}

Sample response

{
"error_code": 0,
"error_message": "Thành công",
"data": {
"merchant_order_id": "251209_24fbc663-f83",
"ts_order_id": "5e096d1f465aaf04f64b",
"order_time": 1765257674274,
"created_time": 1765257674312,
"expire_time": 1765257974312,
"expire_duration": 5,
"updated_time": 1765257850060,
"amount": 100000,
"description": "1765257674274",
"qr_data": "00020101021238570010A000000727012700069704220113VQRQAAUMJ54040208QRIBFTTA530370454061000005802VN62280107NPS6869081317652576742746304EC5F",
"paid_amount": "0",
"paid_time": 1765257712000,
"transaction_detail": "QAAUMI9446 ZTRANS47 4 59ee13....",
"status": "PAID",
"status_code": 2
}
}

Error codes

Error codeError messageGhi chú
-105Invalid signatureLỗi chữ ký xác thực request
-402Invalid order idMã giao dịch không hợp lệ
-501Invalid application idApplication id không hợp lệ
-510Application not existApplication không tồn tại

Order status

Status codeStatus messageMô tả
1QR_GENERATEDĐang chờ thanh toán
2PAIDĐã thanh toán
3EXPIREDĐã hết hạn chờ thanh toán từ ngân hàng. Merchant tự kiểm tra sao kê tài khoản để biết trạng thái thực tế.