Skip to main content

Status page

The gateway keeps its own status page data. It computes uptime for every model group and every provider behind them from the stored health check history and the spend logs, builds daily latency, time to first token and throughput series, and keeps a table of incidents that admins open, update and resolve. Admins read the full picture with GET /status/overview. A trimmed copy for the public model groups is served without a key on GET /public/status when you turn it on, and the Spanway website renders that payload on its status page.

A real-world scenario​

A provider starts failing one of a company's model groups at nine in the morning. Within minutes the Admin UI's Status Page lists the group under suggested incidents because its 24 hour uptime dropped under 99 percent. The on-call admin opens an incident from the suggestion, writes a public message, and the company's status website, which reads /public/status, shows the incident and the dip in uptime. When the failover is in place she posts a monitoring update, and once the provider recovers she resolves the incident. The whole timeline is in the audit log with her user id.

How uptime is computed​

Two signals feed each window.

Health checks. Every stored health check row holds until the next row for the same deployment. Background health checks write a row when a deployment's status changes and at least once an hour while it stays the same, so a row that is older than one hour plus two health check intervals with nothing after it stops counting and that time becomes unknown. A model group is up while any of its deployments is up, down while every deployment with a known state is down, and unknown otherwise. A provider is computed the same way from the deployments that route to it inside the model groups being reported. health_uptime_pct is the up time divided by the known time, and health_coverage_pct is the known time divided by the length of the window.

Requests. request_success_pct is the share of requests in the spend logs for the window that did not fail with a server side error. Failures whose error code is a 4xx, which covers bad requests, authentication errors and the gateway's own rate limits and budgets, are the caller's or a quota's and do not count against uptime. Two 4xx codes are the provider's fault and do count: 408 timeouts, and 429 rate limits that the provider returned rather than the gateway's limiter.

uptime_pct uses the health checks when they cover at least half of the window and falls back to the request success rate otherwise. When there were no requests either, it is the health check figure on whatever coverage exists, and null when there is no data at all. source says which signal was used, health_checks, requests or none, and both raw figures are always returned so you can see when they disagree.

Uptime by health checks needs background health checks enabled and a database. History only goes back as far as maximum_health_check_retention_period keeps rows and as far as your spend log retention keeps logs, so set both above 30 days if you want the 30 day window to be complete.

Daily series​

Each model group and provider carries 30 daily points, oldest first. A day is a rolling 24 hour period ending at the time the report was built, not a calendar day, so the newest point always covers the last 24 hours. Each point has the request count, the server failure count, the health check uptime for that day, p50 and p95 latency over successful requests, p50 time to first token over successful streaming requests, and output tokens per second, which is completion tokens divided by end to end latency over successful requests that produced output. Days with no traffic have zero requests and null latency.

The request figures come from one aggregate query over the last 30 days of spend logs, grouped by model group and by provider per day. On a large spend log table that query is the expensive part of a report, so both reports are cached. The public report is kept for public_status_cache_seconds. The admin report behind /status/overview and /status/suggestions is kept for 30 seconds and is cleared, together with the public one, whenever an incident is created, updated or resolved. When a cached report expires, concurrent requests on the same instance wait for a single rebuild instead of each running the query.

Overall status​

The report's status is outage when an open incident has critical impact or every reported model group is currently down, degraded when any open incident has an impact other than none or any model group is currently down, operational when at least one model group is currently up, and unknown when there is no current health data and no open incident.

Incidents​

An incident has a title, a status (investigating, identified, monitoring or resolved), an impact (none, minor, major or critical), the model groups and providers it affects, a public flag, and a timeline of updates. Creating an incident writes its first update. Changing the status or posting a message adds an update, changing only the title, impact or targets does not. Resolving sets the status to resolved, stamps resolved_at and adds the closing message. A PATCH can only set investigating, identified or monitoring, so resolve with POST .../resolve, and a PATCH that sends "status": "resolved" is refused with 422. Setting a status on a resolved incident reopens it.

The overview and the public payload carry the open incidents and those resolved in the last 14 days. Older resolved incidents drop out of both but stay in GET /status/incidents. Incidents are never deleted and no retention period covers them, so an incident opened by mistake can only be made private with a PATCH that sends "is_public": false.

