Create
Attach an alert to an incident, creating the connection between them.
The API key also needs the ‘manage incident alerts’ scope, which is what actually relates the alert once the connection exists.
If the alert is already related to this incident, the existing connection is returned unchanged. If someone previously marked the alert as unrelated to this incident, that decision is preserved and this endpoint returns a 422 — set re_relate to override it.
Private alerts can only be attached to private incidents, including when re_relate is set. An API key that cannot see the alert or the incident receives a 404.
Busy incidents can be locked by another operation, in which case this endpoint returns a 409 and the request can be retried.
Note that this endpoint returns 201 even when it re-relates or returns an existing connection rather than creating a new one.
alerts.attach_to_incident scope.Authorizations
API key from your incident.io dashboard (Settings → API keys)
Body
Alert to attach to the incident
"01FCNDV6P870EA6S7TK1DSYDG1"
Incident to attach the alert to
"01FCNDV6P870EA6S7TK1DSYDG0"
Relate the alert again even though someone previously marked it unrelated to this incident. Defaults to false, which preserves that decision and returns a 422
false
Response
Created response.