EXTERNAL_SERVICE_ERROR
Error communicating with the external service
Category: General
| HTTP status | 502 Bad Gateway |
| Retry | Yes, unchanged |
When it happens
The AEAT census could not be reached to validate the NIF, so the account or company was not created. Nothing was stored.
How to fix it
Repeat the same request later, with the same Idempotency-Key if you sent one. No Retry-After header is sent.
Retry
Retry the same request unchanged, with the same Idempotency-Key if you sent one. Wait first, and honour the Retry-After header when the response carries it.
Returned by
The operations where this code is most likely. The list is not exhaustive.
Example response
When this error occurs, the API answers 502 Bad Gateway with a JSON body of this shape:
{
"type": "https://docs.beel.es/errors/EXTERNAL_SERVICE_ERROR",
"title": "EXTERNAL_SERVICE_ERROR",
"detail": "Error communicating with the external service",
"instance": "/v1/<resource>",
"errors": [],
"success": false,
"error": {
"code": "EXTERNAL_SERVICE_ERROR",
"message": "Error communicating with the external service",
"details": {}
},
"meta": {
"timestamp": "2026-05-21T10:00:00Z",
"request_id": "4bf92f3577b34da6a3ce929d0e0e4736"
}
}The type URI is stable and always resolves to this page.
Message
Send the request with Accept-Language: <es|en|ca> to receive the message in your preferred language.
Other errors in this category
AUTOMATIC_EMAIL_CONFIG_INVALID
For automatic sending, you must provide an email configuration or a client with email
BAD_REQUEST
The provided data is not valid.
BUSINESS_RULE_VIOLATION
The operation breaks a business rule.
CITY_EMPTY
City cannot be empty
CITY_MAX_LENGTH
City cannot exceed ‹value› characters