thread/get for one thread, thread/history for replay, and thread/tree for the complete workspace tree.
Methods
Starting a thread
Clients provide the thread id. This supports reconnect and optimistic UI flows: the client can create local state immediately and reconcile it with the gateway response.mode and sandbox are PascalCase because they are Rust enum variants without snake-case renaming. origin_kind and sidebar_visibility are snake-case strings.
Thread modes
Chat and Agent are part of the thread model, not separate APIs. A client starts turns the same way in both modes through turn/start; the gateway decides which execution path to run.
In Chat mode the gateway focuses on conversation with the selected model. In Agent mode the gateway can compile richer context, expose tools, call MCP servers, invoke skills, create tasks, and coordinate subagents. Clients should show the mode clearly because it changes what a user should expect from a turn.
Composer execution mode
Thread origin also determines how a Composer submission is admitted:
Clients should render the resolved execution behavior from the thread contract. Do not infer it from sidebar visibility: a hidden task thread and a visible collaborative thread have different roles, but both are gateway-owned execution state.
Reading one thread
thread/get when opening a thread by id or reconciling after a notification. The response contains the durable thread row with its workspace id, mode, model defaults, status fields, and timestamps.
Workspace tree
thread/tree is the primary method for a sidebar or thread picker. It returns related collections: threads, folders, placements, and AGENTS.md summaries. Do not sort threads by timestamps and call it a tree; folder placement is stored separately.
agents_docs contains content-free summaries for root and folder AGENTS.md files. If another client moves a thread or changes an AGENTS.md file, your client should refresh the tree after thread/tree/changed.
See AGENTS.md API for reading and editing full file content.
Moving threads and folders
Use move methods for tree edits instead of mutating local order and hoping the gateway catches up.thread/tree afterward to render the gateway’s resulting state.
Thread history
thread/history returns durable protocol events as well as final assistant messages. Use it to rebuild a thread timeline after reconnect, crash recovery, or opening a thread on another device.
thread/timeline/page for semantic thread blocks and Turns API turn/work/page for expanded turn work; use thread/history when you need to rebuild from the thread level.
thread/history is not the semantic recall API. It gives clients durable events so they can render and recover UI. It should not be used to dump an entire old thread into a model prompt.
For agent-side “what did we discuss earlier?” behavior, Pioneer uses thread episodic context internally: visible conversation material is indexed, searched, filtered, and inserted as bounded prompt snippets when recall decides it is useful. That layer is configured through settings and described in Thread Episodic Context.
Semantic timeline page
thread/timeline/page is the paginated, semantic timeline read API used by shared client timeline reducers. It returns display-oriented blocks rather than raw event rows.
anchor is a TimelinePageAnchor: newest, oldest, before, after, or around. Cursor-based anchors carry a cursor.value.
The response includes workspaceId, threadId, projectionVersion, blocks, and page. Blocks can represent:
Use
thread/timeline/page for scrollable client timelines. Use thread/history when you need durable event replay.
Generated schemas:
/schemas/thread_timeline_page_params.json/schemas/thread_timeline_page_response.json/schemas/thread_timeline_blocks_changed_notification.json/schemas/timeline_page_anchor.json/schemas/timeline_page_info.json/schemas/timeline_block.json/schemas/timeline_block_kind.json
Unsubscribing
Notifications
Thread notifications are not a replacement for read methods. Treat them as invalidation and streaming hints, then call
thread/get, thread/tree, thread/history, thread/timeline/page, turn/work/page, or turn/work/items/get as needed.