Developer Suite
Register Sandbox
Register Sandbox
  1. Ecommerce Checkout
  • Overview
  • API Endpoints
  • Ecommerce Checkout
    • Purchase
      POST
    • Get a transaction details
      POST
    • Close transaction
      POST
    • Check transaction
      POST
    • Refund API
      POST
    • Get transaction list
      POST
    • Exchange rate
      POST
  • Checkout Plugins
    • Prestashop
    • Woocommerce
  • Credentials on File
    • Link Account
      POST
    • Link Card
      POST
    • Purchase using token
      POST
    • Remove account token
      POST
    • Remove card token
      POST
    • Get linked account details
      POST
  • ABA QR API
    • QR API
      POST
  • Payment Link
    • Create payment link
      POST
    • Get payment link details
      POST
  • Pre-auth
    • Complete pre-auth transactions
      POST
    • Complete pre-auh transaction with payout
      POST
    • Cancel pre-purchase transaction
      POST
  • Payout
    • Payout
    • Update a beneficiary status
    • Add a beneficiary to whitelist
  • KHQR Guideline
  • Resources
  1. Ecommerce Checkout

Get a transaction details

POST
/api/payment-gateway/v1/payments/transaction-detail
This API allows you to retrieve details of a purchase transaction, including its history and related operations, for both online and in-store payments.
🚨
Note: This API does not support real-time payment status checks during payment processing.
You can retrieve details for any past transaction.
Limited to 10 requests per minute. This limit cannot be increased.

Request

Header Params
Content-Type
string 
required
Example:
application/json
Body Params application/json
req_time
string 
required
Request date and time in UTC format as YYYYMMDDHHmmss.
merchant_id
string 
required
A unique merchant key provided by ABA Bank.
<= 20 characters
tran_id
string 
required
The purcahse transaction ID.
<= 20 characters
hash
string 
required
A Base64-encoded HMAC SHA-512 hash generated by concatenating req_time, merchant_id, and tran_id, encrypted using your public_key.
PHP Sample Code
Example
{
    "req_time": "20250213084236",
    "merchant_id": "ec000002",
    "tran_id": "17394277693",
    "hash": "QskVi2gEctW...j7Td6kEi/KLPvGcK3ZiA=="
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/api/payment-gateway/v1/payments/transaction-detail' \
--header 'Content-Type: application/json' \
--data-raw '{
    "req_time": "20250213084236",
    "merchant_id": "ec000002",
    "tran_id": "17394277693",
    "hash": "QskVi2gEctW...j7Td6kEi/KLPvGcK3ZiA=="
}'

Responses

🟢200OK
application/json
Body
data
object 
optional
transaction_id
string 
optional
Purchase id.
payment_status_code
number 
optional
Supported values:
0 - APPROVED, PRE-AUTH
2 - PENDING
3 - DECLINDED
4 - REFUNDED
7 - CANCELLED
payment_status
string 
optional
The transaction status. Possible values:
APPROVED – Payment was completed successfully or captured.
PRE-AUTH – Payment is held under pre-authorization, pending capture.
PENDING – Awaiting completion from the payer.
DECLINED – The payment was declined.
REFUNDED – The payment has been refunded fully or partially.
CANCELLED – The transaction or pre-authorization was cancelled.
original_amount
number 
optional
Original transaction amount before discount.
original_currency
string 
optional
Original transaction currency.
payment_amount
number 
optional
Amount that the customer has paid.
payment_currency
string 
optional
Payment currency that the customer used to pay.
total_amount
number 
optional
Amount that customer suppose to pay after discount.
refund_amount
number 
optional
Total refunded amount.
discount_amount
number 
optional
Discounted amount and its currency follow original curency.
apv
string 
optional
Transaction appoval code.
transaction_date
string 
optional
Created date of the transaction in payment gateway database.
first_name
string 
optional
Payer's first name.
last_name
string 
optional
Payer's last name.
email
string 
optional
Payer's email.
phone
string 
optional
Payer's phone number.
bank_ref
string 
optional
Unique booking entry reference number from ABA Core banking system
payment_type
string 
optional
Payment method that the customer used to make payment. Possible values:
ABA Pay : Transaction made with ABA Account (ABA Mobile)
Alipay : Transaction made with Alipay.
Wechat : Transaction made with WeChat pay.
KHQR : Trnasaction made with KHQR.
VISA : Transaction made with Visa card.
MC : Transacion made with Mastercard.
JCB : Transaction made with JCB card
CUP : Transaction made with UPI card.
payer_account
string 
optional
Masked ABA Account Number or Masked Card PAN. For other payment options, it will be blank.
bank_name
string 
optional
If payment is made with ABA PAY, it will show ABA Bank and if payment made using KHQR it will show issuer bank name.
card_source
string 
optional
Possible values:
ONUS : Transaction is made with ABA bank card.
OFFUS_DOMESTIC : Transaction is made with other local bank card.
OFFUS_INTERNATIONAL : Transaction is made with other international bank card
transaction_operations
array [object {4}] 
optional
History of the payments
status
object 
optional
Examples
{
    "data": {
        "transaction_id": "17394277693",
        "payment_status_code": 0,
        "payment_status": "APPROVED",
        "original_amount": 0.1,
        "original_currency": "USD",
        "payment_amount": 0.1,
        "payment_currency": "USD",
        "total_amount": 0.1,
        "refund_amount": 0,
        "discount_amount": 0,
        "apv": "753786",
        "transaction_date": "2025-02-13 13:55:25",
        "first_name": "test",
        "last_name": "test",
        "email": "test1234@gmail.com",
        "phone": "086720539",
        "bank_ref": "100FT30148462274",
        "payment_type": "ABA Pay",
        "payer_account": "*327",
        "bank_name": "ABA Bank",
        "card_source": "",
        "transaction_operations": [
            {
                "status": "Completed",
                "amount": 0.1,
                "transaction_date": "2025-02-13 13:55:25",
                "bank_ref": "100FT30148462274"
            }
        ]
    },
    "status": {
        "code": "00",
        "message": "Success!",
        "tran_id": "17394277693"
    }
}
Previous
Purchase
Next
Close transaction