SLO Targets

Per-account, configurable Service Level Objective targets. These drive the SLI/SLO tab on the observability metrics page — the availability bar, error budget, burn rate, and SLI table all evaluate against the values stored here. An account that has never set targets reads back the platform defaults: 99.90% availability, latency threshold 200 ms, latency target 99.00%.

Account scope: targets belong to your active account. Use switch account to read or edit a different account's targets.

Get SLO Targets

GET /v1/account/slo-targets

Returns the active account's SLO targets, falling back to the platform defaults when no targets have been set.

Response (200 OK)

availability_target float64
Target availability as a percentage, e.g. 99.90. Default 99.90.
latency_threshold_ms int
The "fast" boundary in milliseconds — requests served under this are counted as fast. Default 200.
latency_target_percent float64
Target percentage of requests that must complete under latency_threshold_ms, e.g. 99.00. Default 99.00.

Update SLO Targets

PUT /v1/account/slo-targets

Upserts the active account's SLO targets. On success the stored values are echoed back. Requires an active account — a platform-admin / legacy token with no active account returns 400.

Request body

availability_target float64 Req
Percentage in the range (0, 100]. Values outside the range are rejected with 400.
latency_threshold_ms int Req
Positive millisecond bound, 1600000. Values outside the range are rejected with 400.
latency_target_percent float64 Req
Percentage in the range (0, 100]. Values outside the range are rejected with 400.

Response (200 OK)

Echoes the same three fields that were stored — identical shape to the GET response.

Errors

400 Bad Request
Invalid request body, a field out of its allowed range, or no active account to attach targets to.
401 Unauthorized
Missing auth.
403 Forbidden
Your role lacks the required permission on the traffic-inspector resource (read for GET, write for PUT).
Request — get
curl -X GET "https://api.ngris.com/v1/account/slo-targets" \ -H "X-API-KEY: <your_api_key>"
Response — get (200 OK)
{ "availability_target": 99.90, "latency_threshold_ms": 200, "latency_target_percent": 99.00 }
Request — update
curl -X PUT "https://api.ngris.com/v1/account/slo-targets" \ -H "X-API-KEY: <your_api_key>" \ -H "Content-Type: application/json" \ -d '{ "availability_target": 99.95, "latency_threshold_ms": 150, "latency_target_percent": 99.50 }'
Response — update (200 OK)
{ "availability_target": 99.95, "latency_threshold_ms": 150, "latency_target_percent": 99.50 }
On this page
SLO Targets
Iris