IPN Callback
Instant Payment Notifications (IPN), or callbacks, are the way we notify you of the transaction status updates. This API will call the merchant url and return mercid, aptransaction id, amount, transaction status, merchant name, billed amount, ap_securehash, transaction id, card issuer, currency code etc if successful.
https://examplemerchantwebsite.eg/callbackHeader
Section titled “Header”| Parameter | Type Value | Description | Value Like |
|---|---|---|---|
| Content-Type required | String | The Content-Type header indicates the media type of the request or response body so the receiver knows how to process the data. | application/json |
Success 200
Section titled “Success 200”| Parameter | Type Value | Description | Value Like |
|---|---|---|---|
| merchant_id required | Numeric | Merchant id of the Merchant in the airpay system | 45 |
| ap_transactionid required | Numeric | airpay transaction reference number | 4324324 |
| amount required | Numeric | Amount with two decimals | 1999.00 |
| transaction_status required | Numeric | Transaction Payment Status 200 - Transaction is success 211 - Transaction is processing 400 - Transaction is failed 401 - Transaction will not register properly 402 - Payment that has not yet been processed 403 - Not received any call back from bank 405 - Transaction has bounced 503 - No records found | 200 |
| merchant_name optional | Varchar | Merchant name | Akkara Industries |
| wallet_balance optional | Numeric | Remaining balance in wallet (only in case of wallet transactions) | 2000.00 |
| surcharge_amount optional | Numeric | Additional charges for particular transaction (sending only if applicable) | 5.00 |
| billed_amount optional | Numeric | Billed amount | 1200.00 |
| terminal_id optional | Numeric | Terminal Id (only in case of POS transactions) | |
| pos_entry_mode optional | Numeric | POS entry mode (only in case of POS transactions) | |
| cc_expiry optional | Numeric | Card Expiry (only in case of POS transactions) | |
| auth_id optional | Numeric ( 6) | Authentication Code In case of sale completion it is required. | |
| token optional | Alphanumeric | Token | |
| carduniquecode optional | Alphanumeric | Card unique code (applicable only for pg,emi,pos,onclick ) | |
| reason optional | Alphanumeric | Reason | |
| transaction_reason optional | Alphanumeric | Transaction reason | |
| card_country optional | Alphanumeric | Card country | |
| conversion_rate optional | Numeric | Conversion rate | |
| message required | Alphanumeric | Response message received from the payment gateway | Transaction success |
| customer_vpa optional | Alphanumeric | VPA will return if channel is upi | |
| ap_SecureHash required | AlphaNumeric | Secure hash generated by airpay If Channel is upi, Hash generated by : crc32(TRANSACTIONID. : .APTRANSACTIONID. : .AMOUNT. : .TRANSACTIONSTATUS. : .MESSAGE. : .MID. : .USERNAME. : . CUSTOMERVPA); Otherwise, Hash generated by : crc32(TRANSACTIONID. : .APTRANSACTIONID. : .AMOUNT. : .TRANSACTIONSTATUS. : .MESSAGE. : .MID. : .USERNAME); | 1490948220 |
| orderid required | Numeric | Merchant order ID (length 1-20) | |
| customvar optional | Alphanumeric | Customvar value received from you | |
| chmod required | Alphanumeric | Payment channel used to make payment ppc - Prepaid card pg - Payment gateway nb - Netbanking pgcc - Credit card pgdc - Debit card cash - Cash emi - EMI rtgs - RTGS upi - UPI btqr - Bharat QR payltr - Pay later va - Virtual account enach - eNACH remit - Remittance wallet - Wallet pos - POS payltr - paylater aloan - Aloan aeps - AEPS | pg |
| bank_name optional | Alphanumeric | Bank name used to do the transaction | |
| card_scheme optional | Alphanumeric | Card Issuer (length 1-50) | |
| customer_name optional | Alphanumeric | Customer Name | |
| customer_email optional | Customer Email customer@example.com (length 6-50) | ||
| customer_phone optional | Numeric | Customer Phone (length 8-15) | |
| currency_code optional | Numeric | Currency Code (length 3) | 356 |
| risk optional | Numeric | Risk Transaction (0 or 1) | |
| transaction_type optional | Numeric | transaction_type Mandate approved, Auth - 310 Sale - 320 Capture - 330 Refund - 340 Chargeback - 350 Reversal - 360 SaleComplete - 370 SaleAdjust - 380 TipAdjust - 390 Sale+Cash - 400 Cashback - 410 Void - 420 Release - 430 Cashwithdrawal - 440 Awaiting Confirmation - 450 | |
| transaction_payment_status required | Alphanumeric | Transaction Payment Status SUCCESS TRANSACTION IN PROCESS FAILED DROPPED CANCEL INCOMPLETE BOUNCED NO RECORDS | SUCCESS |
| card_number optional | Chars | Masked card number (length 12-19) | |
| card_type optional | Alphanumeric | Card type (length 5) | |
| emi_tenure optional | Numeric | EMI Tenure (length 2) 3 Months - 3 6 Months - 6 9 Months - 9 12 Months - 12 18 Months - 18 24 Months - 24 | |
| transaction_time optional | Alphanumeric | Transaction datetime d-m-Y H:i:s (length 11) |
Success Response
Section titled “Success Response”IPN Callback Response { "merchant_id": 45, "ap_transactionid": 4324324, "amount": 1999.00, "transaction_status": 200, "message": "Success", "ap_SecureHash": , "orderid": "ORDER123", "customvar": , "chmod": "pg", "bank_name": "AXIS BANK"", "customer_name": "John", "customer_email": "customer@example.com", "customer_phone": 9898989989898, "currency_code": 356, "risk": "0", "transaction_type": 310, "transaction_payment_status": "Authorize", "card_number": 989 ***** 999, "card_type": "cc", "transaction_time": "12-12-2023 10:10:12", "merchant_name": "Akkara Industries", "wallet_balance": 2000.00, "surcharge_amount": 5.00, "billed_amount": 1200.00, "rrn": 016153570198200, "token": "4efaf21c79864ec154babfc494f45fd1f65a570805084965", "card_unique_code": "c237b1ba20f5f6cbe32f47e6db1d1d53", "reason": "Fund", "card_country": "IND", "conversion_rate": 3.68 }