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

# API Error Codes

> Common Nitro API error responses and what they mean

When interacting with the Nitro APIs, you might encounter various HTTP error responses. Here's a breakdown of the most common error codes and how to resolve them.

## 400 - Bad Request

This error occurs when the request is malformed or contains invalid parameters.

**Common causes:**

* Missing required fields
* Invalid query syntax
* Sending data in the wrong format

**How to fix:**

* Double-check your request body or query parameters to ensure all fields are correctly structured.

***

## 401 - Unauthorized

This error means your request lacks valid authentication credentials.

**Common causes:**

* Attempting a request with a missing or expired token
* Attempting a request with an access token in the wrong format.

**How to Fix:**

* Verify that your access token is included and valid.
* Check out the [Authentication and Authorization](https://developers.gonitro.com/docs/authentication/credentials) guide if you need go through the process of obtaining credentials and tokens.

***

## 404 - Not Found

This indicates that the requested resource doesn't exist.

**Common causes:**

* Attempting to get or modify a resources that does not exist. For example, trying to add a Document to an Envelope that doesn't exist.

**How to Fix:**

* Check that you're calling the correct endpoint and using valid resource identifiers.

***

## 405 - Method Not Allowed

This error means that the resource exists, but it does not accept the HTTP method you used.

**Common causes:**

* Using the wrong HTTP method for the endpoint.
* For example, sending a GET request to an endpoint that only supports POST.

**How to fix:**

* Check the API reference to confirm which methods are supported for the endpoint, and update your request.

***

## 406 - Not Acceptable

This error occurs when the server cannot produce a response in a format acceptable to your client.

**Common causes:**

* The Accept header specifies a content type the API doesn't support.
* Missing or incorrect Accept header in the request.

**How to fix:**

* Check the response content type in the API reference tab for the endpoint, and update your Accept header to match, or remove it to use the default.

***

## 408 - Request Timeout

The server timed out before the request could be completed.

**Common causes:**

* Network problems such as high latency, slow connections, or firewalls can generate a server timeout.
* Large payloads (for example, document uploads) that take longer than the allowed processing time.

**How to Fix:**

* Check your network connection and retry later

***

## 409 - Conflict

The request could not be completed because of a conflict with the current state of the target resource. The conflict must be resolved before retrying.

**Nitro-specific causes:**

<Accordion title="Upload Exceeds maximum number of Documents for Envelope">
  **Cause**: Uploading a Document to an Envelope that already contains the maximum of 15 Documents.

  **Fix**: Remove unused Documents from the Envelope or combine smaller files into a single Document before retrying.
</Accordion>

<Accordion title="Resending Envelope for Signature">
  **Cause**: Attempting to send for signature an Envelope that has already been delivered and is in sent status.

  **Fix**: For sending Envelopes, verify the current status and ensure you are not resending an Envelope that has already been delivered.
</Accordion>

***

## 413 - Content too large

This error indicates that the request was valid, but the payload exceeded the maximum size allowed by the system.

**Nitro-specific causes:**

<Accordion title="Upload Document too large">
  **Cause:** Attempting to upload a document that is too large.

  **Fix:** Ensure that uploaded files are no larger than 20 MB.
</Accordion>

***

## 415 - Unsupported Media Type

This error indicates that the file format or media type sent in the request is not supported by the system.

**Nitro-specific causes:**

<Accordion title="File format not supported for document conversion">
  **Cause:** Attempting to upload a document with an unsupported file format to the `/sign/conversions` endpoint.

  **Fix:** Ensure that uploaded files are in one of the supported formats.

  * Refer to the [Convert File to PDF](https://developers.gonitro.com/docs/api-reference/sign/convert-file-to-pdf) endpoint documentation for the complete list of supported file formats.
  * Include the **type** parameter in the form data matching the file's MIME type (e.g., **application/xml** for .xml files).
</Accordion>

<Accordion title="File format not supported for envelope documents">
  **Cause:** Attempting to upload a non-PDF document to the `/sign/envelopes/{envelopeID}/documents` endpoint.

  **Fix:** This endpoint only accepts PDF files. Convert your document to PDF format before uploading, or use the /sign/conversions endpoint to convert supported formats to PDF first.
</Accordion>

***

## 422 - Unprocessable Entity

This error means the request was well-formed but contains semantic issues the server can't process.

**Nitro-specific causes:**

<Accordion title="Too many documents">
  **Cause:** Attempting to add too many documents in an envelope

  **Fix:** Make sure your envelope is within the document limits allowed by the Nitro platform (15).
</Accordion>

<Accordion title="Invalid Params">
  \*\* Cause \*\*
  Transformation - rotate: Unsupported angle, for example 70 degrees.
</Accordion>

***

## 500 - Internal Server Error

A generic error indicating something went wrong on our end.

**Common causes:**

* Server failure
* Unhandled exception in processing

**How to fix:**

* Try your request again later. If the issue persists, contact support with details of your request and error response.
