Skip to content
ClickHouse Docs
ClickHouse DocsClickHouse Docs

Validate Webhook

POST/api/v2/webhooks/validate
API playground

Validates a webhook body against the same schema, URL rules, and body template check used by POST /api/v2/webhooks. The webhook is never persisted. Use this endpoint at plan time (e.g. from a Terraform provider) to check that a webhook configuration is valid before applying it. Name uniqueness is not checked.

Authorizations

  • AuthorizationBearer API Keyheaderrequired
    `Authorization: Bearer <token>`

Request bodyJSON

  • namestringrequired

    Webhook name. Must be unique per service within the team.

    maxLength: 1024
    Example: "Production Alerts"
  • serviceslackorincidentioorgenericrequired

    Webhook service type.

    Example: "slack"
  • urlstringrequired

    Webhook destination URL.

    format: uri, maxLength: 2048
    Example: "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX"
  • descriptionoptionalstring

    Webhook description, shown in the UI.

    maxLength: 2048
    Example: "Sends critical alerts to the #incidents channel"
  • bodyoptionalstring

    Optional Handlebars request body template. Only for generic/incidentio; rejected for slack. Rejected with a 400 if it does not compile or calls a helper other than eq and the Handlebars built-ins.

    maxLength: 16384
    Example: "{\"alert\": \"{{title}}\", \"severity\": \"{{level}}\"}"
  • headersoptionalmap ofstring

    Write-only. Custom HTTP headers sent with the webhook request. Never returned on read. Only for generic/incidentio; rejected for slack. Each value is capped at 4096 characters.

    Example: {"Authorization":"Bearer secret-token"}
  • queryParamsoptionalmap ofstring

    Write-only. Query parameters appended to the webhook URL. Never returned on read. Only for generic/incidentio; rejected for slack. Each value is capped at 4096 characters.

Response

JSON

200

Validation result. HTTP 200 is always returned for valid and invalid bodies — a non-200 response means the request itself failed (auth, server error, etc.).

JSON
  • validbooleanrequired

    True when the body passes all validation rules.

  • errorsarray ofobjectrequired

    Validation errors. Empty when valid is true.

    2 properties
    • pathstringrequired

      Dot-separated field path, or empty string for top-level errors.

    • messagestringrequired

      Human-readable error description.

  • normalizedobjector nullrequired

    The parsed webhook body, without the write-only headers and queryParams. Populated when valid is true, null when valid is false.