---
title: "Health"
method: GET
path: "/health"
---

# Health

`GET /health`

## Request

- Base URL: `https://api.meetadmiral.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.meetadmiral.com/health`
- Auth: none declared

Liveness, and it has to mean something.

This is the ALB's health check (infra/ecs.tf), so what it returns
decides whether a task keeps receiving traffic. It used to return
`ok` unconditionally — so a task whose database connection had died
stayed in the target group and kept answering requests it could not
serve, and the load balancer had no way to route around it.

The query is deliberately the cheapest one there is. A health check
runs every 30 seconds per task forever; anything that touches real
tables would be a permanent load, and anything slow would turn a
busy database into a failed deploy.

It is also cached for a few seconds, because this endpoint is
unauthenticated and has to be — the ALB cannot present a credential.
Probing per request meant anyone who could reach the load balancer
could open a database connection per request, for free, without
signing in: a health check that can be used to exhaust the pool it
exists to report on. The cache makes a flood cost one `SELECT 1`
every `_HEALTH_TTL` no matter how fast it arrives, and the ALB's
30-second interval is far longer than that, so the check it gets is
always freshly measured.

## Response `200`

Successful Response

- unknown

---

[API](https://skmtc.dev/meetadmiral/apis/admiral-api.md) · [All operations](https://skmtc.dev/meetadmiral/apis/admiral-api/llms.txt) · [OpenAPI document](https://skmtc.dev/meetadmiral/apis/admiral-api/revisions/3cf1ee58ce50?raw)
