Transaction Query API
You can query your transaction status any time you want. For ticketing systems or product limitations, it will help you to verify the status before releasing resources.
By Session ID
You can check the status of a transaction by the session id.
So, Let's call the API and the example given below
API Endpoint (Sandbox/Test Environment): https://sandbox.sslcommerz.com/validator/api/merchantTransIDvalidationAPI.php
API Endpoint (Live Environment): https://securepay.sslcommerz.com/validator/api/merchantTransIDvalidationAPI.php
Method: GET
API Endpoint (Live Environment): https://securepay.sslcommerz.com/validator/api/merchantTransIDvalidationAPI.php
Method: GET
Request Parameters
| Param Name | Data Type | Description |
|---|---|---|
sessionkey |
string (50) | Mandatory - The session id generated at the time of transaction initiation. |
store_id |
string (30) | Mandatory - Your SSLCOMMERZ Store ID. |
store_passwd |
string (30) | Mandatory - Your SSLCOMMERZ Store Password. |
Returned Parameters
| Param Name | Data Type | Description |
|---|---|---|
status |
string (20) |
Transaction Status.
|
tran_id |
string (30) | Transaction ID (Unique). |
amount |
decimal (10,2) | The total amount. |
Sample Request
$ curl -X GET 'https://sandbox.sslcommerz.com/validator/api/merchantTransIDvalidationAPI.php?sessionkey=C3329C5E252DF44B323D9BAF47ACBCD9&store_id=testbox&store_passwd=qwerty&format=json'