# API and automation error messages

Use returned API error codes to decide whether to retry, correct invoice data, sign in again, or contact support.

## Who this is for

Use this article when a customer sees an error from an integration, automation, or batch workflow and needs to know what action to take.

## Common messages

| Message or code | What it means | What to do |
| --- | --- | --- |
| AUTHENTICATION_REQUIRED | The request did not include a usable login or bearer token. | Sign in again or add the missing API token. |
| INVALID_API_KEY | The API key is wrong, expired, revoked, or from the wrong environment. | Create or copy the correct key. |
| RATE_LIMITED | Too many requests were sent in a short period. | Wait for the retry window, then continue more slowly. |
| PAYLOAD_TOO_LARGE | The uploaded file is over the size limit. | Compress the PDF or split the work into smaller invoices. |
| INVALID_UPLOAD | The uploaded file could not be read as a valid invoice input. | Check that the file is not empty, corrupted, password-protected, or the wrong format. |
| VALIDATION_FAILED | The invoice data has blocking issues. | Review the returned fields and fix the invoice data before retrying. |
| OUTPUT_PROFILE_REQUIRED | The requested output format needs a clearer compliance profile. | Choose the intended profile, such as XRechnung, EN 16931, ZUGFeRD, or Factur-X. |
| OUTPUT_PROFILE_CONFLICT | The chosen format and profile contradict each other. | Pick one matching output target and retry. |

## Retry guidance

Retry temporary errors such as timeouts, unavailable services, and some upload failures.

Do not blindly retry validation, authentication, rate-limit, file-size, or profile errors. Those need a correction first.
