Signs users in, from the client's /login page. A session is a token the
client keeps; signing out forgets it, with no request.
POST /api/sessions— public. Answers the user and their tokens; rate-limited per account.
v
default: Router
Mounted by api/main.ts behind the error, Open Graph and CORS middleware.
An APIException thrown by a handler becomes the JSON error response there.
Usage
import * as mod from "api/routes/sessions.ts";