Skip to content

Validation failed

Request / validation-error

The data does not meet schema constraints or value rules, such as sender name requirements.

HTTP 400HTTP 422
  1. Check field types, allowed values, formats and limits in OpenAPI.
  2. If detail contains Path: #…, the path helps locate the invalid field.
  3. For a rejected sender name, check its length, characters and naming restrictions; choose an allowed name.
Response headers
HTTP/1.1 400
Content-Type: application/problem+json
Content-Language: en-US
Example API response
{
"type": "https://api.szybkisms.pl/problems/validation-error/",
"status": 400,
"title": "Validation Error",
"detail": "{validation_message}. Path: #{property_path}",
"code": "400-10",
"instance": "/rest/messages/sms"
}

code is a diagnostic code for support. instance provides the request path. The example uses the current API identifiers.

3 situations
HTTP 400Whole request failureLink ↗

{validation_message}. Path: #{property_path}

The description depends on request data; {…} indicates a variable fragment.

Check the field type, constraints and object or array schema variant. Path in detail helps locate invalid data.

Any REST endpoint
HTTP 400Whole request failureLink ↗

{validation_message}

The description depends on request data; {…} indicates a variable fragment.

Check the request parameters and body. If the failure persists, provide code and the endpoint to support.

Any REST endpoint
HTTP 422Whole request failureLink ↗

Sender name validation error: {validation_message}

The description depends on request data; {…} indicates a variable fragment.

Correct the sender name according to detail.

POST /rest/senders