MethodPathWhat it does
GET/status/overviewThe full report for every model group and provider, with every open or recently resolved incident, private ones and ones that name a model group or provider the router no longer serves included. Without a database it answers 200 with status unknown and no incidents.
GET/status/suggestionsModel groups and providers under the uptime threshold with no open incident.
GET/status/incidentsIncidents newest first, with open_only, page and page_size.
POST/status/incidentsOpens an incident with its first update.
GET/status/incidents/{incident_id}One incident with its full timeline.
PATCH/status/incidents/{incident_id}Changes the fields sent and adds an update for a message or a new status.
POST/status/incidents/{incident_id}/resolveResolves the incident with a closing message.
curl -X POST http://localhost:4000/status/incidents \
-H "Authorization: Bearer $SPANWAY_MASTER_KEY" -H "Content-Type: application/json" \
-d '{"title": "Elevated errors on gpt-5.5", "message": "We are seeing failures from one provider and are failing over.", "impact": "minor", "model_groups": ["gpt-5.5"]}'

curl -X PATCH http://localhost:4000/status/incidents/$INCIDENT_ID \
-H "Authorization: Bearer $SPANWAY_MASTER_KEY" -H "Content-Type: application/json" \
-d '{"status": "monitoring", "message": "Failover is in place and errors are back to normal."}'

curl -X POST http://localhost:4000/status/incidents/$INCIDENT_ID/resolve \
-H "Authorization: Bearer $SPANWAY_MASTER_KEY" -H "Content-Type: application/json" -d '{}'

When audit logging is enabled and your license includes it, every create, update and resolve writes an audit log row on the table Spanway_StatusIncidentTable with the incident id as object_id. Opening writes created, and an update and a resolve both write updated with the incident before and after the change.

Proxy admins can read and change incidents. Admin viewers can read the overview, suggestions and incidents but every write is refused. Organization admins and internal users reach none of these routes, because incidents and the overview cover the whole gateway rather than one organization. The only exception is a custom role that grants status.read or status.write.

Suggested incidents​

GET /status/suggestions lists the model groups and providers whose 24 hour uptime is under status_incident_uptime_threshold (99 by default) and that no open incident covers yet, with a suggested title and an impact of major under 90 percent and minor otherwise. An open incident covers a model group or provider it names, and an open incident that names nothing covers everything. Nothing is created automatically. The Admin UI shows the suggestions above the incident list with a button that opens the create form already filled in.

The public endpoint​

GET /public/status is off by default and answers 404 until you enable it. It reports only the model groups in the public model list that the AI hub and the public catalogue use, and only the providers behind them.

general_settings:
public_status: true
public_status_cache_seconds: 60
status_incident_uptime_threshold: 99

spanway_settings:
public_model_groups:
- claude-sonnet-5
- gpt-5.5
KeyDefaultWhat it does
public_statusfalsePublishes a status page anyone can read without a key, so customers can check uptime and incidents themselves instead of asking support. On: GET /public/status serves the uptime, latency and throughput of the model groups in public_model_groups, their providers and every public incident, readable by anyone, so list only model names you are happy to show and write public incidents for customers. Off: the route answers 404. A proxy admin can switch it in the Admin UI without a restart.
public_status_cache_seconds60How long the computed payload stays in the proxy cache and the max-age advertised in Cache-Control.
status_incident_uptime_threshold99The 24 hour uptime percent under which /status/suggestions proposes an incident.
curl http://localhost:4000/public/status
{
"status": "operational",
"generated_at": "2026-10-18T12:00:00Z",
"model_groups": [
{
"dimension": "model_group",
"name": "gpt-5.5",
"providers": ["openai", "azure"],
"current": "healthy",
"uptime": [
{
"window": "24h",
"uptime_pct": 99.931,
"source": "health_checks",
"health_uptime_pct": 99.931,
"health_coverage_pct": 100.0,
"request_success_pct": 99.8,
"requests": 5000,
"server_failures": 10
}
],
"daily": [
{
"day_start": "2026-10-17T12:00:00Z",
"requests": 5000,
"server_failures": 10,
"health_uptime_pct": 99.931,
"p50_latency_ms": 812.5,
"p95_latency_ms": 2100.0,
"p50_ttft_ms": 310.0,
"output_tokens_per_second": 64.2
}
]
}
],
"providers": [],
"incidents": []
}

The example is shortened. Every entry carries all three windows and all 30 daily points, and providers has the same shape as model_groups with an empty providers list.

The response carries Cache-Control: public, max-age=<cache seconds> and Access-Control-Allow-Origin: *, so a CDN can cache it and a page on another domain can read it from the browser.

Privacy​

The public payload names only public model groups and the providers behind them. Incidents marked private never appear on it. An incident that names targets outside the public set is shown with those names removed, and an incident that names only non-public targets is left out entirely, so a private model's name cannot leak through an incident. Incident titles and updates are shown as written, so write them for a public audience. Health check error messages, deployment ids, API bases, keys, teams and users are never part of the payload, and the endpoint only reads the database.

