You will get payment status in your Callback url automatically.
**Response: SUCCESS (200 OK)**
{
"id": "350c65a3-d1c6-46ad-8897-393a5cc9e302",
"transactionId": "33806876-2190502009-4709",
"status": success,
"amount": 1830.39,
"currency":"INR",
}
You can also check payment status with api below
Initiates a new payment transaction.
{{base_url}}
/api/check-payment-status
Parameter | Type | Details |
---|---|---|
transactionId | string | Received Transaction ID |
Expected statuses are 'INITIATED', 'SUCCESS', 'PENDING', 'HOLD'.
Request Example (guzzle)
<?php
require_once('vendor/autoload.php');
// Instantiate Guzzle HTTP client
$client = new GuzzleHttp\Client();
// Define API URL
$api_url = {{base_url}}'api/check-payment-status';
// Define success and cancel URLs
// Prepare POST request parameters
$post_data = [
'form_params' => [
'transactionId' => '215774396343',
]
];
// Send POST request
$response = $client->post($api_url, $post_data);
// Handle response as needed
echo $response->getBody();
?>
**Response: SUCCESS (200 OK)**
{
"transactionId": "25077802-3519003448-5111",
"amount": "18.60",
"currency": "USD",
"status": "SUCCESS",
}
**Response: ERROR (422 FAILED)**
{
"code": "422",
"status": "error",
"message": {
"fieldName:["error message"]"
},
}