> For the complete documentation index, see [llms.txt](https://docs.mindee.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mindee.com/v1/integration/error-management.md).

# Error Management

## Mindee REST API Status and Error Codes

To indicate successful execution or when error occur, we utilize standard HTTP codes. In the case of errors, the response will contain extra information about the error with an error code.

## Response Codes

Mindee REST APIs return either 200 (OK) or 201 (Created) when an API request successfully runs to completion. Status codes in the 400-500 range indicate failures.

## Successful Execution

Those operations that complete successfully will return 2xx status codes in addition to the API response status information in the response body.

The table below shows the typical response codes supported by Mindee API.

| Operation | Response code | HTTP status code | Possible response |
| --------- | ------------- | :--------------: | ----------------: |
| `GET`     | OK            |        200       |  Request succeeds |
| `POST`    | Success       |        201       |  Resource created |

## Error Handling

If an error occurs when calling Mindee's REST API because of an issue with the client's input (such as incorrect data), the standard error code 4xx is used. If an operation fails because of an issue with the Mindee server, a 5xx error code will be returned.

Errors happening can be split in two main parts:

### 4xx Errors - Client Errors

<table><thead><tr><th width="182">Error Code</th><th width="131">HTTP Status</th><th>Possible Reasons</th></tr></thead><tbody><tr><td>BadRequest</td><td>400</td><td><strong>Wrong file type</strong>: file types allowed: png, jpg, webp, heic, tiff, pdf.<br><strong>Missing input file</strong><br><strong>Too many pages in PDF</strong><br><strong>File is too big</strong></td></tr><tr><td>Unauthorized</td><td>401</td><td><strong>Bad token</strong>: you didn’t provide the authentication header or the token is wrong.</td></tr><tr><td>Forbidden</td><td>403</td><td><strong>Inference is blocked</strong>: your API access has been blocked.</td></tr><tr><td>PlanLimitReached</td><td>403</td><td><strong>Plan limit reached</strong>: you have reached your maximum number of requests.</td></tr><tr><td>NotFound</td><td>404</td><td><strong>Wrong endpoint</strong>: provided endpoint doesn't match any product.<br><strong>Wrong version</strong>: wrong version in base URL.<br><strong>No subscription found</strong>: you need to have an active subscription on the associated product</td></tr><tr><td>TooManyRequests</td><td>429</td><td><strong>Too high frequency</strong>: number of requests over time is limited. See <a href="/pages/u2EetqCHkWPdv0Ffx1Ue">Technical limitations documentation</a>.</td></tr></tbody></table>

### 5xx Errors - Server Errors

<table><thead><tr><th width="182">Error Code</th><th width="124">HTTP Status</th><th align="center">Possible Reasons</th></tr></thead><tbody><tr><td>ServerError</td><td>500</td><td align="center">An unknown error occurred during the processing of your request. Either the server is overloaded or there is an error in the application.</td></tr><tr><td>RequestTimeout</td><td>504</td><td align="center">The request takes too much time to be processed.</td></tr></tbody></table>


---

# 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 dynamically by asking a question.

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

```
GET https://docs.mindee.com/v1/integration/error-management.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
