Skip to main content

Module streaming

Module streaming 

Source

Structs§

StreamEvent
A single line from --output-format stream-json output.

Enums§

BlockDelta
The incremental payload carried by a PartialMessageEvent::BlockDelta.
BlockType
The kind of content block reported by a PartialMessageEvent::BlockStart.
PartialMessageEvent
A decoded partial-message event from a streaming claude call.

Functions§

stream_query
Execute a command with streaming output, calling a handler for each NDJSON line.
stream_query_sync
Blocking mirror of stream_query. Reads NDJSON lines from the child’s stdout on a worker thread, dispatches each parsed event to handler on the caller’s thread, and drains stderr on a separate worker thread so the child can’t deadlock on a full pipe.