Chat
Chat API
Chat API
POST /v1/mind/chat — the streaming chat endpoint
POST
Chat
The chat endpoint accepts a single message and streams the reply over Server-Sent Events. The interactive playground above covers the request; the response is a stream, documented here.
Send the next message with the same
The playground sends the request but won’t render a streamed body. To see the live stream, use
curl -N or the frontend client.Request
One of
free-chat, explain-concept, submission-guide, advisor. Set a specific value when the student taps a quick action; otherwise leave free-chat and the router decides.The student’s message (1–8000 characters).
The conversation to continue. Omit on the first message; the response returns one to reuse.
What the student is viewing —
title, path, course_code, material_id. Used as a routing hint. All optional.Response — the event stream
Content-Type: text/event-stream. Frames arrive in order:
Emitted once after routing.
{ conversation_id, action, confidence } — the resolved lane.Emitted repeatedly.
{ text } — a chunk of the answer; concatenate in order.Emitted once at the end.
{ conversation_id, action, revised, remaining }. revised is a guardrail-corrected final answer (usually null); remaining is the day’s quota left (null when unlimited).Emitted instead of
deltas when the turn is blocked. { text, reason } where reason is quota_exceeded, assessment_lock, or prompt_injection. Followed by done.Example
conversation_id and MIND continues the thread. See Streaming for the full frontend client and resumption.Authorizations
Enter your JWT access token
Body
application/json
Response
Successful Response