pub enum ControllerAction {
Show 19 variants
New {
workspace_id: String,
profile_id: String,
bundle_id: String,
target_id: String,
title: Option<String>,
project_directory: Option<PathBuf>,
dirty_ack: Vec<String>,
},
Rename {
session_id: String,
title: String,
},
CancelTurn {
session_id: String,
},
SetConfig {
session_id: String,
key: String,
value: String,
},
SetPlanMode {
session_id: String,
active: bool,
},
RefreshQuota {
profile_id: String,
},
RefreshCapacity {
target_id: String,
},
Resume {
session_id: String,
workspace_id: String,
profile_id: String,
target_id: String,
queue: ResumeQueueDisposition,
additional_mounts: Option<Vec<AdditionalMount>>,
resource_allocation: Option<SessionResourceAllocation>,
},
Move {
request: MoveSessionRequest,
},
Open {
session_id: String,
},
Prompt {
session_id: String,
text: String,
images: Vec<ViewerPromptImage>,
},
RunShell {
session_id: String,
command: String,
},
CancelShell {
session_id: String,
shell_command_id: String,
},
Close {
session_id: String,
},
Cancel {
session_id: String,
},
StartReview {
session_id: String,
},
ResolveReview {
session_id: String,
resolution: String,
},
RemoveQueuedPrompt {
session_id: String,
queue_id: String,
},
RespondElicitation {
session_id: String,
elicitation_id: String,
response: ElicitationResponse,
},
}Expand description
The complete set of operations a phone may ask the controller to perform. Destructive force-cleanup and secret/config editing are intentionally not representable here.
Variants§
New
Fields
workspace_id: StringWhich workspace the session belongs to. Optional on the wire so a viewer cached from before workspaces reached the phone still parses, but a controller holding more than one workspace refuses an empty one rather than guessing.
dirty_ack: Vec<String>The repositories the person was shown as having uncommitted changes and chose to launch over anyway.
This names them rather than being a bare yes, so an acknowledgement cannot be replayed against a set the person never saw: if a different repository has gone dirty since the preflight, the launch stops and asks again.
Rename
Give a session a new title. The terminal calls this a rename.
CancelTurn
Stop the turn the agent is working on, leaving the session alive. This
is not Cancel, which stops a provision, resume or stop.
SetConfig
Change one setting the harness advertised, such as model or effort.
SetPlanMode
Turn plan mode on or off. The harness decides how, which is why this carries an intent rather than a mode id.
RefreshQuota
RefreshCapacity
Resume
Fields
queue: ResumeQueueDispositionadditional_mounts: Option<Vec<AdditionalMount>>A failed Move supplies the settings recorded before source teardown. Ordinary Resume requests leave these absent and retain the historical inheritance behavior.
resource_allocation: Option<SessionResourceAllocation>Move
Confirm a previously prepared move. Preparation is a separate authenticated request so changing the destination cannot be smuggled into a confirmation from an older browser form.
Fields
request: MoveSessionRequestOpen
Prompt
Fields
images: Vec<ViewerPromptImage>Images to send with the prompt. The controller turns each one into the ACP image content block its prompt path already speaks.
RunShell
CancelShell
Close
Cancel
StartReview
Review the turn this session just finished.
ResolveReview
Forward the findings, dismiss them, or cancel the open review.
RemoveQueuedPrompt
RespondElicitation
Answer one of the session’s pending form questions.
Trait Implementations§
Source§impl Clone for ControllerAction
impl Clone for ControllerAction
Source§fn clone(&self) -> ControllerAction
fn clone(&self) -> ControllerAction
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ControllerAction
impl Debug for ControllerAction
Source§impl<'de> Deserialize<'de> for ControllerAction
impl<'de> Deserialize<'de> for ControllerAction
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for ControllerAction
impl PartialEq for ControllerAction
Source§impl Serialize for ControllerAction
impl Serialize for ControllerAction
impl StructuralPartialEq for ControllerAction
Auto Trait Implementations§
impl Freeze for ControllerAction
impl RefUnwindSafe for ControllerAction
impl Send for ControllerAction
impl Sync for ControllerAction
impl Unpin for ControllerAction
impl UnsafeUnpin for ControllerAction
impl UnwindSafe for ControllerAction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more