Skip to content
Beta · The spec may still change before general availability. The API domain api.hensa.example is a placeholder. See changes →

Errors

Every error has the same shape:

{
"error": {
"code": "no_active_bank_account",
"message": "Link a bank account before creating payment requests.",
"request_id": "req_01JD7QF0X2C4M8R6T1Y3W5Z7NB"
}
}
  • code is a stable contract – build your logic on it.
  • message is for humans and may change – don’t compare strings.
  • request_id – include it when contacting support so Hensa finds the exact request.
CodeHTTPMeaning
validation_error400Invalid request data – see message.
unauthorized401Missing or invalid API key.
forbidden403The key lacks permission for this action.
test_mode_only403Only available with hk_test_ keys.
not_found404Not found (or not owned by this key's store).
idempotency_conflict409Same Idempotency-Key with a different body.
already_reconciled409The transaction is already reconciled.
no_active_bank_account422The store has no active bank account.
merchant_name_required422The store has no name yet – set it in the Dashboard before creating QR codes (live mode only).
plan_limit422The current plan's limit is reached.
url_not_https422Webhook URLs must use HTTPS.
url_private_address422The URL resolves to a private address – not allowed.
delivery_too_old422Only events from the last 30 days can be redelivered.
rate_limited429Too many requests – wait for the Retry-After header.
internal_error500Hensa-side error – retry later (safe with Idempotency-Key).
HTTP Retry?
400, 401, 403, 404, 422 No – fix the request
409 idempotency_conflict Only if the first request is still in progress; not if the body differs
429 Yes – wait for the Retry-After header
5xx, network error, timeout Yes – with the same Idempotency-Key, exponential backoff