> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trynito.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Error format

> The API error envelope.

```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
{
  "error": {
    "message": "human-readable description",
    "code": "invalid_request",
    "param": "model"
  }
}
```

| Field | Notes |
| - | - |
| `message` | Human-readable description. |
| `code` | The error family. Branch on this. |
| `param` | Optional. The request field the error refers to. |

Errors carry a `code`, not a `type`. Codes map to statuses (`invalid_request` is `400`, `unauthorized` is `401`, `rate_limited` is `429`); the full list is on [Error codes](/api/api-reference/errors-and-rate-limits/error-codes).

## Related

* [Error codes](/api/api-reference/errors-and-rate-limits/error-codes)
* [Response format](/api/api-reference/overview/response-format)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.