This endpoint provides you the ability to confirm the status of a completed transaction from Interswitch.
You should make provision to query transactions.
1 2 |
GET /collections/api/v1/gettransaction.json? merchantcode=<merchantcode>&transactionreference=<transactionreference>&amount=<amount> |
Request Parameters
1 2 3 |
merchantcode: MX187 transactionreference: 933437251484 amount: 66666600 |
1 2 |
https://sandbox.interswitchng.com/collections/api/v1/gettransaction.json? merchantcode=MX187&transactionreference=933437251484&amount=66666600 |
Sample response (Success)
Find below a sample response.
1 2 3 4 5 6 7 8 9 10 11 12 |
{ "Amount": 66666600, "CardNumber": "", "MerchantReference": "933437251484", "PaymentReference": "UBA|API|MX187|25-07-2018|249510|719456", "RetrievalReferenceNumber": "000647661227", "SplitAccounts": [], "TransactionDate": "2018-07-25T06:57:24", "ResponseCode": "00", "ResponseDescription": "Approved by Financial Institution", "AccountNumber": "9999999999" } |
Sample response (Failure)
Find below a sample response.
1 2 3 4 5 6 |
{ "Amount": 0, "SplitAccounts": [], "ResponseCode": "Z1", "ResponseDescription": "Amount Inconsistency" } |
1 2 3 4 5 6 7 |
{ "Amount": 0, "SplitAccounts": [], "TransactionDate": "0001-01-01T00:00:00", "ResponseCode": "Z25", "ResponseDescription": "Transaction not Found" } |
1 2 3 4 5 6 |
{ "Amount": 0, "SplitAccounts": [], "ResponseCode": "20031", "ResponseDescription": "Invalid value for Product id or Merchant Code" } |