You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The health module exposes four endpoints with different contracts and intended consumers.
Endpoints overview
Endpoint
Purpose
Consumer
GET /api/v1/health
Dependency health — probes database, Redis, and Horizon
Load balancers, uptime monitors
GET /api/v1/health/ready
Readiness — confirms all critical dependencies are reachable
Kubernetes readinessProbe, deploy gates
GET /api/v1/health/detailed
Diagnostics — full system snapshot
Operators, dashboards
GET /api/v1/health/indexer
Worker heartbeat — confirms the indexer is running
Alerting, internal monitoring
GET /api/v1/health actively probes the database (a lightweight SELECT 1), Redis (a PING), and Stellar Horizon (fetching the root endpoint). It responds 200 when every dependency is reachable and 503 when any dependency is degraded, so load balancers and uptime monitors can verify end-to-end connectivity.
GET /api/v1/health/ready also actively pings critical dependencies. A single fail result flips the response to 503, signalling to the orchestrator that this instance should stop receiving traffic until the dependency recovers.
GET /api/v1/health — dependency health check
Probes the database, Redis, and Stellar Horizon. Returns 200 when all dependencies are healthy and 503 when any is degraded. No authentication required.
true only when every check returns "ok". This field determines the HTTP status — true → 200, false → 503.
timestamp
string (ISO-8601)
When the response was built.
latencyMs
number
Total wall-clock duration of the entire readiness probe in milliseconds. Useful for dashboards and SLO tracking.
checks
array
Per-dependency probe results. See the checks table below.
checks array entry fields
Field
Type
Present when
Description
name
string
Always
Dependency name. Current values: "database", "cache".
status
string
Always
"ok" — probe passed; "fail" — probe failed.
latencyMs
number
status: "ok" and check measured a latency
Round-trip time for this probe in milliseconds.
error
string
status: "fail"
Human-readable reason for the failure. No internal hostnames, connection strings, or stack traces.
Probe descriptions
Probe name
What is checked
Healthy value
Unhealthy value
database
Issues SELECT 1 against the primary database.
"ok" + latencyMs present
"fail" + error present
cache
Verifies that the HTTP cache layer config constant is a valid number.
"ok"
"fail" + error present
Non-200 trigger
The ready field is the sole trigger. When any check in the checks array has status: "fail", ready is false and the HTTP status is 503.
The payload is intentionally public-safe: no internal hostnames, connection strings, or stack traces are included even when a check fails.
GET /api/v1/health/detailed — diagnostics
Full system snapshot including memory, uptime, system info, database response time, chain-sync lag, and per-service health flags. Intended for operators and dashboards — use the cheaper liveness and readiness paths for automated probing.
The sync state does not affect the HTTP status code of this endpoint. Use GET /api/v1/health/indexer for a dedicated alerting-friendly probe.
services array
A rolled-up health summary of each major component.
name
status: "healthy" condition
status: "unhealthy" condition
"API Server"
Always healthy (present means the server is up).
Never unhealthy in normal operation.
"Database"
database.status === "connected".
database.status === "disconnected".
"Chain Sync"
syncing.status !== "degraded" (or sync absent).
syncing.status === "degraded".
Non-200 trigger
database.status === "disconnected"andenvironment === "production" triggers a 503. In non-production environments the endpoint always returns 200 regardless of database connectivity.
Field order
The top-level JSON keys are guaranteed to appear in this order:
success
message
timestamp
version
environment
uptime
memory
system
timeouts
database
syncing
services
GET /api/v1/health/indexer — worker heartbeat
Reports the liveness state of the indexer background worker. The indexer calls POST /api/v1/health/indexer/heartbeat after each successful run; this endpoint exposes the resulting state.