Readiness probe
const url = 'https://api.emite.cr/health/ready';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.emite.cr/health/readyPublic endpoint. Confirms the process can actually SERVE: it runs a bounded SELECT 1 against Postgres, because every authenticated request resolves tenant membership from the database and an instance that cannot reach it has nothing useful to answer. Returns 200 when the query succeeds, 503 when it fails or exceeds 2000ms. Third parties (ATV, Onvo, R2, BCCR) are deliberately NOT checked — their outages must not pull our instances out of rotation, and they already report to Sentry grouped per provider. Excluded from the global v1 prefix.
Responses
Section titled “Responses”Ready: checks.database.status is ok.
object
ok when the probe passed; error only from /health/ready, with a 503.
Seconds the process has been running.
When the probe answered.
The result of each check.
object
The Postgres check.
object
Whether a SELECT 1 against Postgres succeeded within the time limit.
How long the check took, in milliseconds.
Why the check failed, only with error: timeout when the query did not answer in time (typically an exhausted connection pool), unavailable when the database refused or failed it. The database error itself is only logged: this route is public.
Example
{ "status": "ok", "uptime": 3600.25, "checks": { "database": { "status": "ok", "error": "timeout" } }}Not ready — the database check failed or timed out (status: error).
object
ok when the probe passed; error only from /health/ready, with a 503.
Seconds the process has been running.
When the probe answered.
The result of each check.
object
The Postgres check.
object
Whether a SELECT 1 against Postgres succeeded within the time limit.
How long the check took, in milliseconds.
Why the check failed, only with error: timeout when the query did not answer in time (typically an exhausted connection pool), unavailable when the database refused or failed it. The database error itself is only logged: this route is public.
Example
{ "status": "ok", "uptime": 3600.25, "checks": { "database": { "status": "ok", "error": "timeout" } }}