Guides
Errors
Failures use real HTTP status codes and one envelope:
JSON
{
"error": {
"type": "validation",
"code": "validation_failed",
"message": "Please correct the highlighted fields.",
"fields": { "recipient.iban": "Invalid IBAN for GB" },
"request_id": "6f0c1e1a-…"
}
}Branch on code. message is for humans and may be reworded; code will not change meaning.
| Status | type | Typical codes |
|---|---|---|
| 400 | invalid_request | idempotency_key_required, malformed_json, missing_parameter, invalid_parameter, invalid_cursor, file_required, url_required, invalid_url, https_required, unknown_event_type, invalid_since |
| 401 | authentication | authentication_required, invalid_api_key |
| 403 | permission | insufficient_scope, ip_not_allowed, subscription_frozen, account_not_verified, forbidden |
| 404 | not_found | payment_not_found, batch_not_found, recipient_not_found, unsupported_country, unknown_template, webhook_endpoint_not_found, delivery_not_found, company_not_found, unknown_endpoint |
| 409 | conflict | idempotency_key_reused, invalid_state, validation_in_progress, price_changed, remittance_not_available, recipient_already_exists, endpoint_already_exists, endpoint_limit_reached, endpoint_disabled, already_delivered |
| 422 | validation | validation_failed, insufficient_balance, batch_has_errors, invalid_template, batch_too_large, wallet_not_found, country_blocked, route_unavailable, fee_bearer_not_offered, amount_too_low, pricing_unavailable |
| 429 | rate_limited | rate_limited, daily_payment_limit_reached |
| 500 | server | internal_error |
| 503 | server | provider_unavailable — the payout provider could not be reached; retry with the same Idempotency-Key |
Two that are worth knowing before you hit them:
404for another company's resource. A payment id that is not yours is reported as not found, never as forbidden — a 403 would confirm the id exists.403 subscription_frozen. A company whose ekash subscription is unpaid can still prepare payments but not release them. Top up the USD wallet and processing resumes automatically.
Pricing errors (422). A payment is priced when you quote it and when you create it. When it cannot be priced the answer is 422 with one of these codes (the sentence in message and the field under fields say what to change; a refused create creates nothing):
code | Meaning | What to change |
|---|---|---|
country_blocked | ekash does not send payments to that country. fields.recipient.country_code | another destination |
route_unavailable | No payout route exists for that country and payout currency yet. fields.recipient.country_code | another payout currency (target_currency) |
fee_bearer_not_offered | That route does not offer the chosen fee_bearer. fields.fees | sender, receiver or shared, whichever the route offers |
amount_too_low | After the fee taken off what the recipient receives, nothing would be left. fields.amount | send more, or pay the fee yourself (fee_bearer sender) |
pricing_unavailable | The price or an exchange rate could not be determined right now. fields.fees | check the currencies; retry |
409 price_changed. See Approve below: the price of the payment moved since it was created and nothing was approved.