#[non_exhaustive]pub struct ClientCapabilities {
pub fs: FileSystemCapabilities,
pub terminal: bool,
pub plan: Option<PlanCapabilities>,
pub auth: AuthCapabilities,
pub elicitation: Option<ElicitationCapabilities>,
pub nes: Option<ClientNesCapabilities>,
pub position_encodings: Vec<PositionEncodingKind>,
pub meta: Option<Meta>,
}Expand description
Capabilities supported by the client.
Advertised during initialization to inform the agent about available features and methods.
See protocol docs: Client Capabilities
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.fs: FileSystemCapabilitiesFile system capabilities supported by the client. Determines which file operations the agent can request.
terminal: boolWhether the Client support all terminal/* methods.
plan: Option<PlanCapabilities>unstable_plan_operations only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
Whether the client supports plan_update and plan_removed session updates.
Optional. Omitted means the client does not advertise support.
Supplying {} means the client can receive both update types.
auth: AuthCapabilitiesunstable_auth_methods only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
Authentication capabilities supported by the client.
Determines which authentication method types the agent may include
in its InitializeResponse.
elicitation: Option<ElicitationCapabilities>unstable_elicitation only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
Elicitation capabilities supported by the client. Determines which elicitation modes the agent may use.
nes: Option<ClientNesCapabilities>unstable_nes only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
NES (Next Edit Suggestions) capabilities supported by the client.
position_encodings: Vec<PositionEncodingKind>unstable_nes only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
The position encodings supported by the client, in order of preference.
meta: Option<Meta>The _meta property is reserved by ACP to allow clients and agents to attach additional metadata to their interactions. Implementations MUST NOT make assumptions about values at these keys.
See protocol docs: Extensibility
Implementations§
Source§impl ClientCapabilities
impl ClientCapabilities
pub fn new() -> Self
Sourcepub fn fs(self, fs: FileSystemCapabilities) -> Self
pub fn fs(self, fs: FileSystemCapabilities) -> Self
File system capabilities supported by the client. Determines which file operations the agent can request.
Sourcepub fn terminal(self, terminal: bool) -> Self
pub fn terminal(self, terminal: bool) -> Self
Whether the Client support all terminal/* methods.
Sourcepub fn plan(self, plan: impl IntoOption<PlanCapabilities>) -> Self
Available on crate feature unstable_plan_operations only.
pub fn plan(self, plan: impl IntoOption<PlanCapabilities>) -> Self
unstable_plan_operations only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
Whether the client supports plan_update and plan_removed session updates.
Omitted means the client does not advertise support.
Supplying {} means the client can receive both update types.
Sourcepub fn auth(self, auth: AuthCapabilities) -> Self
Available on crate feature unstable_auth_methods only.
pub fn auth(self, auth: AuthCapabilities) -> Self
unstable_auth_methods only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
Authentication capabilities supported by the client.
Determines which authentication method types the agent may include
in its InitializeResponse.
Sourcepub fn elicitation(
self,
elicitation: impl IntoOption<ElicitationCapabilities>,
) -> Self
Available on crate feature unstable_elicitation only.
pub fn elicitation( self, elicitation: impl IntoOption<ElicitationCapabilities>, ) -> Self
unstable_elicitation only.UNSTABLE
This capability is not part of the spec yet, and may be removed or changed at any point.
Elicitation capabilities supported by the client. Determines which elicitation modes the agent may use.
Sourcepub fn nes(self, nes: impl IntoOption<ClientNesCapabilities>) -> Self
Available on crate feature unstable_nes only.
pub fn nes(self, nes: impl IntoOption<ClientNesCapabilities>) -> Self
unstable_nes only.UNSTABLE
NES (Next Edit Suggestions) capabilities supported by the client.
Sourcepub fn position_encodings(
self,
position_encodings: Vec<PositionEncodingKind>,
) -> Self
Available on crate feature unstable_nes only.
pub fn position_encodings( self, position_encodings: Vec<PositionEncodingKind>, ) -> Self
unstable_nes only.UNSTABLE
The position encodings supported by the client, in order of preference.
Sourcepub fn meta(self, meta: impl IntoOption<Meta>) -> Self
pub fn meta(self, meta: impl IntoOption<Meta>) -> Self
The _meta property is reserved by ACP to allow clients and agents to attach additional metadata to their interactions. Implementations MUST NOT make assumptions about values at these keys.
See protocol docs: Extensibility
Trait Implementations§
Source§impl Clone for ClientCapabilities
impl Clone for ClientCapabilities
Source§fn clone(&self) -> ClientCapabilities
fn clone(&self) -> ClientCapabilities
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 ClientCapabilities
impl Debug for ClientCapabilities
Source§impl Default for ClientCapabilities
impl Default for ClientCapabilities
Source§fn default() -> ClientCapabilities
fn default() -> ClientCapabilities
Source§impl<'de> Deserialize<'de> for ClientCapabilities
impl<'de> Deserialize<'de> for ClientCapabilities
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>,
impl Eq for ClientCapabilities
Source§impl IntoV2 for ClientCapabilities
Available on crate feature unstable_protocol_v2 only.
impl IntoV2 for ClientCapabilities
unstable_protocol_v2 only.Source§impl JsonSchema for ClientCapabilities
impl JsonSchema for ClientCapabilities
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 ClientCapabilities
impl PartialEq for ClientCapabilities
Source§fn eq(&self, other: &ClientCapabilities) -> bool
fn eq(&self, other: &ClientCapabilities) -> bool
self and other values to be equal, and is used by ==.