# Authentication Errors

The errors returned in the request can be identified by the codes below and have the following structure:

```json
{
  "error": "server_error",
  "error_description": "Falha na autenticação x.x.x"
}
```

| Name          | Description                                                                                                                                                                                                                                                                                        |
| ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 1.0.1         | Check if the ID provided in the formation of the "iss" is the correct tenant ID, provided **during the generation of the private key¹.**                                                                                                                                                           |
| 1.0.14        | Check with the project manager if the application being used is active.                                                                                                                                                                                                                            |
| 1.1.1         | The "scope" parameter was not provided in the payload of the JWT used in the request.                                                                                                                                                                                                              |
| 1.2.4         | The JWT used in the request has expired. Check the value provided in the "exp" field of the payload.                                                                                                                                                                                               |
| 1.2.5         | The JWT used in the request cannot be validated. Check the provided parameters and make sure it has been signed correctly.                                                                                                                                                                         |
| 1.2.6         | The private key used to sign the JWT in the request is no longer acceptable. Please request new credentials for the account used.                                                                                                                                                                  |
| 1.2.7         | O token jwt utilizado na requisição não é mais aceitável, pois já foi utilizado anteriormente. Gere um novo token para fazer uma nova requisição.                                                                                                                                                  |
| 1.2.11        | The account used is not active.                                                                                                                                                                                                                                                                    |
| 1.2.14        | The account used does not have the necessary permissions.                                                                                                                                                                                                                                          |
| 1.2.18        | The account used has been temporarily locked due to exceeding the number of invalid authentication attempts.                                                                                                                                                                                       |
| 1.2.19        | The account used is not authorized to impersonate another user account (remove the "sub" parameter from the payload).                                                                                                                                                                              |
| 1.2.20 1.2.21 | Failed to decode the JWT used in the request. Use a new token by including only the fields specified in the "Mandatory Fields" and "Additional Fields" sections, adhering to the correct naming conventions, semantics, and data types for each field.                                             |
| 1.2.22        | The JWT used in the request contains additional fields in the payload that are not allowed. Use a new token by including only the fields specified in the "Mandatory Fields" and "Additional Fields" sections, following the correct naming conventions, semantics, and data types for each field. |
| 1.3.1         | The account used has source IP restrictions.                                                                                                                                                                                                                                                       |
| 1.3.2         | The account used has access date/time restrictions.                                                                                                                                                                                                                                                |


---

# 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://devcenter.unico.io/unico-idpay/en/integration/authentication/additional-resources/authentication-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.
