Ask the assistant and stream its answer back. Both turns are stored once the answer is complete, with the answer's token usage.
Asking is doing the lesson, so it starts the lesson when the learner has not yet (409 beyond the gate, exactly as starting would). 429 once today's questions are used up — decided before anything streams.
Request
- The document declares no server URL.
- Auth: API key in cookie JWT and API key in header X-XSRF-TOKEN
Path parameters
Request body
Response
The assistant's answer, streamed as plain text while the model produces it.
ogen generates a text/plain string body as an io.Reader the encoder copies straight to the socket, which is what lets tokens reach the learner as they arrive. (bytes would not do: TypeSpec emits it as format: byte for a text content type, and ogen then base64-encodes the stream.) SSE is out of reach — ogen cannot serve it yet (ogen#1742) — and the client does not need it: the AI SDK reads a plain text stream directly.
Changes
- breaking
removed the success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the success response with the status
- breaking
- info
endpoint added
- info