Health

Development These docs follow the development version and change with every merge.

Last updated View as Markdown

Liveness.

Back to the web API reference.

GET /health

Serves GET /health with a static ok payload for liveness probes.

Access: No auth layer. Routes that need a caller say so in security; the handler checks it.

Credentials: none

Responses

  • 200The daemon is serving HTTP. Body: HealthResponse (application/json)1 field
    • statusstringrequiredAlways ok when the process can serve HTTP.

Example request

$ curl 'http://127.0.0.1:8787/health'
Invoke-RestMethod -Uri 'http://127.0.0.1:8787/health'
import requests

response = requests.get("http://127.0.0.1:8787/health")
print(response.status_code, response.text)
const response = await fetch("http://127.0.0.1:8787/health");
console.log(response.status, await response.text());
let response = reqwest::get("http://127.0.0.1:8787/health").await?;
println!("{} {}", response.status(), response.text().await?);

Example response

Status 200: The daemon is serving HTTP.

{
  "status": "ok"
}

Schema:

{
  "type": "object",
  "description": "Liveness payload for unauthenticated `GET /health`.",
  "required": [
    "status"
  ],
  "properties": {
    "status": {
      "type": "string",
      "description": "Always `ok` when the process can serve HTTP.",
      "example": "ok"
    }
  }
}

Generated from crates/bookclerkd/openapi.json at main · View as Markdown