Expand description
The HTTP surface.
Routes and their auth posture are frozen:
| route | auth |
|---|---|
GET /health | none — uptime tooling holds no secret |
GET /admin | none — static markup, no data |
POST /sync, GET /sync, GET /admin/stats | bearer token |
| anything else | 404 JSON |
This module owns the shared state, the router, and the background jobs.
The four things it wires together are private submodules, each living
next to its own tests: middleware.rs (rate limiting, then auth),
handlers.rs (one function per route), respond.rs (the JSON shape of
every reply, errors included) and limit.rs (the per-IP window the
middleware consults).
Structs§
- Server
- The HTTP API, its background jobs, and the state they share.