Oleq Payment Gateway API
Error Handling
Common integration issues and how to resolve them.
| Issue | Likely cause | Resolution |
|---|---|---|
| Auth failure | Incorrect AUTH-SQROOL header | Ensure Timestamp and ShortCode in the header match the request body exactly |
| Salt mismatch | Wrong field used for Reference in Salt computation | For B2C, use the Reference field (M-Pesa TransID), not your original reference |
| No callback received | Callback URL unreachable or returning non-200 | Ensure CallbackUrl is a public HTTPS endpoint returning HTTP 200 immediately. Use QUERY to reconcile missed callbacks. |
| Timestamp rejection | Clock drift or wrong format | C2B/B2C use a yyyyMMddHHmmss string; B2B/QUERY use Unix epoch milliseconds. Sync server time with NTP. |
| QUERY returns 203 | Transaction pending or wrong reference | Wait and retry. Verify Reference, BillRefNumber, and TelcoReference match the original submission exactly. |
Best practice: store the checkoutRequestID (C2B) or ConversationID (B2C) from the initial response. Use QUERY as a fallback reconciliation mechanism when callbacks are delayed or missed. Handle all responses idempotently.