Skip to main content

DaemonCommand

Enum DaemonCommand 

Source
pub enum DaemonCommand {
Show 37 variants Status, Reload, ChannelSet { channel: String, account: String, enabled: bool, workspace: Option<String>, remote_tools: Option<RemoteTools>, senders: Option<Senders>, purpose: Option<Purpose>, }, ChannelLogout { channel: String, account: String, }, Delegations { all: bool, }, DelegationKill { handle: Option<String>, orphans: bool, }, RestartWhenIdle { version: Option<String>, commit: Option<String>, parent: Option<String>, max_wait_seconds: Option<u64>, }, ConfirmAsk { question: String, parent: Option<String>, timeout_seconds: Option<u64>, }, ConfirmStatus { id: String, }, ProjectCreate { name: String, workspace: String, }, ProjectStatus { project: String, }, ProjectEvents { project: String, after: Option<u64>, }, ProjectTasks { project: String, }, ProjectReport { project: String, }, ProjectTaskAdd { project: String, title: String, depends_on: Vec<String>, max_retries: u32, }, ProjectTaskUpdate { project: String, task: String, status: ProjectTaskStatus, progress: Option<String>, }, ProjectRunStart { project: String, task: String, agent: String, }, ProjectRunProgress { project: String, run: String, progress: String, }, ProjectRunFinish { project: String, run: String, status: ProjectRunStatus, }, ProjectHeartbeat { project: String, task: Option<String>, run: Option<String>, }, MailStatus { account: Option<String>, }, MailCancel { account: String, id: Option<String>, all: bool, }, Workbench { watch: bool, }, RunLog { handle: String, after: u64, limit: Option<u32>, }, WorkbenchStart { workspace: String, agent: String, prompt: String, cwd: Option<String>, model: Option<String>, effort: Option<String>, worktree: bool, }, WorkbenchSend { session: String, conversation: String, prompt: String, mode: SendMode, }, WorkbenchCancel { session: String, job: String, }, WorkbenchApprove { id: String, approved: bool, }, WorkbenchResume { session: String, job: String, }, WorkbenchDismiss { session: String, job: String, }, JobResult { session: String, job: String, }, Worktrees, WorktreeRemove { path: String, force: bool, }, Attach { session: String, conversation: String, cols: Option<u16>, rows: Option<u16>, }, AttachIo { id: String, after: u64, input: String, cols: Option<u16>, rows: Option<u16>, }, AttachDetach { id: String, }, AttachEnd { session: String, conversation: String, },
}
Expand description

What a daemon.control message asks the daemon to do.

Variants§

§

Status

Report DaemonStatus.

§

Reload

Reread channel settings and reconcile the components now.

§

ChannelSet

Enable or disable one channel account, optionally changing its workspace, remote tool grant, and whose messages it answers.

Fields

§channel: String

The chat channel, such as wechat or feishu.

§account: String

The account name within the channel.

§enabled: bool

Whether the account should run.

§workspace: Option<String>

The account’s workspace directory; None keeps the saved one.

§remote_tools: Option<RemoteTools>

Omitted keeps the saved setting.

§senders: Option<Senders>

Whose messages the account answers; omitted keeps the saved setting.

§purpose: Option<Purpose>

What a chat account carries; omitted keeps the saved setting.

§

ChannelLogout

Stop one channel account and remove its credentials and state.

Fields

§channel: String

The chat channel, such as wechat or feishu.

§account: String

The account name within the channel.

§

Delegations

List running delegations; all includes orphans awaiting cleanup.

Fields

§all: bool

Include orphans awaiting cleanup.

§

DelegationKill

Stop one delegation by handle, or every orphaned one.

Fields

§handle: Option<String>

The delegation to stop.

§orphans: bool

Stop every orphaned delegation instead.

§

RestartWhenIdle

Restart into the release installed at the daemon’s own path once the requesting delegation has finished and its report is stored and no owner message is being answered, or at max_wait_seconds anyway.

Fields

§version: Option<String>

The release the caller installed; the daemon checks it.

§commit: Option<String>

The commit it was built from, for the announcement.

§parent: Option<String>

The caller’s SCV_PARENT chain, naming the delegation to wait for.

§max_wait_seconds: Option<u64>

Longest wait before restarting anyway.

§

ConfirmAsk

Ask the owner a yes/no question in chat: in the chat that started the work parent names, or else the notify target. The reply’s confirm names the question; confirm_status then follows it.

Fields

§question: String

The question, as the owner reads it.

§parent: Option<String>

The caller’s SCV_PARENT chain, naming the delegation whose chat is asked.

§timeout_seconds: Option<u64>

How long no answer waits before it counts as no (DEFAULT_CONFIRM_SECONDS, at most MAX_CONFIRM_SECONDS).

§

ConfirmStatus

Report where the question id stands. Asking also keeps it alive: a question nobody asks about for a minute is withdrawn.

Fields

§id: String

The ID confirm_ask returned.

§

ProjectCreate

Explicitly create an owner-authorized durable project.

Fields

§name: String

Owner-visible project name.

§workspace: String

Absolute workspace directory.

§

ProjectStatus

Read a project’s reducer state without contacting an agent.

Fields

§project: String

Project name or identifier.

§

ProjectEvents

Read the append-only event history after an optional sequence.

Fields

§project: String

Project name or identifier.

§after: Option<u64>

Return events after this sequence.

§

ProjectTasks

Read current tasks and observed progress.

Fields

§project: String

Project name or identifier.

§

ProjectReport

Build a report from ledger evidence.

Fields

§project: String

Project name or identifier.

§

ProjectTaskAdd

Add a task to an explicitly created project.

