Request
Some fields are invalid
The request did not match what the endpoint expects - a required field is missing, or a value has the wrong type, format or range. Every problem is reported at once, so one round trip is enough to fix them all.
HTTP 400
VALIDATION_FAILEDIn the response
Besides the standard members type, title, status, detail, instance, plus code and requestId:
- errors
- Every invalid field, each with its own message.
detailrepeats the first. Each entry is a{ field, message }, withfielda dotted path into the request body.
Example response
HTTP 400 · application/problem+json
{
"type": "https://smartpathshaala.com/problems/validation-failed",
"title": "Some fields are invalid",
"status": 400,
"detail": "<what went wrong this time>",
"instance": "<the request path>",
"code": "VALIDATION_FAILED",
"requestId": "<also sent as X-Request-Id>",
"errors": [
{
"field": "<path.in.request>",
"message": "<what is wrong with it>"
}
]
} Values in angle brackets vary per request. Quote the requestId when reporting an error; it is how the server’s log line is found.