Create chat completion
"stream": true to receive server-sent events (SSE) as each token is generated. This produces a lower time-to-first-token and is ideal for chat UIs.
data: line is a JSON object. The first chunk includes the role; subsequent chunks contain only delta.content.finish_reason is set, followed by a literal data: [DONE] line.delta.tool_calls arrives incrementally and should be concatenated by index.error key instead of choices. Close the stream and surface the error to the caller.Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Successful completion