#[non_exhaustive]pub struct CancelTerminalRequest {
pub session_id: SessionId,
pub terminal_id: TerminalId,
pub meta: Option<Map<String, Value>>,
}unstable_protocol_v2 only.Expand description
Request parameters for cancelling one terminal.
Clients MUST NOT send it unless the terminal currently advertises capabilities.cancel.
The Agent responds once it has accepted the cancellation. The response does not mean
the work has stopped. The Agent confirms it with a terminal_update that sets
exitStatus. Cancelling stops the process but does not release the terminal, and does
not change the status of a tool call that references it.
The Agent responds with -32602 if the terminal is unknown, has already exited, or is not
cancellable. Cancelling a terminal does not change the foreground state by itself.
See protocol docs: Cancelling Terminals
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.session_id: SessionIdThe ID of the session that owns the terminal.
terminal_id: TerminalIdThe ID of the terminal to cancel.
meta: Option<Map<String, Value>>The _meta property is reserved by ACP to allow clients and agents to attach additional
metadata to their interactions. Omitted and null are equivalent and mean no metadata.
Implementations MUST NOT assign meaning to keys they do not recognize.
See protocol docs: Extensibility
Implementations§
Source§impl CancelTerminalRequest
impl CancelTerminalRequest
Sourcepub fn new(
session_id: impl Into<SessionId>,
terminal_id: impl Into<TerminalId>,
) -> CancelTerminalRequest
pub fn new( session_id: impl Into<SessionId>, terminal_id: impl Into<TerminalId>, ) -> CancelTerminalRequest
Builds CancelTerminalRequest with the required request fields set. Optional fields start unset or empty.
Sourcepub fn meta(
self,
meta: impl IntoOption<Map<String, Value>>,
) -> CancelTerminalRequest
pub fn meta( self, meta: impl IntoOption<Map<String, Value>>, ) -> CancelTerminalRequest
The _meta property is reserved by ACP to allow clients and agents to attach additional metadata to their interactions. Implementations MUST NOT assign meaning to keys they do not recognize.
See protocol docs: Extensibility
Trait Implementations§
Source§impl Clone for CancelTerminalRequest
impl Clone for CancelTerminalRequest
Source§fn clone(&self) -> CancelTerminalRequest
fn clone(&self) -> CancelTerminalRequest
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 CancelTerminalRequest
impl Debug for CancelTerminalRequest
Source§impl<'de> Deserialize<'de> for CancelTerminalRequest
impl<'de> Deserialize<'de> for CancelTerminalRequest
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<CancelTerminalRequest, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<CancelTerminalRequest, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
impl Eq for CancelTerminalRequest
Source§impl JsonRpcMessage for CancelTerminalRequest
impl JsonRpcMessage for CancelTerminalRequest
Source§fn matches_method(method: &str) -> bool
fn matches_method(method: &str) -> bool
Source§fn to_untyped_message(&self) -> Result<UntypedMessage, Error>
fn to_untyped_message(&self) -> Result<UntypedMessage, Error>
Source§impl JsonRpcRequest for CancelTerminalRequest
impl JsonRpcRequest for CancelTerminalRequest
Source§type Response = CancelTerminalResponse
type Response = CancelTerminalResponse
Source§impl JsonSchema for CancelTerminalRequest
impl JsonSchema for CancelTerminalRequest
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreSource§impl PartialEq for CancelTerminalRequest
impl PartialEq for CancelTerminalRequest
Source§impl Serialize for CancelTerminalRequest
impl Serialize for CancelTerminalRequest
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl StructuralPartialEq for CancelTerminalRequest
Auto Trait Implementations§
impl Freeze for CancelTerminalRequest
impl RefUnwindSafe for CancelTerminalRequest
impl Send for CancelTerminalRequest
impl Sync for CancelTerminalRequest
impl Unpin for CancelTerminalRequest
impl UnsafeUnpin for CancelTerminalRequest
impl UnwindSafe for CancelTerminalRequest
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
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.