Oleq Payment Gateway API
Transaction Query
Check the status of a previously submitted transaction.
Checks the status of a previously submitted transaction by reference. Use this to poll for a result when a callback has not been received, or to reconcile transactions after the fact.
POST https://{host}/api/paymentRequest fields
| Field | Type | Required | Description |
|---|---|---|---|
Action | string | required | Must be "QUERY" |
Timestamp | number | required | Unix epoch timestamp in milliseconds. e.g. 1779013110951 |
Reference | string | required | Your original transaction reference. e.g. "9E1MH6SIAVZH96KC7VQ4" |
ApiKey | string | required | Your API key for this short code |
CountryCode | string | required | ISO 3166-1 alpha-2 country code. e.g. "KE" |
Operator | string | optional | Mobile operator identifier. e.g. "AIRTEL" |
ShortCode | string | required | Your merchant short code. e.g. "123456" |
BillRefNumber | string | optional | Account/bill reference from the original transaction. e.g. "E2363G237237283122" |
TelcoReference | string | optional | Telco-issued transaction reference. e.g. "SWAAASSSSSDF" |
TrxType | string | required | Original transaction type: "C2B", "B2C", or "B2B" |
Example request
{
"Action": "QUERY",
"Timestamp": 1779013110951,
"Reference": "9E1MH6SIAVZH96KC7VQ4",
"ApiKey": "yflaqbc5k321",
"CountryCode": "KE",
"Operator": "AIRTEL",
"ShortCode": "123456",
"BillRefNumber": "E2363G237237283122",
"TelcoReference": "SWAAASSSSSDF",
"TrxType": "C2B"
}Response — transaction found
{
"status": "200",
"transactionstatus": "SUCCESSFUL",
"BusinessShortCode": "12345",
"TransType": "C2B",
"TelcoReference": "SWAAASSSSSDF",
"TransTime": "200",
"TransAmount": "200",
"BillRefNumber": "E2363G237237283122",
"message": "Request accepted successfully",
"message2": "request completed successfully"
}| Field | Type | Description |
|---|---|---|
status | string | "0" or "200" = record found. Other values indicate lookup failure. |
transactionstatus | string | Final status of the transaction (e.g. SUCCESSFUL, FAILED) |
BusinessShortCode | string | Short code that processed the original transaction |
TransType | string | Echoes the queried transaction type |
TelcoReference | string | Telco confirmation code for the transaction |
TransTime | string | Timestamp at which the transaction was processed |
TransAmount | string | Confirmed transaction amount |
BillRefNumber | string | Account/bill reference associated with the transaction |
message | string | Gateway-level status message |
message2 | string | Additional operator-level status detail |
Response — no record found
{
"status": "203",
"message": "No Records found"
}Provide as many identifiers as available (Reference, BillRefNumber, TelcoReference) to improve lookup accuracy. A 203 status means no matching record was found — this may indicate the transaction is still pending. Wait and retry before concluding a failure.