Expand description
HTTP handlers, grouped as Lichess’s API docs group them.
Modules§
- account
- Account, user and bot endpoints.
- app_
files - The Chess lab training app (
web/chess, built with its wasm engine), served as static files under/app/fromCHESS_APP_DIR. - challenges
- Challenge endpoints.
- fairplay
- Fair-play review (open-chess endpoints, not Lichess’s): the
queue of flagged games, a game’s reports, a player’s record, and
reviewers’ verdicts. Needs a token with
chess:fairplayheld by a manager or an admin. - games
- Game export: PGN by default, JSON with
Accept: application/json. - lab
- open-chess additions to the Lichess API, used by the chess training app:
- oauth
- OAuth 2.0 with PKCE, as Lichess does it: no client registration (the
client_idis any name the app picks), S256 code challenges, and long-lived access tokens. - play
- Board API and Bot API game actions (the same handlers serve both; the matched path says which).
- streams
- NDJSON streams: a player’s event stream, a game’s board/bot stream and the public move stream.
Functions§
- form
- A urlencoded body (missing or empty is fine: no fields).
- html_
escape - index
GET /: what this is. Browsers go to the training app when it’s installed.- line
- One NDJSON line.
- ndjson
- The response half of an NDJSON stream; a task writes lines into the sender and stops when sending fails (the client went away).
- ok