Problem
Load balancers and orchestrators need a narrow, auth-free DB-readiness probe. The existing /api/health bundles DB + Redis + JWKS, heavier than a pure readiness gate.
Acceptance criteria
GET /api/health/ready route handler exists.
- DB reachable → 200
{ status: "ok" }.
- DB unreachable → 503
{ status: "error", error }; never throws/500.
- No auth required; uses shared Prisma singleton
db from @/lib/db.
- Standard copyright + SPDX header; mirrors
checkDatabase() conventions.
Out of scope
- Changing existing
/api/health route, Redis/JWKS probes, auth middleware, PM Agent config.
Task #383 — slug add-get-health-ready-db-readiness-endpoint
Problem
Load balancers and orchestrators need a narrow, auth-free DB-readiness probe. The existing
/api/healthbundles DB + Redis + JWKS, heavier than a pure readiness gate.Acceptance criteria
GET /api/health/readyroute handler exists.{ status: "ok" }.{ status: "error", error }; never throws/500.dbfrom@/lib/db.checkDatabase()conventions.Out of scope
/api/healthroute, Redis/JWKS probes, auth middleware, PM Agent config.Task #383 — slug
add-get-health-ready-db-readiness-endpoint