Skip to content
All’s Well
API reference · Problem type

Validation failed

Last updated MarkdownOpenAPI 3.1

https://alls-well.io/docs/api/problems/validation-failed

The request body or query is invalid. The status is 422. errors lists every invalid field, in dot notation for nested fields such as config.webhook_url, with its messages. detail is the first message, with a count of any others.

HTTP/1.1 422 Unprocessable Content
Content-Type: application/problem+json

{
  "type": "https://alls-well.io/docs/api/problems/validation-failed",
  "title": "Validation failed",
  "status": 422,
  "detail": "The url field is required unless type is in heartbeat.",
  "errors": {
    "url": ["The url field is required unless type is in heartbeat."]
  }
}

What to do

Fix each field in errors and send the request again; retrying it unchanged fails the same way. The messages are written for people: show them next to the field, or log them. Common causes:

Field Usually means
url It is missing, or not a full URL. tcp and icmp monitors still need a URL such as https://db.example.com; only its host is used
check_interval_minutes It isn't 1, 5, 15, 30 or 60, or it is below the plan's minimum. Read min_interval_minutes from the team
check_interval_seconds It is below the plan's min_interval_seconds
config.* The contact's config is missing a key its type needs. See config for each type
notification_contact_ids.0 The ID isn't one of the team's contacts
per_page It isn't between 1 and 100