Skip to content

API reference

Health

Liveness/readiness.

Liveness/readiness check (incl. DB connectivity)

GET /health

Public — no credentials

Public and token-blind: one body for every caller, and the Authorization header is never read — a missing, invalid or revoked token changes nothing and never yields a 401. The Sidekiq worker figures moved to the operator-only GET /admin/health.

Alert on status, not on the HTTP status code. The code is liveness for the load balancer — 503 only when the database is down — and a dead Sidekiq fleet stays 200 on purpose, because the API still serves every synchronous request while jobs queue. A monitor watching only the code therefore reports a healthy gateway while nothing broadcasts or confirms. status carries ok / degraded / error.

Responses

  • 200 Service healthy. One public body for every caller — the endpoint is token-blind.
  • 503 Degraded (database unreachable). Same public body as the 200.
Terminal window
curl "https://api.rail0.xyz/health"
Response 200
{
"status": "ok",
"db": "ok",
"timestamp": "2026-10-01T12:00:00Z",
"api_version": "string",
"contract_version": "string",
"active_chains": 1,
"active_contracts": 1
}