# Errors

Zūm Rails wraps all API responses in the same JSON format, and the HTTP status is also returned as part of the response body in the statusCode field.

{% tabs %}
{% tab title="Success Response" %}

```json
{
    "statusCode": 200,
    "message": "POST Request successful.",
    "isError": false,
    "result": {
    }
}
```

{% endtab %}

{% tab title="Error Response" %}

```json
{
    "statusCode": 400,
    "isError": true,
    "responseException": {
       "exceptionMessage": {
        }
    }
}
```

{% endtab %}
{% endtabs %}

The Zūm Rails API uses the following http error codes:

<table><thead><tr><th width="134">Error Code</th><th>Meaning</th></tr></thead><tbody><tr><td>400</td><td>Bad Request -- Your request is invalid.</td></tr><tr><td>401</td><td>Unauthorized -- Your API key is wrong.</td></tr><tr><td>403</td><td>Forbidden -- The endpoint requested is hidden for administrators only.</td></tr><tr><td>404</td><td>Not Found -- The specified endpoint or entity could not be found.</td></tr><tr><td>429</td><td>Too Many Requests -- You reached your quota</td></tr><tr><td>500</td><td>Internal Server Error -- We had a problem with our server. Try again later.</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.zumrails.com/api-reference/errors.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
