Skip to content

Alert Webhooks

Ingest alerts from Datadog, Grafana, or any generic HTTP webhook into Batida. All incoming alerts are normalized into a unified incident schema.

Overview

Batida exposes a single webhook endpoint that accepts alert payloads from multiple monitoring tools. Each payload is parsed, normalized, and converted into a Batida incident (or appended to an existing one).

text
https://app.batida.io/api/webhooks/alerts/<team_id>?token=<your_webhook_token>

Token authentication

The webhook URL includes a team-specific token. Keep this token secret. Anyone with the URL can create incidents in your team. Rotate the token periodically from Settings > Integrations > Alert Webhooks > Rotate Token.

Supported sources

Datadog

  1. In Datadog, go to Monitors > Manage Monitors and select the monitor to configure.
  2. Under Notify your team, add a Webhook notification.
  3. Use the Batida webhook URL and set the payload format to the default Datadog JSON.
json
{
  "title": "CPU usage above 95%",
  "message": "Host: prod-web-01",
  "priority": "P1",
  "alert_type": "error",
  "host": "prod-web-01",
  "tags": ["env:production", "team:backend"]
}

Batida maps Datadog fields as follows:

Datadog fieldBatida field
titleIncident title
message + hostDescription
prioritySeverity (P1 = critical, P2 = high, P3 = medium, P4 = low)
tagsLabels for grouping
alert_typeerror = opened, warning = investigating, recovery = resolved

Grafana

  1. In Grafana, go to Alerting > Contact Points.
  2. Add a new contact point of type Webhook.
  3. Paste the Batida webhook URL.
  4. In the alert rule, set the webhook as a notification channel.
json
{
  "status": "firing",
  "alerts": [
    {
      "labels": {
        "alertname": "HighMemoryUsage",
        "severity": "critical"
      },
      "annotations": {
        "summary": "Memory usage above 90% on prod-db-01"
      },
      "startsAt": "2026-04-20T14:30:00Z"
    }
  ]
}
Grafana fieldBatida field
annotations.summaryIncident title
labels.severitySeverity
labels.alertnameLabel
statusfiring = opened, resolved = resolved

Generic webhook

Any HTTP POST with a JSON body can be sent to the webhook URL. Configure field mappings in the Batida dashboard under Settings > Integrations > Alert Webhooks > Custom Mappings.

json
{
  "mapping": {
    "title": "$.alert_name",
    "description": "$.description",
    "severity": "$.level",
    "labels": "$.tags"
  }
}

Use JSONPath expressions to map fields from your custom payload to Batida's incident schema.

Alert normalization

Regardless of the source, all alerts are normalized into the same Batida incident structure. This means your response workflow is identical whether an alert comes from Datadog, Grafana, or a custom source.

Deduplication

Alerts are grouped by combining the source name and alert identifier (e.g., datadog:cpu_alert_42). Adjust the deduplication key under integration settings.

Troubleshooting

  • "Invalid token": Verify the token in your webhook URL matches the token shown in Batida settings.
  • Alerts not creating incidents: Check the field mappings. Use the Test Webhook button on the settings page to send a sample payload and inspect the parsing result.
  • Duplicate incidents: Review the deduplication key configuration. Two alerts with different dedup keys will create separate incidents.

Built by the Batida team