Incidents

Write to an incident's timeline

Changed on

Append a row to an incident's timeline, returning the event it wrote.

eventType says what the row records - COMMENT_ADDED (the default) for an ordinary comment, or AI_DIAGNOSIS_REQUESTED, AI_DIAGNOSIS_COMPLETED and AI_DIAGNOSIS_FAILED to record the start, result or failure of a diagnosis.

agentSessionId names the Orchestra agent session behind the write. The row is then attributed to Orchestra AI and linked to that session rather than to the API key; an agent takes the id from its ORCHESTRA_AGENT_SESSION_ID environment variable. The AI_DIAGNOSIS_* types require it. A session may write several over its life, but posting the same text twice returns the row already written.

description sets the incident's description alongside an AI_DIAGNOSIS_COMPLETED or AI_DIAGNOSIS_FAILED row, and needs edit permission on the incident. It is not applied over a description a person wrote.

The timeline is append-only: nothing can edit or delete a row once it is there.

post/incidents/{incident_id}/comments

Request

  • Base URL
    https://app.getorchestra.io/api/engine/public
  • URL
    https://app.getorchestra.io/api/engine/public/incidents/{incident_id}/comments
  • Auth
    • HTTP bearer
    • or OAuth 2
      Authorization code: https://app.getorchestra.io/oauth/authorize
      Token URL: https://app.getorchestra.io/oauth/token scopes: orchestra:write

Path parameters

incident_idstring uuid4 required

Incident ID.

Headers

X-Orchestra-Account-Idstring uuid4 nullable

Act on this account rather than the one the credential resolves to. Omit it to use the credential's own account. An API key is issued to a single account, so it may only name that account; an OAuth token may name any account its grant covers.

Request body

commentstring required

Response

Successful Response

incidentEventIdstring uuid4 required
incidentIdstring uuid4 required
eventType'AI_DIAGNOSIS_COMPLETED' | 'AI_DIAGNOSIS_FAILED' | 'AI_DIAGNOSIS_REQUESTED' | 'ARCHIVED' | 'ASSIGNED' | 'CHILD_MERGED' | 'COMMENT_ADDED' | 'CREATED' | 'DESCRIPTION_CHANGED' | 'EVENT' | 'MERGED_INTO' | 'MUTED' | 'RENAMED' | 'SEVERITY_CHANGED' | 'STATUS_CHANGED' | 'SUBSCRIBERS_CHANGED' | 'UNASSIGNED' | 'UNMERGED' | 'UNMUTED' required
actorType'AI' | 'API' | 'OTHER' | 'SYSTEM' | 'USER' required
actorIdstring nullable
commentstring nullable
insertedAtstring required
environmentIdstring uuid4 nullable
resourceType'ASSET' | 'EXTERNAL' | 'OPERATION' | 'PIPELINE' | 'SENSOR' | 'TASK'
triggerType'ANOMALY' | 'EXTERNAL' | 'FAILED' | 'WARNING'

The kind of signal that produced an incident event. Producers state what happened; the Incident Manager maps it to a severity and applies the grouping invariants.

pipelineIdstring uuid4 nullable
pipelineRunIdstring uuid4 nullable
taskRunIdstring uuid4 nullable
sensorIdstring nullable
assetIdstring uuid4 nullable
connectionIdstring nullable
commitShastring nullable
groupBystring nullable
hasExternalEventboolean

Changes