pub struct SessionMcpServerStateChangedAction {
pub id: String,
pub state: McpServerState,
pub channel: Option<Uri>,
}Expand description
Updates the runtime fields of an existing
{@link McpServerCustomization} — narrow alternative to
{@link SessionCustomizationUpdatedAction} for the high-frequency
starting ↔ ready ↔ authRequired transitions.
Locates the target entry by id, searching both the top-level
customization list and the children array of every container.
Replaces the entry’s {@link McpServerCustomization.state | state}
and {@link McpServerCustomization.channel | channel}
(full-replacement semantics: omit channel to clear an existing
channel URI). Other fields of the customization are preserved.
Is a no-op when no matching McpServerCustomization is found. To
update any other field (name, icons, mcpApp capabilities, etc.) use
{@link SessionCustomizationUpdatedAction} instead.
When the transition is to {@link McpServerStatus.AuthRequired} because of a request issued mid-turn, the host SHOULD also raise {@link SessionStatus.InputNeeded} on the session — see {@link McpServerAuthRequiredState} for the rationale.
Fields§
§id: StringThe id of the {@link McpServerCustomization} to update.
state: McpServerStateThe new lifecycle state.
channel: Option<Uri>Updated mcp:// side-channel URI. Full-replacement: omit to clear
an existing channel (typical when leaving
{@link McpServerStatus.Ready | Ready}).
Trait Implementations§
Source§impl Clone for SessionMcpServerStateChangedAction
impl Clone for SessionMcpServerStateChangedAction
Source§fn clone(&self) -> SessionMcpServerStateChangedAction
fn clone(&self) -> SessionMcpServerStateChangedAction
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<'de> Deserialize<'de> for SessionMcpServerStateChangedAction
impl<'de> Deserialize<'de> for SessionMcpServerStateChangedAction
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 SessionMcpServerStateChangedAction
impl PartialEq for SessionMcpServerStateChangedAction
Source§fn eq(&self, other: &SessionMcpServerStateChangedAction) -> bool
fn eq(&self, other: &SessionMcpServerStateChangedAction) -> bool
self and other values to be equal, and is used by ==.