Admin UI​

The Status Page entry under Observability in the Admin UI shows the overall status, the 24 hour, 7 day and 30 day uptime and current state of every model group and provider, the suggested incidents, and the incident list. Selecting a model group or provider shows its 30 day history of requests and server failures, p50 and p95 latency, p50 time to first token and output tokens per second. From there an admin can open an incident, post an update, change its status, impact, targets or visibility, and resolve it. The entry is shown to proxy admins and admin viewers only. Admin viewers see a note that only a proxy admin can change incidents, and a custom role with status.write makes its changes through the API, since the Admin UI shows the write buttons to proxy admins only.

Each incident records the user id of the admin who opened it, or nothing when it was opened with a key that has no user, so key values are never stored. A data subject request exports the incidents a user opened and erase replaces their user id with the pseudonym.

Website wiring​

To show the status on your own website, have the page fetch https://<your gateway>/public/status from the browser and render the fields it needs, such as the overall status, the uptime per model group and provider and the open incidents. The response allows any origin, so no proxy is needed. If your site sends a Content Security Policy, add your gateway's origin to its connect-src. When the fetch fails, show that live status is unavailable rather than old numbers.

Step by step​

  1. Turn on background health checks. For a public page, open Observability, then Status Page, scroll to Public surfaces, find the Public status card and switch on Serve GET /public/status. The change applies at once with no restart. Then publish the model groups to show on the AI hub, which sets public_model_groups. Alternatively set public_status: true and public_model_groups under general_settings in config.yaml and roll the gateway.

  2. In the Admin UI open Observability, then Status Page. The overview shows the overall status and the uptime of every model group and provider. Over the API the same report is:

    curl http://localhost:4000/status/overview -H "Authorization: Bearer $SPANWAY_API_KEY"

    Expected result: the report shown above with status, every model group and provider with their three uptime windows and 30 daily points, and the open incidents plus those resolved in the last 14 days.

  3. Check the suggestions and open an incident from one. Over the API:

    curl http://localhost:4000/status/suggestions -H "Authorization: Bearer $SPANWAY_API_KEY"

    Expected result: {"threshold_pct": 99.0, "suggestions": [...]}, empty when every target is above the threshold or already covered.

  4. Open, update and resolve the incident with the three curl commands in the incidents section above. Expected result: each answer is the incident with its growing updates timeline, and the resolve answer has "status": "resolved" and a resolved_at time.

  5. Read the public view without a key, which shows only the public model groups and public incidents:

    curl http://localhost:4000/public/status
  6. Open Logs, then Audit logs, set the table filter to Spanway_StatusIncidentTable (or call GET /audit?table_name=Spanway_StatusIncidentTable&object_id=<incident id>) to see the created row and the updated rows for each update and the resolve.

Errors​

StatusRouteMeaningFix
401 Authentication Error, No api key passed in./status/*No key or Admin UI session was sent.Send Authorization: Bearer <key>.
422 validation error naming the fieldPOST and PATCH /status/incidents, GET /status/incidentsA field is not valid, for example "status": "resolved" in a PATCH, a title over 200 characters, a message over 5000 characters or page_size over 100.Fix the named field. Resolve through POST .../resolve.
403 Only proxy admins can read the status page/status/* readsThe key is not a proxy admin or admin viewer key and no custom role grants the route.Use an admin key, or grant status.read with a custom role.
403 Only proxy admins can change the status page/status/incidents writesAdmin viewers and other roles cannot change incidents.Use a proxy admin key, or grant status.write.
404 incident_id=... not found/status/incidents/{incident_id}No incident has that id.Check the id in the list.
400 nothing to updatePATCH /status/incidents/{incident_id}The body named no field.Send at least one of title, message, status, impact, model_groups, providers, is_public.
409 incident_id=... is already resolvedPOST .../resolveThe incident is resolved.Reopen it with a status in a PATCH if it is not over.
404 Public status page is not enabledGET /public/statuspublic_status is false.Set it to true.
500 DB not connected. This endpoint needs a database; set DATABASE_URL to a PostgreSQL connection string (postgresql://...) to enable it. .../status/incidents routesIncidents need Postgres. The overview, suggestions and /public/status still answer without one, reporting unknown with no incidents.Set DATABASE_URL.
uptime_pct is null and source is nonereportNo health checks and no requests in the window.Turn on background health checks and keep enough retention.

Logs​

LevelLineMeaning
ERRORError reading incidents for the status page: <error>The incidents could not be read, usually because the database is slow or down. The report is still served, without incidents, until the read works again. Check the database connection.

The error and log reference list these entries too, see error reference and log reference.