> For the complete documentation index, see [llms.txt](https://docs.digit.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.digit.org/complaints-management/deploy/configure/notifications/error-codes.md).

# Error Codes

novu-bridge error codes

## Overview

Every `NB_*` code the bridge emits. Machine-readable twin: `backend/novu-bridge/src/main/resources/contract/error-codes.txt` — add a new code to both.

## Details

**Where a code surfaces**

<table><thead><tr><th width="129.05078125">Surface</th><th>What it is</th></tr></thead><tbody><tr><td>ledger</td><td><code>last_error_code</code> on an <code>nb_dispatch_log</code> row, shown on Configurator → Notifications → <strong>Logs</strong></td></tr><tr><td>DLQ</td><td>A message on <code>novu-bridge.dlq</code>: <code>{event, sourceTopic, errorCode, errorMessage}</code>; only events that throw</td></tr><tr><td>HTTP</td><td>An error response from a <code>/novu-adapter/v1</code> endpoint</td></tr></tbody></table>

A `SKIPPED` outcome writes a row and never DLQs. A rejection writes a `REJECTED` row **and** DLQs. `NB_INVALID_CORE_SMS`, `NB_CONFIG_UNAVAILABLE` and `NB_RESOLUTION_INCOMPLETE` DLQ with no row of their own — except `NB_CONFIG_UNAVAILABLE` for a phone's country code, which is a `FAILED` row first (delivery failures). **Retryable**: *no* = the same input fails again; *config* = fix configuration, then replay the DLQ; *yes* = transient.

### Envelope rejections (`REJECTED`, then DLQ)

| Code                            | Meaning                                                                                                                                                                                           | Retryable   | Action                                                                                                         |
| ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------- | -------------------------------------------------------------------------------------------------------------- |
| `NB_INVALID_EVENT`              | Missing/blank `eventId`, `eventType`, `eventName`, `tenantId`, `channel`, `subscriberId` or `renderedBody` (named in the message), or null payload. HTTP 400 on `/dispatch/*`                     | no          | Fix the producer against `envelope-v1.schema.json`                                                             |
| `NB_UNSUPPORTED_SCHEMA_VERSION` | `schemaVersion` present and not `1` (both kinds)                                                                                                                                                  | no          | Upgrade the bridge or pin the producer to 1                                                                    |
| `NB_UNSUPPORTED_EVENT_TYPE`     | `eventType` not in `novu.bridge.event.types` (both kinds)                                                                                                                                         | config      | Add it to `NOVU_BRIDGE_EVENT_TYPES`, restart, replay                                                           |
| `NB_INVALID_CORE_SMS`           | A core `SMSRequest` without phone or text, or without tenant while `NOVU_BRIDGE_CORE_SMS_DEFAULT_TENANT` is blank. **DLQ only, no row**; the DLQ copy has no text and a masked phone (outputs.md) | no / config | Discard (it cannot be replayed; the user asks again). Missing tenant: set the default tenant for the next ones |

### Thin-event rejections (`REJECTED`, channel `NONE`, then DLQ)

| Code                        | Meaning                                                                                                            | Retryable | Action                                               |
| --------------------------- | ------------------------------------------------------------------------------------------------------------------ | --------- | ---------------------------------------------------- |
| `NB_INVALID_THIN_EVENT`     | Missing/blank `kind`, `eventId`, `eventType`, `module`, `eventName` or `tenantId`; `kind` not `THIN`; null payload | no        | Fix the producer against `thin-event-v1.schema.json` |
| `NB_EVENT_NOT_IN_CATALOGUE` | `eventName` has no active `NOTIFICATIONS.EventCatalogue` row                                                       | config    | Add the catalogue row, replay                        |

### Thin-event failures (DLQ only, no row)

These write **no** dispatch-log row for the event: it goes to `novu-bridge.dlq` only, so the Logs screen does not show it — read the DLQ (kafka-events.md).

| Code                       | Meaning                                                                                                   | Retryable | Action                                                                                                |
| -------------------------- | --------------------------------------------------------------------------------------------------------- | --------- | ----------------------------------------------------------------------------------------------------- |
| `NB_CONFIG_UNAVAILABLE`    | A notification master could not be read from MDMS and no cached copy exists; nothing was sent             | yes       | Replay from the DLQ once MDMS is reachable                                                            |
| `NB_RESOLUTION_INCOMPLETE` | A user lookup or a per-recipient send failed; every other recipient was delivered (and keeps its own row) | yes       | Replay from the DLQ once the cause is fixed; recipients already `SENT`/`DELIVERED` are not sent again |

### Delivery gates (`SKIPPED`)

| Code                       | Meaning                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | Retryable | Action                                                                                                                                                                                                               |
| -------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `NB_PREFERENCE_DENIED`     | Recipient has not consented to the channel. A preference-service outage allows delivery by default (`NOVU_BRIDGE_PREFERENCE_FAIL_OPEN`)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     | no        | None — consent working                                                                                                                                                                                               |
| `NB_UNSUPPORTED_CHANNEL`   | Envelope `channel` is not SMS, WHATSAPP or EMAIL                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | no        | Fix the producer                                                                                                                                                                                                     |
| `NB_NO_PROVIDER`           | Channel not enabled for the tenant: it has channel rows and none enables this channel (a missing row is off), or it has no rows and the channel is not in `novu.bridge.channels.enabled`. Also a startup warning                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | config    | Notifications → **Channels**: switch it on, select a provider                                                                                                                                                        |
| `NB_CONTACT_MISSING`       | EMAIL without an address, SMS/WHATSAPP without a phone; on the thin path, per resolved recipient                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            | no        | Fix the recipient record, the producer, or the routing channel                                                                                                                                                       |
| `NB_CONTACT_INVALID`       | SMS/WHATSAPP phone that is national (no `+` / `00`) and no country code is known to complete it: not from the user record, not from the tenant's `common-masters.MobileNumberValidation` rule (read at the tenant, then its state root), and `NOVU_BRIDGE_CORE_SMS_COUNTRY_CODE` is blank. Never sent as `+` + the national number                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | config    | Add the tenant's mobile rule (Configurator → Mobile Number Validation; workspaces get it at signup), or set `NOVU_BRIDGE_CORE_SMS_COUNTRY_CODE`; replay is not needed, the next message goes out                     |
| `NB_TEMPLATE_NOT_APPROVED` | WHATSAPP message with no approved `templateId`                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              | config    | Providers → **Sync WhatsApp templates**, save on **Provider Templates (WhatsApp)**                                                                                                                                   |
| `NB_PROVIDER_UNAVAILABLE`  | The channel's selected provider is missing, disabled or on another channel (SMS and WhatsApp share Novu's `sms` channel, so a Twilio SMS provider selected for WhatsApp, an SMS-only gateway included, or a Twilio WhatsApp one selected for SMS, is on another channel); or it is SMSCountry, Ozeki or Jasmin while `NOVU_BRIDGE_DIGIT_WORKER_PROVIDERS=false` (the Novu worker does not load DIGIT's providers); or, for a channel with no provider selected: Novu has **no active integration that delivers the channel** at all (whatever the flag — Novu would accept the trigger and fail the job with "Subscriber does not have an active integration"; an integration whose catalog type delivers another channel, such as Twilio WhatsApp for SMS, does not count), or Novu's default for it (its primary integration, or every active one when none is primary, or the one `NOVU_BRIDGE_INTEGRATION_ID_WHATSAPP` names) is one of those three under the same flag | config    | Re-enable it or select another on **Channels**; with no provider at all, add one on **Providers** and select it; for the worker case, select a Twilio provider or mount the providers into the worker (providers.md) |

### Resolution decisions (`SKIPPED`, thin path only)

Channel `NONE`, `recipient_value` `none`, `transaction_id` `<seed>:NONE` — except `NB_NO_TEMPLATE`, which names the real channel. Never DLQ'd.

| Code                          | Meaning                                                                              | Action                                                                |
| ----------------------------- | ------------------------------------------------------------------------------------ | --------------------------------------------------------------------- |
| `NB_NO_ROUTING`               | No active routing row for the `eventName`                                            | Add routing on **Routing** / **Configure**                            |
| `NB_NO_RECIPIENTS`            | Every audience resolved to nobody                                                    | Check role holders in the tenant, or that the producer sent the actor |
| `NB_UNKNOWN_AUDIENCE_SCHEME`  | Audience scheme with no resolver                                                     | Fix the routing row                                                   |
| `NB_RECIPIENT_LIMIT_EXCEEDED` | Fan-out over `novu.bridge.notifications.recipient.cap` (1000); **nothing** delivered | Check role assignment; raise the cap deliberately                     |
| `NB_NO_TEMPLATE`              | No template for `(eventName, audience, channel, locale)` nor the default locale      | Add it on **Templates**                                               |

### Delivery failures (`FAILED`)

| Code                            | Meaning                                                                                                                                                                                                                                                                                                                                                                                            | Retryable    | Action                                                                                                                                                                                     |
| ------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `NB_NOVU_TRIGGER_FAILED`        | Novu trigger failed or answered non-2xx (DLQ when thrown)                                                                                                                                                                                                                                                                                                                                          | yes          | Check Novu and `NOVU_API_KEY`; replay                                                                                                                                                      |
| `NB_DELIVERY_ERROR`             | A provider threw an unexpected exception (also DLQ)                                                                                                                                                                                                                                                                                                                                                | yes          | Read `last_error_message`                                                                                                                                                                  |
| `NB_CONFIG_UNAVAILABLE`         | SMS/WHATSAPP phone that is national, and the tenant's `common-masters.MobileNumberValidation` rule could not be read from MDMS with no earlier answer to fall back on. A failed read is never taken as "no rule", so `NOVU_BRIDGE_CORE_SMS_COUNTRY_CODE` (possibly another country's) is not used. Nothing was sent; also DLQ (a thin event's as `NB_RESOLUTION_INCOMPLETE`, a login OTP redacted) | yes          | Replay once MDMS answers; a login OTP cannot be replayed, the user asks again                                                                                                              |
| `NB_SMSCOUNTRY_UNREACHABLE`     | Legacy direct route (`novu.bridge.sms.provider=smscountry`): SMSCountry bulk API unreachable                                                                                                                                                                                                                                                                                                       | yes          | Check egress and `novu.bridge.smscountry.url`                                                                                                                                              |
| `NB_SMSCOUNTRY_REJECTED`        | Legacy direct route: SMSCountry answered anything but `OK:<jobid>`                                                                                                                                                                                                                                                                                                                                 | no / config  | Usually credentials, sender id or (India) DLT template; the gateway's reply is in the bridge log (by the masked txn quoted in `last_error_message`), redacted, not in `last_error_message` |
| `NB_PROCESSING_ERROR`           | Uncoded failure caught by the consumer. DLQ only                                                                                                                                                                                                                                                                                                                                                   | yes          | Bridge log has the stack trace                                                                                                                                                             |
| `NB_PROVIDER_FAILED`            | A receipt reported final failure (`UNDELIV`, `REJECTD`, `EXPIRED`, `failed`, `…error…`)                                                                                                                                                                                                                                                                                                            | no           | `last_error_message` holds the provider's word                                                                                                                                             |
| `NB_PROVIDER_BOUNCED`           | A receipt reported a bounce (status `BOUNCED`)                                                                                                                                                                                                                                                                                                                                                     | no           | Correct the address                                                                                                                                                                        |
| `NB_TENANT_ACCOUNT_UNAVAILABLE` | The tenant's root has its own Novu organization (tenant-accounts.md) but its row could not be read or its stored key does not decrypt (wrong `NOVU_BRIDGE_TENANT_KEY_ENCRYPTION_KEY`). Fails closed: never sent through the shared account. Also DLQ                                                                                                                                               | yes / config | Check the bridge database and the encryption key (and `..._PREVIOUS` during a rotation); replay                                                                                            |

### Provider management (HTTP only)

Body: `{"ResponseInfo": …, "Errors": [{"code", "message"}]}`.

<table><thead><tr><th width="160.953125">Code</th><th width="136.32421875">HTTP</th><th>Meaning / action</th></tr></thead><tbody><tr><td><code>NB_INVALID_PROVIDER</code></td><td>400</td><td>Missing <code>id</code> / <code>providerId</code>, empty <code>_update</code>, a required credential missing (see <code>GET /providers/catalog</code>), a catalog-form <code>identifier</code> that does not start with <code>&#x3C;type>-</code>, no <code>tenantId</code> on <code>_delete</code> / <code>_update</code> with <code>active: false</code>, or a credential rotation on an integration whose Novu provider is not its type's (an SMSCountry / Ozeki provider made as <code>generic-sms</code> before they became native): add a new provider, select it, delete the old one</td></tr><tr><td><code>NB_UNKNOWN_PROVIDER_TYPE</code></td><td>400</td><td><code>type</code> not one of <code>twilio-sms</code>, <code>twilio-whatsapp</code>, <code>smtp</code>, <code>smscountry</code>, <code>ozeki</code>, <code>jasmin</code>, or an existing integration's type cannot be derived for a rotation — re-create it from the catalog</td></tr><tr><td><code>NB_PROVIDER_TYPE_UNAVAILABLE</code></td><td>400</td><td>Creating, rotating, re-enabling (<code>active: true</code>), testing or checking an SMSCountry, Ozeki or Jasmin provider while <code>NOVU_BRIDGE_DIGIT_WORKER_PROVIDERS=false</code>: the Novu worker does not load DIGIT's providers, so Novu would accept it and fail every send. Choose another provider, or mount <code>novu-worker-providers</code> into the worker and set the flag to <code>true</code>. Renaming, disabling and deleting one still work</td></tr><tr><td><code>NB_INVALID_CHANNEL</code></td><td>400</td><td><code>channel</code> blank or not SMS / WHATSAPP / EMAIL</td></tr><tr><td><code>NB_PROVIDER_NOT_FOUND</code></td><td>400</td><td>No integration with that <code>_id</code> / identifier</td></tr><tr><td><code>NB_PROVIDER_UNAVAILABLE</code></td><td>409</td><td><code>test-send</code> refused: nothing could deliver the test, by the check dispatch makes (delivery gates), on a fresh read of the integrations of the account the test goes through (a workspace's own Novu organization, else the shared account; unless a read failed within the cache TTL: then the test is sent unchecked, below). The named integration is disabled or on another channel than the test's (a Twilio SMS integration does not deliver a WhatsApp test, nor a Twilio WhatsApp one an SMS test) (one Novu does not know is <code>NB_PROVIDER_NOT_FOUND</code>); or none is named and Novu has no active integration that delivers the channel, or its default is SMSCountry, Ozeki or Jasmin while <code>NOVU_BRIDGE_DIGIT_WORKER_PROVIDERS=false</code>. Nothing was sent and no row written; the message says what to fix. When Novu's integration list cannot be read, the test is sent unchecked and the 200 carries <code>warning</code></td></tr><tr><td><code>NB_PROVIDER_IN_USE</code></td><td>409</td><td>Delete or disable refused: a channel still selects it (by identifier or Novu <code>_id</code>) — select another first. Or it is the integration <code>NOVU_BRIDGE_INTEGRATION_ID_WHATSAPP</code> names while an enabled WhatsApp channel selects no provider. Or it is the last active integration of its DIGIT channel (SMS, WhatsApp or Email: a Twilio WhatsApp integration is no substitute for SMS, nor SMS for WhatsApp) while an enabled channel of that kind with no selected provider sends through Novu's default: a legacy row without <code>provider</code>, a state on <code>NOVU_BRIDGE_CHANNELS_ENABLED</code>, or every tenant with the channel policy off — select a provider on those channels, or add and enable another first. Also when a state's channel rows could not be read: nothing changed, retry once MDMS answers</td></tr><tr><td><code>NB_ADMIN_ROLE_REQUIRED</code></td><td>403</td><td>Create / <code>_update</code> / <code>_delete</code> / <code>test-send</code> / <code>/dispatch/_dry-run</code> / <code>/dispatch/_resolve</code> without a role from <code>novu.bridge.proxy.admin.roles</code> held at a state tenant (a city-level admin role does not count)</td></tr><tr><td><code>NB_TENANT_NOT_ALLOWED</code></td><td>403</td><td>A provider call with <code>?tenantId=&#x3C;workspace></code> on a workspace that has its own Novu organization, by a caller holding no admin role at that workspace's root (writes) or without it among its tenants (reads), an owning state's admin included; <code>/logs</code> or <code>/config/source</code> for a tenant that is not the caller's own, nor a city of its state; <code>_delete</code> / disable for a <code>tenantId</code> whose state the caller holds no admin role at; or create / <code>_update</code> / <code>_delete</code> / <code>test-send</code> by an admin whose state does not own the deployment's providers (owners: the state of <code>NOVU_BRIDGE_CORE_SMS_DEFAULT_TENANT</code> plus <code>NOVU_BRIDGE_PROVIDER_ADMIN_TENANTS</code>; with neither set, nobody); or <code>/dispatch/_resolve</code> / <code>_dry-run</code> by an admin of neither the event tenant's state root nor an owning state (<code>_dry-run</code> with <code>send: true</code> needs an owning state)</td></tr><tr><td><code>NB_NO_TWILIO_INTEGRATION</code></td><td>400</td><td>Template sync found no Twilio integration with credentials</td></tr><tr><td><code>NB_TWILIO_CONTENT_FETCH_FAILED</code></td><td>400</td><td>Twilio ContentAndApprovals call failed; check credentials and egress (retryable)</td></tr><tr><td><code>NB_TWILIO_CONTENT_VARS_SERIALIZE</code></td><td>400</td><td><code>contentVariables</code> values must be plain scalars</td></tr><tr><td><code>NB_NOVU_INTEGRATIONS_FAILED</code></td><td>400 / 502</td><td>Listing Novu integrations failed; check Novu and the API key</td></tr><tr><td><code>NB_NOVU_INTEGRATION_CREATE_FAILED</code> / <code>NB_NOVU_INTEGRATION_UPDATE_FAILED</code> / <code>NB_NOVU_INTEGRATION_DELETE_FAILED</code></td><td>400</td><td>Novu refused; read the message (e.g. SMTP port must be text)</td></tr><tr><td><code>NB_NOVU_WORKFLOWS_FAILED</code></td><td>400</td><td>Listing Novu workflows failed</td></tr><tr><td><code>NB_TENANT_MISMATCH</code></td><td>400</td><td><code>_delete</code> / disable / <code>test-send</code> on a workspace's own organization with a body <code>tenantId</code> of another root (a test's ledger row would land in that tenant's Logs)</td></tr><tr><td><code>NB_TENANT_ACCOUNT_UNAVAILABLE</code></td><td>503</td><td>A provider write let through for a workspace's own organization, when by the time the controller acts the workspace no longer reads as having one (it is being deprovisioned, or the read failed). Nothing changed, and the shared account was not used; retry</td></tr></tbody></table>

### Tenant accounts and `messages/_send` (HTTP only, internal)

The internal APIs of tenant-accounts.md: `/tenants/**` and `POST /messages/_send`, header `X-Novu-Bridge-Token`. Body: `{"Errors": [{"code", "message"}]}`.

<table><thead><tr><th width="202.703125">Code</th><th width="91.44140625">HTTP</th><th>Meaning / action</th></tr></thead><tbody><tr><td><code>NB_INTERNAL_API_DISABLED</code></td><td>403</td><td>The token for this API is not configured (<code>NOVU_BRIDGE_INTERNAL_ADMIN_TOKEN</code> / <code>_SEND_TOKEN</code>), so the API is off</td></tr><tr><td><code>NB_INTERNAL_TOKEN_REQUIRED</code> / <code>NB_INTERNAL_TOKEN_INVALID</code></td><td>401</td><td>No <code>X-Novu-Bridge-Token</code>, or not this API's token (the send token opens only <code>_send</code> and <code>GET /tenants/{tenant}</code>)</td></tr><tr><td><code>NB_TENANT_ACCOUNTS_DISABLED</code></td><td>409</td><td>Provision or deprovision while <code>NOVU_BRIDGE_TENANT_ACCOUNTS_ENABLED</code> is false</td></tr><tr><td><code>NB_TENANT_ACCOUNTS_MISCONFIGURED</code></td><td>503</td><td>No Novu admin login, or an encryption key shorter than 32 characters</td></tr><tr><td><code>NB_INVALID_TENANT</code></td><td>400</td><td><code>tenantId</code> is not a tenant code (lower-case letters, digits, <code>-</code>, <code>_</code>; a dotted id means its root)</td></tr><tr><td><code>NB_PROVISIONING_IN_PROGRESS</code></td><td>409</td><td>Another request holds the tenant's lease (2 min), on this replica or another; or this request's lease ran out before it finished and another request took the tenant over, so nothing more was written. Retry shortly</td></tr><tr><td><code>NB_PROVISIONING_FAILED</code> / <code>NB_DEPROVISIONING_FAILED</code></td><td>500 / 502</td><td>Unexpected failure; the row keeps <code>last_error_code</code> / <code>last_error_message</code>. Retry: provision is idempotent</td></tr><tr><td><code>NB_NOVU_PLATFORM_LOGIN_FAILED</code></td><td>502</td><td>Novu refused the platform admin login: check <code>NOVU_BRIDGE_NOVU_ADMIN_EMAIL</code> / <code>_PASSWORD</code> (the deploy's <code>novu_admin_password</code> in OpenBao)</td></tr><tr><td><code>NB_NOVU_PLATFORM_FAILED</code></td><td>502</td><td>Novu refused or misanswered an organization, environment or key call; read the message</td></tr><tr><td><code>NB_NOVU_WORKFLOW_CREATE_FAILED</code></td><td>502</td><td>Novu refused a workflow in the tenant's organization; retry the provision</td></tr><tr><td><code>NB_NOVU_UNAVAILABLE</code></td><td>503</td><td>Novu could not be reached (provision, status, <code>_send</code>)</td></tr><tr><td><code>NB_NOVU_NOTIFICATIONS_FAILED</code></td><td>—</td><td>Reading a send's job state failed; <code>_send</code> then answers <code>202 QUEUED</code>, never an error</td></tr><tr><td><code>NB_TENANT_NOT_PROVISIONED</code></td><td>409 (404 on <code>_deprovision</code>)</td><td>The tenant's root has no organization of its own. On <code>_send</code>, the BFF maps it to <code>OTP_CHANNEL_UNAVAILABLE</code></td></tr><tr><td><code>NB_NO_PROVIDER_FOR_CHANNEL</code></td><td>422</td><td><code>_send</code>: the tenant has an organization but no usable provider carries the channel (the selected one is missing, disabled or the wrong channel, or none is active). The BFF maps it to <code>OTP_CHANNEL_UNAVAILABLE</code></td></tr><tr><td><code>NB_PROVIDER_FAILED</code></td><td>502</td><td><code>_send</code>: Novu ran the send and the provider refused it; the message carries Novu's short reason, masked</td></tr><tr><td><code>NB_NOVU_TRIGGER_FAILED</code></td><td>502</td><td><code>_send</code>: Novu refused the trigger</td></tr><tr><td><code>NB_INVALID_REQUEST</code> / <code>NB_UNKNOWN_TEMPLATE</code></td><td>400</td><td><code>_send</code> body malformed (channel, E.164 recipient: a national number is refused, never completed with a country code, 4-12 character code, an expiry within 24 h), or a <code>templateKey</code> other than <code>OTP</code></td></tr></tbody></table>

### Contract documents (HTTP only)

<table><thead><tr><th width="232.2578125">Code</th><th width="138.84375">HTTP</th><th>Meaning / action</th></tr></thead><tbody><tr><td><code>NB_CONTRACT_NOT_PACKAGED</code></td><td>404</td><td>The jar was built without <code>src/main/resources/contract/</code> — rebuild the image</td></tr><tr><td><code>NB_CONTRACT_UNREADABLE</code></td><td>500</td><td>Packaged document unreadable — rebuild the image</td></tr></tbody></table>

### Not an `NB_*` code

Refusals from `ProxyAuthFilter`, body `{"error": "..."}`:

| Response                                     | Meaning                                                                              |
| -------------------------------------------- | ------------------------------------------------------------------------------------ |
| `401 missing bearer token` / `invalid token` | No `Authorization: Bearer`, or egov-user did not resolve it                          |
| `403 insufficient role`                      | Not an `EMPLOYEE`, or no role from `novu.bridge.proxy.allowed.roles` / `admin.roles` |

`/receipts/{provider}` answers `401 bad receipt secret`, or `403` when `novu.bridge.receipts.secret` is blank.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.digit.org/complaints-management/deploy/configure/notifications/error-codes.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
