Service liveness and dependency status
GET
/v1/health
const url = 'https://api.legesher.io/v1/health';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.legesher.io/v1/healthLiveness plus per-component dependency status.
Always returns 200: a deployment with a failing component is alive but ‘degraded’ (the affected endpoints answer their own 5xx). Read the JSON body, not the HTTP status, to tell a degraded deployment from a healthy one.
Responses
Section titled “ Responses ”Successful Response
Media type application/json
HealthResponse
Service liveness plus dependency status.
object
components
required
ComponentStatuses
Per-component health, one status word each.
object
database
required
Database
The key and subscription store.
string
foundation
required
Foundation
The translation engine (‘down’ when it is unavailable).
string
limiter
required
Limiter
The rate limiter.
string
foundation
required
FoundationStatus
Availability of the foundation packages on this deployment.
status
required
Status
‘degraded’ when any component is not ok.
string
version
required
Version
The API service’s version.
string
Example
{ "components": { "database": "ok", "foundation": "ok", "limiter": "ok" }, "status": "ok"}Headers
Section titled “ Headers ” X-Request-ID
string
Correlation id for this request: the validated inbound X-Request-ID when one was sent, else a server-minted UUID.