API Reference

This API will furnish comprehensive information about a particular transaction.

By utilizing this API, you can access all the pertinent information regarding a transaction. Merchant Transaction ID can be used to search for the specific transaction details.

🚧

Sandbox Environment

All operations conducted in this environment are considered as trial transaction.

Store ID : aamarpaytest

Signature Key : dbb74894e82415a2f7ff0ec3a97e4183

Live Environment

All operations conducted in this environment are considered as Real transaction.

Store ID : Your Strore ID

Signature Key : Your Signature Key

ℹ️

Obtain Live Credentials

For acquiring the necessary live credentials to process payments, please don't hesitate to contact our Support Team at [email protected]. They are readily available to guide you throughout the procedure and provide the essential credentials to facilitate live payment transactions on your platform.

Request Parameters

PropertyRequirementTypeDescription
request_idMandatoryStringYour unique identifier for merchant transactions, often referred to as the merchant transaction ID. (Example: WEP-SMZZ4ZM8EC)
store_idMandatoryStringYou need to provide the merchant ID assigned by aamarPay, which serves as your unique identifier. (Example: aamarpay)
signature_keyMandatoryStringYou will need to provide the Signature Key issued by aamarPay, which serves as a unique authentication key. (Example: 28c78XXXXXXXXXXXXXXX4645e)
typeMandatoryStringThe value of this parameter is always "json".

Sample Request

<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://sandbox.aamarpay.com/api/v1/trxcheck/request.php?request_id=XXXXXX&store_id=XXXXXX&signature_key=XXXXXX&type=json',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
  CURLOPT_HTTPHEADER => ''
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
import requests

url = "https://sandbox.aamarpay.com/api/v1/trxcheck/request.php?request_id=XXXXXX&store_id=XXXXXX&signature_key=XXXXXX&type=json"

payload = {}
headers = {}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)

Sample Response


👩‍💻

Check The "status_code" field and "amount" field

{
  "pg_txnid": "AAMXXXXXXXXXXXX",
  "mer_txnid": "XXXXXXXXXX",
  "risk_title": "Not-Available",
  "risk_level": null,
  "cus_name": "Mr. ABC",
  "cus_email": "[email protected]",
  "cus_phone": "010000000",
  "cus_add1": "Dhaka",
  "cus_add2": "Dhaka",
  "cus_city": "Dhaka",
  "cus_state": "Dhaka",
  "cus_postcode": "1206",
  "cus_country": "Bangladesh",
  "cus_fax": "010000000",
  "ship_name": null,
  "ship_add1": null,
  "ship_add2": null,
  "ship_city": null,
  "ship_state": null,
  "ship_postcode": null,
  "ship_country": null,
  "desc": null,
  "merchant_id": "XXXXXXX",
  "store_id": "XXXXXXX",
  "amount": "10.00",
  "amount_bdt": "10.00",
  "pay_status": "Successful",
  "status_code": "2",
  "status_title": "Successful Transaction",
  "cardnumber": "XXXXXXXXXXXXXXX",
  "approval_code": "XXXXXXXXXXX",
  "payment_processor": "XXXXXXXXXX",
  "bank_trxid": "XXXXXXXXXXXXX",
  "payment_type": "XXXXXXXXX",
  "error_code": "0000",
  "error_title": "Not-Available",
  "bin_country": "Not-Available",
  "bin_issuer": "Not-Available",
  "bin_cardtype": "Not-Available",
  "bin_cardcategory": "Not-Available",
  "date": "2018-03-17 15:20:55",
  "date_processed": "2018-03-17 15:55:35",
  "amount_currency": "10.00",
  "rec_amount": "9.65",
  "processing_ratio": "3.50",
  "processing_charge": "0.35",
  "ip": "XXXXXXXXXXX",
  "currency": "BDT",
  "currency_merchant": "BDT",
  "convertion_rate": "Not-Available",
  "opt_a": "Not-Available",
  "opt_b": "Not-Available",
  "opt_c": "Not-Available",
  "opt_d": "Not-Available",
  "verify_status": "PENDING",
  "call_type": "Post-Method",
  "email_send": "1",
  "doc_recived": "NO",
  "checkout_status": "Not-Paid-Yet"
}