Fields

§project: String

Project name or identifier.

§title: String

Owner-visible task title.

§depends_on: Vec<String>

Task identifiers that must be done first.

§max_retries: u32

Maximum failed attempts before permanent failure.

§

ProjectTaskUpdate

Record an observed task state/progress update.

Fields

§project: String

Project name or identifier.

§task: String

Task identifier.

§status: ProjectTaskStatus

New task state.

§progress: Option<String>

Optional progress text.

§

ProjectRunStart

Record a supervised agent run starting.

Fields

§project: String

Project name or identifier.

§task: String

Task identifier.

§agent: String

Agent adapter name.

§

ProjectRunProgress

Record observed progress from a run heartbeat.

Fields

§project: String

Project name or identifier.

§run: String

Run identifier.

§progress: String

Progress text.

§

ProjectRunFinish

Record an observed terminal run state.

Fields

§project: String

Project name or identifier.

§run: String

Run identifier.

§status: ProjectRunStatus

Terminal run state.

§

ProjectHeartbeat

Record a heartbeat for a project task/run.

Fields

§project: String

Project name or identifier.

§task: Option<String>

Optional task identifier.

§run: Option<String>

Optional run identifier.

§

MailStatus

List the mail actions of every running email account, or of one; the reply’s mail_actions holds them.

Fields

§account: Option<String>

The email account name; omitted, every account.

§

MailCancel

Withdraw one mail action by its ID, or every action of an account that has not started. It can never approve anything.

Fields

§account: String

The email account name.

§id: Option<String>

The action’s ID; omitted with all.

§all: bool

Withdraw every action that has not started.

§

Workbench

Report the workbench: sessions, background jobs, delegated runs, approval requests waiting for the owner, and restorable sessions.

Fields

§watch: bool

The owner is watching (a dashboard that keeps asking): for the next 15 seconds, a background job’s approval request that the session would deny unattended waits up to two minutes for the owner’s answer instead.

§

RunLog

Read a delegated run’s activity log after position after.

Fields

§handle: String

The run’s delegation handle.

§after: u64

Return events after this position; 0 reads from the start.

§limit: Option<u32>

At most this many events (default and ceiling 500).

§

WorkbenchStart

Start a background job for the owner, in the workbench’s own session for workspace: no model is involved, and the job is not reported to any model.

Fields

§workspace: String

The absolute workspace directory the job belongs to.

§agent: String

The agent to run, such as codex.

§prompt: String

The prompt, as the agent reads it.

§cwd: Option<String>

A directory inside the workspace to run in.

§model: Option<String>

The model for the agent.

§effort: Option<String>

The reasoning effort for the agent.

§worktree: bool

Run in a new git worktree of the repository holding cwd.

§

WorkbenchSend

Send the owner’s prompt to a delegated conversation of a live session (attach and take over): a new turn of it, queued behind a running turn, or added to the running turn (mode).

Fields

§session: String

The session that holds the conversation.

§conversation: String

The conversation, such as codex-2.

§prompt: String

The owner’s prompt.

§mode: SendMode

What to do while the conversation runs a turn.

§

WorkbenchCancel

Stop a background job of a live session.

Fields

§session: String

The session that owns it.

§job: String

The job, such as job-3.

§

WorkbenchApprove

Answer an approval request a background job relayed.

Fields

§id: String

The request, as the workbench listed it.

§approved: bool

Whether the request may go ahead.

§

WorkbenchResume

Run an interrupted job again in the workbench’s session for its workspace, continuing its agent’s own conversation when that agent can.

Fields

§session: String

The session that owned it.

§job: String

The job.

§

WorkbenchDismiss

Forget a finished or interrupted job’s record.

Fields

§session: String

The session that owned it.

§job: String

The job.

§

JobResult

Report one job’s state and, once it has ended, its bounded reply or error; the reply’s job_result holds them. It only reads.

Fields

§session: String

The session that owns it.

§job: String

The job.

§

Worktrees

List the git worktrees SCV created for jobs.

§

WorktreeRemove

Remove a worktree SCV created; one with uncommitted changes only with force. Its branch is kept.

Fields

§path: String

The worktree’s directory, as worktrees lists it.

§force: bool

Remove it even with uncommitted changes.

§

Attach

Take a live session’s idle conversation over in its agent’s own terminal, or attach to the takeover already running, and return its screen. Only agents whose terminal asks nothing SCV’s approval gate decides can be taken over; others are refused with why.

Fields

§session: String

The session that holds the conversation.

§conversation: String

The conversation, such as codex-2.

§cols: Option<u16>

The client’s screen width for the terminal, in cells.

§rows: Option<u16>

The client’s screen height for the terminal, in rows.

§

AttachIo

Type into an attached terminal and read what changed on its screen.

Fields

§id: String

The hold attach returned.

§after: u64

The generation the client has; 0 reads the whole screen.

§input: String

Keys to send the agent, as the bytes a terminal sends them.

§cols: Option<u16>

A new screen width, in cells.

§rows: Option<u16>

A new screen height, in rows.

§

AttachDetach

Stop watching an attached terminal; the agent keeps running in it.

Fields

§id: String

The hold attach returned.

§

AttachEnd

End a takeover: hang up the agent’s terminal, stop its process, and give the conversation back to SCV’s turns.

Fields

§session: String

The session that holds the conversation.

§conversation: String

The conversation taken over.

Trait Implementations§

Source§

impl Clone for DaemonCommand

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for DaemonCommand

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for DaemonCommand

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Eq for DaemonCommand

Source§

impl PartialEq for DaemonCommand

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for DaemonCommand

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for DaemonCommand

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.