Decline codes and timeouts

Gateway codes, verify status, and the 120 second timeout.

Most gateway calls return HTTP 200. Read code in the JSON. For verify, also read status. Verify does not use Basic auth. Charge /gateway/ does.

Codes

codeMeaning
601Success. Save sid, mark paid.
603Waiting on phone approval. Poll verify on hosted checkout or e-Wallet API. Don’t charge again. Stop on 601 or 600/604.
604Insufficient balance
600Failed
0Wrong username or API key
"404"Missing or empty fields

Verify

statuscodeMeaning
success601Paid. Fulfill the order.
pending603Still waiting — keep polling verify, don’t charge again
failed600 or 604Declined or insufficient

Map these exact strings in your app or plugin (success / pending / failed). Do not expect failure — verify always returns failed for declines.

Prefer sid. Verify by order_id returns only the most recent payment for that id.

payment_type on verify: EDAHAB, ZAAD (Waafi — not "WAAFI"), PREMIER WALLET, or CARD.

Timeouts

Set the total HTTP timeout to 120 seconds. eDahab can take about a minute. If you time out, verify on hosted checkout or e-Wallet API before charging again.


Did this page help you?