- Supports automatic reconnection with
Last-Event-IDheader - When the client reconnects, the server resumes from the last received event
- Stream terminates with
[DONE]message
Stream Event Types
The stream returnsTextStreamPartWrapper events with a discriminated type field. These events are compatible with the Vercel AI SDK format.
| Event Type | Description |
|---|---|
start | Marks the beginning of the streaming session |
start-step | Marks the beginning of an agentic step |
text-start | Marks the beginning of a text block |
text-delta | Incremental text content |
text-end | Marks the end of a text block |
reasoning-start | Marks the beginning of reasoning/thinking content |
reasoning-delta | Incremental reasoning content |
reasoning-end | Marks the end of reasoning content |
tool-input-start | Marks the beginning of tool input streaming |
tool-input-delta | Incremental tool input (JSON streaming) |
tool-input-end | Marks the end of tool input |
tool-call | Complete tool call with parsed input |
tool-result | Tool execution result |
finish-step | Marks the end of an agentic step |
finish | Marks the end of the streaming session |
error | Error during streaming |
text-delta
Incremental text content from the agent.tool-call
Complete tool call with parsed input arguments.tool-result
Tool execution result.finish
Marks the end of the streaming session.error
Error during streaming.These event types are designed to be compatible with the Vercel AI SDK streaming format, making it easy to integrate with AI SDK-based applications.