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

Exchange rate

POST
/api/payment-gateway/v1/exchange-rate
With the Exchange rate API you can fetch the latest exchange rate from ABA bank, the exchange rates are exactly like the prices you will find on https://www.ababank.com/en/forex-exchange

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 which provided by ABA Bank.
hash
string 
required
Base64 encode of hash hmac sha512 encryption of concatenates values req_time, and merchant_id with public_key.
Example
{
    "req_time": "20250212104216",
    "merchant_id": "ec000002",
    "hash": "2P+5NrSb5g2XyITaxttsnjW...JVKguqghoQrq4y4C3tbUiA=="
}

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/exchange-rate' \
--header 'Content-Type: application/json' \
--data-raw '{
    "req_time": "20250212104216",
    "merchant_id": "ec000002",
    "hash": "2P+5NrSb5g2XyITaxttsnjW...JVKguqghoQrq4y4C3tbUiA=="
}'

Responses

🟢200OK
application/json
Body
status
object 
required
code
string 
required
00 : Success
1 : Wrong hash
26 : Invalid merchant profile
message
string 
required
Please see the property reponse code for the details.
exchange_rates
object 
required
aud
object 
required
Australia dollar
sgd
object 
required
Singapore dollar
eur
object 
required
Euro
sell
string 
required
Sell rate
buy
string 
required
Buy rate
gbp
object 
required
Pound sterling
sell
string 
required
Sell rate
buy
string 
required
Buy rate
myr
object 
required
Malaysian Ringgit
sell
string 
required
Sell rate
buy
string 
required
Buy rate
thb
object 
required
Thai Baht
sell
string 
required
Sell rate
buy
string 
required
Buy rate
hkd
object 
required
Hong Kong Dollar
sell
string 
required
Sell rate
buy
string 
required
Buy rate
cny
object 
required
Chinese Yuan
sell
string 
required
Sell rate
buy
string 
required
Buy rate
cad
object 
required
Canadian Dollar
sell
string 
required
Sell rate
buy
string 
required
Buy rate
krw
object 
required
South Korean won
sell
string 
required
Sell rate
buy
string 
required
Buy rate
jpy
object 
required
Japanese Yen
sell
string 
required
Sell rate
buy
string 
required
Buy rate
vnd
object 
required
Vietnamese dong
sell
string 
required
Sell rate
buy
string 
required
Buy rate
Examples
{
    "status": {
        "code": "00",
        "message": "Success!"
    },
    "exchange_rates": {
        "aud": {
            "sell": "2719.38",
            "buy": "2540.49"
        },
        "sgd": {
            "sell": "3113.18",
            "buy": "2914.72"
        },
        "eur": {
            "sell": "4461.07",
            "buy": "4258.34"
        },
        "gbp": {
            "sell": "5333.51",
            "buy": "5064.89"
        },
        "myr": {
            "sell": "943.65",
            "buy": "839.94"
        },
        "thb": {
            "sell": "122.14",
            "buy": "118.18"
        },
        "hkd": {
            "sell": "531.57",
            "buy": "473.15"
        },
        "cny": {
            "sell": "577.35",
            "buy": "521.23"
        },
        "cad": {
            "sell": "2956.91",
            "buy": "2666.82"
        },
        "krw": {
            "sell": "3.0151",
            "buy": "2.6634"
        },
        "jpy": {
            "sell": "27.1139",
            "buy": "25.0701"
        },
        "vnd": {
            "sell": "0.1631",
            "buy": "0.1509"
        }
    }
}
Previous
Get transaction list
Next
Checkout Plugins