Status API › Incidents
Create an incident
Opens an incident on the page. With body it gets a first timeline entry, and
confirmed subscribers who follow an affected component (or the whole page) are
mailed.
To record one that is already over, send started_at and resolved_at (and
resolution_body): it is marked backfilled, lands on the days it happened
and mails nobody.
Permission (API-key scope): status:incident:write.
Authorization
bearerAuth(status:incident:write)apiKeyHeader(status:incident:write)
Parameters
Path parameters
pageIDstring (uuid) requiredThe status page's id (a UUID).
Request body required
titlestring requiredimpactIncidentImpactstatusIncidentStatusaffected_component_idsarray of string (uuid)Components of this page; an id that is not one of the page's components is skipped.bodystring | nullThe first timeline entry. Mailed to subscribers unless the incident is backfilled.started_atstring (date-time) | nullRecords an incident that already began (at most two minutes in the future). Makes itbackfilled.resolved_atstring (date-time) | nullWithstarted_at: when it ended. Sets the status toresolved.resolution_bodystringWhat the resolved entry of a backfilled incident says.managed_inManagedIn
Responses
201
The incident.
dataIncident requiredShow Incident properties
idstring (uuid) requiredorg_idstring requiredpage_idstring (uuid) requiredtitlestring requiredimpactIncidentImpact requiredstatusIncidentStatus requiredstarted_atstring (date-time) requiredresolved_atstring (date-time)created_atstring (date-time) requiredWhen the page got it.updated_atstring (date-time) requiredpostmortem_bodystringMarkdown; absent when none is written.postmortem_published_atstring (date-time)Set while the postmortem shows on the public page.backfilledboolean requiredWritten after the fact with its own past times; it mailed no subscriber.managed_inManagedIn requiredaffected_component_idsarray of string (uuid) requiredupdatesarray of IncidentUpdate requiredThe timeline.Show IncidentUpdate properties
idstring (uuid)incident_idstring (uuid)statusIncidentStatusbodystringcreated_atstring (date-time)
successboolean required
400
A field is missing or invalid (VALIDATION_ERROR); the message names it, or the body is not valid (INVALID_BODY).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.request_idstringThis request's id, also inX-Request-ID.
401
No API key was sent, or it is unknown, revoked or expired (UNAUTHORIZED).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.request_idstringThis request's id, also inX-Request-ID.
403
The key lacks the scope this endpoint needs (FORBIDDEN).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.request_idstringThis request's id, also inX-Request-ID.
404
No such page (PAGE_NOT_FOUND, or NOT_FOUND for a page the caller cannot see).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.request_idstringThis request's id, also inX-Request-ID.
429
Too many requests (RATE_LIMITED). Wait Retry-After seconds.
Retry-AfterintegerSeconds to wait.
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.request_idstringThis request's id, also inX-Request-ID.
500
Something went wrong on EvoHub's side (INTERNAL_ERROR). Retry later.
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.request_idstringThis request's id, also inX-Request-ID.
Example request
curl -X POST 'https://evohub.io/api/v1/pages/3f6c2a1e-8b4d-4f7a-9c21-5d0e7a9b1c42/incidents' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
-d '{
"body": "We are looking into elevated error rates on the API.",
"title": "Elevated API error rates",
"impact": "major",
"status": "investigating",
"managed_in": "status_page",
"affected_component_ids": [
"a7c1e3f5-2b4d-4c6e-8f0a-1b3d5f7a9c2e"
]
}'