Sign in
Docs
API referenceIncidents

API reference

Get an incident's report

Have a token? Manage tokens in the console
GET
/v1/incidents/{incident_id}/report

One report in five parts: the monitors' runs, their latency and success rate, the evidence bundle (labelled a stub until it is live), an AI explanation whose every claim cites those runs and metrics, and an AI-proposed status that a person confirms with Update an incident. A key sees the first three parts only.

Needs scope incidents:read.

Authorization

bearer
headerAuthorizationBearer <JWT>

An access token from the identity provider: a person's, or a customer's from the client credentials grant with an API key (developers.inorbit.hr). The gateway verifies it; the audience is iohr-api.

Path Parameters

incident_id*string

The incident's id, inc_ and 26 characters, from List incidents.

Query Parameters

account_id?string

The account's id: org in GET /v1/me.

Response Body

iohr.incidents.v1.GetIncidentReportResponse

application/json
  1. response

iohr.incidents.v1.GetIncidentReportResponse

report?

iohr.incidents.v1.IncidentReport

import { ApiError, Public } from "@inorbithr/sdk";// Reads INORBIT_TOKEN, or INORBIT_KEY_ID and INORBIT_KEY_SECRET.const api = Public.fromEnv();try {  const { value } = await api.incidents.getIncidentReport("<incident_id>");  console.log(value);} catch (e) {  if (!(e instanceof ApiError)) throw e;  console.error(`${e.code}: ${e.problem} (request id ${e.raw.requestId})`);  process.exitCode = 1;}

npm install @inorbithr/sdk. Calls the package's public surface; an operation newer than your package needs the next release or a client generated for your account. The SDKs.

Example Response
{  "report": {    "evidence": {      "available": true,      "items": [        {          "id": "string",          "kind": "string",          "label": "string",          "observed_at": "string",          "ref": "string",          "source": "string"        }      ],      "note": "string",      "stub": true    },    "explanation": {      "ai": true,      "basis_run_id": "string",      "claims": [        {          "cites": [            "string"          ],          "text": "string"        }      ],      "dropped": 0,      "generated_at": "2019-08-24T14:15:22Z",      "label": "string",      "model": "string",      "note": "string",      "stale": true,      "state": "string",      "tokens": 0    },    "incident_id": "string",    "incident_version": 0,    "metrics": {      "monitors": [        {          "bucket_secs": 0,          "monitor_id": "string",          "points": [            {              "end": "2019-08-24T14:15:22Z",              "failed": 0,              "p50_ms": 0,              "p95_ms": 0,              "passed": 0,              "point_id": "string",              "runs": 0,              "seen": 0,              "start": "2019-08-24T14:15:22Z",              "success_rate": 0.1            }          ],          "total": {            "end": "2019-08-24T14:15:22Z",            "failed": 0,            "p50_ms": 0,            "p95_ms": 0,            "passed": 0,            "point_id": "string",            "runs": 0,            "seen": 0,            "start": "2019-08-24T14:15:22Z",            "success_rate": 0.1          }        }      ],      "source": "string"    },    "proposed_status": {      "ai": true,      "label": "string",      "proposed_at_version": 0,      "reason": {        "cites": [          "string"        ],        "text": "string"      },      "state": "string",      "status": "string"    },    "runs": {      "monitors": [        {          "failed_total": 0,          "failures": [            {              "count": 0,              "error_class": "string",              "last_run_id": "string"            }          ],          "health": "string",          "monitor_id": "string",          "name": "string",          "runs": [            {              "at": "2019-08-24T14:15:22Z",              "error_class": "string",              "latency_ms": 0,              "ok": true,              "run_id": "string",              "status_code": 0            }          ],          "runs_total": 0        }      ],      "source": "string"    },    "status": "string",    "window_from": "2019-08-24T14:15:22Z",    "window_to": "2019-08-24T14:15:22Z"  }}