Webhook nhận kết quả thanh toán
Merchant thiết lập Webhook để nhận kết quả thanh toán từ Transfer Service. Khi Transfer Service nhận trạng thái thanh toán từ ngân hàng, hệ thống sẽ gọi URL này để thông báo kết quả cho Merchant.
- URL:
https://your-webhookurl.com - Method:
POST - Response Type:
application/json
Request body
Transfer Service gửi body dạng JSON chứa đầy đủ thông tin giao dịch, cấu trúc tương tự response của API truy vấn trạng thái giao dịch. Merchant nên xác thực chữ ký (signature) trước khi xử lý để đảm bảo request đến từ Transfer Service.
Sample callback payload
{
"merchant_order_id": "251125_004904618",
"ts_order_id": "1ea9544268078159d816",
"created_time": 1764056578002,
"order_time": 1764056578002,
"expire_time": 1764057778002,
"updated_time": 1764056609139,
"bank_code": null,
"amount": 50000,
"description": "Nap DT 251125004904618",
"embed_data": "{}",
"qr_data": "0002010102123857....",
"paid_amount": 50000,
"paid_time": 1764056608000,
"transaction_detail": "QAAUMI9446 ZTRANS47 4 59ee13.....",
"status": "PAID",
"status_code": 2,
"signature": "5d592031dba0c9....",
"app_id": "726e9484a8c1419f18d0",
"timestamp": 1764056609169
}