Error responses
When a request fails, the API returns an HTTP error status and a JSON body that describes the problem.
Every error body contains:
| Field | Description |
|---|---|
title | Short summary of the problem |
detail | Explanation of this specific occurrence |
Invalid request fields
If one or more fields in the request body do not meet their constraints, for example a wrong format or a missing value, the API returns HTTP 422.
The body then also contains a violations array with one entry per invalid field:
| Field | Description |
|---|---|
propertyPath | The field that failed, e.g. vatId |
message | Why the value was rejected |
code | Identifier of the failed constraint |
Example: creating a Legal Entity with an invalid VAT ID
{
"title": "An error occurred",
"detail": "vatId: The VAT ID must start with \"DE\" followed by 9 digits.",
"violations": [
{
"propertyPath": "vatId",
"message": "The VAT ID must start with \"DE\" followed by 9 digits.",
"code": "de1e3db3-5ed4-4941-aae4-59f3667cc3a3"
}
]
}