pub enum Response {
Show 38 variants
SessionCreated {
session_id: String,
},
SessionInfo {
info: SessionInfo,
},
SessionAncestors {
sessions: Vec<SessionInfo>,
},
Sessions {
sessions: Vec<SessionInfo>,
},
SessionDeleted,
SessionArchived,
SessionRestored,
Models {
models: Vec<ModelInfo>,
},
Aliases {
global: Vec<AliasInfo>,
project: Vec<AliasInfo>,
},
ModelChanged {
model: ModelInfo,
},
Stream {
event: Box<StreamEvent>,
},
LoginSuccess {
provider: String,
},
AuthStatus {
providers: Vec<String>,
},
SubscriptionUsage {
usage: SubscriptionUsage,
},
ServerShutdown {
restart: bool,
},
SessionsCompleted {
results: Vec<SessionResult>,
},
Cancelled,
Messages {
messages: Vec<Message>,
},
UserMessage {
text: String,
},
AgentDone,
MessageReply {
content: String,
},
Ok,
OkWithNote {
note: String,
},
GcComplete {
deleted: usize,
},
ToolExecuted {
content: String,
is_error: bool,
},
TaskList {
tasks: Vec<TaskInfo>,
},
TaskDetail {
task: TaskInfo,
messages: Vec<TaskMessageInfo>,
relations: Vec<TaskRelationInfo>,
subtasks: Vec<TaskInfo>,
sessions: Vec<TaskSessionInfo>,
history: Vec<TaskHistoryInfo>,
},
TaskUpdated {
task: TaskInfo,
},
TaskStatus {
text: String,
},
TaskOverview {
active: Vec<TaskInfo>,
queued_ready: Vec<TaskInfo>,
queued_planning: Vec<TaskInfo>,
blocked: Vec<TaskInfo>,
held: Vec<TaskInfo>,
recently_merged: Vec<TaskInfo>,
recently_done: Vec<TaskInfo>,
recently_closed: Vec<TaskInfo>,
inflight_count: usize,
max_concurrent: usize,
wait_reasons: Vec<TaskWaitReasons>,
},
TaskTree {
tasks: Vec<(usize, TaskInfo)>,
},
TaskMergeQueue {
tasks: Vec<TaskInfo>,
},
ProjectStats {
stats: ProjectStatsInfo,
},
ProjectInfo {
project: Option<ProjectInfoEntry>,
},
ResolvedSuccessor {
session_id: String,
},
SessionSucceeded {
successor_id: String,
},
TaskSessionRole {
is_worker: bool,
task_id: Option<i64>,
role: Option<String>,
},
Error {
message: String,
},
}Variants§
SessionCreated
Session was created.
SessionInfo
Info about a single session.
Fields
info: SessionInfoSessionAncestors
Ancestor chain for a session, leaf-first. See Request::GetSessionAncestors.
Fields
sessions: Vec<SessionInfo>Sessions
List of sessions.
Fields
sessions: Vec<SessionInfo>SessionDeleted
Session deleted.
SessionArchived
Session archived.
SessionRestored
Session restored (un-archived).
Models
Available models.
Aliases
Configured aliases (global + per-project).
Added in protocol v0.2. Older clients will not understand this variant and will fall through to their default error path.
ModelChanged
Model changed.
Stream
Streaming event from the LLM.
Fields
event: Box<StreamEvent>LoginSuccess
OAuth login succeeded.
AuthStatus
Authentication status.
SubscriptionUsage
Subscription usage data.
Fields
usage: SubscriptionUsageServerShutdown
Server is shutting down. Clients should reconnect if restart=true.
SessionsCompleted
Sessions completed (response to WaitSessions).
Fields
results: Vec<SessionResult>Cancelled
Agent loop was cancelled by the user.
Messages
Message history for a session.
UserMessage
A user message was sent (broadcast to subscribers).
AgentDone
Agent loop completed (all turns done).
MessageReply
Reply content (returned to a QueueMessage with await_reply=true).
Ok
Success (generic ack).
OkWithNote
Success, with an advisory note from the server.
Emitted in place of Ok when the server wants to tell the caller
something about how the request was handled without treating it as
an error. Today: QueueMessage (fire-and-forget) targeting a
placeholder (log-provider) session — the note explains that the
message was recorded but no agent loop ran. See task 582.
Older clients that don’t know this variant will fall through to their default-error path; the request still succeeded on the server side.
GcComplete
Garbage-collection result.
ToolExecuted
Tool execution result (response to ExecuteTool).
TaskList
List of tasks (flat, for search/merge queue results).
TaskDetail
Full task details (response to TaskGet).
Fields
messages: Vec<TaskMessageInfo>relations: Vec<TaskRelationInfo>sessions: Vec<TaskSessionInfo>Every (session_id, role) pair recorded for this task, enriched
with best-effort session state. Missing / deleted / cross-project
sessions are dropped silently. Back-compat: older clients that
don’t know about this field ignore it.
history: Vec<TaskHistoryInfo>State transitions and other task updates in chronological order.
TaskUpdated
Task created or updated (response to TaskCreate, TaskUpdate, TaskAssign).
TaskStatus
Scheduler status text (response to TaskStatus).
TaskOverview
Structured scheduler overview (response to TaskOverview).
Fields
recently_merged: Vec<TaskInfo>Most recently merged tasks, newest first, capped at recent_limit
(the request’s per-bucket limit).
recently_done: Vec<TaskInfo>Most recently “done” tasks (no_merge tasks that completed without
producing a code change), newest first, capped at recent_limit.
recently_closed: Vec<TaskInfo>Most recently closed tasks, newest first, capped at recent_limit
(the request’s per-bucket limit; merged and closed are independent).
wait_reasons: Vec<TaskWaitReasons>For each queued/blocked task id, the full list of wait reasons
keeping it from dispatch. Dependency reasons drive the inline
⏳ #N suffix in the picker; the detail pane renders every
reason verbatim.
TaskTree
Task list with tree depth info (response to TaskList).
TaskMergeQueue
Merge queue (approved + merging tasks, response to TaskMergeQueue).
ProjectStats
Project-wide usage / cost totals (response to ProjectStats).
Fields
stats: ProjectStatsInfoProjectInfo
Project metadata (response to GetProjectInfo).
project is None when the named project does not exist; this is
not treated as an error response so callers can match on “unknown
project” cleanly.
Fields
project: Option<ProjectInfoEntry>ResolvedSuccessor
Resolved tip of a session’s successor chain (response to
Request::ResolveSuccessor). Returns the input session id
unchanged when no successor is set or the chain dead-ends at an
archived / missing successor. See task 914.
SessionSucceeded
Broadcast on the predecessor’s subscriber channel when the session
has been retired in favour of successor_id. Subscribed clients
(e.g. the TUI) typically react by switching their view to the
successor. See task 915.
TaskSessionRole
Response to Request::GetTaskSessionRole. When is_worker
is true the session is currently bound to a non-terminal task in
the role identified by role (typically "worker"); task_id
names the task. When is_worker is false (no task linkage),
task_id and role are None. See task 915.
Error
Error.