diff --git a/dotnet/src/Generated/Rpc.cs b/dotnet/src/Generated/Rpc.cs
index a93789c9a..a831d93d0 100644
--- a/dotnet/src/Generated/Rpc.cs
+++ b/dotnet/src/Generated/Rpc.cs
@@ -17,7 +17,7 @@
namespace GitHub.Copilot.SDK.Rpc;
-/// RPC data type for Ping operations.
+/// Server liveness response, including the echoed message, current timestamp, and protocol version.
public sealed class PingResult
{
/// Echoed message (or default greeting).
@@ -33,7 +33,7 @@ public sealed class PingResult
public long Timestamp { get; set; }
}
-/// RPC data type for Ping operations.
+/// Optional message to echo back to the caller.
internal sealed class PingRequest
{
/// Optional message to echo back.
@@ -41,7 +41,7 @@ internal sealed class PingRequest
public string? Message { get; set; }
}
-/// RPC data type for Connect operations.
+/// Handshake result reporting the server's protocol version and package version on success.
internal sealed class ConnectResult
{
/// Always true on success.
@@ -57,7 +57,7 @@ internal sealed class ConnectResult
public string Version { get; set; } = string.Empty;
}
-/// RPC data type for Connect operations.
+/// Optional connection token presented by the SDK client during the handshake.
internal sealed class ConnectRequest
{
/// Connection token; required when the server was started with COPILOT_CONNECTION_TOKEN.
@@ -174,7 +174,7 @@ public sealed class ModelPolicy
public string? Terms { get; set; }
}
-/// RPC data type for Model operations.
+/// Schema for the `Model` type.
public sealed class Model
{
/// Billing information.
@@ -214,7 +214,7 @@ public sealed class Model
public IList? SupportedReasoningEfforts { get; set; }
}
-/// RPC data type for ModelList operations.
+/// List of Copilot models available to the resolved user, including capabilities and billing metadata.
public sealed class ModelList
{
/// List of available models with full metadata.
@@ -230,7 +230,7 @@ internal sealed class ModelsListRequest
public string? GitHubToken { get; set; }
}
-/// RPC data type for Tool operations.
+/// Schema for the `Tool` type.
public sealed class Tool
{
/// Description of what the tool does.
@@ -254,7 +254,7 @@ public sealed class Tool
public IDictionary? Parameters { get; set; }
}
-/// RPC data type for ToolList operations.
+/// Built-in tools available for the requested model, with their parameters and instructions.
public sealed class ToolList
{
/// List of available built-in tools with metadata.
@@ -262,7 +262,7 @@ public sealed class ToolList
public IList Tools { get => field ??= []; set; }
}
-/// RPC data type for ToolsList operations.
+/// Optional model identifier whose tool overrides should be applied to the listing.
internal sealed class ToolsListRequest
{
/// Optional model ID — when provided, the returned tool list reflects model-specific overrides.
@@ -270,7 +270,7 @@ internal sealed class ToolsListRequest
public string? Model { get; set; }
}
-/// RPC data type for AccountQuotaSnapshot operations.
+/// Schema for the `AccountQuotaSnapshot` type.
public sealed class AccountQuotaSnapshot
{
/// Number of requests included in the entitlement.
@@ -308,7 +308,7 @@ public sealed class AccountQuotaSnapshot
public long UsedRequests { get; set; }
}
-/// RPC data type for AccountGetQuota operations.
+/// Quota usage snapshots for the resolved user, keyed by quota type.
public sealed class AccountGetQuotaResult
{
/// Quota snapshots keyed by type (e.g., chat, completions, premium_interactions).
@@ -324,7 +324,7 @@ internal sealed class AccountGetQuotaRequest
public string? GitHubToken { get; set; }
}
-/// RPC data type for DiscoveredMcpServer operations.
+/// Schema for the `DiscoveredMcpServer` type.
public sealed class DiscoveredMcpServer
{
/// Whether the server is enabled (not in the disabled list).
@@ -347,7 +347,7 @@ public sealed class DiscoveredMcpServer
public DiscoveredMcpServerType? Type { get; set; }
}
-/// RPC data type for McpDiscover operations.
+/// MCP servers discovered from user, workspace, plugin, and built-in sources.
public sealed class McpDiscoverResult
{
/// MCP servers discovered from all sources.
@@ -355,7 +355,7 @@ public sealed class McpDiscoverResult
public IList Servers { get => field ??= []; set; }
}
-/// RPC data type for McpDiscover operations.
+/// Optional working directory used as context for MCP server discovery.
internal sealed class McpDiscoverRequest
{
/// Working directory used as context for discovery (e.g., plugin resolution).
@@ -363,7 +363,7 @@ internal sealed class McpDiscoverRequest
public string? WorkingDirectory { get; set; }
}
-/// RPC data type for McpConfigList operations.
+/// User-configured MCP servers, keyed by server name.
public sealed class McpConfigList
{
/// All MCP servers from user config, keyed by name.
@@ -371,7 +371,7 @@ public sealed class McpConfigList
public IDictionary Servers { get => field ??= new Dictionary(); set; }
}
-/// RPC data type for McpConfigAdd operations.
+/// MCP server name and configuration to add to user configuration.
internal sealed class McpConfigAddRequest
{
/// MCP server configuration (local/stdio or remote/http).
@@ -386,7 +386,7 @@ internal sealed class McpConfigAddRequest
public string Name { get; set; } = string.Empty;
}
-/// RPC data type for McpConfigUpdate operations.
+/// MCP server name and replacement configuration to write to user configuration.
internal sealed class McpConfigUpdateRequest
{
/// MCP server configuration (local/stdio or remote/http).
@@ -401,7 +401,7 @@ internal sealed class McpConfigUpdateRequest
public string Name { get; set; } = string.Empty;
}
-/// RPC data type for McpConfigRemove operations.
+/// MCP server name to remove from user configuration.
internal sealed class McpConfigRemoveRequest
{
/// Name of the MCP server to remove.
@@ -412,7 +412,7 @@ internal sealed class McpConfigRemoveRequest
public string Name { get; set; } = string.Empty;
}
-/// RPC data type for McpConfigEnable operations.
+/// MCP server names to enable for new sessions.
internal sealed class McpConfigEnableRequest
{
/// Names of MCP servers to enable. Each server is removed from the persisted disabled list so new sessions spawn it. Unknown or already-enabled names are ignored.
@@ -420,7 +420,7 @@ internal sealed class McpConfigEnableRequest
public IList Names { get => field ??= []; set; }
}
-/// RPC data type for McpConfigDisable operations.
+/// MCP server names to disable for new sessions.
internal sealed class McpConfigDisableRequest
{
/// Names of MCP servers to disable. Each server is added to the persisted disabled list so new sessions skip it. Already-disabled names are ignored. Active sessions keep their current connections until they end.
@@ -428,7 +428,7 @@ internal sealed class McpConfigDisableRequest
public IList Names { get => field ??= []; set; }
}
-/// RPC data type for ServerSkill operations.
+/// Schema for the `ServerSkill` type.
public sealed class ServerSkill
{
/// Description of what the skill does.
@@ -460,7 +460,7 @@ public sealed class ServerSkill
public bool UserInvocable { get; set; }
}
-/// RPC data type for ServerSkillList operations.
+/// Skills discovered across global and project sources.
public sealed class ServerSkillList
{
/// All discovered skills across all sources.
@@ -468,7 +468,7 @@ public sealed class ServerSkillList
public IList Skills { get => field ??= []; set; }
}
-/// RPC data type for SkillsDiscover operations.
+/// Optional project paths and additional skill directories to include in discovery.
internal sealed class SkillsDiscoverRequest
{
/// Optional list of project directory paths to scan for project-scoped skills.
@@ -480,7 +480,7 @@ internal sealed class SkillsDiscoverRequest
public IList? SkillDirectories { get; set; }
}
-/// RPC data type for SkillsConfigSetDisabledSkills operations.
+/// Skill names to mark as disabled in global configuration, replacing any previous list.
internal sealed class SkillsConfigSetDisabledSkillsRequest
{
/// List of skill names to disable.
@@ -488,7 +488,7 @@ internal sealed class SkillsConfigSetDisabledSkillsRequest
public IList DisabledSkills { get => field ??= []; set; }
}
-/// RPC data type for SessionFsSetProvider operations.
+/// Indicates whether the calling client was registered as the session filesystem provider.
public sealed class SessionFsSetProviderResult
{
/// Whether the provider was set successfully.
@@ -496,7 +496,7 @@ public sealed class SessionFsSetProviderResult
public bool Success { get; set; }
}
-/// RPC data type for SessionFsSetProvider operations.
+/// Initial working directory, session-state path layout, and path conventions used to register the calling SDK client as the session filesystem provider.
internal sealed class SessionFsSetProviderRequest
{
/// Path conventions used by this filesystem.
@@ -512,7 +512,7 @@ internal sealed class SessionFsSetProviderRequest
public string SessionStatePath { get; set; } = string.Empty;
}
-/// RPC data type for SessionsFork operations.
+/// Identifier and optional friendly name assigned to the newly forked session.
[Experimental(Diagnostics.Experimental)]
public sealed class SessionsForkResult
{
@@ -525,7 +525,7 @@ public sealed class SessionsForkResult
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionsFork operations.
+/// Source session identifier to fork from, optional event-ID boundary, and optional friendly name for the new session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionsForkRequest
{
@@ -542,7 +542,7 @@ internal sealed class SessionsForkRequest
public string? ToEventId { get; set; }
}
-/// RPC data type for SessionSuspend operations.
+/// Identifies the target session.
internal sealed class SessionSuspendRequest
{
/// Target session identifier.
@@ -550,7 +550,7 @@ internal sealed class SessionSuspendRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for Log operations.
+/// Identifier of the session event that was emitted for the log message.
public sealed class LogResult
{
/// The unique identifier of the emitted session event.
@@ -558,7 +558,7 @@ public sealed class LogResult
public Guid EventId { get; set; }
}
-/// RPC data type for Log operations.
+/// Message text, optional severity level, persistence flag, and optional follow-up URL.
internal sealed class LogRequest
{
/// When true, the message is transient and not persisted to the session event log on disk.
@@ -584,7 +584,7 @@ internal sealed class LogRequest
public string? Url { get; set; }
}
-/// RPC data type for SessionAuthStatus operations.
+/// Authentication status and account metadata for the session.
public sealed class SessionAuthStatus
{
/// Authentication type.
@@ -612,7 +612,7 @@ public sealed class SessionAuthStatus
public string? StatusMessage { get; set; }
}
-/// RPC data type for SessionAuthGetStatus operations.
+/// Identifies the target session.
internal sealed class SessionAuthGetStatusRequest
{
/// Target session identifier.
@@ -620,7 +620,7 @@ internal sealed class SessionAuthGetStatusRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for CurrentModel operations.
+/// The currently selected model for the session.
public sealed class CurrentModel
{
/// Currently active model identifier.
@@ -628,7 +628,7 @@ public sealed class CurrentModel
public string? ModelId { get; set; }
}
-/// RPC data type for SessionModelGetCurrent operations.
+/// Identifies the target session.
internal sealed class SessionModelGetCurrentRequest
{
/// Target session identifier.
@@ -636,7 +636,7 @@ internal sealed class SessionModelGetCurrentRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for ModelSwitchTo operations.
+/// The model identifier active on the session after the switch.
public sealed class ModelSwitchToResult
{
/// Currently active model identifier after the switch.
@@ -644,7 +644,7 @@ public sealed class ModelSwitchToResult
public string? ModelId { get; set; }
}
-/// RPC data type for ModelCapabilitiesOverrideLimitsVision operations.
+/// Vision-specific limits.
public sealed class ModelCapabilitiesOverrideLimitsVision
{
/// Maximum image size in bytes.
@@ -670,17 +670,17 @@ public sealed class ModelCapabilitiesOverrideLimits
[JsonPropertyName("max_context_window_tokens")]
public long? MaxContextWindowTokens { get; set; }
- /// Gets or sets the max_output_tokens value.
+ /// Maximum number of output/completion tokens.
[Range((double)0, (double)long.MaxValue)]
[JsonPropertyName("max_output_tokens")]
public long? MaxOutputTokens { get; set; }
- /// Gets or sets the max_prompt_tokens value.
+ /// Maximum number of prompt/input tokens.
[Range((double)0, (double)long.MaxValue)]
[JsonPropertyName("max_prompt_tokens")]
public long? MaxPromptTokens { get; set; }
- /// Gets or sets the vision value.
+ /// Vision-specific limits.
[JsonPropertyName("vision")]
public ModelCapabilitiesOverrideLimitsVision? Vision { get; set; }
}
@@ -688,11 +688,11 @@ public sealed class ModelCapabilitiesOverrideLimits
/// Feature flags indicating what the model supports.
public sealed class ModelCapabilitiesOverrideSupports
{
- /// Gets or sets the reasoningEffort value.
+ /// Whether this model supports reasoning effort configuration.
[JsonPropertyName("reasoningEffort")]
public bool? ReasoningEffort { get; set; }
- /// Gets or sets the vision value.
+ /// Whether this model supports vision/image input.
[JsonPropertyName("vision")]
public bool? Vision { get; set; }
}
@@ -709,7 +709,7 @@ public sealed class ModelCapabilitiesOverride
public ModelCapabilitiesOverrideSupports? Supports { get; set; }
}
-/// RPC data type for ModelSwitchTo operations.
+/// Target model identifier and optional reasoning effort, summary, and capability overrides.
internal sealed class ModelSwitchToRequest
{
/// Override individual model capabilities resolved by the runtime.
@@ -720,16 +720,20 @@ internal sealed class ModelSwitchToRequest
[JsonPropertyName("modelId")]
public string ModelId { get; set; } = string.Empty;
- /// Reasoning effort level to use for the model.
+ /// Reasoning effort level to use for the model. "none" disables reasoning.
[JsonPropertyName("reasoningEffort")]
public string? ReasoningEffort { get; set; }
+ /// Reasoning summary mode to request for supported model clients.
+ [JsonPropertyName("reasoningSummary")]
+ public ReasoningSummary? ReasoningSummary { get; set; }
+
/// Target session identifier.
[JsonPropertyName("sessionId")]
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionModeGet operations.
+/// Identifies the target session.
internal sealed class SessionModeGetRequest
{
/// Target session identifier.
@@ -737,7 +741,7 @@ internal sealed class SessionModeGetRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for ModeSet operations.
+/// Agent interaction mode to apply to the session.
internal sealed class ModeSetRequest
{
/// The agent mode. Valid values: "interactive", "plan", "autopilot".
@@ -749,7 +753,7 @@ internal sealed class ModeSetRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for NameGet operations.
+/// The session's friendly name, or null when not yet set.
public sealed class NameGetResult
{
/// The session name (user-set or auto-generated), or null if not yet set.
@@ -757,7 +761,7 @@ public sealed class NameGetResult
public string? Name { get; set; }
}
-/// RPC data type for SessionNameGet operations.
+/// Identifies the target session.
internal sealed class SessionNameGetRequest
{
/// Target session identifier.
@@ -765,7 +769,7 @@ internal sealed class SessionNameGetRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for NameSet operations.
+/// New friendly name to apply to the session.
internal sealed class NameSetRequest
{
/// New session name (1–100 characters, trimmed of leading/trailing whitespace).
@@ -780,7 +784,7 @@ internal sealed class NameSetRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for PlanRead operations.
+/// Existence, contents, and resolved path of the session plan file.
public sealed class PlanReadResult
{
/// The content of the plan file, or null if it does not exist.
@@ -796,7 +800,7 @@ public sealed class PlanReadResult
public string? Path { get; set; }
}
-/// RPC data type for SessionPlanRead operations.
+/// Identifies the target session.
internal sealed class SessionPlanReadRequest
{
/// Target session identifier.
@@ -804,7 +808,7 @@ internal sealed class SessionPlanReadRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for PlanUpdate operations.
+/// Replacement contents to write to the session plan file.
internal sealed class PlanUpdateRequest
{
/// The new content for the plan file.
@@ -816,7 +820,7 @@ internal sealed class PlanUpdateRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionPlanDelete operations.
+/// Identifies the target session.
internal sealed class SessionPlanDeleteRequest
{
/// Target session identifier.
@@ -893,7 +897,7 @@ public sealed class WorkspacesGetWorkspaceResultWorkspace
public bool? UserNamed { get; set; }
}
-/// RPC data type for WorkspacesGetWorkspace operations.
+/// Current workspace metadata for the session, or null when not available.
public sealed class WorkspacesGetWorkspaceResult
{
/// Current workspace metadata, or null if not available.
@@ -901,7 +905,7 @@ public sealed class WorkspacesGetWorkspaceResult
public WorkspacesGetWorkspaceResultWorkspace? Workspace { get; set; }
}
-/// RPC data type for SessionWorkspacesGetWorkspace operations.
+/// Identifies the target session.
internal sealed class SessionWorkspacesGetWorkspaceRequest
{
/// Target session identifier.
@@ -909,7 +913,7 @@ internal sealed class SessionWorkspacesGetWorkspaceRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for WorkspacesListFiles operations.
+/// Relative paths of files stored in the session workspace files directory.
public sealed class WorkspacesListFilesResult
{
/// Relative file paths in the workspace files directory.
@@ -917,7 +921,7 @@ public sealed class WorkspacesListFilesResult
public IList Files { get => field ??= []; set; }
}
-/// RPC data type for SessionWorkspacesListFiles operations.
+/// Identifies the target session.
internal sealed class SessionWorkspacesListFilesRequest
{
/// Target session identifier.
@@ -925,7 +929,7 @@ internal sealed class SessionWorkspacesListFilesRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for WorkspacesReadFile operations.
+/// Contents of the requested workspace file as a UTF-8 string.
public sealed class WorkspacesReadFileResult
{
/// File content as a UTF-8 string.
@@ -933,7 +937,7 @@ public sealed class WorkspacesReadFileResult
public string Content { get; set; } = string.Empty;
}
-/// RPC data type for WorkspacesReadFile operations.
+/// Relative path of the workspace file to read.
internal sealed class WorkspacesReadFileRequest
{
/// Relative path within the workspace files directory.
@@ -945,7 +949,7 @@ internal sealed class WorkspacesReadFileRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for WorkspacesCreateFile operations.
+/// Relative path and UTF-8 content for the workspace file to create or overwrite.
internal sealed class WorkspacesCreateFileRequest
{
/// File content to write as a UTF-8 string.
@@ -961,7 +965,7 @@ internal sealed class WorkspacesCreateFileRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for InstructionsSources operations.
+/// Schema for the `InstructionsSources` type.
public sealed class InstructionsSources
{
/// Glob pattern from frontmatter — when set, this instruction applies only to matching files.
@@ -997,7 +1001,7 @@ public sealed class InstructionsSources
public InstructionsSourcesType Type { get; set; }
}
-/// RPC data type for InstructionsGetSources operations.
+/// Instruction sources loaded for the session, in merge order.
public sealed class InstructionsGetSourcesResult
{
/// Instruction sources for the session.
@@ -1005,7 +1009,7 @@ public sealed class InstructionsGetSourcesResult
public IList Sources { get => field ??= []; set; }
}
-/// RPC data type for SessionInstructionsGetSources operations.
+/// Identifies the target session.
internal sealed class SessionInstructionsGetSourcesRequest
{
/// Target session identifier.
@@ -1013,7 +1017,7 @@ internal sealed class SessionInstructionsGetSourcesRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for FleetStart operations.
+/// Indicates whether fleet mode was successfully activated.
[Experimental(Diagnostics.Experimental)]
public sealed class FleetStartResult
{
@@ -1022,7 +1026,7 @@ public sealed class FleetStartResult
public bool Started { get; set; }
}
-/// RPC data type for FleetStart operations.
+/// Optional user prompt to combine with the fleet orchestration instructions.
[Experimental(Diagnostics.Experimental)]
internal sealed class FleetStartRequest
{
@@ -1035,7 +1039,7 @@ internal sealed class FleetStartRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for AgentInfo operations.
+/// Schema for the `AgentInfo` type.
public sealed class AgentInfo
{
/// Description of the agent's purpose.
@@ -1055,7 +1059,7 @@ public sealed class AgentInfo
public string? Path { get; set; }
}
-/// RPC data type for AgentList operations.
+/// Custom agents available to the session.
[Experimental(Diagnostics.Experimental)]
public sealed class AgentList
{
@@ -1064,7 +1068,7 @@ public sealed class AgentList
public IList Agents { get => field ??= []; set; }
}
-/// RPC data type for SessionAgentList operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionAgentListRequest
{
@@ -1073,7 +1077,7 @@ internal sealed class SessionAgentListRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for AgentGetCurrent operations.
+/// The currently selected custom agent, or null when using the default agent.
[Experimental(Diagnostics.Experimental)]
public sealed class AgentGetCurrentResult
{
@@ -1082,7 +1086,7 @@ public sealed class AgentGetCurrentResult
public AgentInfo? Agent { get; set; }
}
-/// RPC data type for SessionAgentGetCurrent operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionAgentGetCurrentRequest
{
@@ -1091,7 +1095,7 @@ internal sealed class SessionAgentGetCurrentRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for AgentSelect operations.
+/// The newly selected custom agent.
[Experimental(Diagnostics.Experimental)]
public sealed class AgentSelectResult
{
@@ -1100,7 +1104,7 @@ public sealed class AgentSelectResult
public AgentInfo Agent { get => field ??= new(); set; }
}
-/// RPC data type for AgentSelect operations.
+/// Name of the custom agent to select for subsequent turns.
[Experimental(Diagnostics.Experimental)]
internal sealed class AgentSelectRequest
{
@@ -1113,7 +1117,7 @@ internal sealed class AgentSelectRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionAgentDeselect operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionAgentDeselectRequest
{
@@ -1122,7 +1126,7 @@ internal sealed class SessionAgentDeselectRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for AgentReload operations.
+/// Custom agents available to the session after reloading definitions from disk.
[Experimental(Diagnostics.Experimental)]
public sealed class AgentReloadResult
{
@@ -1131,7 +1135,7 @@ public sealed class AgentReloadResult
public IList Agents { get => field ??= []; set; }
}
-/// RPC data type for SessionAgentReload operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionAgentReloadRequest
{
@@ -1140,7 +1144,7 @@ internal sealed class SessionAgentReloadRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for TasksStartAgent operations.
+/// Identifier assigned to the newly started background agent task.
[Experimental(Diagnostics.Experimental)]
public sealed class TasksStartAgentResult
{
@@ -1149,7 +1153,7 @@ public sealed class TasksStartAgentResult
public string AgentId { get; set; } = string.Empty;
}
-/// RPC data type for TasksStartAgent operations.
+/// Agent type, prompt, name, and optional description and model override for the new task.
[Experimental(Diagnostics.Experimental)]
internal sealed class TasksStartAgentRequest
{
@@ -1178,7 +1182,8 @@ internal sealed class TasksStartAgentRequest
public string SessionId { get; set; } = string.Empty;
}
-/// Polymorphic base type discriminated by type .
+/// Schema for the `TaskInfo` type.
+/// Polymorphic base type discriminated by type .
[JsonPolymorphic(
TypeDiscriminatorPropertyName = "type",
UnknownDerivedTypeHandling = JsonUnknownDerivedTypeHandling.FallBackToBaseType)]
@@ -1192,7 +1197,8 @@ public partial class TaskInfo
}
-/// The agent variant of .
+/// Schema for the `TaskAgentInfo` type.
+/// The agent variant of .
public partial class TaskInfoAgent : TaskInfo
{
///
@@ -1279,7 +1285,8 @@ public partial class TaskInfoAgent : TaskInfo
public required string ToolCallId { get; set; }
}
-/// The shell variant of .
+/// Schema for the `TaskShellInfo` type.
+/// The shell variant of .
public partial class TaskInfoShell : TaskInfo
{
///
@@ -1336,7 +1343,7 @@ public partial class TaskInfoShell : TaskInfo
public required TaskShellInfoStatus Status { get; set; }
}
-/// RPC data type for TaskList operations.
+/// Background tasks currently tracked by the session.
[Experimental(Diagnostics.Experimental)]
public sealed class TaskList
{
@@ -1345,7 +1352,7 @@ public sealed class TaskList
public IList Tasks { get => field ??= []; set; }
}
-/// RPC data type for SessionTasksList operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionTasksListRequest
{
@@ -1354,7 +1361,7 @@ internal sealed class SessionTasksListRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for TasksPromoteToBackground operations.
+/// Indicates whether the task was successfully promoted to background mode.
[Experimental(Diagnostics.Experimental)]
public sealed class TasksPromoteToBackgroundResult
{
@@ -1363,7 +1370,7 @@ public sealed class TasksPromoteToBackgroundResult
public bool Promoted { get; set; }
}
-/// RPC data type for TasksPromoteToBackground operations.
+/// Identifier of the task to promote to background mode.
[Experimental(Diagnostics.Experimental)]
internal sealed class TasksPromoteToBackgroundRequest
{
@@ -1376,7 +1383,7 @@ internal sealed class TasksPromoteToBackgroundRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for TasksCancel operations.
+/// Indicates whether the background task was successfully cancelled.
[Experimental(Diagnostics.Experimental)]
public sealed class TasksCancelResult
{
@@ -1385,7 +1392,7 @@ public sealed class TasksCancelResult
public bool Cancelled { get; set; }
}
-/// RPC data type for TasksCancel operations.
+/// Identifier of the background task to cancel.
[Experimental(Diagnostics.Experimental)]
internal sealed class TasksCancelRequest
{
@@ -1398,7 +1405,7 @@ internal sealed class TasksCancelRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for TasksRemove operations.
+/// Indicates whether the task was removed. False when the task does not exist or is still running/idle.
[Experimental(Diagnostics.Experimental)]
public sealed class TasksRemoveResult
{
@@ -1407,7 +1414,7 @@ public sealed class TasksRemoveResult
public bool Removed { get; set; }
}
-/// RPC data type for TasksRemove operations.
+/// Identifier of the completed or cancelled task to remove from tracking.
[Experimental(Diagnostics.Experimental)]
internal sealed class TasksRemoveRequest
{
@@ -1420,7 +1427,7 @@ internal sealed class TasksRemoveRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for TasksSendMessage operations.
+/// Indicates whether the message was delivered, with an error message when delivery failed.
[Experimental(Diagnostics.Experimental)]
public sealed class TasksSendMessageResult
{
@@ -1433,7 +1440,7 @@ public sealed class TasksSendMessageResult
public bool Sent { get; set; }
}
-/// RPC data type for TasksSendMessage operations.
+/// Identifier of the target agent task, message content, and optional sender agent ID.
[Experimental(Diagnostics.Experimental)]
internal sealed class TasksSendMessageRequest
{
@@ -1454,7 +1461,7 @@ internal sealed class TasksSendMessageRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for Skill operations.
+/// Schema for the `Skill` type.
public sealed class Skill
{
/// Description of what the skill does.
@@ -1482,7 +1489,7 @@ public sealed class Skill
public bool UserInvocable { get; set; }
}
-/// RPC data type for SkillList operations.
+/// Skills available to the session, with their enabled state.
[Experimental(Diagnostics.Experimental)]
public sealed class SkillList
{
@@ -1491,7 +1498,7 @@ public sealed class SkillList
public IList Skills { get => field ??= []; set; }
}
-/// RPC data type for SessionSkillsList operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionSkillsListRequest
{
@@ -1500,7 +1507,7 @@ internal sealed class SessionSkillsListRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SkillsEnable operations.
+/// Name of the skill to enable for the session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SkillsEnableRequest
{
@@ -1513,7 +1520,7 @@ internal sealed class SkillsEnableRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SkillsDisable operations.
+/// Name of the skill to disable for the session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SkillsDisableRequest
{
@@ -1526,7 +1533,7 @@ internal sealed class SkillsDisableRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SkillsLoadDiagnostics operations.
+/// Diagnostics from reloading skill definitions, with warnings and errors as separate lists.
[Experimental(Diagnostics.Experimental)]
public sealed class SkillsLoadDiagnostics
{
@@ -1539,7 +1546,7 @@ public sealed class SkillsLoadDiagnostics
public IList Warnings { get => field ??= []; set; }
}
-/// RPC data type for SessionSkillsReload operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionSkillsReloadRequest
{
@@ -1548,7 +1555,7 @@ internal sealed class SessionSkillsReloadRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for McpServer operations.
+/// Schema for the `McpServer` type.
public sealed class McpServer
{
/// Error message if the server failed to connect.
@@ -1571,7 +1578,7 @@ public sealed class McpServer
public McpServerStatus Status { get; set; }
}
-/// RPC data type for McpServerList operations.
+/// MCP servers configured for the session, with their connection status.
[Experimental(Diagnostics.Experimental)]
public sealed class McpServerList
{
@@ -1580,7 +1587,7 @@ public sealed class McpServerList
public IList Servers { get => field ??= []; set; }
}
-/// RPC data type for SessionMcpList operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionMcpListRequest
{
@@ -1589,7 +1596,7 @@ internal sealed class SessionMcpListRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for McpEnable operations.
+/// Name of the MCP server to enable for the session.
[Experimental(Diagnostics.Experimental)]
internal sealed class McpEnableRequest
{
@@ -1605,7 +1612,7 @@ internal sealed class McpEnableRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for McpDisable operations.
+/// Name of the MCP server to disable for the session.
[Experimental(Diagnostics.Experimental)]
internal sealed class McpDisableRequest
{
@@ -1621,7 +1628,7 @@ internal sealed class McpDisableRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionMcpReload operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionMcpReloadRequest
{
@@ -1630,7 +1637,7 @@ internal sealed class SessionMcpReloadRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for McpOauthLogin operations.
+/// OAuth authorization URL the caller should open, or empty when cached tokens already authenticated the server.
[Experimental(Diagnostics.Experimental)]
public sealed class McpOauthLoginResult
{
@@ -1639,7 +1646,7 @@ public sealed class McpOauthLoginResult
public string? AuthorizationUrl { get; set; }
}
-/// RPC data type for McpOauthLogin operations.
+/// Remote MCP server name and optional overrides controlling reauthentication, OAuth client display name, and the callback success-page copy.
[Experimental(Diagnostics.Experimental)]
internal sealed class McpOauthLoginRequest
{
@@ -1667,7 +1674,7 @@ internal sealed class McpOauthLoginRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for Plugin operations.
+/// Schema for the `Plugin` type.
public sealed class Plugin
{
/// Whether the plugin is currently enabled.
@@ -1687,7 +1694,7 @@ public sealed class Plugin
public string? Version { get; set; }
}
-/// RPC data type for PluginList operations.
+/// Plugins installed for the session, with their enabled state and version metadata.
[Experimental(Diagnostics.Experimental)]
public sealed class PluginList
{
@@ -1696,7 +1703,7 @@ public sealed class PluginList
public IList Plugins { get => field ??= []; set; }
}
-/// RPC data type for SessionPluginsList operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionPluginsListRequest
{
@@ -1705,7 +1712,7 @@ internal sealed class SessionPluginsListRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for Extension operations.
+/// Schema for the `Extension` type.
public sealed class Extension
{
/// Source-qualified ID (e.g., 'project:my-ext', 'user:auth-helper').
@@ -1729,7 +1736,7 @@ public sealed class Extension
public ExtensionStatus Status { get; set; }
}
-/// RPC data type for ExtensionList operations.
+/// Extensions discovered for the session, with their current status.
[Experimental(Diagnostics.Experimental)]
public sealed class ExtensionList
{
@@ -1738,7 +1745,7 @@ public sealed class ExtensionList
public IList Extensions { get => field ??= []; set; }
}
-/// RPC data type for SessionExtensionsList operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionExtensionsListRequest
{
@@ -1747,7 +1754,7 @@ internal sealed class SessionExtensionsListRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for ExtensionsEnable operations.
+/// Source-qualified extension identifier to enable for the session.
[Experimental(Diagnostics.Experimental)]
internal sealed class ExtensionsEnableRequest
{
@@ -1760,7 +1767,7 @@ internal sealed class ExtensionsEnableRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for ExtensionsDisable operations.
+/// Source-qualified extension identifier to disable for the session.
[Experimental(Diagnostics.Experimental)]
internal sealed class ExtensionsDisableRequest
{
@@ -1773,7 +1780,7 @@ internal sealed class ExtensionsDisableRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionExtensionsReload operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionExtensionsReloadRequest
{
@@ -1782,7 +1789,7 @@ internal sealed class SessionExtensionsReloadRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for HandlePendingToolCall operations.
+/// Indicates whether the external tool call result was handled successfully.
public sealed class HandlePendingToolCallResult
{
/// Whether the tool call result was handled successfully.
@@ -1790,7 +1797,7 @@ public sealed class HandlePendingToolCallResult
public bool Success { get; set; }
}
-/// RPC data type for HandlePendingToolCall operations.
+/// Pending external tool call request ID, with the tool result or an error describing why it failed.
internal sealed class HandlePendingToolCallRequest
{
/// Error message if the tool call failed.
@@ -1830,7 +1837,7 @@ public sealed class SlashCommandInput
public bool? Required { get; set; }
}
-/// RPC data type for SlashCommandInfo operations.
+/// Schema for the `SlashCommandInfo` type.
public sealed class SlashCommandInfo
{
/// Canonical aliases without leading slashes.
@@ -1862,7 +1869,7 @@ public sealed class SlashCommandInfo
public string Name { get; set; } = string.Empty;
}
-/// RPC data type for CommandList operations.
+/// Slash commands available in the session, after applying any include/exclude filters.
public sealed class CommandList
{
/// Commands available in this session.
@@ -1870,7 +1877,7 @@ public sealed class CommandList
public IList Commands { get => field ??= []; set; }
}
-/// RPC data type for CommandsList operations.
+/// Optional filters controlling which command sources to include in the listing.
public sealed class CommandsListRequest
{
/// Include runtime built-in commands.
@@ -1886,7 +1893,7 @@ public sealed class CommandsListRequest
public bool? IncludeSkills { get; set; }
}
-/// RPC data type for CommandsListRequestWithSession operations.
+/// Optional filters controlling which command sources to include in the listing.
internal sealed class CommandsListRequestWithSession
{
/// Include runtime built-in commands.
@@ -1906,7 +1913,8 @@ internal sealed class CommandsListRequestWithSession
public string SessionId { get; set; } = string.Empty;
}
-/// Polymorphic base type discriminated by kind .
+/// Result of invoking the slash command (text output, prompt to send to the agent, or completion).
+/// Polymorphic base type discriminated by kind .
[JsonPolymorphic(
TypeDiscriminatorPropertyName = "kind",
UnknownDerivedTypeHandling = JsonUnknownDerivedTypeHandling.FallBackToBaseType)]
@@ -1921,7 +1929,8 @@ public partial class SlashCommandInvocationResult
}
-/// The text variant of .
+/// Schema for the `SlashCommandTextResult` type.
+/// The text variant of .
public partial class SlashCommandInvocationResultText : SlashCommandInvocationResult
{
///
@@ -1948,7 +1957,8 @@ public partial class SlashCommandInvocationResultText : SlashCommandInvocationRe
public required string Text { get; set; }
}
-/// The agent-prompt variant of .
+/// Schema for the `SlashCommandAgentPromptResult` type.
+/// The agent-prompt variant of .
public partial class SlashCommandInvocationResultAgentPrompt : SlashCommandInvocationResult
{
///
@@ -1974,7 +1984,8 @@ public partial class SlashCommandInvocationResultAgentPrompt : SlashCommandInvoc
public bool? RuntimeSettingsChanged { get; set; }
}
-/// The completed variant of .
+/// Schema for the `SlashCommandCompletedResult` type.
+/// The completed variant of .
public partial class SlashCommandInvocationResultCompleted : SlashCommandInvocationResult
{
///
@@ -1992,7 +2003,7 @@ public partial class SlashCommandInvocationResultCompleted : SlashCommandInvocat
public bool? RuntimeSettingsChanged { get; set; }
}
-/// RPC data type for CommandsInvoke operations.
+/// Slash command name and optional raw input string to invoke.
internal sealed class CommandsInvokeRequest
{
/// Raw input after the command name.
@@ -2008,7 +2019,7 @@ internal sealed class CommandsInvokeRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for CommandsHandlePendingCommand operations.
+/// Indicates whether the pending client-handled command was completed successfully.
public sealed class CommandsHandlePendingCommandResult
{
/// Whether the command was handled successfully.
@@ -2016,7 +2027,7 @@ public sealed class CommandsHandlePendingCommandResult
public bool Success { get; set; }
}
-/// RPC data type for CommandsHandlePendingCommand operations.
+/// Pending command request ID and an optional error if the client handler failed.
internal sealed class CommandsHandlePendingCommandRequest
{
/// Error message if the command handler failed.
@@ -2032,7 +2043,7 @@ internal sealed class CommandsHandlePendingCommandRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for CommandsRespondToQueuedCommand operations.
+/// Indicates whether the queued-command response was accepted by the session.
public sealed class CommandsRespondToQueuedCommandResult
{
/// Whether the response was accepted (false if the requestId was not found or already resolved).
@@ -2054,7 +2065,7 @@ public partial class QueuedCommandResult
public bool? StopProcessingQueue { get; set; }
}
-/// RPC data type for CommandsRespondToQueuedCommand operations.
+/// Queued command request ID and the result indicating whether the client handled it.
internal sealed class CommandsRespondToQueuedCommandRequest
{
/// Request ID from the queued command event.
@@ -2098,7 +2109,7 @@ public sealed class UIElicitationSchema
public string Type { get; set; } = string.Empty;
}
-/// RPC data type for UIElicitation operations.
+/// Prompt message and JSON schema describing the form fields to elicit from the user.
internal sealed class UIElicitationRequest
{
/// Message describing what information is needed from the user.
@@ -2114,7 +2125,7 @@ internal sealed class UIElicitationRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for UIElicitation operations.
+/// Indicates whether the elicitation response was accepted; false if it was already resolved by another client.
public sealed class UIElicitationResult
{
/// Whether the response was accepted. False if the request was already resolved by another client.
@@ -2122,7 +2133,7 @@ public sealed class UIElicitationResult
public bool Success { get; set; }
}
-/// RPC data type for UIHandlePendingElicitation operations.
+/// Pending elicitation request ID and the user's response (accept/decline/cancel + form values).
internal sealed class UIHandlePendingElicitationRequest
{
/// The unique request ID from the elicitation.requested event.
@@ -2138,7 +2149,7 @@ internal sealed class UIHandlePendingElicitationRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for PermissionRequest operations.
+/// Indicates whether the permission decision was applied; false when the request was already resolved.
public sealed class PermissionRequestResult
{
/// Whether the permission request was handled successfully.
@@ -2146,7 +2157,8 @@ public sealed class PermissionRequestResult
public bool Success { get; set; }
}
-/// Polymorphic base type discriminated by kind .
+/// Decision to apply to a pending permission request.
+/// Polymorphic base type discriminated by kind .
[JsonPolymorphic(
TypeDiscriminatorPropertyName = "kind",
UnknownDerivedTypeHandling = JsonUnknownDerivedTypeHandling.FallBackToBaseType)]
@@ -2164,7 +2176,8 @@ public partial class PermissionDecision
}
-/// The approve-once variant of .
+/// Schema for the `PermissionDecisionApproveOnce` type.
+/// The approve-once variant of .
public partial class PermissionDecisionApproveOnce : PermissionDecision
{
///
@@ -2194,19 +2207,21 @@ public partial class PermissionDecisionApproveForSessionApproval
}
-/// The commands variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalCommands` type.
+/// The commands variant of .
public partial class PermissionDecisionApproveForSessionApprovalCommands : PermissionDecisionApproveForSessionApproval
{
///
[JsonIgnore]
public override string Kind => "commands";
- /// Gets or sets the commandIdentifiers value.
+ /// Command identifiers covered by this approval.
[JsonPropertyName("commandIdentifiers")]
public required IList CommandIdentifiers { get; set; }
}
-/// The read variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalRead` type.
+/// The read variant of .
public partial class PermissionDecisionApproveForSessionApprovalRead : PermissionDecisionApproveForSessionApproval
{
///
@@ -2214,7 +2229,8 @@ public partial class PermissionDecisionApproveForSessionApprovalRead : Permissio
public override string Kind => "read";
}
-/// The write variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalWrite` type.
+/// The write variant of .
public partial class PermissionDecisionApproveForSessionApprovalWrite : PermissionDecisionApproveForSessionApproval
{
///
@@ -2222,35 +2238,38 @@ public partial class PermissionDecisionApproveForSessionApprovalWrite : Permissi
public override string Kind => "write";
}
-/// The mcp variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalMcp` type.
+/// The mcp variant of .
public partial class PermissionDecisionApproveForSessionApprovalMcp : PermissionDecisionApproveForSessionApproval
{
///
[JsonIgnore]
public override string Kind => "mcp";
- /// Gets or sets the serverName value.
+ /// MCP server name.
[JsonPropertyName("serverName")]
public required string ServerName { get; set; }
- /// Gets or sets the toolName value.
+ /// MCP tool name, or null to cover every tool on the server.
[JsonPropertyName("toolName")]
public string? ToolName { get; set; }
}
-/// The mcp-sampling variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalMcpSampling` type.
+/// The mcp-sampling variant of .
public partial class PermissionDecisionApproveForSessionApprovalMcpSampling : PermissionDecisionApproveForSessionApproval
{
///
[JsonIgnore]
public override string Kind => "mcp-sampling";
- /// Gets or sets the serverName value.
+ /// MCP server name.
[JsonPropertyName("serverName")]
public required string ServerName { get; set; }
}
-/// The memory variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalMemory` type.
+/// The memory variant of .
public partial class PermissionDecisionApproveForSessionApprovalMemory : PermissionDecisionApproveForSessionApproval
{
///
@@ -2258,44 +2277,48 @@ public partial class PermissionDecisionApproveForSessionApprovalMemory : Permiss
public override string Kind => "memory";
}
-/// The custom-tool variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalCustomTool` type.
+/// The custom-tool variant of .
public partial class PermissionDecisionApproveForSessionApprovalCustomTool : PermissionDecisionApproveForSessionApproval
{
///
[JsonIgnore]
public override string Kind => "custom-tool";
- /// Gets or sets the toolName value.
+ /// Custom tool name.
[JsonPropertyName("toolName")]
public required string ToolName { get; set; }
}
-/// The extension-management variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalExtensionManagement` type.
+/// The extension-management variant of .
public partial class PermissionDecisionApproveForSessionApprovalExtensionManagement : PermissionDecisionApproveForSessionApproval
{
///
[JsonIgnore]
public override string Kind => "extension-management";
- /// Gets or sets the operation value.
+ /// Optional operation identifier; when omitted, the approval covers all extension management operations.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("operation")]
public string? Operation { get; set; }
}
-/// The extension-permission-access variant of .
+/// Schema for the `PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess` type.
+/// The extension-permission-access variant of .
public partial class PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess : PermissionDecisionApproveForSessionApproval
{
///
[JsonIgnore]
public override string Kind => "extension-permission-access";
- /// Gets or sets the extensionName value.
+ /// Extension name.
[JsonPropertyName("extensionName")]
public required string ExtensionName { get; set; }
}
-/// The approve-for-session variant of .
+/// Schema for the `PermissionDecisionApproveForSession` type.
+/// The approve-for-session variant of .
public partial class PermissionDecisionApproveForSession : PermissionDecision
{
///
@@ -2335,19 +2358,21 @@ public partial class PermissionDecisionApproveForLocationApproval
}
-/// The commands variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalCommands` type.
+/// The commands variant of .
public partial class PermissionDecisionApproveForLocationApprovalCommands : PermissionDecisionApproveForLocationApproval
{
///
[JsonIgnore]
public override string Kind => "commands";
- /// Gets or sets the commandIdentifiers value.
+ /// Command identifiers covered by this approval.
[JsonPropertyName("commandIdentifiers")]
public required IList CommandIdentifiers { get; set; }
}
-/// The read variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalRead` type.
+/// The read variant of .
public partial class PermissionDecisionApproveForLocationApprovalRead : PermissionDecisionApproveForLocationApproval
{
///
@@ -2355,7 +2380,8 @@ public partial class PermissionDecisionApproveForLocationApprovalRead : Permissi
public override string Kind => "read";
}
-/// The write variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalWrite` type.
+/// The write variant of .
public partial class PermissionDecisionApproveForLocationApprovalWrite : PermissionDecisionApproveForLocationApproval
{
///
@@ -2363,35 +2389,38 @@ public partial class PermissionDecisionApproveForLocationApprovalWrite : Permiss
public override string Kind => "write";
}
-/// The mcp variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalMcp` type.
+/// The mcp variant of .
public partial class PermissionDecisionApproveForLocationApprovalMcp : PermissionDecisionApproveForLocationApproval
{
///
[JsonIgnore]
public override string Kind => "mcp";
- /// Gets or sets the serverName value.
+ /// MCP server name.
[JsonPropertyName("serverName")]
public required string ServerName { get; set; }
- /// Gets or sets the toolName value.
+ /// MCP tool name, or null to cover every tool on the server.
[JsonPropertyName("toolName")]
public string? ToolName { get; set; }
}
-/// The mcp-sampling variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalMcpSampling` type.
+/// The mcp-sampling variant of .
public partial class PermissionDecisionApproveForLocationApprovalMcpSampling : PermissionDecisionApproveForLocationApproval
{
///
[JsonIgnore]
public override string Kind => "mcp-sampling";
- /// Gets or sets the serverName value.
+ /// MCP server name.
[JsonPropertyName("serverName")]
public required string ServerName { get; set; }
}
-/// The memory variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalMemory` type.
+/// The memory variant of .
public partial class PermissionDecisionApproveForLocationApprovalMemory : PermissionDecisionApproveForLocationApproval
{
///
@@ -2399,44 +2428,48 @@ public partial class PermissionDecisionApproveForLocationApprovalMemory : Permis
public override string Kind => "memory";
}
-/// The custom-tool variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalCustomTool` type.
+/// The custom-tool variant of .
public partial class PermissionDecisionApproveForLocationApprovalCustomTool : PermissionDecisionApproveForLocationApproval
{
///
[JsonIgnore]
public override string Kind => "custom-tool";
- /// Gets or sets the toolName value.
+ /// Custom tool name.
[JsonPropertyName("toolName")]
public required string ToolName { get; set; }
}
-/// The extension-management variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalExtensionManagement` type.
+/// The extension-management variant of .
public partial class PermissionDecisionApproveForLocationApprovalExtensionManagement : PermissionDecisionApproveForLocationApproval
{
///
[JsonIgnore]
public override string Kind => "extension-management";
- /// Gets or sets the operation value.
+ /// Optional operation identifier; when omitted, the approval covers all extension management operations.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("operation")]
public string? Operation { get; set; }
}
-/// The extension-permission-access variant of .
+/// Schema for the `PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess` type.
+/// The extension-permission-access variant of .
public partial class PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess : PermissionDecisionApproveForLocationApproval
{
///
[JsonIgnore]
public override string Kind => "extension-permission-access";
- /// Gets or sets the extensionName value.
+ /// Extension name.
[JsonPropertyName("extensionName")]
public required string ExtensionName { get; set; }
}
-/// The approve-for-location variant of .
+/// Schema for the `PermissionDecisionApproveForLocation` type.
+/// The approve-for-location variant of .
public partial class PermissionDecisionApproveForLocation : PermissionDecision
{
///
@@ -2452,7 +2485,8 @@ public partial class PermissionDecisionApproveForLocation : PermissionDecision
public required string LocationKey { get; set; }
}
-/// The approve-permanently variant of .
+/// Schema for the `PermissionDecisionApprovePermanently` type.
+/// The approve-permanently variant of .
public partial class PermissionDecisionApprovePermanently : PermissionDecision
{
///
@@ -2464,7 +2498,8 @@ public partial class PermissionDecisionApprovePermanently : PermissionDecision
public required string Domain { get; set; }
}
-/// The reject variant of .
+/// Schema for the `PermissionDecisionReject` type.
+/// The reject variant of .
public partial class PermissionDecisionReject : PermissionDecision
{
///
@@ -2477,7 +2512,8 @@ public partial class PermissionDecisionReject : PermissionDecision
public string? Feedback { get; set; }
}
-/// The user-not-available variant of .
+/// Schema for the `PermissionDecisionUserNotAvailable` type.
+/// The user-not-available variant of .
public partial class PermissionDecisionUserNotAvailable : PermissionDecision
{
///
@@ -2485,14 +2521,14 @@ public partial class PermissionDecisionUserNotAvailable : PermissionDecision
public override string Kind => "user-not-available";
}
-/// RPC data type for PermissionDecision operations.
+/// Pending permission request ID and the decision to apply (approve/reject and scope).
internal sealed class PermissionDecisionRequest
{
/// Request ID of the pending permission request.
[JsonPropertyName("requestId")]
public string RequestId { get; set; } = string.Empty;
- /// Gets or sets the result value.
+ /// Decision to apply to a pending permission request.
[JsonPropertyName("result")]
public PermissionDecision Result { get => field ??= new(); set; }
@@ -2501,7 +2537,7 @@ internal sealed class PermissionDecisionRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for PermissionsSetApproveAll operations.
+/// Indicates whether the operation succeeded.
public sealed class PermissionsSetApproveAllResult
{
/// Whether the operation succeeded.
@@ -2509,7 +2545,7 @@ public sealed class PermissionsSetApproveAllResult
public bool Success { get; set; }
}
-/// RPC data type for PermissionsSetApproveAll operations.
+/// Whether to auto-approve all tool permission requests for the rest of the session.
internal sealed class PermissionsSetApproveAllRequest
{
/// Whether to auto-approve all tool permission requests.
@@ -2521,7 +2557,7 @@ internal sealed class PermissionsSetApproveAllRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for PermissionsResetSessionApprovals operations.
+/// Indicates whether the operation succeeded.
public sealed class PermissionsResetSessionApprovalsResult
{
/// Whether the operation succeeded.
@@ -2529,7 +2565,7 @@ public sealed class PermissionsResetSessionApprovalsResult
public bool Success { get; set; }
}
-/// RPC data type for PermissionsResetSessionApprovals operations.
+/// No parameters; clears all session-scoped tool permission approvals.
internal sealed class PermissionsResetSessionApprovalsRequest
{
/// Target session identifier.
@@ -2537,7 +2573,7 @@ internal sealed class PermissionsResetSessionApprovalsRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for ShellExec operations.
+/// Identifier of the spawned process, used to correlate streamed output and exit notifications.
public sealed class ShellExecResult
{
/// Unique identifier for tracking streamed output.
@@ -2545,7 +2581,7 @@ public sealed class ShellExecResult
public string ProcessId { get; set; } = string.Empty;
}
-/// RPC data type for ShellExec operations.
+/// Shell command to run, with optional working directory and timeout in milliseconds.
internal sealed class ShellExecRequest
{
/// Shell command to execute.
@@ -2567,7 +2603,7 @@ internal sealed class ShellExecRequest
public TimeSpan? Timeout { get; set; }
}
-/// RPC data type for ShellKill operations.
+/// Indicates whether the signal was delivered; false if the process was unknown or already exited.
public sealed class ShellKillResult
{
/// Whether the signal was sent successfully.
@@ -2575,7 +2611,7 @@ public sealed class ShellKillResult
public bool Killed { get; set; }
}
-/// RPC data type for ShellKill operations.
+/// Identifier of a process previously returned by "shell.exec" and the signal to send.
internal sealed class ShellKillRequest
{
/// Process identifier returned by shell.exec.
@@ -2625,7 +2661,7 @@ public sealed class HistoryCompactContextWindow
public long? ToolDefinitionsTokens { get; set; }
}
-/// RPC data type for HistoryCompact operations.
+/// Compaction outcome with the number of tokens and messages removed and the resulting context window breakdown.
[Experimental(Diagnostics.Experimental)]
public sealed class HistoryCompactResult
{
@@ -2648,7 +2684,7 @@ public sealed class HistoryCompactResult
public long TokensRemoved { get; set; }
}
-/// RPC data type for SessionHistoryCompact operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionHistoryCompactRequest
{
@@ -2657,7 +2693,7 @@ internal sealed class SessionHistoryCompactRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for HistoryTruncate operations.
+/// Number of events that were removed by the truncation.
[Experimental(Diagnostics.Experimental)]
public sealed class HistoryTruncateResult
{
@@ -2667,7 +2703,7 @@ public sealed class HistoryTruncateResult
public long EventsRemoved { get; set; }
}
-/// RPC data type for HistoryTruncate operations.
+/// Identifier of the event to truncate to; this event and all later events are removed.
[Experimental(Diagnostics.Experimental)]
internal sealed class HistoryTruncateRequest
{
@@ -2708,7 +2744,7 @@ public sealed class UsageMetricsModelMetricRequests
public long Count { get; set; }
}
-/// RPC data type for UsageMetricsModelMetricTokenDetail operations.
+/// Schema for the `UsageMetricsModelMetricTokenDetail` type.
public sealed class UsageMetricsModelMetricTokenDetail
{
/// Accumulated token count for this token type.
@@ -2746,7 +2782,7 @@ public sealed class UsageMetricsModelMetricUsage
public long? ReasoningTokens { get; set; }
}
-/// RPC data type for UsageMetricsModelMetric operations.
+/// Schema for the `UsageMetricsModelMetric` type.
public sealed class UsageMetricsModelMetric
{
/// Request count and cost metrics for this model.
@@ -2767,7 +2803,7 @@ public sealed class UsageMetricsModelMetric
public UsageMetricsModelMetricUsage Usage { get => field ??= new(); set; }
}
-/// RPC data type for UsageMetricsTokenDetail operations.
+/// Schema for the `UsageMetricsTokenDetail` type.
public sealed class UsageMetricsTokenDetail
{
/// Accumulated token count for this token type.
@@ -2776,7 +2812,7 @@ public sealed class UsageMetricsTokenDetail
public long TokenCount { get; set; }
}
-/// RPC data type for UsageGetMetrics operations.
+/// Accumulated session usage metrics, including premium request cost, token counts, model breakdown, and code-change totals.
[Experimental(Diagnostics.Experimental)]
public sealed class UsageGetMetricsResult
{
@@ -2831,7 +2867,7 @@ public sealed class UsageGetMetricsResult
public long TotalUserRequests { get; set; }
}
-/// RPC data type for SessionUsageGetMetrics operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionUsageGetMetricsRequest
{
@@ -2840,7 +2876,7 @@ internal sealed class SessionUsageGetMetricsRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for RemoteEnable operations.
+/// GitHub URL for the session and a flag indicating whether remote steering is enabled.
[Experimental(Diagnostics.Experimental)]
public sealed class RemoteEnableResult
{
@@ -2848,16 +2884,16 @@ public sealed class RemoteEnableResult
[JsonPropertyName("remoteSteerable")]
public bool RemoteSteerable { get; set; }
- /// Mission Control frontend URL for this session.
+ /// GitHub frontend URL for this session.
[JsonPropertyName("url")]
public string? Url { get; set; }
}
-/// RPC data type for RemoteEnable operations.
+/// Optional remote session mode ("off", "export", or "on"); defaults to enabling both export and remote steering.
[Experimental(Diagnostics.Experimental)]
internal sealed class RemoteEnableRequest
{
- /// Per-session remote mode. "off" disables remote, "export" exports session events to Mission Control without enabling remote steering, "on" enables both export and remote steering.
+ /// Per-session remote mode. "off" disables remote, "export" exports session events to GitHub without enabling remote steering, "on" enables both export and remote steering.
[JsonPropertyName("mode")]
public RemoteSessionMode? Mode { get; set; }
@@ -2866,7 +2902,7 @@ internal sealed class RemoteEnableRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionRemoteDisable operations.
+/// Identifies the target session.
[Experimental(Diagnostics.Experimental)]
internal sealed class SessionRemoteDisableRequest
{
@@ -2887,7 +2923,7 @@ public sealed class SessionFsError
public string? Message { get; set; }
}
-/// RPC data type for SessionFsReadFile operations.
+/// File content as a UTF-8 string, or a filesystem error if the read failed.
public sealed class SessionFsReadFileResult
{
/// File content as UTF-8 string.
@@ -2899,7 +2935,7 @@ public sealed class SessionFsReadFileResult
public SessionFsError? Error { get; set; }
}
-/// RPC data type for SessionFsReadFile operations.
+/// Path of the file to read from the client-provided session filesystem.
public sealed class SessionFsReadFileRequest
{
/// Path using SessionFs conventions.
@@ -2911,7 +2947,7 @@ public sealed class SessionFsReadFileRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsWriteFile operations.
+/// File path, content to write, and optional mode for the client-provided session filesystem.
public sealed class SessionFsWriteFileRequest
{
/// Content to write.
@@ -2932,7 +2968,7 @@ public sealed class SessionFsWriteFileRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsAppendFile operations.
+/// File path, content to append, and optional mode for the client-provided session filesystem.
public sealed class SessionFsAppendFileRequest
{
/// Content to append.
@@ -2953,7 +2989,7 @@ public sealed class SessionFsAppendFileRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsExists operations.
+/// Indicates whether the requested path exists in the client-provided session filesystem.
public sealed class SessionFsExistsResult
{
/// Whether the path exists.
@@ -2961,7 +2997,7 @@ public sealed class SessionFsExistsResult
public bool Exists { get; set; }
}
-/// RPC data type for SessionFsExists operations.
+/// Path to test for existence in the client-provided session filesystem.
public sealed class SessionFsExistsRequest
{
/// Path using SessionFs conventions.
@@ -2973,7 +3009,7 @@ public sealed class SessionFsExistsRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsStat operations.
+/// Filesystem metadata for the requested path, or a filesystem error if the stat failed.
public sealed class SessionFsStatResult
{
/// ISO 8601 timestamp of creation.
@@ -3002,7 +3038,7 @@ public sealed class SessionFsStatResult
public long Size { get; set; }
}
-/// RPC data type for SessionFsStat operations.
+/// Path whose metadata should be returned from the client-provided session filesystem.
public sealed class SessionFsStatRequest
{
/// Path using SessionFs conventions.
@@ -3014,7 +3050,7 @@ public sealed class SessionFsStatRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsMkdir operations.
+/// Directory path to create in the client-provided session filesystem, with options for recursive creation and POSIX mode.
public sealed class SessionFsMkdirRequest
{
/// Optional POSIX-style mode for newly created directories.
@@ -3035,7 +3071,7 @@ public sealed class SessionFsMkdirRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsReaddir operations.
+/// Names of entries in the requested directory, or a filesystem error if the read failed.
public sealed class SessionFsReaddirResult
{
/// Entry names in the directory.
@@ -3047,7 +3083,7 @@ public sealed class SessionFsReaddirResult
public SessionFsError? Error { get; set; }
}
-/// RPC data type for SessionFsReaddir operations.
+/// Directory path whose entries should be listed from the client-provided session filesystem.
public sealed class SessionFsReaddirRequest
{
/// Path using SessionFs conventions.
@@ -3059,7 +3095,7 @@ public sealed class SessionFsReaddirRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsReaddirWithTypesEntry operations.
+/// Schema for the `SessionFsReaddirWithTypesEntry` type.
public sealed class SessionFsReaddirWithTypesEntry
{
/// Entry name.
@@ -3071,7 +3107,7 @@ public sealed class SessionFsReaddirWithTypesEntry
public SessionFsReaddirWithTypesEntryType Type { get; set; }
}
-/// RPC data type for SessionFsReaddirWithTypes operations.
+/// Entries in the requested directory paired with file/directory type information, or a filesystem error if the read failed.
public sealed class SessionFsReaddirWithTypesResult
{
/// Directory entries with type information.
@@ -3083,7 +3119,7 @@ public sealed class SessionFsReaddirWithTypesResult
public SessionFsError? Error { get; set; }
}
-/// RPC data type for SessionFsReaddirWithTypes operations.
+/// Directory path whose entries (with type information) should be listed from the client-provided session filesystem.
public sealed class SessionFsReaddirWithTypesRequest
{
/// Path using SessionFs conventions.
@@ -3095,7 +3131,7 @@ public sealed class SessionFsReaddirWithTypesRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsRm operations.
+/// Path to remove from the client-provided session filesystem, with options for recursive removal and force.
public sealed class SessionFsRmRequest
{
/// Ignore errors if the path does not exist.
@@ -3115,7 +3151,7 @@ public sealed class SessionFsRmRequest
public string SessionId { get; set; } = string.Empty;
}
-/// RPC data type for SessionFsRename operations.
+/// Source and destination paths for renaming or moving an entry in the client-provided session filesystem.
public sealed class SessionFsRenameRequest
{
/// Destination path using SessionFs conventions.
@@ -4789,7 +4825,7 @@ public override void Write(Utf8JsonWriter writer, ShellKillSignal value, JsonSer
}
-/// Per-session remote mode. "off" disables remote, "export" exports session events to Mission Control without enabling remote steering, "on" enables both export and remote steering.
+/// Per-session remote mode. "off" disables remote, "export" exports session events to GitHub without enabling remote steering, "on" enables both export and remote steering.
[JsonConverter(typeof(Converter))]
[DebuggerDisplay("{Value,nq}")]
public readonly struct RemoteSessionMode : IEquatable
@@ -4995,18 +5031,20 @@ internal ServerRpc(JsonRpc rpc)
Sessions = new ServerSessionsApi(rpc);
}
- /// Calls "ping".
+ /// Checks server responsiveness and returns protocol information.
/// Optional message to echo back.
/// The to monitor for cancellation requests. The default is .
+ /// Server liveness response, including the echoed message, current timestamp, and protocol version.
public async Task PingAsync(string? message = null, CancellationToken cancellationToken = default)
{
var request = new PingRequest { Message = message };
return await CopilotClient.InvokeRpcAsync(_rpc, "ping", [request], cancellationToken);
}
- /// Calls "connect".
+ /// Performs the SDK server connection handshake and validates the optional connection token.
/// Connection token; required when the server was started with COPILOT_CONNECTION_TOKEN.
/// The to monitor for cancellation requests. The default is .
+ /// Handshake result reporting the server's protocol version and package version on success.
internal async Task ConnectAsync(string? token = null, CancellationToken cancellationToken = default)
{
var request = new ConnectRequest { Token = token };
@@ -5045,9 +5083,10 @@ internal ServerModelsApi(JsonRpc rpc)
_rpc = rpc;
}
- /// Calls "models.list".
+ /// Lists Copilot models available to the authenticated user.
/// GitHub token for per-user model listing. When provided, resolves this token to determine the user's Copilot plan and available models instead of using the global auth.
/// The to monitor for cancellation requests. The default is .
+ /// List of Copilot models available to the resolved user, including capabilities and billing metadata.
public async Task ListAsync(string? gitHubToken = null, CancellationToken cancellationToken = default)
{
var request = new ModelsListRequest { GitHubToken = gitHubToken };
@@ -5065,9 +5104,10 @@ internal ServerToolsApi(JsonRpc rpc)
_rpc = rpc;
}
- /// Calls "tools.list".
+ /// Lists built-in tools available for a model.
/// Optional model ID — when provided, the returned tool list reflects model-specific overrides.
/// The to monitor for cancellation requests. The default is .
+ /// Built-in tools available for the requested model, with their parameters and instructions.
public async Task ListAsync(string? model = null, CancellationToken cancellationToken = default)
{
var request = new ToolsListRequest { Model = model };
@@ -5085,9 +5125,10 @@ internal ServerAccountApi(JsonRpc rpc)
_rpc = rpc;
}
- /// Calls "account.getQuota".
+ /// Gets Copilot quota usage for the authenticated user or supplied GitHub token.
/// GitHub token for per-user quota lookup. When provided, resolves this token to determine the user's quota instead of using the global auth.
/// The to monitor for cancellation requests. The default is .
+ /// Quota usage snapshots for the resolved user, keyed by quota type.
public async Task GetQuotaAsync(string? gitHubToken = null, CancellationToken cancellationToken = default)
{
var request = new AccountGetQuotaRequest { GitHubToken = gitHubToken };
@@ -5106,9 +5147,10 @@ internal ServerMcpApi(JsonRpc rpc)
Config = new ServerMcpConfigApi(rpc);
}
- /// Calls "mcp.discover".
+ /// Discovers MCP servers from user, workspace, plugin, and builtin sources.
/// Working directory used as context for discovery (e.g., plugin resolution).
/// The to monitor for cancellation requests. The default is .
+ /// MCP servers discovered from user, workspace, plugin, and built-in sources.
public async Task DiscoverAsync(string? workingDirectory = null, CancellationToken cancellationToken = default)
{
var request = new McpDiscoverRequest { WorkingDirectory = workingDirectory };
@@ -5129,14 +5171,15 @@ internal ServerMcpConfigApi(JsonRpc rpc)
_rpc = rpc;
}
- /// Calls "mcp.config.list".
+ /// Lists MCP servers from user configuration.
/// The to monitor for cancellation requests. The default is .
+ /// User-configured MCP servers, keyed by server name.
public async Task ListAsync(CancellationToken cancellationToken = default)
{
return await CopilotClient.InvokeRpcAsync(_rpc, "mcp.config.list", [], cancellationToken);
}
- /// Calls "mcp.config.add".
+ /// Adds an MCP server to user configuration.
/// Unique name for the MCP server.
/// MCP server configuration (local/stdio or remote/http).
/// The to monitor for cancellation requests. The default is .
@@ -5146,7 +5189,7 @@ public async Task AddAsync(string name, object config, CancellationToken cancell
await CopilotClient.InvokeRpcAsync(_rpc, "mcp.config.add", [request], cancellationToken);
}
- /// Calls "mcp.config.update".
+ /// Updates an MCP server in user configuration.
/// Name of the MCP server to update.
/// MCP server configuration (local/stdio or remote/http).
/// The to monitor for cancellation requests. The default is .
@@ -5156,7 +5199,7 @@ public async Task UpdateAsync(string name, object config, CancellationToken canc
await CopilotClient.InvokeRpcAsync(_rpc, "mcp.config.update", [request], cancellationToken);
}
- /// Calls "mcp.config.remove".
+ /// Removes an MCP server from user configuration.
/// Name of the MCP server to remove.
/// The to monitor for cancellation requests. The default is .
public async Task RemoveAsync(string name, CancellationToken cancellationToken = default)
@@ -5165,7 +5208,7 @@ public async Task RemoveAsync(string name, CancellationToken cancellationToken =
await CopilotClient.InvokeRpcAsync(_rpc, "mcp.config.remove", [request], cancellationToken);
}
- /// Calls "mcp.config.enable".
+ /// Enables MCP servers in user configuration for new sessions.
/// Names of MCP servers to enable. Each server is removed from the persisted disabled list so new sessions spawn it. Unknown or already-enabled names are ignored.
/// The to monitor for cancellation requests. The default is .
public async Task EnableAsync(IList names, CancellationToken cancellationToken = default)
@@ -5174,7 +5217,7 @@ public async Task EnableAsync(IList names, CancellationToken cancellatio
await CopilotClient.InvokeRpcAsync(_rpc, "mcp.config.enable", [request], cancellationToken);
}
- /// Calls "mcp.config.disable".
+ /// Disables MCP servers in user configuration for new sessions.
/// Names of MCP servers to disable. Each server is added to the persisted disabled list so new sessions skip it. Already-disabled names are ignored. Active sessions keep their current connections until they end.
/// The to monitor for cancellation requests. The default is .
public async Task DisableAsync(IList names, CancellationToken cancellationToken = default)
@@ -5195,10 +5238,11 @@ internal ServerSkillsApi(JsonRpc rpc)
Config = new ServerSkillsConfigApi(rpc);
}
- /// Calls "skills.discover".
+ /// Discovers skills across global and project sources.
/// Optional list of project directory paths to scan for project-scoped skills.
/// Optional list of additional skill directory paths to include.
/// The to monitor for cancellation requests. The default is .
+ /// Skills discovered across global and project sources.
public async Task DiscoverAsync(IList? projectPaths = null, IList? skillDirectories = null, CancellationToken cancellationToken = default)
{
var request = new SkillsDiscoverRequest { ProjectPaths = projectPaths, SkillDirectories = skillDirectories };
@@ -5219,7 +5263,7 @@ internal ServerSkillsConfigApi(JsonRpc rpc)
_rpc = rpc;
}
- /// Calls "skills.config.setDisabledSkills".
+ /// Replaces the global list of disabled skills.
/// List of skill names to disable.
/// The to monitor for cancellation requests. The default is .
public async Task SetDisabledSkillsAsync(IList disabledSkills, CancellationToken cancellationToken = default)
@@ -5239,11 +5283,12 @@ internal ServerSessionFsApi(JsonRpc rpc)
_rpc = rpc;
}
- /// Calls "sessionFs.setProvider".
+ /// Registers an SDK client as the session filesystem provider.
/// Initial working directory for sessions.
/// Path within each session's SessionFs where the runtime stores files for that session.
/// Path conventions used by this filesystem.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the calling client was registered as the session filesystem provider.
public async Task SetProviderAsync(string initialCwd, string sessionStatePath, SessionFsSetProviderConventions conventions, CancellationToken cancellationToken = default)
{
var request = new SessionFsSetProviderRequest { InitialCwd = initialCwd, SessionStatePath = sessionStatePath, Conventions = conventions };
@@ -5262,11 +5307,12 @@ internal ServerSessionsApi(JsonRpc rpc)
_rpc = rpc;
}
- /// Calls "sessions.fork".
+ /// Creates a new session by forking persisted history from an existing session.
/// Source session ID to fork from.
/// Optional event ID boundary. When provided, the fork includes only events before this ID (exclusive). When omitted, all events are included.
/// Optional friendly name to assign to the forked session.
/// The to monitor for cancellation requests. The default is .
+ /// Identifier and optional friendly name assigned to the newly forked session.
public async Task ForkAsync(string sessionId, string? toEventId = null, string? name = null, CancellationToken cancellationToken = default)
{
var request = new SessionsForkRequest { SessionId = sessionId, ToEventId = toEventId, Name = name };
@@ -5374,7 +5420,7 @@ internal SessionRpc(JsonRpc rpc, string sessionId)
/// Remote APIs.
public RemoteApi Remote { get; }
- /// Calls "session.suspend".
+ /// Suspends the session while preserving persisted state for later resume.
/// The to monitor for cancellation requests. The default is .
public async Task SuspendAsync(CancellationToken cancellationToken = default)
{
@@ -5382,12 +5428,13 @@ public async Task SuspendAsync(CancellationToken cancellationToken = default)
await CopilotClient.InvokeRpcAsync(_rpc, "session.suspend", [request], cancellationToken);
}
- /// Calls "session.log".
+ /// Emits a user-visible session log event.
/// Human-readable message.
/// Log severity level. Determines how the message is displayed in the timeline. Defaults to "info".
/// When true, the message is transient and not persisted to the session event log on disk.
/// Optional URL the user can open in their browser for more details.
/// The to monitor for cancellation requests. The default is .
+ /// Identifier of the session event that was emitted for the log message.
public async Task LogAsync(string message, SessionLogLevel? level = null, bool? ephemeral = null, string? url = null, CancellationToken cancellationToken = default)
{
var request = new LogRequest { SessionId = _sessionId, Message = message, Level = level, Ephemeral = ephemeral, Url = url };
@@ -5407,8 +5454,9 @@ internal AuthApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.auth.getStatus".
+ /// Gets authentication status and account metadata for the session.
/// The to monitor for cancellation requests. The default is .
+ /// Authentication status and account metadata for the session.
public async Task GetStatusAsync(CancellationToken cancellationToken = default)
{
var request = new SessionAuthGetStatusRequest { SessionId = _sessionId };
@@ -5428,22 +5476,25 @@ internal ModelApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.model.getCurrent".
+ /// Gets the currently selected model for the session.
/// The to monitor for cancellation requests. The default is .
+ /// The currently selected model for the session.
public async Task GetCurrentAsync(CancellationToken cancellationToken = default)
{
var request = new SessionModelGetCurrentRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.model.getCurrent", [request], cancellationToken);
}
- /// Calls "session.model.switchTo".
+ /// Switches the session to a model and optional reasoning configuration.
/// Model identifier to switch to.
- /// Reasoning effort level to use for the model.
+ /// Reasoning effort level to use for the model. "none" disables reasoning.
+ /// Reasoning summary mode to request for supported model clients.
/// Override individual model capabilities resolved by the runtime.
/// The to monitor for cancellation requests. The default is .
- public async Task SwitchToAsync(string modelId, string? reasoningEffort = null, ModelCapabilitiesOverride? modelCapabilities = null, CancellationToken cancellationToken = default)
+ /// The model identifier active on the session after the switch.
+ public async Task SwitchToAsync(string modelId, string? reasoningEffort = null, ReasoningSummary? reasoningSummary = null, ModelCapabilitiesOverride? modelCapabilities = null, CancellationToken cancellationToken = default)
{
- var request = new ModelSwitchToRequest { SessionId = _sessionId, ModelId = modelId, ReasoningEffort = reasoningEffort, ModelCapabilities = modelCapabilities };
+ var request = new ModelSwitchToRequest { SessionId = _sessionId, ModelId = modelId, ReasoningEffort = reasoningEffort, ReasoningSummary = reasoningSummary, ModelCapabilities = modelCapabilities };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.model.switchTo", [request], cancellationToken);
}
}
@@ -5460,7 +5511,7 @@ internal ModeApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.mode.get".
+ /// Gets the current agent interaction mode.
/// The to monitor for cancellation requests. The default is .
/// The agent mode. Valid values: "interactive", "plan", "autopilot".
public async Task GetAsync(CancellationToken cancellationToken = default)
@@ -5469,7 +5520,7 @@ public async Task GetAsync(CancellationToken cancellationToken = de
return await CopilotClient.InvokeRpcAsync(_rpc, "session.mode.get", [request], cancellationToken);
}
- /// Calls "session.mode.set".
+ /// Sets the current agent interaction mode.
/// The agent mode. Valid values: "interactive", "plan", "autopilot".
/// The to monitor for cancellation requests. The default is .
public async Task SetAsync(SessionMode mode, CancellationToken cancellationToken = default)
@@ -5491,15 +5542,16 @@ internal NameApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.name.get".
+ /// Gets the session's friendly name.
/// The to monitor for cancellation requests. The default is .
+ /// The session's friendly name, or null when not yet set.
public async Task GetAsync(CancellationToken cancellationToken = default)
{
var request = new SessionNameGetRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.name.get", [request], cancellationToken);
}
- /// Calls "session.name.set".
+ /// Sets the session's friendly name.
/// New session name (1–100 characters, trimmed of leading/trailing whitespace).
/// The to monitor for cancellation requests. The default is .
public async Task SetAsync(string name, CancellationToken cancellationToken = default)
@@ -5521,15 +5573,16 @@ internal PlanApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.plan.read".
+ /// Reads the session plan file from the workspace.
/// The to monitor for cancellation requests. The default is .
+ /// Existence, contents, and resolved path of the session plan file.
public async Task ReadAsync(CancellationToken cancellationToken = default)
{
var request = new SessionPlanReadRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.plan.read", [request], cancellationToken);
}
- /// Calls "session.plan.update".
+ /// Writes new content to the session plan file.
/// The new content for the plan file.
/// The to monitor for cancellation requests. The default is .
public async Task UpdateAsync(string content, CancellationToken cancellationToken = default)
@@ -5538,7 +5591,7 @@ public async Task UpdateAsync(string content, CancellationToken cancellationToke
await CopilotClient.InvokeRpcAsync(_rpc, "session.plan.update", [request], cancellationToken);
}
- /// Calls "session.plan.delete".
+ /// Deletes the session plan file from the workspace.
/// The to monitor for cancellation requests. The default is .
public async Task DeleteAsync(CancellationToken cancellationToken = default)
{
@@ -5559,32 +5612,35 @@ internal WorkspacesApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.workspaces.getWorkspace".
+ /// Gets current workspace metadata for the session.
/// The to monitor for cancellation requests. The default is .
+ /// Current workspace metadata for the session, or null when not available.
public async Task GetWorkspaceAsync(CancellationToken cancellationToken = default)
{
var request = new SessionWorkspacesGetWorkspaceRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.workspaces.getWorkspace", [request], cancellationToken);
}
- /// Calls "session.workspaces.listFiles".
+ /// Lists files stored in the session workspace files directory.
/// The to monitor for cancellation requests. The default is .
+ /// Relative paths of files stored in the session workspace files directory.
public async Task ListFilesAsync(CancellationToken cancellationToken = default)
{
var request = new SessionWorkspacesListFilesRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.workspaces.listFiles", [request], cancellationToken);
}
- /// Calls "session.workspaces.readFile".
+ /// Reads a file from the session workspace files directory.
/// Relative path within the workspace files directory.
/// The to monitor for cancellation requests. The default is .
+ /// Contents of the requested workspace file as a UTF-8 string.
public async Task ReadFileAsync(string path, CancellationToken cancellationToken = default)
{
var request = new WorkspacesReadFileRequest { SessionId = _sessionId, Path = path };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.workspaces.readFile", [request], cancellationToken);
}
- /// Calls "session.workspaces.createFile".
+ /// Creates or overwrites a file in the session workspace files directory.
/// Relative path within the workspace files directory.
/// File content to write as a UTF-8 string.
/// The to monitor for cancellation requests. The default is .
@@ -5607,8 +5663,9 @@ internal InstructionsApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.instructions.getSources".
+ /// Gets instruction sources loaded for the session.
/// The to monitor for cancellation requests. The default is .
+ /// Instruction sources loaded for the session, in merge order.
public async Task GetSourcesAsync(CancellationToken cancellationToken = default)
{
var request = new SessionInstructionsGetSourcesRequest { SessionId = _sessionId };
@@ -5629,9 +5686,10 @@ internal FleetApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.fleet.start".
+ /// Starts fleet mode by submitting the fleet orchestration prompt to the session.
/// Optional user prompt to combine with fleet instructions.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether fleet mode was successfully activated.
public async Task StartAsync(string? prompt = null, CancellationToken cancellationToken = default)
{
var request = new FleetStartRequest { SessionId = _sessionId, Prompt = prompt };
@@ -5652,32 +5710,35 @@ internal AgentApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.agent.list".
+ /// Lists custom agents available to the session.
/// The to monitor for cancellation requests. The default is .
+ /// Custom agents available to the session.
public async Task ListAsync(CancellationToken cancellationToken = default)
{
var request = new SessionAgentListRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.agent.list", [request], cancellationToken);
}
- /// Calls "session.agent.getCurrent".
+ /// Gets the currently selected custom agent for the session.
/// The to monitor for cancellation requests. The default is .
+ /// The currently selected custom agent, or null when using the default agent.
public async Task GetCurrentAsync(CancellationToken cancellationToken = default)
{
var request = new SessionAgentGetCurrentRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.agent.getCurrent", [request], cancellationToken);
}
- /// Calls "session.agent.select".
+ /// Selects a custom agent for subsequent turns in the session.
/// Name of the custom agent to select.
/// The to monitor for cancellation requests. The default is .
+ /// The newly selected custom agent.
public async Task SelectAsync(string name, CancellationToken cancellationToken = default)
{
var request = new AgentSelectRequest { SessionId = _sessionId, Name = name };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.agent.select", [request], cancellationToken);
}
- /// Calls "session.agent.deselect".
+ /// Clears the selected custom agent and returns the session to the default agent.
/// The to monitor for cancellation requests. The default is .
public async Task DeselectAsync(CancellationToken cancellationToken = default)
{
@@ -5685,8 +5746,9 @@ public async Task DeselectAsync(CancellationToken cancellationToken = default)
await CopilotClient.InvokeRpcAsync(_rpc, "session.agent.deselect", [request], cancellationToken);
}
- /// Calls "session.agent.reload".
+ /// Reloads custom agent definitions and returns the refreshed list.
/// The to monitor for cancellation requests. The default is .
+ /// Custom agents available to the session after reloading definitions from disk.
public async Task ReloadAsync(CancellationToken cancellationToken = default)
{
var request = new SessionAgentReloadRequest { SessionId = _sessionId };
@@ -5707,59 +5769,65 @@ internal TasksApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.tasks.startAgent".
+ /// Starts a background agent task in the session.
/// Type of agent to start (e.g., 'explore', 'task', 'general-purpose').
/// Task prompt for the agent.
/// Short name for the agent, used to generate a human-readable ID.
/// Short description of the task.
/// Optional model override.
/// The to monitor for cancellation requests. The default is .
+ /// Identifier assigned to the newly started background agent task.
public async Task StartAgentAsync(string agentType, string prompt, string name, string? description = null, string? model = null, CancellationToken cancellationToken = default)
{
var request = new TasksStartAgentRequest { SessionId = _sessionId, AgentType = agentType, Prompt = prompt, Name = name, Description = description, Model = model };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.tasks.startAgent", [request], cancellationToken);
}
- /// Calls "session.tasks.list".
+ /// Lists background tasks tracked by the session.
/// The to monitor for cancellation requests. The default is .
+ /// Background tasks currently tracked by the session.
public async Task ListAsync(CancellationToken cancellationToken = default)
{
var request = new SessionTasksListRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.tasks.list", [request], cancellationToken);
}
- /// Calls "session.tasks.promoteToBackground".
+ /// Promotes an eligible synchronously-waited task so it continues running in the background.
/// Task identifier.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the task was successfully promoted to background mode.
public async Task PromoteToBackgroundAsync(string id, CancellationToken cancellationToken = default)
{
var request = new TasksPromoteToBackgroundRequest { SessionId = _sessionId, Id = id };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.tasks.promoteToBackground", [request], cancellationToken);
}
- /// Calls "session.tasks.cancel".
+ /// Cancels a background task.
/// Task identifier.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the background task was successfully cancelled.
public async Task CancelAsync(string id, CancellationToken cancellationToken = default)
{
var request = new TasksCancelRequest { SessionId = _sessionId, Id = id };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.tasks.cancel", [request], cancellationToken);
}
- /// Calls "session.tasks.remove".
+ /// Removes a completed or cancelled background task from tracking.
/// Task identifier.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the task was removed. False when the task does not exist or is still running/idle.
public async Task RemoveAsync(string id, CancellationToken cancellationToken = default)
{
var request = new TasksRemoveRequest { SessionId = _sessionId, Id = id };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.tasks.remove", [request], cancellationToken);
}
- /// Calls "session.tasks.sendMessage".
+ /// Sends a message to a background agent task.
/// Agent task identifier.
/// Message content to send to the agent.
/// Agent ID of the sender, if sent on behalf of another agent.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the message was delivered, with an error message when delivery failed.
public async Task SendMessageAsync(string id, string message, string? fromAgentId = null, CancellationToken cancellationToken = default)
{
var request = new TasksSendMessageRequest { SessionId = _sessionId, Id = id, Message = message, FromAgentId = fromAgentId };
@@ -5780,15 +5848,16 @@ internal SkillsApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.skills.list".
+ /// Lists skills available to the session.
/// The to monitor for cancellation requests. The default is .
+ /// Skills available to the session, with their enabled state.
public async Task ListAsync(CancellationToken cancellationToken = default)
{
var request = new SessionSkillsListRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.skills.list", [request], cancellationToken);
}
- /// Calls "session.skills.enable".
+ /// Enables a skill for the session.
/// Name of the skill to enable.
/// The to monitor for cancellation requests. The default is .
public async Task EnableAsync(string name, CancellationToken cancellationToken = default)
@@ -5797,7 +5866,7 @@ public async Task EnableAsync(string name, CancellationToken cancellationToken =
await CopilotClient.InvokeRpcAsync(_rpc, "session.skills.enable", [request], cancellationToken);
}
- /// Calls "session.skills.disable".
+ /// Disables a skill for the session.
/// Name of the skill to disable.
/// The to monitor for cancellation requests. The default is .
public async Task DisableAsync(string name, CancellationToken cancellationToken = default)
@@ -5806,8 +5875,9 @@ public async Task DisableAsync(string name, CancellationToken cancellationToken
await CopilotClient.InvokeRpcAsync(_rpc, "session.skills.disable", [request], cancellationToken);
}
- /// Calls "session.skills.reload".
+ /// Reloads skill definitions for the session.
/// The to monitor for cancellation requests. The default is .
+ /// Diagnostics from reloading skill definitions, with warnings and errors as separate lists.
public async Task ReloadAsync(CancellationToken cancellationToken = default)
{
var request = new SessionSkillsReloadRequest { SessionId = _sessionId };
@@ -5829,15 +5899,16 @@ internal McpApi(JsonRpc rpc, string sessionId)
Oauth = new McpOauthApi(rpc, sessionId);
}
- /// Calls "session.mcp.list".
+ /// Lists MCP servers configured for the session and their connection status.
/// The to monitor for cancellation requests. The default is .
+ /// MCP servers configured for the session, with their connection status.
public async Task ListAsync(CancellationToken cancellationToken = default)
{
var request = new SessionMcpListRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.mcp.list", [request], cancellationToken);
}
- /// Calls "session.mcp.enable".
+ /// Enables an MCP server for the session.
/// Name of the MCP server to enable.
/// The to monitor for cancellation requests. The default is .
public async Task EnableAsync(string serverName, CancellationToken cancellationToken = default)
@@ -5846,7 +5917,7 @@ public async Task EnableAsync(string serverName, CancellationToken cancellationT
await CopilotClient.InvokeRpcAsync(_rpc, "session.mcp.enable", [request], cancellationToken);
}
- /// Calls "session.mcp.disable".
+ /// Disables an MCP server for the session.
/// Name of the MCP server to disable.
/// The to monitor for cancellation requests. The default is .
public async Task DisableAsync(string serverName, CancellationToken cancellationToken = default)
@@ -5855,7 +5926,7 @@ public async Task DisableAsync(string serverName, CancellationToken cancellation
await CopilotClient.InvokeRpcAsync(_rpc, "session.mcp.disable", [request], cancellationToken);
}
- /// Calls "session.mcp.reload".
+ /// Reloads MCP server connections for the session.
/// The to monitor for cancellation requests. The default is .
public async Task ReloadAsync(CancellationToken cancellationToken = default)
{
@@ -5880,12 +5951,13 @@ internal McpOauthApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.mcp.oauth.login".
+ /// Starts OAuth authentication for a remote MCP server.
/// Name of the remote MCP server to authenticate.
/// When true, clears any cached OAuth token for the server and runs a full new authorization. Use when the user explicitly wants to switch accounts or believes their session is stuck.
/// Optional override for the OAuth client display name shown on the consent screen. Applies to newly registered dynamic clients only — existing registrations keep the name they were created with. When omitted, the runtime applies a neutral fallback; callers driving interactive auth should pass their own surface-specific label so the consent screen matches the product the user sees.
/// Optional override for the body text shown on the OAuth loopback callback success page. When omitted, the runtime applies a neutral fallback; callers driving interactive auth should pass surface-specific copy telling the user where to return.
/// The to monitor for cancellation requests. The default is .
+ /// OAuth authorization URL the caller should open, or empty when cached tokens already authenticated the server.
public async Task LoginAsync(string serverName, bool? forceReauth = null, string? clientName = null, string? callbackSuccessMessage = null, CancellationToken cancellationToken = default)
{
var request = new McpOauthLoginRequest { SessionId = _sessionId, ServerName = serverName, ForceReauth = forceReauth, ClientName = clientName, CallbackSuccessMessage = callbackSuccessMessage };
@@ -5906,8 +5978,9 @@ internal PluginsApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.plugins.list".
+ /// Lists plugins installed for the session.
/// The to monitor for cancellation requests. The default is .
+ /// Plugins installed for the session, with their enabled state and version metadata.
public async Task ListAsync(CancellationToken cancellationToken = default)
{
var request = new SessionPluginsListRequest { SessionId = _sessionId };
@@ -5928,15 +6001,16 @@ internal ExtensionsApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.extensions.list".
+ /// Lists extensions discovered for the session and their current status.
/// The to monitor for cancellation requests. The default is .
+ /// Extensions discovered for the session, with their current status.
public async Task ListAsync(CancellationToken cancellationToken = default)
{
var request = new SessionExtensionsListRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.extensions.list", [request], cancellationToken);
}
- /// Calls "session.extensions.enable".
+ /// Enables an extension for the session.
/// Source-qualified extension ID to enable.
/// The to monitor for cancellation requests. The default is .
public async Task EnableAsync(string id, CancellationToken cancellationToken = default)
@@ -5945,7 +6019,7 @@ public async Task EnableAsync(string id, CancellationToken cancellationToken = d
await CopilotClient.InvokeRpcAsync(_rpc, "session.extensions.enable", [request], cancellationToken);
}
- /// Calls "session.extensions.disable".
+ /// Disables an extension for the session.
/// Source-qualified extension ID to disable.
/// The to monitor for cancellation requests. The default is .
public async Task DisableAsync(string id, CancellationToken cancellationToken = default)
@@ -5954,7 +6028,7 @@ public async Task DisableAsync(string id, CancellationToken cancellationToken =
await CopilotClient.InvokeRpcAsync(_rpc, "session.extensions.disable", [request], cancellationToken);
}
- /// Calls "session.extensions.reload".
+ /// Reloads extension definitions and processes for the session.
/// The to monitor for cancellation requests. The default is .
public async Task ReloadAsync(CancellationToken cancellationToken = default)
{
@@ -5975,11 +6049,12 @@ internal ToolsApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.tools.handlePendingToolCall".
+ /// Provides the result for a pending external tool call.
/// Request ID of the pending tool call.
/// Tool call result (string or expanded result object).
/// Error message if the tool call failed.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the external tool call result was handled successfully.
public async Task HandlePendingToolCallAsync(string requestId, object? result = null, string? error = null, CancellationToken cancellationToken = default)
{
var request = new HandlePendingToolCallRequest { SessionId = _sessionId, RequestId = requestId, Result = result, Error = error };
@@ -5999,39 +6074,43 @@ internal CommandsApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.commands.list".
- /// The request parameters.
+ /// Lists slash commands available in the session.
+ /// Optional filters controlling which command sources to include in the listing.
/// The to monitor for cancellation requests. The default is .
+ /// Slash commands available in the session, after applying any include/exclude filters.
public async Task ListAsync(CommandsListRequest? request = null, CancellationToken cancellationToken = default)
{
var rpcRequest = new CommandsListRequestWithSession { SessionId = _sessionId, IncludeBuiltins = request?.IncludeBuiltins, IncludeSkills = request?.IncludeSkills, IncludeClientCommands = request?.IncludeClientCommands };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.commands.list", [rpcRequest], cancellationToken);
}
- /// Calls "session.commands.invoke".
+ /// Invokes a slash command in the session.
/// Command name. Leading slashes are stripped and the name is matched case-insensitively.
/// Raw input after the command name.
/// The to monitor for cancellation requests. The default is .
+ /// Result of invoking the slash command (text output, prompt to send to the agent, or completion).
public async Task InvokeAsync(string name, string? input = null, CancellationToken cancellationToken = default)
{
var request = new CommandsInvokeRequest { SessionId = _sessionId, Name = name, Input = input };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.commands.invoke", [request], cancellationToken);
}
- /// Calls "session.commands.handlePendingCommand".
+ /// Reports completion of a pending client-handled slash command.
/// Request ID from the command invocation event.
/// Error message if the command handler failed.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the pending client-handled command was completed successfully.
public async Task HandlePendingCommandAsync(string requestId, string? error = null, CancellationToken cancellationToken = default)
{
var request = new CommandsHandlePendingCommandRequest { SessionId = _sessionId, RequestId = requestId, Error = error };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.commands.handlePendingCommand", [request], cancellationToken);
}
- /// Calls "session.commands.respondToQueuedCommand".
+ /// Responds to a queued command request from the session.
/// Request ID from the queued command event.
/// Result of the queued command execution.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the queued-command response was accepted by the session.
public async Task RespondToQueuedCommandAsync(string requestId, QueuedCommandResult result, CancellationToken cancellationToken = default)
{
var request = new CommandsRespondToQueuedCommandRequest { SessionId = _sessionId, RequestId = requestId, Result = result };
@@ -6051,7 +6130,7 @@ internal UiApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.ui.elicitation".
+ /// Requests structured input from a UI-capable client.
/// Message describing what information is needed from the user.
/// JSON Schema describing the form fields to present to the user.
/// The to monitor for cancellation requests. The default is .
@@ -6062,10 +6141,11 @@ public async Task ElicitationAsync(string message, UIElic
return await CopilotClient.InvokeRpcAsync(_rpc, "session.ui.elicitation", [request], cancellationToken);
}
- /// Calls "session.ui.handlePendingElicitation".
+ /// Provides the user response for a pending elicitation request.
/// The unique request ID from the elicitation.requested event.
/// The elicitation response (accept with form values, decline, or cancel).
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the elicitation response was accepted; false if it was already resolved by another client.
public async Task HandlePendingElicitationAsync(string requestId, UIElicitationResponse result, CancellationToken cancellationToken = default)
{
var request = new UIHandlePendingElicitationRequest { SessionId = _sessionId, RequestId = requestId, Result = result };
@@ -6085,27 +6165,30 @@ internal PermissionsApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.permissions.handlePendingPermissionRequest".
+ /// Provides a decision for a pending tool permission request.
/// Request ID of the pending permission request.
- /// The result parameter.
+ /// Decision to apply to a pending permission request.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the permission decision was applied; false when the request was already resolved.
public async Task HandlePendingPermissionRequestAsync(string requestId, PermissionDecision result, CancellationToken cancellationToken = default)
{
var request = new PermissionDecisionRequest { SessionId = _sessionId, RequestId = requestId, Result = result };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.permissions.handlePendingPermissionRequest", [request], cancellationToken);
}
- /// Calls "session.permissions.setApproveAll".
+ /// Enables or disables automatic approval of tool permission requests for the session.
/// Whether to auto-approve all tool permission requests.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the operation succeeded.
public async Task SetApproveAllAsync(bool enabled, CancellationToken cancellationToken = default)
{
var request = new PermissionsSetApproveAllRequest { SessionId = _sessionId, Enabled = enabled };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.permissions.setApproveAll", [request], cancellationToken);
}
- /// Calls "session.permissions.resetSessionApprovals".
+ /// Clears session-scoped tool permission approvals.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the operation succeeded.
public async Task ResetSessionApprovalsAsync(CancellationToken cancellationToken = default)
{
var request = new PermissionsResetSessionApprovalsRequest { SessionId = _sessionId };
@@ -6125,21 +6208,23 @@ internal ShellApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.shell.exec".
+ /// Starts a shell command and streams output through session notifications.
/// Shell command to execute.
/// Working directory (defaults to session working directory).
/// Timeout in milliseconds (default: 30000).
/// The to monitor for cancellation requests. The default is .
+ /// Identifier of the spawned process, used to correlate streamed output and exit notifications.
public async Task ExecAsync(string command, string? cwd = null, TimeSpan? timeout = null, CancellationToken cancellationToken = default)
{
var request = new ShellExecRequest { SessionId = _sessionId, Command = command, Cwd = cwd, Timeout = timeout };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.shell.exec", [request], cancellationToken);
}
- /// Calls "session.shell.kill".
+ /// Sends a signal to a shell process previously started via "shell.exec".
/// Process identifier returned by shell.exec.
/// Signal to send (default: SIGTERM).
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the signal was delivered; false if the process was unknown or already exited.
public async Task KillAsync(string processId, ShellKillSignal? signal = null, CancellationToken cancellationToken = default)
{
var request = new ShellKillRequest { SessionId = _sessionId, ProcessId = processId, Signal = signal };
@@ -6160,17 +6245,19 @@ internal HistoryApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.history.compact".
+ /// Compacts the session history to reduce context usage.
/// The to monitor for cancellation requests. The default is .
+ /// Compaction outcome with the number of tokens and messages removed and the resulting context window breakdown.
public async Task CompactAsync(CancellationToken cancellationToken = default)
{
var request = new SessionHistoryCompactRequest { SessionId = _sessionId };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.history.compact", [request], cancellationToken);
}
- /// Calls "session.history.truncate".
+ /// Truncates persisted session history to a specific event.
/// Event ID to truncate to. This event and all events after it are removed from the session.
/// The to monitor for cancellation requests. The default is .
+ /// Number of events that were removed by the truncation.
public async Task TruncateAsync(string eventId, CancellationToken cancellationToken = default)
{
var request = new HistoryTruncateRequest { SessionId = _sessionId, EventId = eventId };
@@ -6191,8 +6278,9 @@ internal UsageApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.usage.getMetrics".
+ /// Gets accumulated usage metrics for the session.
/// The to monitor for cancellation requests. The default is .
+ /// Accumulated session usage metrics, including premium request cost, token counts, model breakdown, and code-change totals.
public async Task GetMetricsAsync(CancellationToken cancellationToken = default)
{
var request = new SessionUsageGetMetricsRequest { SessionId = _sessionId };
@@ -6213,16 +6301,17 @@ internal RemoteApi(JsonRpc rpc, string sessionId)
_sessionId = sessionId;
}
- /// Calls "session.remote.enable".
- /// Per-session remote mode. "off" disables remote, "export" exports session events to Mission Control without enabling remote steering, "on" enables both export and remote steering.
+ /// Enables remote session export or steering.
+ /// Per-session remote mode. "off" disables remote, "export" exports session events to GitHub without enabling remote steering, "on" enables both export and remote steering.
/// The to monitor for cancellation requests. The default is .
+ /// GitHub URL for the session and a flag indicating whether remote steering is enabled.
public async Task EnableAsync(RemoteSessionMode? mode = null, CancellationToken cancellationToken = default)
{
var request = new RemoteEnableRequest { SessionId = _sessionId, Mode = mode };
return await CopilotClient.InvokeRpcAsync(_rpc, "session.remote.enable", [request], cancellationToken);
}
- /// Calls "session.remote.disable".
+ /// Disables remote session export and steering.
/// The to monitor for cancellation requests. The default is .
public async Task DisableAsync(CancellationToken cancellationToken = default)
{
@@ -6234,48 +6323,53 @@ public async Task DisableAsync(CancellationToken cancellationToken = default)
/// Handles `sessionFs` client session API methods.
public interface ISessionFsHandler
{
- /// Handles "sessionFs.readFile".
- /// The request parameters.
+ /// Reads a file from the client-provided session filesystem.
+ /// Path of the file to read from the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
+ /// File content as a UTF-8 string, or a filesystem error if the read failed.
Task ReadFileAsync(SessionFsReadFileRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.writeFile".
- /// The request parameters.
+ /// Writes a file in the client-provided session filesystem.
+ /// File path, content to write, and optional mode for the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
/// Describes a filesystem error.
Task WriteFileAsync(SessionFsWriteFileRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.appendFile".
- /// The request parameters.
+ /// Appends content to a file in the client-provided session filesystem.
+ /// File path, content to append, and optional mode for the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
/// Describes a filesystem error.
Task AppendFileAsync(SessionFsAppendFileRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.exists".
- /// The request parameters.
+ /// Checks whether a path exists in the client-provided session filesystem.
+ /// Path to test for existence in the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
+ /// Indicates whether the requested path exists in the client-provided session filesystem.
Task ExistsAsync(SessionFsExistsRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.stat".
- /// The request parameters.
+ /// Gets metadata for a path in the client-provided session filesystem.
+ /// Path whose metadata should be returned from the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
+ /// Filesystem metadata for the requested path, or a filesystem error if the stat failed.
Task StatAsync(SessionFsStatRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.mkdir".
- /// The request parameters.
+ /// Creates a directory in the client-provided session filesystem.
+ /// Directory path to create in the client-provided session filesystem, with options for recursive creation and POSIX mode.
/// The to monitor for cancellation requests. The default is .
/// Describes a filesystem error.
Task MkdirAsync(SessionFsMkdirRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.readdir".
- /// The request parameters.
+ /// Lists entry names in a directory from the client-provided session filesystem.
+ /// Directory path whose entries should be listed from the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
+ /// Names of entries in the requested directory, or a filesystem error if the read failed.
Task ReaddirAsync(SessionFsReaddirRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.readdirWithTypes".
- /// The request parameters.
+ /// Lists directory entries with type information from the client-provided session filesystem.
+ /// Directory path whose entries (with type information) should be listed from the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
+ /// Entries in the requested directory paired with file/directory type information, or a filesystem error if the read failed.
Task ReaddirWithTypesAsync(SessionFsReaddirWithTypesRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.rm".
- /// The request parameters.
+ /// Removes a file or directory from the client-provided session filesystem.
+ /// Path to remove from the client-provided session filesystem, with options for recursive removal and force.
/// The to monitor for cancellation requests. The default is .
/// Describes a filesystem error.
Task RmAsync(SessionFsRmRequest request, CancellationToken cancellationToken = default);
- /// Handles "sessionFs.rename".
- /// The request parameters.
+ /// Renames or moves a path in the client-provided session filesystem.
+ /// Source and destination paths for renaming or moving an entry in the client-provided session filesystem.
/// The to monitor for cancellation requests. The default is .
/// Describes a filesystem error.
Task RenameAsync(SessionFsRenameRequest request, CancellationToken cancellationToken = default);
@@ -6372,6 +6466,7 @@ public static void RegisterClientSessionApiHandlers(JsonRpc rpc, FuncNotifies Mission Control that the session's remote steering capability has changed.
+/// Notifies that the session's remote steering capability has changed.
/// Represents the session.remote_steerable_changed event.
public partial class SessionRemoteSteerableChangedEvent : SessionEvent
{
@@ -446,7 +446,8 @@ public partial class SessionTaskCompleteEvent : SessionEvent
public required SessionTaskCompleteData Data { get; set; }
}
-/// Represents the user.message event.
+/// Schema for the `UserMessageData` type.
+/// Represents the user.message event.
public partial class UserMessageEvent : SessionEvent
{
///
@@ -1108,7 +1109,8 @@ public partial class ExitPlanModeCompletedEvent : SessionEvent
public required ExitPlanModeCompletedData Data { get; set; }
}
-/// Represents the session.tools_updated event.
+/// Schema for the `ToolsUpdatedData` type.
+/// Represents the session.tools_updated event.
public partial class SessionToolsUpdatedEvent : SessionEvent
{
///
@@ -1120,7 +1122,8 @@ public partial class SessionToolsUpdatedEvent : SessionEvent
public required SessionToolsUpdatedData Data { get; set; }
}
-/// Represents the session.background_tasks_changed event.
+/// Schema for the `BackgroundTasksChangedData` type.
+/// Represents the session.background_tasks_changed event.
public partial class SessionBackgroundTasksChangedEvent : SessionEvent
{
///
@@ -1132,7 +1135,8 @@ public partial class SessionBackgroundTasksChangedEvent : SessionEvent
public required SessionBackgroundTasksChangedData Data { get; set; }
}
-/// Represents the session.skills_loaded event.
+/// Schema for the `SkillsLoadedData` type.
+/// Represents the session.skills_loaded event.
public partial class SessionSkillsLoadedEvent : SessionEvent
{
///
@@ -1144,7 +1148,8 @@ public partial class SessionSkillsLoadedEvent : SessionEvent
public required SessionSkillsLoadedData Data { get; set; }
}
-/// Represents the session.custom_agents_updated event.
+/// Schema for the `CustomAgentsUpdatedData` type.
+/// Represents the session.custom_agents_updated event.
public partial class SessionCustomAgentsUpdatedEvent : SessionEvent
{
///
@@ -1156,7 +1161,8 @@ public partial class SessionCustomAgentsUpdatedEvent : SessionEvent
public required SessionCustomAgentsUpdatedData Data { get; set; }
}
-/// Represents the session.mcp_servers_loaded event.
+/// Schema for the `McpServersLoadedData` type.
+/// Represents the session.mcp_servers_loaded event.
public partial class SessionMcpServersLoadedEvent : SessionEvent
{
///
@@ -1168,7 +1174,8 @@ public partial class SessionMcpServersLoadedEvent : SessionEvent
public required SessionMcpServersLoadedData Data { get; set; }
}
-/// Represents the session.mcp_server_status_changed event.
+/// Schema for the `McpServerStatusChangedData` type.
+/// Represents the session.mcp_server_status_changed event.
public partial class SessionMcpServerStatusChangedEvent : SessionEvent
{
///
@@ -1180,7 +1187,8 @@ public partial class SessionMcpServerStatusChangedEvent : SessionEvent
public required SessionMcpServerStatusChangedData Data { get; set; }
}
-/// Represents the session.extensions_loaded event.
+/// Schema for the `ExtensionsLoadedData` type.
+/// Represents the session.extensions_loaded event.
public partial class SessionExtensionsLoadedEvent : SessionEvent
{
///
@@ -1218,12 +1226,17 @@ public partial class SessionStartData
[JsonPropertyName("producer")]
public required string Producer { get; set; }
- /// Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh").
+ /// Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh").
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("reasoningEffort")]
public string? ReasoningEffort { get; set; }
- /// Whether this session supports remote steering via Mission Control.
+ /// Reasoning summary mode used for model calls, if applicable (e.g. "none", "concise", "detailed").
+ [JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
+ [JsonPropertyName("reasoningSummary")]
+ public ReasoningSummary? ReasoningSummary { get; set; }
+
+ /// Whether this session supports remote steering via GitHub.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("remoteSteerable")]
public bool? RemoteSteerable { get; set; }
@@ -1268,12 +1281,17 @@ public partial class SessionResumeData
[JsonPropertyName("eventCount")]
public required double EventCount { get; set; }
- /// Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh").
+ /// Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh").
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("reasoningEffort")]
public string? ReasoningEffort { get; set; }
- /// Whether this session supports remote steering via Mission Control.
+ /// Reasoning summary mode used for model calls, if applicable (e.g. "none", "concise", "detailed").
+ [JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
+ [JsonPropertyName("reasoningSummary")]
+ public ReasoningSummary? ReasoningSummary { get; set; }
+
+ /// Whether this session supports remote steering via GitHub.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("remoteSteerable")]
public bool? RemoteSteerable { get; set; }
@@ -1293,10 +1311,10 @@ public partial class SessionResumeData
public bool? SessionWasActive { get; set; }
}
-/// Notifies Mission Control that the session's remote steering capability has changed.
+/// Notifies that the session's remote steering capability has changed.
public partial class SessionRemoteSteerableChangedData
{
- /// Whether this session now supports remote steering via Mission Control.
+ /// Whether this session now supports remote steering via GitHub.
[JsonPropertyName("remoteSteerable")]
public required bool RemoteSteerable { get; set; }
}
@@ -1365,6 +1383,11 @@ public partial class SessionTitleChangedData
/// Scheduled prompt registered via /every or /after.
public partial class SessionScheduleCreatedData
{
+ /// Optional user-facing label shown in the timeline instead of the actual prompt (e.g. `/skill-name args` when the prompt is a skill invocation expansion).
+ [JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
+ [JsonPropertyName("displayPrompt")]
+ public string? DisplayPrompt { get; set; }
+
/// Sequential id assigned to the scheduled prompt within the session.
[JsonPropertyName("id")]
public required long Id { get; set; }
@@ -1456,10 +1479,20 @@ public partial class SessionModelChangeData
[JsonPropertyName("previousReasoningEffort")]
public string? PreviousReasoningEffort { get; set; }
+ /// Reasoning summary mode before the model change, if applicable.
+ [JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
+ [JsonPropertyName("previousReasoningSummary")]
+ public ReasoningSummary? PreviousReasoningSummary { get; set; }
+
/// Reasoning effort level after the model change, if applicable.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("reasoningEffort")]
public string? ReasoningEffort { get; set; }
+
+ /// Reasoning summary mode after the model change, if applicable.
+ [JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
+ [JsonPropertyName("reasoningSummary")]
+ public ReasoningSummary? ReasoningSummary { get; set; }
}
/// Agent mode change details including previous and new modes.
@@ -1837,7 +1870,7 @@ public partial class SessionTaskCompleteData
public string? Summary { get; set; }
}
-/// Event payload for .
+/// Schema for the `UserMessageData` type.
public partial class UserMessageData
{
/// The agent mode that was active when this message was sent.
@@ -2146,7 +2179,7 @@ public partial class AssistantUsageData
[JsonPropertyName("quotaSnapshots")]
public IDictionary? QuotaSnapshots { get; set; }
- /// Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh").
+ /// Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh").
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("reasoningEffort")]
public string? ReasoningEffort { get; set; }
@@ -2986,20 +3019,20 @@ public partial class ExitPlanModeCompletedData
public string? SelectedAction { get; set; }
}
-/// Event payload for .
+/// Schema for the `ToolsUpdatedData` type.
public partial class SessionToolsUpdatedData
{
- /// Gets or sets the model value.
+ /// Identifier of the model the resolved tools apply to.
[JsonPropertyName("model")]
public required string Model { get; set; }
}
-/// Event payload for .
+/// Schema for the `BackgroundTasksChangedData` type.
public partial class SessionBackgroundTasksChangedData
{
}
-/// Event payload for .
+/// Schema for the `SkillsLoadedData` type.
public partial class SessionSkillsLoadedData
{
/// Array of resolved skill metadata.
@@ -3007,7 +3040,7 @@ public partial class SessionSkillsLoadedData
public required SkillsLoadedSkill[] Skills { get; set; }
}
-/// Event payload for .
+/// Schema for the `CustomAgentsUpdatedData` type.
public partial class SessionCustomAgentsUpdatedData
{
/// Array of loaded custom agent metadata.
@@ -3023,7 +3056,7 @@ public partial class SessionCustomAgentsUpdatedData
public required string[] Warnings { get; set; }
}
-/// Event payload for .
+/// Schema for the `McpServersLoadedData` type.
public partial class SessionMcpServersLoadedData
{
/// Array of MCP server status summaries.
@@ -3031,7 +3064,7 @@ public partial class SessionMcpServersLoadedData
public required McpServersLoadedServer[] Servers { get; set; }
}
-/// Event payload for .
+/// Schema for the `McpServerStatusChangedData` type.
public partial class SessionMcpServerStatusChangedData
{
/// Name of the MCP server whose status changed.
@@ -3043,7 +3076,7 @@ public partial class SessionMcpServerStatusChangedData
public required McpServerStatusChangedStatus Status { get; set; }
}
-/// Event payload for .
+/// Schema for the `ExtensionsLoadedData` type.
public partial class SessionExtensionsLoadedData
{
/// Array of discovered extensions and their status.
@@ -3143,7 +3176,8 @@ public partial class ShutdownModelMetricRequests
public required double Count { get; set; }
}
-/// Nested data type for ShutdownModelMetricTokenDetail .
+/// Schema for the `ShutdownModelMetricTokenDetail` type.
+/// Nested data type for ShutdownModelMetricTokenDetail .
public partial class ShutdownModelMetricTokenDetail
{
/// Accumulated token count for this token type.
@@ -3177,7 +3211,8 @@ public partial class ShutdownModelMetricUsage
public double? ReasoningTokens { get; set; }
}
-/// Nested data type for ShutdownModelMetric .
+/// Schema for the `ShutdownModelMetric` type.
+/// Nested data type for ShutdownModelMetric .
public partial class ShutdownModelMetric
{
/// Request count and cost metrics.
@@ -3199,7 +3234,8 @@ public partial class ShutdownModelMetric
public required ShutdownModelMetricUsage Usage { get; set; }
}
-/// Nested data type for ShutdownTokenDetail .
+/// Schema for the `ShutdownTokenDetail` type.
+/// Nested data type for ShutdownTokenDetail .
public partial class ShutdownTokenDetail
{
/// Accumulated token count for this token type.
@@ -3544,7 +3580,8 @@ public partial class AssistantUsageCopilotUsage
public required double TotalNanoAiu { get; set; }
}
-/// Nested data type for AssistantUsageQuotaSnapshot .
+/// Schema for the `AssistantUsageQuotaSnapshot` type.
+/// Nested data type for AssistantUsageQuotaSnapshot .
public partial class AssistantUsageQuotaSnapshot
{
/// Total requests allowed by the entitlement.
@@ -3733,7 +3770,8 @@ public partial class ToolExecutionCompleteContentResourceLink : ToolExecutionCom
public required string Uri { get; set; }
}
-/// Nested data type for EmbeddedTextResourceContents .
+/// Schema for the `EmbeddedTextResourceContents` type.
+/// Nested data type for EmbeddedTextResourceContents .
public partial class EmbeddedTextResourceContents
{
/// MIME type of the text content.
@@ -3750,7 +3788,8 @@ public partial class EmbeddedTextResourceContents
public required string Uri { get; set; }
}
-/// Nested data type for EmbeddedBlobResourceContents .
+/// Schema for the `EmbeddedBlobResourceContents` type.
+/// Nested data type for EmbeddedBlobResourceContents .
public partial class EmbeddedBlobResourceContents
{
/// Base64-encoded binary content of the resource.
@@ -3926,7 +3965,8 @@ public partial class SystemMessageMetadata
public IDictionary? Variables { get; set; }
}
-/// The agent_completed variant of .
+/// Schema for the `SystemNotificationAgentCompleted` type.
+/// The agent_completed variant of .
public partial class SystemNotificationAgentCompleted : SystemNotification
{
///
@@ -3956,7 +3996,8 @@ public partial class SystemNotificationAgentCompleted : SystemNotification
public required SystemNotificationAgentCompletedStatus Status { get; set; }
}
-/// The agent_idle variant of .
+/// Schema for the `SystemNotificationAgentIdle` type.
+/// The agent_idle variant of .
public partial class SystemNotificationAgentIdle : SystemNotification
{
///
@@ -3977,7 +4018,8 @@ public partial class SystemNotificationAgentIdle : SystemNotification
public string? Description { get; set; }
}
-/// The new_inbox_message variant of .
+/// Schema for the `SystemNotificationNewInboxMessage` type.
+/// The new_inbox_message variant of .
public partial class SystemNotificationNewInboxMessage : SystemNotification
{
///
@@ -4001,7 +4043,8 @@ public partial class SystemNotificationNewInboxMessage : SystemNotification
public required string Summary { get; set; }
}
-/// The shell_completed variant of .
+/// Schema for the `SystemNotificationShellCompleted` type.
+/// The shell_completed variant of .
public partial class SystemNotificationShellCompleted : SystemNotification
{
///
@@ -4023,7 +4066,8 @@ public partial class SystemNotificationShellCompleted : SystemNotification
public required string ShellId { get; set; }
}
-/// The shell_detached_completed variant of .
+/// Schema for the `SystemNotificationShellDetachedCompleted` type.
+/// The shell_detached_completed variant of .
public partial class SystemNotificationShellDetachedCompleted : SystemNotification
{
///
@@ -4040,7 +4084,8 @@ public partial class SystemNotificationShellDetachedCompleted : SystemNotificati
public required string ShellId { get; set; }
}
-/// The instruction_discovered variant of .
+/// Schema for the `SystemNotificationInstructionDiscovered` type.
+/// The instruction_discovered variant of .
public partial class SystemNotificationInstructionDiscovered : SystemNotification
{
///
@@ -4084,7 +4129,8 @@ public partial class SystemNotification
}
-/// Nested data type for PermissionRequestShellCommand .
+/// Schema for the `PermissionRequestShellCommand` type.
+/// Nested data type for PermissionRequestShellCommand .
public partial class PermissionRequestShellCommand
{
/// Command identifier (e.g., executable name).
@@ -4096,7 +4142,8 @@ public partial class PermissionRequestShellCommand
public required bool ReadOnly { get; set; }
}
-/// Nested data type for PermissionRequestShellPossibleUrl .
+/// Schema for the `PermissionRequestShellPossibleUrl` type.
+/// Nested data type for PermissionRequestShellPossibleUrl .
public partial class PermissionRequestShellPossibleUrl
{
/// URL that may be accessed by the command.
@@ -4765,7 +4812,8 @@ public partial class PermissionPromptRequest
}
-/// The approved variant of .
+/// Schema for the `PermissionApproved` type.
+/// The approved variant of .
public partial class PermissionResultApproved : PermissionResult
{
///
@@ -4773,7 +4821,8 @@ public partial class PermissionResultApproved : PermissionResult
public override string Kind => "approved";
}
-/// The commands variant of .
+/// Schema for the `UserToolSessionApprovalCommands` type.
+/// The commands variant of .
public partial class UserToolSessionApprovalCommands : UserToolSessionApproval
{
///
@@ -4785,7 +4834,8 @@ public partial class UserToolSessionApprovalCommands : UserToolSessionApproval
public required string[] CommandIdentifiers { get; set; }
}
-/// The read variant of .
+/// Schema for the `UserToolSessionApprovalRead` type.
+/// The read variant of .
public partial class UserToolSessionApprovalRead : UserToolSessionApproval
{
///
@@ -4793,7 +4843,8 @@ public partial class UserToolSessionApprovalRead : UserToolSessionApproval
public override string Kind => "read";
}
-/// The write variant of .
+/// Schema for the `UserToolSessionApprovalWrite` type.
+/// The write variant of .
public partial class UserToolSessionApprovalWrite : UserToolSessionApproval
{
///
@@ -4801,7 +4852,8 @@ public partial class UserToolSessionApprovalWrite : UserToolSessionApproval
public override string Kind => "write";
}
-/// The mcp variant of .
+/// Schema for the `UserToolSessionApprovalMcp` type.
+/// The mcp variant of .
public partial class UserToolSessionApprovalMcp : UserToolSessionApproval
{
///
@@ -4817,7 +4869,8 @@ public partial class UserToolSessionApprovalMcp : UserToolSessionApproval
public string? ToolName { get; set; }
}
-/// The memory variant of .
+/// Schema for the `UserToolSessionApprovalMemory` type.
+/// The memory variant of .
public partial class UserToolSessionApprovalMemory : UserToolSessionApproval
{
///
@@ -4825,7 +4878,8 @@ public partial class UserToolSessionApprovalMemory : UserToolSessionApproval
public override string Kind => "memory";
}
-/// The custom-tool variant of .
+/// Schema for the `UserToolSessionApprovalCustomTool` type.
+/// The custom-tool variant of .
public partial class UserToolSessionApprovalCustomTool : UserToolSessionApproval
{
///
@@ -4837,7 +4891,8 @@ public partial class UserToolSessionApprovalCustomTool : UserToolSessionApproval
public required string ToolName { get; set; }
}
-/// The extension-management variant of .
+/// Schema for the `UserToolSessionApprovalExtensionManagement` type.
+/// The extension-management variant of .
public partial class UserToolSessionApprovalExtensionManagement : UserToolSessionApproval
{
///
@@ -4850,7 +4905,8 @@ public partial class UserToolSessionApprovalExtensionManagement : UserToolSessio
public string? Operation { get; set; }
}
-/// The extension-permission-access variant of .
+/// Schema for the `UserToolSessionApprovalExtensionPermissionAccess` type.
+/// The extension-permission-access variant of .
public partial class UserToolSessionApprovalExtensionPermissionAccess : UserToolSessionApproval
{
///
@@ -4883,7 +4939,8 @@ public partial class UserToolSessionApproval
}
-/// The approved-for-session variant of .
+/// Schema for the `PermissionApprovedForSession` type.
+/// The approved-for-session variant of .
public partial class PermissionResultApprovedForSession : PermissionResult
{
///
@@ -4895,7 +4952,8 @@ public partial class PermissionResultApprovedForSession : PermissionResult
public required UserToolSessionApproval Approval { get; set; }
}
-/// The approved-for-location variant of .
+/// Schema for the `PermissionApprovedForLocation` type.
+/// The approved-for-location variant of .
public partial class PermissionResultApprovedForLocation : PermissionResult
{
///
@@ -4911,7 +4969,8 @@ public partial class PermissionResultApprovedForLocation : PermissionResult
public required string LocationKey { get; set; }
}
-/// The cancelled variant of .
+/// Schema for the `PermissionCancelled` type.
+/// The cancelled variant of .
public partial class PermissionResultCancelled : PermissionResult
{
///
@@ -4924,7 +4983,8 @@ public partial class PermissionResultCancelled : PermissionResult
public string? Reason { get; set; }
}
-/// Nested data type for PermissionRule .
+/// Schema for the `PermissionRule` type.
+/// Nested data type for PermissionRule .
public partial class PermissionRule
{
/// Optional rule argument matched against the request.
@@ -4936,7 +4996,8 @@ public partial class PermissionRule
public required string Kind { get; set; }
}
-/// The denied-by-rules variant of .
+/// Schema for the `PermissionDeniedByRules` type.
+/// The denied-by-rules variant of .
public partial class PermissionResultDeniedByRules : PermissionResult
{
///
@@ -4948,7 +5009,8 @@ public partial class PermissionResultDeniedByRules : PermissionResult
public required PermissionRule[] Rules { get; set; }
}
-/// The denied-no-approval-rule-and-could-not-request-from-user variant of .
+/// Schema for the `PermissionDeniedNoApprovalRuleAndCouldNotRequestFromUser` type.
+/// The denied-no-approval-rule-and-could-not-request-from-user variant of .
public partial class PermissionResultDeniedNoApprovalRuleAndCouldNotRequestFromUser : PermissionResult
{
///
@@ -4956,7 +5018,8 @@ public partial class PermissionResultDeniedNoApprovalRuleAndCouldNotRequestFromU
public override string Kind => "denied-no-approval-rule-and-could-not-request-from-user";
}
-/// The denied-interactively-by-user variant of .
+/// Schema for the `PermissionDeniedInteractivelyByUser` type.
+/// The denied-interactively-by-user variant of .
public partial class PermissionResultDeniedInteractivelyByUser : PermissionResult
{
///
@@ -4974,7 +5037,8 @@ public partial class PermissionResultDeniedInteractivelyByUser : PermissionResul
public bool? ForceReject { get; set; }
}
-/// The denied-by-content-exclusion-policy variant of .
+/// Schema for the `PermissionDeniedByContentExclusionPolicy` type.
+/// The denied-by-content-exclusion-policy variant of .
public partial class PermissionResultDeniedByContentExclusionPolicy : PermissionResult
{
///
@@ -4990,7 +5054,8 @@ public partial class PermissionResultDeniedByContentExclusionPolicy : Permission
public required string Path { get; set; }
}
-/// The denied-by-permission-request-hook variant of .
+/// Schema for the `PermissionDeniedByPermissionRequestHook` type.
+/// The denied-by-permission-request-hook variant of .
public partial class PermissionResultDeniedByPermissionRequestHook : PermissionResult
{
///
@@ -5067,15 +5132,16 @@ public partial class McpOauthRequiredStaticClientConfig
public bool? PublicClient { get; set; }
}
-/// Nested data type for CommandsChangedCommand .
+/// Schema for the `CommandsChangedCommand` type.
+/// Nested data type for CommandsChangedCommand .
public partial class CommandsChangedCommand
{
- /// Gets or sets the description value.
+ /// Optional human-readable command description.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("description")]
public string? Description { get; set; }
- /// Gets or sets the name value.
+ /// Slash command name without the leading slash.
[JsonPropertyName("name")]
public required string Name { get; set; }
}
@@ -5090,7 +5156,8 @@ public partial class CapabilitiesChangedUI
public bool? Elicitation { get; set; }
}
-/// Nested data type for SkillsLoadedSkill .
+/// Schema for the `SkillsLoadedSkill` type.
+/// Nested data type for SkillsLoadedSkill .
public partial class SkillsLoadedSkill
{
/// Description of what the skill does.
@@ -5119,7 +5186,8 @@ public partial class SkillsLoadedSkill
public required bool UserInvocable { get; set; }
}
-/// Nested data type for CustomAgentsUpdatedAgent .
+/// Schema for the `CustomAgentsUpdatedAgent` type.
+/// Nested data type for CustomAgentsUpdatedAgent .
public partial class CustomAgentsUpdatedAgent
{
/// Description of what the agent does.
@@ -5156,7 +5224,8 @@ public partial class CustomAgentsUpdatedAgent
public required bool UserInvocable { get; set; }
}
-/// Nested data type for McpServersLoadedServer .
+/// Schema for the `McpServersLoadedServer` type.
+/// Nested data type for McpServersLoadedServer .
public partial class McpServersLoadedServer
{
/// Error message if the server failed to connect.
@@ -5178,7 +5247,8 @@ public partial class McpServersLoadedServer
public required McpServersLoadedServerStatus Status { get; set; }
}
-/// Nested data type for ExtensionsLoadedExtension .
+/// Schema for the `ExtensionsLoadedExtension` type.
+/// Nested data type for ExtensionsLoadedExtension .
public partial class ExtensionsLoadedExtension
{
/// Source-qualified extension ID (e.g., 'project:my-ext', 'user:auth-helper').
@@ -5259,6 +5329,70 @@ public override void Write(Utf8JsonWriter writer, WorkingDirectoryContextHostTyp
}
}
+/// Reasoning summary mode used for model calls, if applicable (e.g. "none", "concise", "detailed").
+[JsonConverter(typeof(Converter))]
+[DebuggerDisplay("{Value,nq}")]
+public readonly struct ReasoningSummary : IEquatable
+{
+ private readonly string? _value;
+
+ /// Initializes a new instance of the struct.
+ /// The value to associate with this .
+ [JsonConstructor]
+ public ReasoningSummary(string value)
+ {
+ ArgumentException.ThrowIfNullOrWhiteSpace(value);
+ _value = value;
+ }
+
+ /// Gets the value associated with this .
+ public string Value => _value ?? string.Empty;
+
+ /// Gets the none value.
+ public static ReasoningSummary None { get; } = new("none");
+
+ /// Gets the concise value.
+ public static ReasoningSummary Concise { get; } = new("concise");
+
+ /// Gets the detailed value.
+ public static ReasoningSummary Detailed { get; } = new("detailed");
+
+ /// Returns a value indicating whether two instances are equivalent.
+ public static bool operator ==(ReasoningSummary left, ReasoningSummary right) => left.Equals(right);
+
+ /// Returns a value indicating whether two instances are not equivalent.
+ public static bool operator !=(ReasoningSummary left, ReasoningSummary right) => !(left == right);
+
+ ///
+ public override bool Equals(object? obj) => obj is ReasoningSummary other && Equals(other);
+
+ ///
+ public bool Equals(ReasoningSummary other) => string.Equals(Value, other.Value, StringComparison.OrdinalIgnoreCase);
+
+ ///
+ public override int GetHashCode() => StringComparer.OrdinalIgnoreCase.GetHashCode(Value);
+
+ ///
+ public override string ToString() => Value;
+
+ /// Provides a for serializing instances.
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public sealed class Converter : JsonConverter
+ {
+ ///
+ public override ReasoningSummary Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
+ {
+ return new(GitHub.Copilot.SDK.GeneratedStringEnumJson.ReadValue(ref reader, typeToConvert));
+ }
+
+ ///
+ public override void Write(Utf8JsonWriter writer, ReasoningSummary value, JsonSerializerOptions options)
+ {
+ GitHub.Copilot.SDK.GeneratedStringEnumJson.WriteValue(writer, value.Value, typeof(ReasoningSummary));
+ }
+ }
+}
+
/// The type of operation performed on the plan file.
[JsonConverter(typeof(Converter))]
[DebuggerDisplay("{Value,nq}")]
diff --git a/dotnet/src/Session.cs b/dotnet/src/Session.cs
index 856b85866..90e434380 100644
--- a/dotnet/src/Session.cs
+++ b/dotnet/src/Session.cs
@@ -1320,7 +1320,7 @@ await InvokeRpcAsync(
///
public async Task SetModelAsync(string model, string? reasoningEffort, ModelCapabilitiesOverride? modelCapabilities = null, CancellationToken cancellationToken = default)
{
- await Rpc.Model.SwitchToAsync(model, reasoningEffort, modelCapabilities, cancellationToken);
+ await Rpc.Model.SwitchToAsync(model, reasoningEffort, reasoningSummary: null, modelCapabilities: modelCapabilities, cancellationToken: cancellationToken);
}
///
diff --git a/go/rpc/zrpc.go b/go/rpc/zrpc.go
index f114e2382..fb8f0efaa 100644
--- a/go/rpc/zrpc.go
+++ b/go/rpc/zrpc.go
@@ -18,11 +18,13 @@ type AccountGetQuotaRequest struct {
GitHubToken *string `json:"gitHubToken,omitempty"`
}
+// Quota usage snapshots for the resolved user, keyed by quota type.
type AccountGetQuotaResult struct {
// Quota snapshots keyed by type (e.g., chat, completions, premium_interactions)
QuotaSnapshots map[string]AccountQuotaSnapshot `json:"quotaSnapshots"`
}
+// Schema for the `AccountQuotaSnapshot` type.
type AccountQuotaSnapshot struct {
// Number of requests included in the entitlement
EntitlementRequests int64 `json:"entitlementRequests"`
@@ -42,11 +44,7 @@ type AccountQuotaSnapshot struct {
UsedRequests int64 `json:"usedRequests"`
}
-// Experimental: AgentDeselectResult is part of an experimental API and may change or be
-// removed.
-type AgentDeselectResult struct {
-}
-
+// The currently selected custom agent, or null when using the default agent.
// Experimental: AgentGetCurrentResult is part of an experimental API and may change or be
// removed.
type AgentGetCurrentResult struct {
@@ -54,6 +52,7 @@ type AgentGetCurrentResult struct {
Agent *AgentInfo `json:"agent,omitempty"`
}
+// Schema for the `AgentInfo` type.
type AgentInfo struct {
// Description of the agent's purpose
Description string `json:"description"`
@@ -66,12 +65,14 @@ type AgentInfo struct {
Path *string `json:"path,omitempty"`
}
+// Custom agents available to the session.
// Experimental: AgentList is part of an experimental API and may change or be removed.
type AgentList struct {
// Available custom agents
Agents []AgentInfo `json:"agents"`
}
+// Custom agents available to the session after reloading definitions from disk.
// Experimental: AgentReloadResult is part of an experimental API and may change or be
// removed.
type AgentReloadResult struct {
@@ -79,6 +80,7 @@ type AgentReloadResult struct {
Agents []AgentInfo `json:"agents"`
}
+// Name of the custom agent to select for subsequent turns.
// Experimental: AgentSelectRequest is part of an experimental API and may change or be
// removed.
type AgentSelectRequest struct {
@@ -86,6 +88,7 @@ type AgentSelectRequest struct {
Name string `json:"name"`
}
+// The newly selected custom agent.
// Experimental: AgentSelectResult is part of an experimental API and may change or be
// removed.
type AgentSelectResult struct {
@@ -93,11 +96,13 @@ type AgentSelectResult struct {
Agent AgentInfo `json:"agent"`
}
+// Slash commands available in the session, after applying any include/exclude filters.
type CommandList struct {
// Commands available in this session
Commands []SlashCommandInfo `json:"commands"`
}
+// Pending command request ID and an optional error if the client handler failed.
type CommandsHandlePendingCommandRequest struct {
// Error message if the command handler failed
Error *string `json:"error,omitempty"`
@@ -105,11 +110,13 @@ type CommandsHandlePendingCommandRequest struct {
RequestID string `json:"requestId"`
}
+// Indicates whether the pending client-handled command was completed successfully.
type CommandsHandlePendingCommandResult struct {
// Whether the command was handled successfully
Success bool `json:"success"`
}
+// Slash command name and optional raw input string to invoke.
type CommandsInvokeRequest struct {
// Raw input after the command name
Input *string `json:"input,omitempty"`
@@ -117,6 +124,7 @@ type CommandsInvokeRequest struct {
Name string `json:"name"`
}
+// Optional filters controlling which command sources to include in the listing.
type CommandsListRequest struct {
// Include runtime built-in commands
IncludeBuiltins *bool `json:"includeBuiltins,omitempty"`
@@ -126,6 +134,7 @@ type CommandsListRequest struct {
IncludeSkills *bool `json:"includeSkills,omitempty"`
}
+// Queued command request ID and the result indicating whether the client handled it.
type CommandsRespondToQueuedCommandRequest struct {
// Request ID from the queued command event
RequestID string `json:"requestId"`
@@ -133,18 +142,21 @@ type CommandsRespondToQueuedCommandRequest struct {
Result QueuedCommandResult `json:"result"`
}
+// Indicates whether the queued-command response was accepted by the session.
type CommandsRespondToQueuedCommandResult struct {
// Whether the response was accepted (false if the requestId was not found or already
// resolved)
Success bool `json:"success"`
}
+// Optional connection token presented by the SDK client during the handshake.
// Internal: ConnectRequest is an internal SDK API and is not part of the public surface.
type ConnectRequest struct {
// Connection token; required when the server was started with COPILOT_CONNECTION_TOKEN
Token *string `json:"token,omitempty"`
}
+// Handshake result reporting the server's protocol version and package version on success.
// Internal: ConnectResult is an internal SDK API and is not part of the public surface.
type ConnectResult struct {
// Always true on success
@@ -155,11 +167,13 @@ type ConnectResult struct {
Version string `json:"version"`
}
+// The currently selected model for the session.
type CurrentModel struct {
// Currently active model identifier
ModelID *string `json:"modelId,omitempty"`
}
+// Schema for the `DiscoveredMcpServer` type.
type DiscoveredMcpServer struct {
// Whether the server is enabled (not in the disabled list)
Enabled bool `json:"enabled"`
@@ -171,6 +185,7 @@ type DiscoveredMcpServer struct {
Type *DiscoveredMcpServerType `json:"type,omitempty"`
}
+// Schema for the `Extension` type.
type Extension struct {
// Source-qualified ID (e.g., 'project:my-ext', 'user:auth-helper')
ID string `json:"id"`
@@ -184,12 +199,14 @@ type Extension struct {
Status ExtensionStatus `json:"status"`
}
+// Extensions discovered for the session, with their current status.
// Experimental: ExtensionList is part of an experimental API and may change or be removed.
type ExtensionList struct {
// Discovered extensions and their current status
Extensions []Extension `json:"extensions"`
}
+// Source-qualified extension identifier to disable for the session.
// Experimental: ExtensionsDisableRequest is part of an experimental API and may change or
// be removed.
type ExtensionsDisableRequest struct {
@@ -197,11 +214,7 @@ type ExtensionsDisableRequest struct {
ID string `json:"id"`
}
-// Experimental: ExtensionsDisableResult is part of an experimental API and may change or be
-// removed.
-type ExtensionsDisableResult struct {
-}
-
+// Source-qualified extension identifier to enable for the session.
// Experimental: ExtensionsEnableRequest is part of an experimental API and may change or be
// removed.
type ExtensionsEnableRequest struct {
@@ -209,16 +222,6 @@ type ExtensionsEnableRequest struct {
ID string `json:"id"`
}
-// Experimental: ExtensionsEnableResult is part of an experimental API and may change or be
-// removed.
-type ExtensionsEnableResult struct {
-}
-
-// Experimental: ExtensionsReloadResult is part of an experimental API and may change or be
-// removed.
-type ExtensionsReloadResult struct {
-}
-
// Tool call result (string or expanded result object)
type ExternalToolResult interface {
externalToolResult()
@@ -362,6 +365,7 @@ type RawExternalToolTextResultForLlmContentResourceDetailsData struct {
func (RawExternalToolTextResultForLlmContentResourceDetailsData) externalToolTextResultForLlmContentResourceDetails() {
}
+// Schema for the `EmbeddedBlobResourceContents` type.
type EmbeddedBlobResourceContents struct {
// Base64-encoded binary content of the resource
Blob string `json:"blob"`
@@ -373,6 +377,7 @@ type EmbeddedBlobResourceContents struct {
func (EmbeddedBlobResourceContents) externalToolTextResultForLlmContentResourceDetails() {}
+// Schema for the `EmbeddedTextResourceContents` type.
type EmbeddedTextResourceContents struct {
// MIME type of the text content
MIMEType *string `json:"mimeType,omitempty"`
@@ -396,6 +401,8 @@ type ExternalToolTextResultForLlmContentResourceLinkIcon struct {
Theme *ExternalToolTextResultForLlmContentResourceLinkIconTheme `json:"theme,omitempty"`
}
+// Content filtering mode to apply to all tools, or a map of tool name to content filtering
+// mode.
type FilterMapping interface {
filterMapping()
}
@@ -406,6 +413,7 @@ func (FilterMappingEnumMap) filterMapping() {}
func (FilterMappingString) filterMapping() {}
+// Optional user prompt to combine with the fleet orchestration instructions.
// Experimental: FleetStartRequest is part of an experimental API and may change or be
// removed.
type FleetStartRequest struct {
@@ -413,6 +421,7 @@ type FleetStartRequest struct {
Prompt *string `json:"prompt,omitempty"`
}
+// Indicates whether fleet mode was successfully activated.
// Experimental: FleetStartResult is part of an experimental API and may change or be
// removed.
type FleetStartResult struct {
@@ -420,6 +429,8 @@ type FleetStartResult struct {
Started bool `json:"started"`
}
+// Pending external tool call request ID, with the tool result or an error describing why it
+// failed.
type HandlePendingToolCallRequest struct {
// Error message if the tool call failed
Error *string `json:"error,omitempty"`
@@ -429,6 +440,7 @@ type HandlePendingToolCallRequest struct {
Result ExternalToolResult `json:"result,omitempty"`
}
+// Indicates whether the external tool call result was handled successfully.
type HandlePendingToolCallResult struct {
// Whether the tool call result was handled successfully
Success bool `json:"success"`
@@ -450,6 +462,8 @@ type HistoryCompactContextWindow struct {
ToolDefinitionsTokens *int64 `json:"toolDefinitionsTokens,omitempty"`
}
+// Compaction outcome with the number of tokens and messages removed and the resulting
+// context window breakdown.
// Experimental: HistoryCompactResult is part of an experimental API and may change or be
// removed.
type HistoryCompactResult struct {
@@ -463,6 +477,7 @@ type HistoryCompactResult struct {
TokensRemoved int64 `json:"tokensRemoved"`
}
+// Identifier of the event to truncate to; this event and all later events are removed.
// Experimental: HistoryTruncateRequest is part of an experimental API and may change or be
// removed.
type HistoryTruncateRequest struct {
@@ -470,6 +485,7 @@ type HistoryTruncateRequest struct {
EventID string `json:"eventId"`
}
+// Number of events that were removed by the truncation.
// Experimental: HistoryTruncateResult is part of an experimental API and may change or be
// removed.
type HistoryTruncateResult struct {
@@ -477,11 +493,13 @@ type HistoryTruncateResult struct {
EventsRemoved int64 `json:"eventsRemoved"`
}
+// Instruction sources loaded for the session, in merge order.
type InstructionsGetSourcesResult struct {
// Instruction sources for the session
Sources []InstructionsSources `json:"sources"`
}
+// Schema for the `InstructionsSources` type.
type InstructionsSources struct {
// Glob pattern from frontmatter — when set, this instruction applies only to matching files
ApplyTo *string `json:"applyTo,omitempty"`
@@ -501,6 +519,7 @@ type InstructionsSources struct {
Type InstructionsSourcesType `json:"type"`
}
+// Message text, optional severity level, persistence flag, and optional follow-up URL.
type LogRequest struct {
// When true, the message is transient and not persisted to the session event log on disk
Ephemeral *bool `json:"ephemeral,omitempty"`
@@ -513,11 +532,13 @@ type LogRequest struct {
URL *string `json:"url,omitempty"`
}
+// Identifier of the session event that was emitted for the log message.
type LogResult struct {
// The unique identifier of the emitted session event
EventID string `json:"eventId"`
}
+// MCP server name and configuration to add to user configuration.
type McpConfigAddRequest struct {
// MCP server configuration (local/stdio or remote/http)
Config McpServerConfig `json:"config"`
@@ -528,6 +549,7 @@ type McpConfigAddRequest struct {
type McpConfigAddResult struct {
}
+// MCP server names to disable for new sessions.
type McpConfigDisableRequest struct {
// Names of MCP servers to disable. Each server is added to the persisted disabled list so
// new sessions skip it. Already-disabled names are ignored. Active sessions keep their
@@ -538,6 +560,7 @@ type McpConfigDisableRequest struct {
type McpConfigDisableResult struct {
}
+// MCP server names to enable for new sessions.
type McpConfigEnableRequest struct {
// Names of MCP servers to enable. Each server is removed from the persisted disabled list
// so new sessions spawn it. Unknown or already-enabled names are ignored.
@@ -547,11 +570,13 @@ type McpConfigEnableRequest struct {
type McpConfigEnableResult struct {
}
+// User-configured MCP servers, keyed by server name.
type McpConfigList struct {
// All MCP servers from user config, keyed by name
Servers map[string]McpServerConfig `json:"servers"`
}
+// MCP server name to remove from user configuration.
type McpConfigRemoveRequest struct {
// Name of the MCP server to remove
Name string `json:"name"`
@@ -560,6 +585,7 @@ type McpConfigRemoveRequest struct {
type McpConfigRemoveResult struct {
}
+// MCP server name and replacement configuration to write to user configuration.
type McpConfigUpdateRequest struct {
// MCP server configuration (local/stdio or remote/http)
Config McpServerConfig `json:"config"`
@@ -570,6 +596,7 @@ type McpConfigUpdateRequest struct {
type McpConfigUpdateResult struct {
}
+// Name of the MCP server to disable for the session.
// Experimental: McpDisableRequest is part of an experimental API and may change or be
// removed.
type McpDisableRequest struct {
@@ -577,21 +604,19 @@ type McpDisableRequest struct {
ServerName string `json:"serverName"`
}
-// Experimental: McpDisableResult is part of an experimental API and may change or be
-// removed.
-type McpDisableResult struct {
-}
-
+// Optional working directory used as context for MCP server discovery.
type McpDiscoverRequest struct {
// Working directory used as context for discovery (e.g., plugin resolution)
WorkingDirectory *string `json:"workingDirectory,omitempty"`
}
+// MCP servers discovered from user, workspace, plugin, and built-in sources.
type McpDiscoverResult struct {
// MCP servers discovered from all sources
Servers []DiscoveredMcpServer `json:"servers"`
}
+// Name of the MCP server to enable for the session.
// Experimental: McpEnableRequest is part of an experimental API and may change or be
// removed.
type McpEnableRequest struct {
@@ -599,10 +624,8 @@ type McpEnableRequest struct {
ServerName string `json:"serverName"`
}
-// Experimental: McpEnableResult is part of an experimental API and may change or be removed.
-type McpEnableResult struct {
-}
-
+// Remote MCP server name and optional overrides controlling reauthentication, OAuth client
+// display name, and the callback success-page copy.
// Experimental: McpOauthLoginRequest is part of an experimental API and may change or be
// removed.
type McpOauthLoginRequest struct {
@@ -624,6 +647,8 @@ type McpOauthLoginRequest struct {
ServerName string `json:"serverName"`
}
+// OAuth authorization URL the caller should open, or empty when cached tokens already
+// authenticated the server.
// Experimental: McpOauthLoginResult is part of an experimental API and may change or be
// removed.
type McpOauthLoginResult struct {
@@ -635,10 +660,7 @@ type McpOauthLoginResult struct {
AuthorizationURL *string `json:"authorizationUrl,omitempty"`
}
-// Experimental: McpReloadResult is part of an experimental API and may change or be removed.
-type McpReloadResult struct {
-}
-
+// Schema for the `McpServer` type.
type McpServer struct {
// Error message if the server failed to connect
Error *string `json:"error,omitempty"`
@@ -661,46 +683,68 @@ type RawMcpServerConfigData struct {
func (RawMcpServerConfigData) mcpServerConfig() {}
+// Remote MCP server configuration accessed over HTTP or SSE.
type McpServerConfigHTTP struct {
- FilterMapping FilterMapping `json:"filterMapping,omitempty"`
- Headers map[string]string `json:"headers,omitempty"`
- IsDefaultServer *bool `json:"isDefaultServer,omitempty"`
- OauthClientID *string `json:"oauthClientId,omitempty"`
- OauthGrantType *McpServerConfigHTTPOauthGrantType `json:"oauthGrantType,omitempty"`
- OauthPublicClient *bool `json:"oauthPublicClient,omitempty"`
+ // Content filtering mode to apply to all tools, or a map of tool name to content filtering
+ // mode.
+ FilterMapping FilterMapping `json:"filterMapping,omitempty"`
+ // HTTP headers to include in requests to the remote MCP server.
+ Headers map[string]string `json:"headers,omitempty"`
+ // Whether this server is a built-in fallback used when the user has not configured their
+ // own server.
+ IsDefaultServer *bool `json:"isDefaultServer,omitempty"`
+ // OAuth client ID for a pre-registered remote MCP OAuth client.
+ OauthClientID *string `json:"oauthClientId,omitempty"`
+ // OAuth grant type to use when authenticating to the remote MCP server.
+ OauthGrantType *McpServerConfigHTTPOauthGrantType `json:"oauthGrantType,omitempty"`
+ // Whether the configured OAuth client is public and does not require a client secret.
+ OauthPublicClient *bool `json:"oauthPublicClient,omitempty"`
// Timeout in milliseconds for tool calls to this server.
Timeout *int64 `json:"timeout,omitempty"`
// Tools to include. Defaults to all tools if not specified.
Tools []string `json:"tools,omitempty"`
// Remote transport type. Defaults to "http" when omitted.
Type *McpServerConfigHTTPType `json:"type,omitempty"`
- URL string `json:"url"`
+ // URL of the remote MCP server endpoint.
+ URL string `json:"url"`
}
func (McpServerConfigHTTP) mcpServerConfig() {}
+// Local MCP server configuration launched as a child process.
type McpServerConfigLocal struct {
- Args []string `json:"args"`
- Command string `json:"command"`
- Cwd *string `json:"cwd,omitempty"`
- Env map[string]string `json:"env,omitempty"`
- FilterMapping FilterMapping `json:"filterMapping,omitempty"`
- IsDefaultServer *bool `json:"isDefaultServer,omitempty"`
+ // Command-line arguments passed to the local MCP server process.
+ Args []string `json:"args"`
+ // Executable command used to start the local MCP server process.
+ Command string `json:"command"`
+ // Working directory for the local MCP server process.
+ Cwd *string `json:"cwd,omitempty"`
+ // Environment variables to pass to the local MCP server process.
+ Env map[string]string `json:"env,omitempty"`
+ // Content filtering mode to apply to all tools, or a map of tool name to content filtering
+ // mode.
+ FilterMapping FilterMapping `json:"filterMapping,omitempty"`
+ // Whether this server is a built-in fallback used when the user has not configured their
+ // own server.
+ IsDefaultServer *bool `json:"isDefaultServer,omitempty"`
// Timeout in milliseconds for tool calls to this server.
Timeout *int64 `json:"timeout,omitempty"`
// Tools to include. Defaults to all tools if not specified.
- Tools []string `json:"tools,omitempty"`
- Type *McpServerConfigLocalType `json:"type,omitempty"`
+ Tools []string `json:"tools,omitempty"`
+ // Local transport type. Defaults to "local".
+ Type *McpServerConfigLocalType `json:"type,omitempty"`
}
func (McpServerConfigLocal) mcpServerConfig() {}
+// MCP servers configured for the session, with their connection status.
// Experimental: McpServerList is part of an experimental API and may change or be removed.
type McpServerList struct {
// Configured MCP servers
Servers []McpServer `json:"servers"`
}
+// Schema for the `Model` type.
type Model struct {
// Billing information
Billing *ModelBilling `json:"billing,omitempty"`
@@ -786,12 +830,16 @@ type ModelCapabilitiesOverride struct {
// Token limits for prompts, outputs, and context window
type ModelCapabilitiesOverrideLimits struct {
// Maximum total context window size in tokens
- MaxContextWindowTokens *int64 `json:"max_context_window_tokens,omitempty"`
- MaxOutputTokens *int64 `json:"max_output_tokens,omitempty"`
- MaxPromptTokens *int64 `json:"max_prompt_tokens,omitempty"`
- Vision *ModelCapabilitiesOverrideLimitsVision `json:"vision,omitempty"`
+ MaxContextWindowTokens *int64 `json:"max_context_window_tokens,omitempty"`
+ // Maximum number of output/completion tokens
+ MaxOutputTokens *int64 `json:"max_output_tokens,omitempty"`
+ // Maximum number of prompt/input tokens
+ MaxPromptTokens *int64 `json:"max_prompt_tokens,omitempty"`
+ // Vision-specific limits
+ Vision *ModelCapabilitiesOverrideLimitsVision `json:"vision,omitempty"`
}
+// Vision-specific limits
type ModelCapabilitiesOverrideLimitsVision struct {
// Maximum number of images per prompt
MaxPromptImages *int64 `json:"max_prompt_images,omitempty"`
@@ -803,8 +851,10 @@ type ModelCapabilitiesOverrideLimitsVision struct {
// Feature flags indicating what the model supports
type ModelCapabilitiesOverrideSupports struct {
+ // Whether this model supports reasoning effort configuration
ReasoningEffort *bool `json:"reasoningEffort,omitempty"`
- Vision *bool `json:"vision,omitempty"`
+ // Whether this model supports vision/image input
+ Vision *bool `json:"vision,omitempty"`
}
// Feature flags indicating what the model supports
@@ -815,6 +865,8 @@ type ModelCapabilitiesSupports struct {
Vision *bool `json:"vision,omitempty"`
}
+// List of Copilot models available to the resolved user, including capabilities and billing
+// metadata.
type ModelList struct {
// List of available models with full metadata
Models []Model `json:"models"`
@@ -834,41 +886,43 @@ type ModelsListRequest struct {
GitHubToken *string `json:"gitHubToken,omitempty"`
}
+// Target model identifier and optional reasoning effort, summary, and capability overrides.
type ModelSwitchToRequest struct {
// Override individual model capabilities resolved by the runtime
ModelCapabilities *ModelCapabilitiesOverride `json:"modelCapabilities,omitempty"`
// Model identifier to switch to
ModelID string `json:"modelId"`
- // Reasoning effort level to use for the model
+ // Reasoning effort level to use for the model. "none" disables reasoning.
ReasoningEffort *string `json:"reasoningEffort,omitempty"`
+ // Reasoning summary mode to request for supported model clients
+ ReasoningSummary *ReasoningSummary `json:"reasoningSummary,omitempty"`
}
+// The model identifier active on the session after the switch.
type ModelSwitchToResult struct {
// Currently active model identifier after the switch
ModelID *string `json:"modelId,omitempty"`
}
+// Agent interaction mode to apply to the session.
type ModeSetRequest struct {
// The agent mode. Valid values: "interactive", "plan", "autopilot".
Mode SessionMode `json:"mode"`
}
-type ModeSetResult struct {
-}
-
+// The session's friendly name, or null when not yet set.
type NameGetResult struct {
// The session name (user-set or auto-generated), or null if not yet set
Name *string `json:"name"`
}
+// New friendly name to apply to the session.
type NameSetRequest struct {
// New session name (1–100 characters, trimmed of leading/trailing whitespace)
Name string `json:"name"`
}
-type NameSetResult struct {
-}
-
+// Decision to apply to a pending permission request.
type PermissionDecision interface {
permissionDecision()
Kind() PermissionDecisionKind
@@ -884,6 +938,7 @@ func (r RawPermissionDecisionData) Kind() PermissionDecisionKind {
return r.Discriminator
}
+// Schema for the `PermissionDecisionApproveForLocation` type.
type PermissionDecisionApproveForLocation struct {
// The approval to persist for this location
Approval PermissionDecisionApproveForLocationApproval `json:"approval"`
@@ -896,6 +951,7 @@ func (PermissionDecisionApproveForLocation) Kind() PermissionDecisionKind {
return PermissionDecisionKindApproveForLocation
}
+// Schema for the `PermissionDecisionApproveForSession` type.
type PermissionDecisionApproveForSession struct {
// The approval to add as a session-scoped rule
Approval PermissionDecisionApproveForSessionApproval `json:"approval,omitempty"`
@@ -908,6 +964,7 @@ func (PermissionDecisionApproveForSession) Kind() PermissionDecisionKind {
return PermissionDecisionKindApproveForSession
}
+// Schema for the `PermissionDecisionApproveOnce` type.
type PermissionDecisionApproveOnce struct {
}
@@ -916,6 +973,7 @@ func (PermissionDecisionApproveOnce) Kind() PermissionDecisionKind {
return PermissionDecisionKindApproveOnce
}
+// Schema for the `PermissionDecisionApprovePermanently` type.
type PermissionDecisionApprovePermanently struct {
// The URL domain to approve permanently
Domain string `json:"domain"`
@@ -926,6 +984,7 @@ func (PermissionDecisionApprovePermanently) Kind() PermissionDecisionKind {
return PermissionDecisionKindApprovePermanently
}
+// Schema for the `PermissionDecisionReject` type.
type PermissionDecisionReject struct {
// Optional feedback from the user explaining the denial
Feedback *string `json:"feedback,omitempty"`
@@ -936,6 +995,7 @@ func (PermissionDecisionReject) Kind() PermissionDecisionKind {
return PermissionDecisionKindReject
}
+// Schema for the `PermissionDecisionUserNotAvailable` type.
type PermissionDecisionUserNotAvailable struct {
}
@@ -961,7 +1021,9 @@ func (r RawPermissionDecisionApproveForLocationApprovalData) Kind() PermissionDe
return r.Discriminator
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalCommands` type.
type PermissionDecisionApproveForLocationApprovalCommands struct {
+ // Command identifiers covered by this approval.
CommandIdentifiers []string `json:"commandIdentifiers"`
}
@@ -971,7 +1033,9 @@ func (PermissionDecisionApproveForLocationApprovalCommands) Kind() PermissionDec
return PermissionDecisionApproveForLocationApprovalKindCommands
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalCustomTool` type.
type PermissionDecisionApproveForLocationApprovalCustomTool struct {
+ // Custom tool name.
ToolName string `json:"toolName"`
}
@@ -981,7 +1045,10 @@ func (PermissionDecisionApproveForLocationApprovalCustomTool) Kind() PermissionD
return PermissionDecisionApproveForLocationApprovalKindCustomTool
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalExtensionManagement` type.
type PermissionDecisionApproveForLocationApprovalExtensionManagement struct {
+ // Optional operation identifier; when omitted, the approval covers all extension management
+ // operations.
Operation *string `json:"operation,omitempty"`
}
@@ -991,7 +1058,10 @@ func (PermissionDecisionApproveForLocationApprovalExtensionManagement) Kind() Pe
return PermissionDecisionApproveForLocationApprovalKindExtensionManagement
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess`
+// type.
type PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess struct {
+ // Extension name.
ExtensionName string `json:"extensionName"`
}
@@ -1001,9 +1071,12 @@ func (PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess) Kin
return PermissionDecisionApproveForLocationApprovalKindExtensionPermissionAccess
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalMcp` type.
type PermissionDecisionApproveForLocationApprovalMcp struct {
- ServerName string `json:"serverName"`
- ToolName *string `json:"toolName"`
+ // MCP server name.
+ ServerName string `json:"serverName"`
+ // MCP tool name, or null to cover every tool on the server.
+ ToolName *string `json:"toolName"`
}
func (PermissionDecisionApproveForLocationApprovalMcp) permissionDecisionApproveForLocationApproval() {
@@ -1012,7 +1085,9 @@ func (PermissionDecisionApproveForLocationApprovalMcp) Kind() PermissionDecision
return PermissionDecisionApproveForLocationApprovalKindMcp
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalMcpSampling` type.
type PermissionDecisionApproveForLocationApprovalMcpSampling struct {
+ // MCP server name.
ServerName string `json:"serverName"`
}
@@ -1022,6 +1097,7 @@ func (PermissionDecisionApproveForLocationApprovalMcpSampling) Kind() Permission
return PermissionDecisionApproveForLocationApprovalKindMcpSampling
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalMemory` type.
type PermissionDecisionApproveForLocationApprovalMemory struct {
}
@@ -1031,6 +1107,7 @@ func (PermissionDecisionApproveForLocationApprovalMemory) Kind() PermissionDecis
return PermissionDecisionApproveForLocationApprovalKindMemory
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalRead` type.
type PermissionDecisionApproveForLocationApprovalRead struct {
}
@@ -1040,6 +1117,7 @@ func (PermissionDecisionApproveForLocationApprovalRead) Kind() PermissionDecisio
return PermissionDecisionApproveForLocationApprovalKindRead
}
+// Schema for the `PermissionDecisionApproveForLocationApprovalWrite` type.
type PermissionDecisionApproveForLocationApprovalWrite struct {
}
@@ -1066,7 +1144,9 @@ func (r RawPermissionDecisionApproveForSessionApprovalData) Kind() PermissionDec
return r.Discriminator
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalCommands` type.
type PermissionDecisionApproveForSessionApprovalCommands struct {
+ // Command identifiers covered by this approval.
CommandIdentifiers []string `json:"commandIdentifiers"`
}
@@ -1076,7 +1156,9 @@ func (PermissionDecisionApproveForSessionApprovalCommands) Kind() PermissionDeci
return PermissionDecisionApproveForSessionApprovalKindCommands
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalCustomTool` type.
type PermissionDecisionApproveForSessionApprovalCustomTool struct {
+ // Custom tool name.
ToolName string `json:"toolName"`
}
@@ -1086,7 +1168,10 @@ func (PermissionDecisionApproveForSessionApprovalCustomTool) Kind() PermissionDe
return PermissionDecisionApproveForSessionApprovalKindCustomTool
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalExtensionManagement` type.
type PermissionDecisionApproveForSessionApprovalExtensionManagement struct {
+ // Optional operation identifier; when omitted, the approval covers all extension management
+ // operations.
Operation *string `json:"operation,omitempty"`
}
@@ -1096,7 +1181,10 @@ func (PermissionDecisionApproveForSessionApprovalExtensionManagement) Kind() Per
return PermissionDecisionApproveForSessionApprovalKindExtensionManagement
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess`
+// type.
type PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess struct {
+ // Extension name.
ExtensionName string `json:"extensionName"`
}
@@ -1106,9 +1194,12 @@ func (PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess) Kind
return PermissionDecisionApproveForSessionApprovalKindExtensionPermissionAccess
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalMcp` type.
type PermissionDecisionApproveForSessionApprovalMcp struct {
- ServerName string `json:"serverName"`
- ToolName *string `json:"toolName"`
+ // MCP server name.
+ ServerName string `json:"serverName"`
+ // MCP tool name, or null to cover every tool on the server.
+ ToolName *string `json:"toolName"`
}
func (PermissionDecisionApproveForSessionApprovalMcp) permissionDecisionApproveForSessionApproval() {}
@@ -1116,7 +1207,9 @@ func (PermissionDecisionApproveForSessionApprovalMcp) Kind() PermissionDecisionA
return PermissionDecisionApproveForSessionApprovalKindMcp
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalMcpSampling` type.
type PermissionDecisionApproveForSessionApprovalMcpSampling struct {
+ // MCP server name.
ServerName string `json:"serverName"`
}
@@ -1126,6 +1219,7 @@ func (PermissionDecisionApproveForSessionApprovalMcpSampling) Kind() PermissionD
return PermissionDecisionApproveForSessionApprovalKindMcpSampling
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalMemory` type.
type PermissionDecisionApproveForSessionApprovalMemory struct {
}
@@ -1135,6 +1229,7 @@ func (PermissionDecisionApproveForSessionApprovalMemory) Kind() PermissionDecisi
return PermissionDecisionApproveForSessionApprovalKindMemory
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalRead` type.
type PermissionDecisionApproveForSessionApprovalRead struct {
}
@@ -1144,6 +1239,7 @@ func (PermissionDecisionApproveForSessionApprovalRead) Kind() PermissionDecision
return PermissionDecisionApproveForSessionApprovalKindRead
}
+// Schema for the `PermissionDecisionApproveForSessionApprovalWrite` type.
type PermissionDecisionApproveForSessionApprovalWrite struct {
}
@@ -1153,40 +1249,51 @@ func (PermissionDecisionApproveForSessionApprovalWrite) Kind() PermissionDecisio
return PermissionDecisionApproveForSessionApprovalKindWrite
}
+// Pending permission request ID and the decision to apply (approve/reject and scope).
type PermissionDecisionRequest struct {
// Request ID of the pending permission request
- RequestID string `json:"requestId"`
- Result PermissionDecision `json:"result"`
+ RequestID string `json:"requestId"`
+ // Decision to apply to a pending permission request.
+ Result PermissionDecision `json:"result"`
}
+// Indicates whether the permission decision was applied; false when the request was already
+// resolved.
type PermissionRequestResult struct {
// Whether the permission request was handled successfully
Success bool `json:"success"`
}
+// No parameters; clears all session-scoped tool permission approvals.
type PermissionsResetSessionApprovalsRequest struct {
}
+// Indicates whether the operation succeeded.
type PermissionsResetSessionApprovalsResult struct {
// Whether the operation succeeded
Success bool `json:"success"`
}
+// Whether to auto-approve all tool permission requests for the rest of the session.
type PermissionsSetApproveAllRequest struct {
// Whether to auto-approve all tool permission requests
Enabled bool `json:"enabled"`
}
+// Indicates whether the operation succeeded.
type PermissionsSetApproveAllResult struct {
// Whether the operation succeeded
Success bool `json:"success"`
}
+// Optional message to echo back to the caller.
type PingRequest struct {
// Optional message to echo back
Message *string `json:"message,omitempty"`
}
+// Server liveness response, including the echoed message, current timestamp, and protocol
+// version.
type PingResult struct {
// Echoed message (or default greeting)
Message string `json:"message"`
@@ -1196,9 +1303,7 @@ type PingResult struct {
Timestamp int64 `json:"timestamp"`
}
-type PlanDeleteResult struct {
-}
-
+// Existence, contents, and resolved path of the session plan file.
type PlanReadResult struct {
// The content of the plan file, or null if it does not exist
Content *string `json:"content"`
@@ -1208,14 +1313,13 @@ type PlanReadResult struct {
Path *string `json:"path"`
}
+// Replacement contents to write to the session plan file.
type PlanUpdateRequest struct {
// The new content for the plan file
Content string `json:"content"`
}
-type PlanUpdateResult struct {
-}
-
+// Schema for the `Plugin` type.
type Plugin struct {
// Whether the plugin is currently enabled
Enabled bool `json:"enabled"`
@@ -1227,6 +1331,7 @@ type Plugin struct {
Version *string `json:"version,omitempty"`
}
+// Plugins installed for the session, with their enabled state and version metadata.
// Experimental: PluginList is part of an experimental API and may change or be removed.
type PluginList struct {
// Installed plugins
@@ -1239,6 +1344,7 @@ type QueuedCommandResult interface {
Handled() bool
}
+// Schema for the `QueuedCommandHandled` type.
type QueuedCommandHandled struct {
// If true, stop processing remaining queued items
StopProcessingQueue *bool `json:"stopProcessingQueue,omitempty"`
@@ -1249,6 +1355,7 @@ func (QueuedCommandHandled) Handled() bool {
return true
}
+// Schema for the `QueuedCommandNotHandled` type.
type QueuedCommandNotHandled struct {
}
@@ -1257,29 +1364,27 @@ func (QueuedCommandNotHandled) Handled() bool {
return false
}
-// Experimental: RemoteDisableResult is part of an experimental API and may change or be
-// removed.
-type RemoteDisableResult struct {
-}
-
+// Optional remote session mode ("off", "export", or "on"); defaults to enabling both export
+// and remote steering.
// Experimental: RemoteEnableRequest is part of an experimental API and may change or be
// removed.
type RemoteEnableRequest struct {
- // Per-session remote mode. "off" disables remote, "export" exports session events to
- // Mission Control without enabling remote steering, "on" enables both export and remote
- // steering.
+ // Per-session remote mode. "off" disables remote, "export" exports session events to GitHub
+ // without enabling remote steering, "on" enables both export and remote steering.
Mode *RemoteSessionMode `json:"mode,omitempty"`
}
+// GitHub URL for the session and a flag indicating whether remote steering is enabled.
// Experimental: RemoteEnableResult is part of an experimental API and may change or be
// removed.
type RemoteEnableResult struct {
// Whether remote steering is enabled
RemoteSteerable bool `json:"remoteSteerable"`
- // Mission Control frontend URL for this session
+ // GitHub frontend URL for this session
URL *string `json:"url,omitempty"`
}
+// Schema for the `ServerSkill` type.
type ServerSkill struct {
// Description of what the skill does
Description string `json:"description"`
@@ -1297,11 +1402,18 @@ type ServerSkill struct {
UserInvocable bool `json:"userInvocable"`
}
+// Skills discovered across global and project sources.
type ServerSkillList struct {
// All discovered skills across all sources
Skills []ServerSkill `json:"skills"`
}
+// Experimental: SessionAgentDeselectResult is part of an experimental API and may change or
+// be removed.
+type SessionAgentDeselectResult struct {
+}
+
+// Authentication status and account metadata for the session.
type SessionAuthStatus struct {
// Authentication type
AuthType *AuthInfoType `json:"authType,omitempty"`
@@ -1317,6 +1429,23 @@ type SessionAuthStatus struct {
StatusMessage *string `json:"statusMessage,omitempty"`
}
+// Experimental: SessionExtensionsDisableResult is part of an experimental API and may
+// change or be removed.
+type SessionExtensionsDisableResult struct {
+}
+
+// Experimental: SessionExtensionsEnableResult is part of an experimental API and may change
+// or be removed.
+type SessionExtensionsEnableResult struct {
+}
+
+// Experimental: SessionExtensionsReloadResult is part of an experimental API and may change
+// or be removed.
+type SessionExtensionsReloadResult struct {
+}
+
+// File path, content to append, and optional mode for the client-provided session
+// filesystem.
type SessionFsAppendFileRequest struct {
// Content to append
Content string `json:"content"`
@@ -1336,6 +1465,7 @@ type SessionFsError struct {
Message *string `json:"message,omitempty"`
}
+// Path to test for existence in the client-provided session filesystem.
type SessionFsExistsRequest struct {
// Path using SessionFs conventions
Path string `json:"path"`
@@ -1343,11 +1473,14 @@ type SessionFsExistsRequest struct {
SessionID string `json:"sessionId"`
}
+// Indicates whether the requested path exists in the client-provided session filesystem.
type SessionFsExistsResult struct {
// Whether the path exists
Exists bool `json:"exists"`
}
+// Directory path to create in the client-provided session filesystem, with options for
+// recursive creation and POSIX mode.
type SessionFsMkdirRequest struct {
// Optional POSIX-style mode for newly created directories
Mode *int64 `json:"mode,omitempty"`
@@ -1359,6 +1492,7 @@ type SessionFsMkdirRequest struct {
SessionID string `json:"sessionId"`
}
+// Directory path whose entries should be listed from the client-provided session filesystem.
type SessionFsReaddirRequest struct {
// Path using SessionFs conventions
Path string `json:"path"`
@@ -1366,6 +1500,7 @@ type SessionFsReaddirRequest struct {
SessionID string `json:"sessionId"`
}
+// Names of entries in the requested directory, or a filesystem error if the read failed.
type SessionFsReaddirResult struct {
// Entry names in the directory
Entries []string `json:"entries"`
@@ -1373,6 +1508,7 @@ type SessionFsReaddirResult struct {
Error *SessionFsError `json:"error,omitempty"`
}
+// Schema for the `SessionFsReaddirWithTypesEntry` type.
type SessionFsReaddirWithTypesEntry struct {
// Entry name
Name string `json:"name"`
@@ -1380,6 +1516,8 @@ type SessionFsReaddirWithTypesEntry struct {
Type SessionFsReaddirWithTypesEntryType `json:"type"`
}
+// Directory path whose entries (with type information) should be listed from the
+// client-provided session filesystem.
type SessionFsReaddirWithTypesRequest struct {
// Path using SessionFs conventions
Path string `json:"path"`
@@ -1387,6 +1525,8 @@ type SessionFsReaddirWithTypesRequest struct {
SessionID string `json:"sessionId"`
}
+// Entries in the requested directory paired with file/directory type information, or a
+// filesystem error if the read failed.
type SessionFsReaddirWithTypesResult struct {
// Directory entries with type information
Entries []SessionFsReaddirWithTypesEntry `json:"entries"`
@@ -1394,6 +1534,7 @@ type SessionFsReaddirWithTypesResult struct {
Error *SessionFsError `json:"error,omitempty"`
}
+// Path of the file to read from the client-provided session filesystem.
type SessionFsReadFileRequest struct {
// Path using SessionFs conventions
Path string `json:"path"`
@@ -1401,6 +1542,7 @@ type SessionFsReadFileRequest struct {
SessionID string `json:"sessionId"`
}
+// File content as a UTF-8 string, or a filesystem error if the read failed.
type SessionFsReadFileResult struct {
// File content as UTF-8 string
Content string `json:"content"`
@@ -1408,6 +1550,8 @@ type SessionFsReadFileResult struct {
Error *SessionFsError `json:"error,omitempty"`
}
+// Source and destination paths for renaming or moving an entry in the client-provided
+// session filesystem.
type SessionFsRenameRequest struct {
// Destination path using SessionFs conventions
Dest string `json:"dest"`
@@ -1417,6 +1561,8 @@ type SessionFsRenameRequest struct {
Src string `json:"src"`
}
+// Path to remove from the client-provided session filesystem, with options for recursive
+// removal and force.
type SessionFsRmRequest struct {
// Ignore errors if the path does not exist
Force *bool `json:"force,omitempty"`
@@ -1428,6 +1574,8 @@ type SessionFsRmRequest struct {
SessionID string `json:"sessionId"`
}
+// Initial working directory, session-state path layout, and path conventions used to
+// register the calling SDK client as the session filesystem provider.
type SessionFsSetProviderRequest struct {
// Path conventions used by this filesystem
Conventions SessionFsSetProviderConventions `json:"conventions"`
@@ -1437,11 +1585,13 @@ type SessionFsSetProviderRequest struct {
SessionStatePath string `json:"sessionStatePath"`
}
+// Indicates whether the calling client was registered as the session filesystem provider.
type SessionFsSetProviderResult struct {
// Whether the provider was set successfully
Success bool `json:"success"`
}
+// Path whose metadata should be returned from the client-provided session filesystem.
type SessionFsStatRequest struct {
// Path using SessionFs conventions
Path string `json:"path"`
@@ -1449,6 +1599,7 @@ type SessionFsStatRequest struct {
SessionID string `json:"sessionId"`
}
+// Filesystem metadata for the requested path, or a filesystem error if the stat failed.
type SessionFsStatResult struct {
// ISO 8601 timestamp of creation
Birthtime time.Time `json:"birthtime"`
@@ -1464,6 +1615,7 @@ type SessionFsStatResult struct {
Size int64 `json:"size"`
}
+// File path, content to write, and optional mode for the client-provided session filesystem.
type SessionFsWriteFileRequest struct {
// Content to write
Content string `json:"content"`
@@ -1475,6 +1627,40 @@ type SessionFsWriteFileRequest struct {
SessionID string `json:"sessionId"`
}
+// Experimental: SessionMcpDisableResult is part of an experimental API and may change or be
+// removed.
+type SessionMcpDisableResult struct {
+}
+
+// Experimental: SessionMcpEnableResult is part of an experimental API and may change or be
+// removed.
+type SessionMcpEnableResult struct {
+}
+
+// Experimental: SessionMcpReloadResult is part of an experimental API and may change or be
+// removed.
+type SessionMcpReloadResult struct {
+}
+
+type SessionModeSetResult struct {
+}
+
+type SessionNameSetResult struct {
+}
+
+type SessionPlanDeleteResult struct {
+}
+
+type SessionPlanUpdateResult struct {
+}
+
+// Experimental: SessionRemoteDisableResult is part of an experimental API and may change or
+// be removed.
+type SessionRemoteDisableResult struct {
+}
+
+// Source session identifier to fork from, optional event-ID boundary, and optional friendly
+// name for the new session.
// Experimental: SessionsForkRequest is part of an experimental API and may change or be
// removed.
type SessionsForkRequest struct {
@@ -1487,6 +1673,7 @@ type SessionsForkRequest struct {
ToEventID *string `json:"toEventId,omitempty"`
}
+// Identifier and optional friendly name assigned to the newly forked session.
// Experimental: SessionsForkResult is part of an experimental API and may change or be
// removed.
type SessionsForkResult struct {
@@ -1496,6 +1683,23 @@ type SessionsForkResult struct {
SessionID string `json:"sessionId"`
}
+// Experimental: SessionSkillsDisableResult is part of an experimental API and may change or
+// be removed.
+type SessionSkillsDisableResult struct {
+}
+
+// Experimental: SessionSkillsEnableResult is part of an experimental API and may change or
+// be removed.
+type SessionSkillsEnableResult struct {
+}
+
+type SessionSuspendResult struct {
+}
+
+type SessionWorkspacesCreateFileResult struct {
+}
+
+// Shell command to run, with optional working directory and timeout in milliseconds.
type ShellExecRequest struct {
// Shell command to execute
Command string `json:"command"`
@@ -1505,11 +1709,14 @@ type ShellExecRequest struct {
Timeout *int64 `json:"timeout,omitempty"`
}
+// Identifier of the spawned process, used to correlate streamed output and exit
+// notifications.
type ShellExecResult struct {
// Unique identifier for tracking streamed output
ProcessID string `json:"processId"`
}
+// Identifier of a process previously returned by "shell.exec" and the signal to send.
type ShellKillRequest struct {
// Process identifier returned by shell.exec
ProcessID string `json:"processId"`
@@ -1517,11 +1724,14 @@ type ShellKillRequest struct {
Signal *ShellKillSignal `json:"signal,omitempty"`
}
+// Indicates whether the signal was delivered; false if the process was unknown or already
+// exited.
type ShellKillResult struct {
// Whether the signal was sent successfully
Killed bool `json:"killed"`
}
+// Schema for the `Skill` type.
type Skill struct {
// Description of what the skill does
Description string `json:"description"`
@@ -1537,12 +1747,14 @@ type Skill struct {
UserInvocable bool `json:"userInvocable"`
}
+// Skills available to the session, with their enabled state.
// Experimental: SkillList is part of an experimental API and may change or be removed.
type SkillList struct {
// Available skills
Skills []Skill `json:"skills"`
}
+// Skill names to mark as disabled in global configuration, replacing any previous list.
type SkillsConfigSetDisabledSkillsRequest struct {
// List of skill names to disable
DisabledSkills []string `json:"disabledSkills"`
@@ -1551,6 +1763,7 @@ type SkillsConfigSetDisabledSkillsRequest struct {
type SkillsConfigSetDisabledSkillsResult struct {
}
+// Name of the skill to disable for the session.
// Experimental: SkillsDisableRequest is part of an experimental API and may change or be
// removed.
type SkillsDisableRequest struct {
@@ -1558,11 +1771,7 @@ type SkillsDisableRequest struct {
Name string `json:"name"`
}
-// Experimental: SkillsDisableResult is part of an experimental API and may change or be
-// removed.
-type SkillsDisableResult struct {
-}
-
+// Optional project paths and additional skill directories to include in discovery.
type SkillsDiscoverRequest struct {
// Optional list of project directory paths to scan for project-scoped skills
ProjectPaths []string `json:"projectPaths,omitempty"`
@@ -1570,6 +1779,7 @@ type SkillsDiscoverRequest struct {
SkillDirectories []string `json:"skillDirectories,omitempty"`
}
+// Name of the skill to enable for the session.
// Experimental: SkillsEnableRequest is part of an experimental API and may change or be
// removed.
type SkillsEnableRequest struct {
@@ -1577,11 +1787,7 @@ type SkillsEnableRequest struct {
Name string `json:"name"`
}
-// Experimental: SkillsEnableResult is part of an experimental API and may change or be
-// removed.
-type SkillsEnableResult struct {
-}
-
+// Diagnostics from reloading skill definitions, with warnings and errors as separate lists.
// Experimental: SkillsLoadDiagnostics is part of an experimental API and may change or be
// removed.
type SkillsLoadDiagnostics struct {
@@ -1591,6 +1797,7 @@ type SkillsLoadDiagnostics struct {
Warnings []string `json:"warnings"`
}
+// Schema for the `SlashCommandInfo` type.
type SlashCommandInfo struct {
// Canonical aliases without leading slashes
Aliases []string `json:"aliases,omitempty"`
@@ -1623,6 +1830,8 @@ type SlashCommandInput struct {
Required *bool `json:"required,omitempty"`
}
+// Result of invoking the slash command (text output, prompt to send to the agent, or
+// completion).
type SlashCommandInvocationResult interface {
slashCommandInvocationResult()
Kind() SlashCommandInvocationResultKind
@@ -1638,6 +1847,7 @@ func (r RawSlashCommandInvocationResultData) Kind() SlashCommandInvocationResult
return r.Discriminator
}
+// Schema for the `SlashCommandAgentPromptResult` type.
type SlashCommandAgentPromptResult struct {
// Prompt text to display to the user
DisplayPrompt string `json:"displayPrompt"`
@@ -1655,6 +1865,7 @@ func (SlashCommandAgentPromptResult) Kind() SlashCommandInvocationResultKind {
return SlashCommandInvocationResultKindAgentPrompt
}
+// Schema for the `SlashCommandCompletedResult` type.
type SlashCommandCompletedResult struct {
// Optional user-facing message describing the completed command
Message *string `json:"message,omitempty"`
@@ -1668,6 +1879,7 @@ func (SlashCommandCompletedResult) Kind() SlashCommandInvocationResultKind {
return SlashCommandInvocationResultKindCompleted
}
+// Schema for the `SlashCommandTextResult` type.
type SlashCommandTextResult struct {
// Whether text contains Markdown
Markdown *bool `json:"markdown,omitempty"`
@@ -1685,9 +1897,7 @@ func (SlashCommandTextResult) Kind() SlashCommandInvocationResultKind {
return SlashCommandInvocationResultKindText
}
-type SuspendResult struct {
-}
-
+// Schema for the `TaskInfo` type.
type TaskInfo interface {
taskInfo()
Type() TaskInfoType
@@ -1703,6 +1913,7 @@ func (r RawTaskInfoData) Type() TaskInfoType {
return r.Discriminator
}
+// Schema for the `TaskAgentInfo` type.
type TaskAgentInfo struct {
// ISO 8601 timestamp when the current active period began
ActiveStartedAt *time.Time `json:"activeStartedAt,omitempty"`
@@ -1747,6 +1958,7 @@ func (TaskAgentInfo) Type() TaskInfoType {
return TaskInfoTypeAgent
}
+// Schema for the `TaskShellInfo` type.
type TaskShellInfo struct {
// Whether the shell runs inside a managed PTY session or as an independent background
// process
@@ -1778,12 +1990,14 @@ func (TaskShellInfo) Type() TaskInfoType {
return TaskInfoTypeShell
}
+// Background tasks currently tracked by the session.
// Experimental: TaskList is part of an experimental API and may change or be removed.
type TaskList struct {
// Currently tracked tasks
Tasks []TaskInfo `json:"tasks"`
}
+// Identifier of the background task to cancel.
// Experimental: TasksCancelRequest is part of an experimental API and may change or be
// removed.
type TasksCancelRequest struct {
@@ -1791,6 +2005,7 @@ type TasksCancelRequest struct {
ID string `json:"id"`
}
+// Indicates whether the background task was successfully cancelled.
// Experimental: TasksCancelResult is part of an experimental API and may change or be
// removed.
type TasksCancelResult struct {
@@ -1798,6 +2013,7 @@ type TasksCancelResult struct {
Cancelled bool `json:"cancelled"`
}
+// Identifier of the task to promote to background mode.
// Experimental: TasksPromoteToBackgroundRequest is part of an experimental API and may
// change or be removed.
type TasksPromoteToBackgroundRequest struct {
@@ -1805,6 +2021,7 @@ type TasksPromoteToBackgroundRequest struct {
ID string `json:"id"`
}
+// Indicates whether the task was successfully promoted to background mode.
// Experimental: TasksPromoteToBackgroundResult is part of an experimental API and may
// change or be removed.
type TasksPromoteToBackgroundResult struct {
@@ -1812,6 +2029,7 @@ type TasksPromoteToBackgroundResult struct {
Promoted bool `json:"promoted"`
}
+// Identifier of the completed or cancelled task to remove from tracking.
// Experimental: TasksRemoveRequest is part of an experimental API and may change or be
// removed.
type TasksRemoveRequest struct {
@@ -1819,6 +2037,8 @@ type TasksRemoveRequest struct {
ID string `json:"id"`
}
+// Indicates whether the task was removed. False when the task does not exist or is still
+// running/idle.
// Experimental: TasksRemoveResult is part of an experimental API and may change or be
// removed.
type TasksRemoveResult struct {
@@ -1827,6 +2047,7 @@ type TasksRemoveResult struct {
Removed bool `json:"removed"`
}
+// Identifier of the target agent task, message content, and optional sender agent ID.
// Experimental: TasksSendMessageRequest is part of an experimental API and may change or be
// removed.
type TasksSendMessageRequest struct {
@@ -1838,6 +2059,7 @@ type TasksSendMessageRequest struct {
Message string `json:"message"`
}
+// Indicates whether the message was delivered, with an error message when delivery failed.
// Experimental: TasksSendMessageResult is part of an experimental API and may change or be
// removed.
type TasksSendMessageResult struct {
@@ -1847,6 +2069,7 @@ type TasksSendMessageResult struct {
Sent bool `json:"sent"`
}
+// Agent type, prompt, name, and optional description and model override for the new task.
// Experimental: TasksStartAgentRequest is part of an experimental API and may change or be
// removed.
type TasksStartAgentRequest struct {
@@ -1862,6 +2085,7 @@ type TasksStartAgentRequest struct {
Prompt string `json:"prompt"`
}
+// Identifier assigned to the newly started background agent task.
// Experimental: TasksStartAgentResult is part of an experimental API and may change or be
// removed.
type TasksStartAgentResult struct {
@@ -1869,6 +2093,7 @@ type TasksStartAgentResult struct {
AgentID string `json:"agentId"`
}
+// Schema for the `Tool` type.
type Tool struct {
// Description of what the tool does
Description string `json:"description"`
@@ -1883,31 +2108,42 @@ type Tool struct {
Parameters map[string]any `json:"parameters,omitempty"`
}
+// Built-in tools available for the requested model, with their parameters and instructions.
type ToolList struct {
// List of available built-in tools with metadata
Tools []Tool `json:"tools"`
}
+// Optional model identifier whose tool overrides should be applied to the listing.
type ToolsListRequest struct {
// Optional model ID — when provided, the returned tool list reflects model-specific
// overrides
Model *string `json:"model,omitempty"`
}
+// Schema applied to each item in the array.
type UIElicitationArrayAnyOfFieldItems struct {
+ // Selectable options, each with a value and a display label.
AnyOf []UIElicitationArrayAnyOfFieldItemsAnyOf `json:"anyOf"`
}
+// Schema for the `UIElicitationArrayAnyOfFieldItemsAnyOf` type.
type UIElicitationArrayAnyOfFieldItemsAnyOf struct {
+ // Value submitted when this option is selected.
Const string `json:"const"`
+ // Display label for this option.
Title string `json:"title"`
}
+// Schema applied to each item in the array.
type UIElicitationArrayEnumFieldItems struct {
- Enum []string `json:"enum"`
+ // Allowed string values for each selected item.
+ Enum []string `json:"enum"`
+ // Type discriminator. Always "string".
Type UIElicitationArrayEnumFieldItemsType `json:"type"`
}
+// Schema for the `UIElicitationFieldValue` type.
type UIElicitationFieldValue interface {
uIElicitationFieldValue()
}
@@ -1928,6 +2164,7 @@ type UIElicitationStringValue string
func (UIElicitationStringValue) uIElicitationFieldValue() {}
+// Prompt message and JSON schema describing the form fields to elicit from the user.
type UIElicitationRequest struct {
// Message describing what information is needed from the user
Message string `json:"message"`
@@ -1946,6 +2183,8 @@ type UIElicitationResponse struct {
// The form values submitted by the user (present when action is 'accept')
type UIElicitationResponseContent map[string]UIElicitationFieldValue
+// Indicates whether the elicitation response was accepted; false if it was already resolved
+// by another client.
type UIElicitationResult struct {
// Whether the response was accepted. False if the request was already resolved by another
// client.
@@ -1962,6 +2201,7 @@ type UIElicitationSchema struct {
Type UIElicitationSchemaType `json:"type"`
}
+// Definition for a single elicitation form field.
type UIElicitationSchemaProperty interface {
uIElicitationSchemaProperty()
Type() UIElicitationSchemaPropertyType
@@ -1977,13 +2217,20 @@ func (r RawUIElicitationSchemaPropertyData) Type() UIElicitationSchemaPropertyTy
return r.Discriminator
}
+// Multi-select string field where each option pairs a value with a display label.
type UIElicitationArrayAnyOfField struct {
- Default []string `json:"default,omitempty"`
- Description *string `json:"description,omitempty"`
- Items UIElicitationArrayAnyOfFieldItems `json:"items"`
- MaxItems *float64 `json:"maxItems,omitempty"`
- MinItems *float64 `json:"minItems,omitempty"`
- Title *string `json:"title,omitempty"`
+ // Default values selected when the form is first shown.
+ Default []string `json:"default,omitempty"`
+ // Help text describing the field.
+ Description *string `json:"description,omitempty"`
+ // Schema applied to each item in the array.
+ Items UIElicitationArrayAnyOfFieldItems `json:"items"`
+ // Maximum number of items the user may select.
+ MaxItems *float64 `json:"maxItems,omitempty"`
+ // Minimum number of items the user must select.
+ MinItems *float64 `json:"minItems,omitempty"`
+ // Human-readable label for the field.
+ Title *string `json:"title,omitempty"`
}
func (UIElicitationArrayAnyOfField) uIElicitationSchemaProperty() {}
@@ -1991,13 +2238,20 @@ func (UIElicitationArrayAnyOfField) Type() UIElicitationSchemaPropertyType {
return UIElicitationSchemaPropertyTypeArray
}
+// Multi-select string field whose allowed values are defined inline.
type UIElicitationArrayEnumField struct {
- Default []string `json:"default,omitempty"`
- Description *string `json:"description,omitempty"`
- Items UIElicitationArrayEnumFieldItems `json:"items"`
- MaxItems *float64 `json:"maxItems,omitempty"`
- MinItems *float64 `json:"minItems,omitempty"`
- Title *string `json:"title,omitempty"`
+ // Default values selected when the form is first shown.
+ Default []string `json:"default,omitempty"`
+ // Help text describing the field.
+ Description *string `json:"description,omitempty"`
+ // Schema applied to each item in the array.
+ Items UIElicitationArrayEnumFieldItems `json:"items"`
+ // Maximum number of items the user may select.
+ MaxItems *float64 `json:"maxItems,omitempty"`
+ // Minimum number of items the user must select.
+ MinItems *float64 `json:"minItems,omitempty"`
+ // Human-readable label for the field.
+ Title *string `json:"title,omitempty"`
}
func (UIElicitationArrayEnumField) uIElicitationSchemaProperty() {}
@@ -2005,10 +2259,14 @@ func (UIElicitationArrayEnumField) Type() UIElicitationSchemaPropertyType {
return UIElicitationSchemaPropertyTypeArray
}
+// Boolean field rendered as a yes/no toggle.
type UIElicitationSchemaPropertyBoolean struct {
- Default *bool `json:"default,omitempty"`
+ // Default value selected when the form is first shown.
+ Default *bool `json:"default,omitempty"`
+ // Help text describing the field.
Description *string `json:"description,omitempty"`
- Title *string `json:"title,omitempty"`
+ // Human-readable label for the field.
+ Title *string `json:"title,omitempty"`
}
func (UIElicitationSchemaPropertyBoolean) uIElicitationSchemaProperty() {}
@@ -2016,11 +2274,17 @@ func (UIElicitationSchemaPropertyBoolean) Type() UIElicitationSchemaPropertyType
return UIElicitationSchemaPropertyTypeBoolean
}
+// Numeric field accepting either a number or an integer.
type UIElicitationSchemaPropertyNumber struct {
- Default *float64 `json:"default,omitempty"`
- Description *string `json:"description,omitempty"`
- Maximum *float64 `json:"maximum,omitempty"`
- Minimum *float64 `json:"minimum,omitempty"`
+ // Default value populated in the input when the form is first shown.
+ Default *float64 `json:"default,omitempty"`
+ // Help text describing the field.
+ Description *string `json:"description,omitempty"`
+ // Maximum allowed value (inclusive).
+ Maximum *float64 `json:"maximum,omitempty"`
+ // Minimum allowed value (inclusive).
+ Minimum *float64 `json:"minimum,omitempty"`
+ // Human-readable label for the field.
Title *string `json:"title,omitempty"`
Discriminator UIElicitationSchemaPropertyNumberType `json:"type,omitempty"`
}
@@ -2033,13 +2297,20 @@ func (r UIElicitationSchemaPropertyNumber) Type() UIElicitationSchemaPropertyTyp
return UIElicitationSchemaPropertyType(r.Discriminator)
}
+// Free-text string field with optional length and format constraints.
type UIElicitationSchemaPropertyString struct {
- Default *string `json:"default,omitempty"`
- Description *string `json:"description,omitempty"`
- Format *UIElicitationSchemaPropertyStringFormat `json:"format,omitempty"`
- MaxLength *float64 `json:"maxLength,omitempty"`
- MinLength *float64 `json:"minLength,omitempty"`
- Title *string `json:"title,omitempty"`
+ // Default value populated in the input when the form is first shown.
+ Default *string `json:"default,omitempty"`
+ // Help text describing the field.
+ Description *string `json:"description,omitempty"`
+ // Optional format hint that constrains the accepted input.
+ Format *UIElicitationSchemaPropertyStringFormat `json:"format,omitempty"`
+ // Maximum number of characters allowed.
+ MaxLength *float64 `json:"maxLength,omitempty"`
+ // Minimum number of characters required.
+ MinLength *float64 `json:"minLength,omitempty"`
+ // Human-readable label for the field.
+ Title *string `json:"title,omitempty"`
}
func (UIElicitationSchemaPropertyString) uIElicitationSchemaProperty() {}
@@ -2047,12 +2318,18 @@ func (UIElicitationSchemaPropertyString) Type() UIElicitationSchemaPropertyType
return UIElicitationSchemaPropertyTypeString
}
+// Single-select string field whose allowed values are defined inline.
type UIElicitationStringEnumField struct {
- Default *string `json:"default,omitempty"`
- Description *string `json:"description,omitempty"`
- Enum []string `json:"enum"`
- EnumNames []string `json:"enumNames,omitempty"`
- Title *string `json:"title,omitempty"`
+ // Default value selected when the form is first shown.
+ Default *string `json:"default,omitempty"`
+ // Help text describing the field.
+ Description *string `json:"description,omitempty"`
+ // Allowed string values.
+ Enum []string `json:"enum"`
+ // Optional display labels for each enum value, in the same order as `enum`.
+ EnumNames []string `json:"enumNames,omitempty"`
+ // Human-readable label for the field.
+ Title *string `json:"title,omitempty"`
}
func (UIElicitationStringEnumField) uIElicitationSchemaProperty() {}
@@ -2060,11 +2337,16 @@ func (UIElicitationStringEnumField) Type() UIElicitationSchemaPropertyType {
return UIElicitationSchemaPropertyTypeString
}
+// Single-select string field where each option pairs a value with a display label.
type UIElicitationStringOneOfField struct {
- Default *string `json:"default,omitempty"`
- Description *string `json:"description,omitempty"`
- OneOf []UIElicitationStringOneOfFieldOneOf `json:"oneOf"`
- Title *string `json:"title,omitempty"`
+ // Default value selected when the form is first shown.
+ Default *string `json:"default,omitempty"`
+ // Help text describing the field.
+ Description *string `json:"description,omitempty"`
+ // Selectable options, each with a value and a display label.
+ OneOf []UIElicitationStringOneOfFieldOneOf `json:"oneOf"`
+ // Human-readable label for the field.
+ Title *string `json:"title,omitempty"`
}
func (UIElicitationStringOneOfField) uIElicitationSchemaProperty() {}
@@ -2072,11 +2354,16 @@ func (UIElicitationStringOneOfField) Type() UIElicitationSchemaPropertyType {
return UIElicitationSchemaPropertyTypeString
}
+// Schema for the `UIElicitationStringOneOfFieldOneOf` type.
type UIElicitationStringOneOfFieldOneOf struct {
+ // Value submitted when this option is selected.
Const string `json:"const"`
+ // Display label for this option.
Title string `json:"title"`
}
+// Pending elicitation request ID and the user's response (accept/decline/cancel + form
+// values).
type UIHandlePendingElicitationRequest struct {
// The unique request ID from the elicitation.requested event
RequestID string `json:"requestId"`
@@ -2084,6 +2371,8 @@ type UIHandlePendingElicitationRequest struct {
Result UIElicitationResponse `json:"result"`
}
+// Accumulated session usage metrics, including premium request cost, token counts, model
+// breakdown, and code-change totals.
// Experimental: UsageGetMetricsResult is part of an experimental API and may change or be
// removed.
type UsageGetMetricsResult struct {
@@ -2122,6 +2411,7 @@ type UsageMetricsCodeChanges struct {
LinesRemoved int64 `json:"linesRemoved"`
}
+// Schema for the `UsageMetricsModelMetric` type.
type UsageMetricsModelMetric struct {
// Request count and cost metrics for this model
Requests UsageMetricsModelMetricRequests `json:"requests"`
@@ -2141,6 +2431,7 @@ type UsageMetricsModelMetricRequests struct {
Count int64 `json:"count"`
}
+// Schema for the `UsageMetricsModelMetricTokenDetail` type.
type UsageMetricsModelMetricTokenDetail struct {
// Accumulated token count for this token type
TokenCount int64 `json:"tokenCount"`
@@ -2160,11 +2451,13 @@ type UsageMetricsModelMetricUsage struct {
ReasoningTokens *int64 `json:"reasoningTokens,omitempty"`
}
+// Schema for the `UsageMetricsTokenDetail` type.
type UsageMetricsTokenDetail struct {
// Accumulated token count for this token type
TokenCount int64 `json:"tokenCount"`
}
+// Relative path and UTF-8 content for the workspace file to create or overwrite.
type WorkspacesCreateFileRequest struct {
// File content to write as a UTF-8 string
Content string `json:"content"`
@@ -2172,9 +2465,7 @@ type WorkspacesCreateFileRequest struct {
Path string `json:"path"`
}
-type WorkspacesCreateFileResult struct {
-}
-
+// Current workspace metadata for the session, or null when not available.
type WorkspacesGetWorkspaceResult struct {
// Current workspace metadata, or null if not available
Workspace *WorkspacesGetWorkspaceResultWorkspace `json:"workspace"`
@@ -2199,16 +2490,19 @@ type WorkspacesGetWorkspaceResultWorkspace struct {
UserNamed *bool `json:"user_named,omitempty"`
}
+// Relative paths of files stored in the session workspace files directory.
type WorkspacesListFilesResult struct {
// Relative file paths in the workspace files directory
Files []string `json:"files"`
}
+// Relative path of the workspace file to read.
type WorkspacesReadFileRequest struct {
// Relative path within the workspace files directory
Path string `json:"path"`
}
+// Contents of the requested workspace file as a UTF-8 string.
type WorkspacesReadFileResult struct {
// File content as a UTF-8 string
Content string `json:"content"`
@@ -2285,6 +2579,7 @@ const (
ExternalToolTextResultForLlmContentTypeText ExternalToolTextResultForLlmContentType = "text"
)
+// Allowed values for the `FilterMappingString` enumeration.
type FilterMappingString string
const (
@@ -2293,6 +2588,7 @@ const (
FilterMappingStringNone FilterMappingString = "none"
)
+// Allowed values for the `FilterMappingValue` enumeration.
type FilterMappingValue string
const (
@@ -2322,6 +2618,7 @@ const (
InstructionsSourcesTypeVscode InstructionsSourcesType = "vscode"
)
+// OAuth grant type to use when authenticating to the remote MCP server.
type McpServerConfigHTTPOauthGrantType string
const (
@@ -2337,6 +2634,7 @@ const (
McpServerConfigHTTPTypeSse McpServerConfigHTTPType = "sse"
)
+// Local transport type. Defaults to "local".
type McpServerConfigLocalType string
const (
@@ -2427,9 +2725,17 @@ const (
PermissionDecisionKindUserNotAvailable PermissionDecisionKind = "user-not-available"
)
-// Per-session remote mode. "off" disables remote, "export" exports session events to
-// Mission Control without enabling remote steering, "on" enables both export and remote
-// steering.
+// Reasoning summary mode to request for supported model clients
+type ReasoningSummary string
+
+const (
+ ReasoningSummaryConcise ReasoningSummary = "concise"
+ ReasoningSummaryDetailed ReasoningSummary = "detailed"
+ ReasoningSummaryNone ReasoningSummary = "none"
+)
+
+// Per-session remote mode. "off" disables remote, "export" exports session events to GitHub
+// without enabling remote steering, "on" enables both export and remote steering.
type RemoteSessionMode string
const (
@@ -2580,6 +2886,7 @@ const (
TaskShellInfoStatusRunning TaskShellInfoStatus = "running"
)
+// Type discriminator. Always "string".
type UIElicitationArrayEnumFieldItemsType string
const (
@@ -2595,6 +2902,7 @@ const (
UIElicitationResponseActionDecline UIElicitationResponseAction = "decline"
)
+// Numeric type accepted by the field.
type UIElicitationSchemaPropertyNumberType string
const (
@@ -2602,6 +2910,7 @@ const (
UIElicitationSchemaPropertyNumberTypeNumber UIElicitationSchemaPropertyNumberType = "number"
)
+// Optional format hint that constrains the accepted input.
type UIElicitationSchemaPropertyStringFormat string
const (
@@ -2642,9 +2951,14 @@ type serverApi struct {
type ServerAccountApi serverApi
-// GetQuota calls account.getQuota.
+// GetQuota gets Copilot quota usage for the authenticated user or supplied GitHub token.
//
// RPC method: account.getQuota.
+//
+// Parameters: Optional GitHub token used to look up quota for a specific user instead of
+// the global auth context.
+//
+// Returns: Quota usage snapshots for the resolved user, keyed by quota type.
func (a *ServerAccountApi) GetQuota(ctx context.Context, params *AccountGetQuotaRequest) (*AccountGetQuotaResult, error) {
raw, err := a.client.Request("account.getQuota", params)
if err != nil {
@@ -2659,9 +2973,13 @@ func (a *ServerAccountApi) GetQuota(ctx context.Context, params *AccountGetQuota
type ServerMcpApi serverApi
-// Discover calls mcp.discover.
+// Discovers MCP servers from user, workspace, plugin, and builtin sources.
//
// RPC method: mcp.discover.
+//
+// Parameters: Optional working directory used as context for MCP server discovery.
+//
+// Returns: MCP servers discovered from user, workspace, plugin, and built-in sources.
func (a *ServerMcpApi) Discover(ctx context.Context, params *McpDiscoverRequest) (*McpDiscoverResult, error) {
raw, err := a.client.Request("mcp.discover", params)
if err != nil {
@@ -2676,9 +2994,11 @@ func (a *ServerMcpApi) Discover(ctx context.Context, params *McpDiscoverRequest)
type ServerMcpConfigApi serverApi
-// Add calls mcp.config.add.
+// Adds an MCP server to user configuration.
//
// RPC method: mcp.config.add.
+//
+// Parameters: MCP server name and configuration to add to user configuration.
func (a *ServerMcpConfigApi) Add(ctx context.Context, params *McpConfigAddRequest) (*McpConfigAddResult, error) {
raw, err := a.client.Request("mcp.config.add", params)
if err != nil {
@@ -2691,9 +3011,11 @@ func (a *ServerMcpConfigApi) Add(ctx context.Context, params *McpConfigAddReques
return &result, nil
}
-// Disable calls mcp.config.disable.
+// Disables MCP servers in user configuration for new sessions.
//
// RPC method: mcp.config.disable.
+//
+// Parameters: MCP server names to disable for new sessions.
func (a *ServerMcpConfigApi) Disable(ctx context.Context, params *McpConfigDisableRequest) (*McpConfigDisableResult, error) {
raw, err := a.client.Request("mcp.config.disable", params)
if err != nil {
@@ -2706,9 +3028,11 @@ func (a *ServerMcpConfigApi) Disable(ctx context.Context, params *McpConfigDisab
return &result, nil
}
-// Enable calls mcp.config.enable.
+// Enables MCP servers in user configuration for new sessions.
//
// RPC method: mcp.config.enable.
+//
+// Parameters: MCP server names to enable for new sessions.
func (a *ServerMcpConfigApi) Enable(ctx context.Context, params *McpConfigEnableRequest) (*McpConfigEnableResult, error) {
raw, err := a.client.Request("mcp.config.enable", params)
if err != nil {
@@ -2721,9 +3045,11 @@ func (a *ServerMcpConfigApi) Enable(ctx context.Context, params *McpConfigEnable
return &result, nil
}
-// List calls mcp.config.list.
+// Lists MCP servers from user configuration.
//
// RPC method: mcp.config.list.
+//
+// Returns: User-configured MCP servers, keyed by server name.
func (a *ServerMcpConfigApi) List(ctx context.Context) (*McpConfigList, error) {
raw, err := a.client.Request("mcp.config.list", nil)
if err != nil {
@@ -2736,9 +3062,11 @@ func (a *ServerMcpConfigApi) List(ctx context.Context) (*McpConfigList, error) {
return &result, nil
}
-// Remove calls mcp.config.remove.
+// Removes an MCP server from user configuration.
//
// RPC method: mcp.config.remove.
+//
+// Parameters: MCP server name to remove from user configuration.
func (a *ServerMcpConfigApi) Remove(ctx context.Context, params *McpConfigRemoveRequest) (*McpConfigRemoveResult, error) {
raw, err := a.client.Request("mcp.config.remove", params)
if err != nil {
@@ -2751,9 +3079,11 @@ func (a *ServerMcpConfigApi) Remove(ctx context.Context, params *McpConfigRemove
return &result, nil
}
-// Update calls mcp.config.update.
+// Updates an MCP server in user configuration.
//
// RPC method: mcp.config.update.
+//
+// Parameters: MCP server name and replacement configuration to write to user configuration.
func (a *ServerMcpConfigApi) Update(ctx context.Context, params *McpConfigUpdateRequest) (*McpConfigUpdateResult, error) {
raw, err := a.client.Request("mcp.config.update", params)
if err != nil {
@@ -2772,9 +3102,15 @@ func (s *ServerMcpApi) Config() *ServerMcpConfigApi {
type ServerModelsApi serverApi
-// List calls models.list.
+// Lists Copilot models available to the authenticated user.
//
// RPC method: models.list.
+//
+// Parameters: Optional GitHub token used to list models for a specific user instead of the
+// global auth context.
+//
+// Returns: List of Copilot models available to the resolved user, including capabilities
+// and billing metadata.
func (a *ServerModelsApi) List(ctx context.Context, params *ModelsListRequest) (*ModelList, error) {
raw, err := a.client.Request("models.list", params)
if err != nil {
@@ -2789,9 +3125,15 @@ func (a *ServerModelsApi) List(ctx context.Context, params *ModelsListRequest) (
type ServerSessionFsApi serverApi
-// SetProvider calls sessionFs.setProvider.
+// SetProvider registers an SDK client as the session filesystem provider.
//
// RPC method: sessionFs.setProvider.
+//
+// Parameters: Initial working directory, session-state path layout, and path conventions
+// used to register the calling SDK client as the session filesystem provider.
+//
+// Returns: Indicates whether the calling client was registered as the session filesystem
+// provider.
func (a *ServerSessionFsApi) SetProvider(ctx context.Context, params *SessionFsSetProviderRequest) (*SessionFsSetProviderResult, error) {
raw, err := a.client.Request("sessionFs.setProvider", params)
if err != nil {
@@ -2807,9 +3149,14 @@ func (a *ServerSessionFsApi) SetProvider(ctx context.Context, params *SessionFsS
// Experimental: ServerSessionsApi contains experimental APIs that may change or be removed.
type ServerSessionsApi serverApi
-// Fork calls sessions.fork.
+// Fork creates a new session by forking persisted history from an existing session.
//
// RPC method: sessions.fork.
+//
+// Parameters: Source session identifier to fork from, optional event-ID boundary, and
+// optional friendly name for the new session.
+//
+// Returns: Identifier and optional friendly name assigned to the newly forked session.
func (a *ServerSessionsApi) Fork(ctx context.Context, params *SessionsForkRequest) (*SessionsForkResult, error) {
raw, err := a.client.Request("sessions.fork", params)
if err != nil {
@@ -2824,9 +3171,14 @@ func (a *ServerSessionsApi) Fork(ctx context.Context, params *SessionsForkReques
type ServerSkillsApi serverApi
-// Discover calls skills.discover.
+// Discovers skills across global and project sources.
//
// RPC method: skills.discover.
+//
+// Parameters: Optional project paths and additional skill directories to include in
+// discovery.
+//
+// Returns: Skills discovered across global and project sources.
func (a *ServerSkillsApi) Discover(ctx context.Context, params *SkillsDiscoverRequest) (*ServerSkillList, error) {
raw, err := a.client.Request("skills.discover", params)
if err != nil {
@@ -2841,9 +3193,12 @@ func (a *ServerSkillsApi) Discover(ctx context.Context, params *SkillsDiscoverRe
type ServerSkillsConfigApi serverApi
-// SetDisabledSkills calls skills.config.setDisabledSkills.
+// SetDisabledSkills replaces the global list of disabled skills.
//
// RPC method: skills.config.setDisabledSkills.
+//
+// Parameters: Skill names to mark as disabled in global configuration, replacing any
+// previous list.
func (a *ServerSkillsConfigApi) SetDisabledSkills(ctx context.Context, params *SkillsConfigSetDisabledSkillsRequest) (*SkillsConfigSetDisabledSkillsResult, error) {
raw, err := a.client.Request("skills.config.setDisabledSkills", params)
if err != nil {
@@ -2862,9 +3217,15 @@ func (s *ServerSkillsApi) Config() *ServerSkillsConfigApi {
type ServerToolsApi serverApi
-// List calls tools.list.
+// Lists built-in tools available for a model.
//
// RPC method: tools.list.
+//
+// Parameters: Optional model identifier whose tool overrides should be applied to the
+// listing.
+//
+// Returns: Built-in tools available for the requested model, with their parameters and
+// instructions.
func (a *ServerToolsApi) List(ctx context.Context, params *ToolsListRequest) (*ToolList, error) {
raw, err := a.client.Request("tools.list", params)
if err != nil {
@@ -2891,9 +3252,14 @@ type ServerRpc struct {
Tools *ServerToolsApi
}
-// Ping calls ping.
+// Ping checks server responsiveness and returns protocol information.
//
// RPC method: ping.
+//
+// Parameters: Optional message to echo back to the caller.
+//
+// Returns: Server liveness response, including the echoed message, current timestamp, and
+// protocol version.
func (a *ServerRpc) Ping(ctx context.Context, params *PingRequest) (*PingResult, error) {
raw, err := a.common.client.Request("ping", params)
if err != nil {
@@ -2930,9 +3296,15 @@ type InternalServerRpc struct {
common internalServerApi
}
-// Connect calls connect.
+// Connect performs the SDK server connection handshake and validates the optional
+// connection token.
//
// RPC method: connect.
+//
+// Parameters: Optional connection token presented by the SDK client during the handshake.
+//
+// Returns: Handshake result reporting the server's protocol version and package version on
+// success.
// Internal: Connect is part of the SDK's internal handshake/plumbing; external callers
// should not use it.
func (a *InternalServerRpc) Connect(ctx context.Context, params *ConnectRequest) (*ConnectResult, error) {
@@ -2961,25 +3333,27 @@ type sessionApi struct {
// Experimental: AgentApi contains experimental APIs that may change or be removed.
type AgentApi sessionApi
-// Deselect calls session.agent.deselect.
+// Deselect clears the selected custom agent and returns the session to the default agent.
//
// RPC method: session.agent.deselect.
-func (a *AgentApi) Deselect(ctx context.Context) (*AgentDeselectResult, error) {
+func (a *AgentApi) Deselect(ctx context.Context) (*SessionAgentDeselectResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.agent.deselect", req)
if err != nil {
return nil, err
}
- var result AgentDeselectResult
+ var result SessionAgentDeselectResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// GetCurrent calls session.agent.getCurrent.
+// GetCurrent gets the currently selected custom agent for the session.
//
// RPC method: session.agent.getCurrent.
+//
+// Returns: The currently selected custom agent, or null when using the default agent.
func (a *AgentApi) GetCurrent(ctx context.Context) (*AgentGetCurrentResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.agent.getCurrent", req)
@@ -2993,9 +3367,11 @@ func (a *AgentApi) GetCurrent(ctx context.Context) (*AgentGetCurrentResult, erro
return &result, nil
}
-// List calls session.agent.list.
+// Lists custom agents available to the session.
//
// RPC method: session.agent.list.
+//
+// Returns: Custom agents available to the session.
func (a *AgentApi) List(ctx context.Context) (*AgentList, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.agent.list", req)
@@ -3009,9 +3385,11 @@ func (a *AgentApi) List(ctx context.Context) (*AgentList, error) {
return &result, nil
}
-// Reload calls session.agent.reload.
+// Reloads custom agent definitions and returns the refreshed list.
//
// RPC method: session.agent.reload.
+//
+// Returns: Custom agents available to the session after reloading definitions from disk.
func (a *AgentApi) Reload(ctx context.Context) (*AgentReloadResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.agent.reload", req)
@@ -3025,9 +3403,13 @@ func (a *AgentApi) Reload(ctx context.Context) (*AgentReloadResult, error) {
return &result, nil
}
-// Select calls session.agent.select.
+// Selects a custom agent for subsequent turns in the session.
//
// RPC method: session.agent.select.
+//
+// Parameters: Name of the custom agent to select for subsequent turns.
+//
+// Returns: The newly selected custom agent.
func (a *AgentApi) Select(ctx context.Context, params *AgentSelectRequest) (*AgentSelectResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3046,9 +3428,11 @@ func (a *AgentApi) Select(ctx context.Context, params *AgentSelectRequest) (*Age
type AuthApi sessionApi
-// GetStatus calls session.auth.getStatus.
+// GetStatus gets authentication status and account metadata for the session.
//
// RPC method: session.auth.getStatus.
+//
+// Returns: Authentication status and account metadata for the session.
func (a *AuthApi) GetStatus(ctx context.Context) (*SessionAuthStatus, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.auth.getStatus", req)
@@ -3064,9 +3448,13 @@ func (a *AuthApi) GetStatus(ctx context.Context) (*SessionAuthStatus, error) {
type CommandsApi sessionApi
-// HandlePendingCommand calls session.commands.handlePendingCommand.
+// HandlePendingCommand reports completion of a pending client-handled slash command.
//
// RPC method: session.commands.handlePendingCommand.
+//
+// Parameters: Pending command request ID and an optional error if the client handler failed.
+//
+// Returns: Indicates whether the pending client-handled command was completed successfully.
func (a *CommandsApi) HandlePendingCommand(ctx context.Context, params *CommandsHandlePendingCommandRequest) (*CommandsHandlePendingCommandResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3086,9 +3474,14 @@ func (a *CommandsApi) HandlePendingCommand(ctx context.Context, params *Commands
return &result, nil
}
-// Invoke calls session.commands.invoke.
+// Invokes a slash command in the session.
//
// RPC method: session.commands.invoke.
+//
+// Parameters: Slash command name and optional raw input string to invoke.
+//
+// Returns: Result of invoking the slash command (text output, prompt to send to the agent,
+// or completion).
func (a *CommandsApi) Invoke(ctx context.Context, params *CommandsInvokeRequest) (SlashCommandInvocationResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3108,9 +3501,14 @@ func (a *CommandsApi) Invoke(ctx context.Context, params *CommandsInvokeRequest)
return result, nil
}
-// List calls session.commands.list.
+// Lists slash commands available in the session.
//
// RPC method: session.commands.list.
+//
+// Parameters: Optional filters controlling which command sources to include in the listing.
+//
+// Returns: Slash commands available in the session, after applying any include/exclude
+// filters.
func (a *CommandsApi) List(ctx context.Context, params ...*CommandsListRequest) (*CommandList, error) {
var requestParams *CommandsListRequest
if len(params) > 0 {
@@ -3139,9 +3537,14 @@ func (a *CommandsApi) List(ctx context.Context, params ...*CommandsListRequest)
return &result, nil
}
-// RespondToQueuedCommand calls session.commands.respondToQueuedCommand.
+// RespondToQueuedCommand responds to a queued command request from the session.
//
// RPC method: session.commands.respondToQueuedCommand.
+//
+// Parameters: Queued command request ID and the result indicating whether the client
+// handled it.
+//
+// Returns: Indicates whether the queued-command response was accepted by the session.
func (a *CommandsApi) RespondToQueuedCommand(ctx context.Context, params *CommandsRespondToQueuedCommandRequest) (*CommandsRespondToQueuedCommandResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3162,10 +3565,12 @@ func (a *CommandsApi) RespondToQueuedCommand(ctx context.Context, params *Comman
// Experimental: ExtensionsApi contains experimental APIs that may change or be removed.
type ExtensionsApi sessionApi
-// Disable calls session.extensions.disable.
+// Disables an extension for the session.
//
// RPC method: session.extensions.disable.
-func (a *ExtensionsApi) Disable(ctx context.Context, params *ExtensionsDisableRequest) (*ExtensionsDisableResult, error) {
+//
+// Parameters: Source-qualified extension identifier to disable for the session.
+func (a *ExtensionsApi) Disable(ctx context.Context, params *ExtensionsDisableRequest) (*SessionExtensionsDisableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["id"] = params.ID
@@ -3174,17 +3579,19 @@ func (a *ExtensionsApi) Disable(ctx context.Context, params *ExtensionsDisableRe
if err != nil {
return nil, err
}
- var result ExtensionsDisableResult
+ var result SessionExtensionsDisableResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// Enable calls session.extensions.enable.
+// Enables an extension for the session.
//
// RPC method: session.extensions.enable.
-func (a *ExtensionsApi) Enable(ctx context.Context, params *ExtensionsEnableRequest) (*ExtensionsEnableResult, error) {
+//
+// Parameters: Source-qualified extension identifier to enable for the session.
+func (a *ExtensionsApi) Enable(ctx context.Context, params *ExtensionsEnableRequest) (*SessionExtensionsEnableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["id"] = params.ID
@@ -3193,16 +3600,18 @@ func (a *ExtensionsApi) Enable(ctx context.Context, params *ExtensionsEnableRequ
if err != nil {
return nil, err
}
- var result ExtensionsEnableResult
+ var result SessionExtensionsEnableResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// List calls session.extensions.list.
+// Lists extensions discovered for the session and their current status.
//
// RPC method: session.extensions.list.
+//
+// Returns: Extensions discovered for the session, with their current status.
func (a *ExtensionsApi) List(ctx context.Context) (*ExtensionList, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.extensions.list", req)
@@ -3216,16 +3625,16 @@ func (a *ExtensionsApi) List(ctx context.Context) (*ExtensionList, error) {
return &result, nil
}
-// Reload calls session.extensions.reload.
+// Reloads extension definitions and processes for the session.
//
// RPC method: session.extensions.reload.
-func (a *ExtensionsApi) Reload(ctx context.Context) (*ExtensionsReloadResult, error) {
+func (a *ExtensionsApi) Reload(ctx context.Context) (*SessionExtensionsReloadResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.extensions.reload", req)
if err != nil {
return nil, err
}
- var result ExtensionsReloadResult
+ var result SessionExtensionsReloadResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
@@ -3235,9 +3644,13 @@ func (a *ExtensionsApi) Reload(ctx context.Context) (*ExtensionsReloadResult, er
// Experimental: FleetApi contains experimental APIs that may change or be removed.
type FleetApi sessionApi
-// Start calls session.fleet.start.
+// Starts fleet mode by submitting the fleet orchestration prompt to the session.
//
// RPC method: session.fleet.start.
+//
+// Parameters: Optional user prompt to combine with the fleet orchestration instructions.
+//
+// Returns: Indicates whether fleet mode was successfully activated.
func (a *FleetApi) Start(ctx context.Context, params *FleetStartRequest) (*FleetStartResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3259,9 +3672,12 @@ func (a *FleetApi) Start(ctx context.Context, params *FleetStartRequest) (*Fleet
// Experimental: HistoryApi contains experimental APIs that may change or be removed.
type HistoryApi sessionApi
-// Compact calls session.history.compact.
+// Compacts the session history to reduce context usage.
//
// RPC method: session.history.compact.
+//
+// Returns: Compaction outcome with the number of tokens and messages removed and the
+// resulting context window breakdown.
func (a *HistoryApi) Compact(ctx context.Context) (*HistoryCompactResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.history.compact", req)
@@ -3275,9 +3691,14 @@ func (a *HistoryApi) Compact(ctx context.Context) (*HistoryCompactResult, error)
return &result, nil
}
-// Truncate calls session.history.truncate.
+// Truncates persisted session history to a specific event.
//
// RPC method: session.history.truncate.
+//
+// Parameters: Identifier of the event to truncate to; this event and all later events are
+// removed.
+//
+// Returns: Number of events that were removed by the truncation.
func (a *HistoryApi) Truncate(ctx context.Context, params *HistoryTruncateRequest) (*HistoryTruncateResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3296,9 +3717,11 @@ func (a *HistoryApi) Truncate(ctx context.Context, params *HistoryTruncateReques
type InstructionsApi sessionApi
-// GetSources calls session.instructions.getSources.
+// GetSources gets instruction sources loaded for the session.
//
// RPC method: session.instructions.getSources.
+//
+// Returns: Instruction sources loaded for the session, in merge order.
func (a *InstructionsApi) GetSources(ctx context.Context) (*InstructionsGetSourcesResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.instructions.getSources", req)
@@ -3315,10 +3738,12 @@ func (a *InstructionsApi) GetSources(ctx context.Context) (*InstructionsGetSourc
// Experimental: McpApi contains experimental APIs that may change or be removed.
type McpApi sessionApi
-// Disable calls session.mcp.disable.
+// Disables an MCP server for the session.
//
// RPC method: session.mcp.disable.
-func (a *McpApi) Disable(ctx context.Context, params *McpDisableRequest) (*McpDisableResult, error) {
+//
+// Parameters: Name of the MCP server to disable for the session.
+func (a *McpApi) Disable(ctx context.Context, params *McpDisableRequest) (*SessionMcpDisableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["serverName"] = params.ServerName
@@ -3327,17 +3752,19 @@ func (a *McpApi) Disable(ctx context.Context, params *McpDisableRequest) (*McpDi
if err != nil {
return nil, err
}
- var result McpDisableResult
+ var result SessionMcpDisableResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// Enable calls session.mcp.enable.
+// Enables an MCP server for the session.
//
// RPC method: session.mcp.enable.
-func (a *McpApi) Enable(ctx context.Context, params *McpEnableRequest) (*McpEnableResult, error) {
+//
+// Parameters: Name of the MCP server to enable for the session.
+func (a *McpApi) Enable(ctx context.Context, params *McpEnableRequest) (*SessionMcpEnableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["serverName"] = params.ServerName
@@ -3346,16 +3773,18 @@ func (a *McpApi) Enable(ctx context.Context, params *McpEnableRequest) (*McpEnab
if err != nil {
return nil, err
}
- var result McpEnableResult
+ var result SessionMcpEnableResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// List calls session.mcp.list.
+// Lists MCP servers configured for the session and their connection status.
//
// RPC method: session.mcp.list.
+//
+// Returns: MCP servers configured for the session, with their connection status.
func (a *McpApi) List(ctx context.Context) (*McpServerList, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.mcp.list", req)
@@ -3369,16 +3798,16 @@ func (a *McpApi) List(ctx context.Context) (*McpServerList, error) {
return &result, nil
}
-// Reload calls session.mcp.reload.
+// Reloads MCP server connections for the session.
//
// RPC method: session.mcp.reload.
-func (a *McpApi) Reload(ctx context.Context) (*McpReloadResult, error) {
+func (a *McpApi) Reload(ctx context.Context) (*SessionMcpReloadResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.mcp.reload", req)
if err != nil {
return nil, err
}
- var result McpReloadResult
+ var result SessionMcpReloadResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
@@ -3388,9 +3817,15 @@ func (a *McpApi) Reload(ctx context.Context) (*McpReloadResult, error) {
// Experimental: McpOauthApi contains experimental APIs that may change or be removed.
type McpOauthApi sessionApi
-// Login calls session.mcp.oauth.login.
+// Login starts OAuth authentication for a remote MCP server.
//
// RPC method: session.mcp.oauth.login.
+//
+// Parameters: Remote MCP server name and optional overrides controlling reauthentication,
+// OAuth client display name, and the callback success-page copy.
+//
+// Returns: OAuth authorization URL the caller should open, or empty when cached tokens
+// already authenticated the server.
func (a *McpOauthApi) Login(ctx context.Context, params *McpOauthLoginRequest) (*McpOauthLoginResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3423,7 +3858,7 @@ func (s *McpApi) Oauth() *McpOauthApi {
type ModeApi sessionApi
-// Get calls session.mode.get.
+// Gets the current agent interaction mode.
//
// RPC method: session.mode.get.
//
@@ -3441,10 +3876,12 @@ func (a *ModeApi) Get(ctx context.Context) (*SessionMode, error) {
return &result, nil
}
-// Set calls session.mode.set.
+// Sets the current agent interaction mode.
//
// RPC method: session.mode.set.
-func (a *ModeApi) Set(ctx context.Context, params *ModeSetRequest) (*ModeSetResult, error) {
+//
+// Parameters: Agent interaction mode to apply to the session.
+func (a *ModeApi) Set(ctx context.Context, params *ModeSetRequest) (*SessionModeSetResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["mode"] = params.Mode
@@ -3453,7 +3890,7 @@ func (a *ModeApi) Set(ctx context.Context, params *ModeSetRequest) (*ModeSetResu
if err != nil {
return nil, err
}
- var result ModeSetResult
+ var result SessionModeSetResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
@@ -3462,9 +3899,11 @@ func (a *ModeApi) Set(ctx context.Context, params *ModeSetRequest) (*ModeSetResu
type ModelApi sessionApi
-// GetCurrent calls session.model.getCurrent.
+// GetCurrent gets the currently selected model for the session.
//
// RPC method: session.model.getCurrent.
+//
+// Returns: The currently selected model for the session.
func (a *ModelApi) GetCurrent(ctx context.Context) (*CurrentModel, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.model.getCurrent", req)
@@ -3478,9 +3917,14 @@ func (a *ModelApi) GetCurrent(ctx context.Context) (*CurrentModel, error) {
return &result, nil
}
-// SwitchTo calls session.model.switchTo.
+// SwitchTo switches the session to a model and optional reasoning configuration.
//
// RPC method: session.model.switchTo.
+//
+// Parameters: Target model identifier and optional reasoning effort, summary, and
+// capability overrides.
+//
+// Returns: The model identifier active on the session after the switch.
func (a *ModelApi) SwitchTo(ctx context.Context, params *ModelSwitchToRequest) (*ModelSwitchToResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3491,6 +3935,9 @@ func (a *ModelApi) SwitchTo(ctx context.Context, params *ModelSwitchToRequest) (
if params.ReasoningEffort != nil {
req["reasoningEffort"] = *params.ReasoningEffort
}
+ if params.ReasoningSummary != nil {
+ req["reasoningSummary"] = *params.ReasoningSummary
+ }
}
raw, err := a.client.Request("session.model.switchTo", req)
if err != nil {
@@ -3505,9 +3952,11 @@ func (a *ModelApi) SwitchTo(ctx context.Context, params *ModelSwitchToRequest) (
type NameApi sessionApi
-// Get calls session.name.get.
+// Gets the session's friendly name.
//
// RPC method: session.name.get.
+//
+// Returns: The session's friendly name, or null when not yet set.
func (a *NameApi) Get(ctx context.Context) (*NameGetResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.name.get", req)
@@ -3521,10 +3970,12 @@ func (a *NameApi) Get(ctx context.Context) (*NameGetResult, error) {
return &result, nil
}
-// Set calls session.name.set.
+// Sets the session's friendly name.
//
// RPC method: session.name.set.
-func (a *NameApi) Set(ctx context.Context, params *NameSetRequest) (*NameSetResult, error) {
+//
+// Parameters: New friendly name to apply to the session.
+func (a *NameApi) Set(ctx context.Context, params *NameSetRequest) (*SessionNameSetResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["name"] = params.Name
@@ -3533,7 +3984,7 @@ func (a *NameApi) Set(ctx context.Context, params *NameSetRequest) (*NameSetResu
if err != nil {
return nil, err
}
- var result NameSetResult
+ var result SessionNameSetResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
@@ -3542,9 +3993,15 @@ func (a *NameApi) Set(ctx context.Context, params *NameSetRequest) (*NameSetResu
type PermissionsApi sessionApi
-// HandlePendingPermissionRequest calls session.permissions.handlePendingPermissionRequest.
+// HandlePendingPermissionRequest provides a decision for a pending tool permission request.
//
// RPC method: session.permissions.handlePendingPermissionRequest.
+//
+// Parameters: Pending permission request ID and the decision to apply (approve/reject and
+// scope).
+//
+// Returns: Indicates whether the permission decision was applied; false when the request
+// was already resolved.
func (a *PermissionsApi) HandlePendingPermissionRequest(ctx context.Context, params *PermissionDecisionRequest) (*PermissionRequestResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3562,9 +4019,11 @@ func (a *PermissionsApi) HandlePendingPermissionRequest(ctx context.Context, par
return &result, nil
}
-// ResetSessionApprovals calls session.permissions.resetSessionApprovals.
+// ResetSessionApprovals clears session-scoped tool permission approvals.
//
// RPC method: session.permissions.resetSessionApprovals.
+//
+// Returns: Indicates whether the operation succeeded.
func (a *PermissionsApi) ResetSessionApprovals(ctx context.Context) (*PermissionsResetSessionApprovalsResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.permissions.resetSessionApprovals", req)
@@ -3578,9 +4037,15 @@ func (a *PermissionsApi) ResetSessionApprovals(ctx context.Context) (*Permission
return &result, nil
}
-// SetApproveAll calls session.permissions.setApproveAll.
+// SetApproveAll enables or disables automatic approval of tool permission requests for the
+// session.
//
// RPC method: session.permissions.setApproveAll.
+//
+// Parameters: Whether to auto-approve all tool permission requests for the rest of the
+// session.
+//
+// Returns: Indicates whether the operation succeeded.
func (a *PermissionsApi) SetApproveAll(ctx context.Context, params *PermissionsSetApproveAllRequest) (*PermissionsSetApproveAllResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3599,25 +4064,27 @@ func (a *PermissionsApi) SetApproveAll(ctx context.Context, params *PermissionsS
type PlanApi sessionApi
-// Delete calls session.plan.delete.
+// Deletes the session plan file from the workspace.
//
// RPC method: session.plan.delete.
-func (a *PlanApi) Delete(ctx context.Context) (*PlanDeleteResult, error) {
+func (a *PlanApi) Delete(ctx context.Context) (*SessionPlanDeleteResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.plan.delete", req)
if err != nil {
return nil, err
}
- var result PlanDeleteResult
+ var result SessionPlanDeleteResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// Read calls session.plan.read.
+// Reads the session plan file from the workspace.
//
// RPC method: session.plan.read.
+//
+// Returns: Existence, contents, and resolved path of the session plan file.
func (a *PlanApi) Read(ctx context.Context) (*PlanReadResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.plan.read", req)
@@ -3631,10 +4098,12 @@ func (a *PlanApi) Read(ctx context.Context) (*PlanReadResult, error) {
return &result, nil
}
-// Update calls session.plan.update.
+// Update writes new content to the session plan file.
//
// RPC method: session.plan.update.
-func (a *PlanApi) Update(ctx context.Context, params *PlanUpdateRequest) (*PlanUpdateResult, error) {
+//
+// Parameters: Replacement contents to write to the session plan file.
+func (a *PlanApi) Update(ctx context.Context, params *PlanUpdateRequest) (*SessionPlanUpdateResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["content"] = params.Content
@@ -3643,7 +4112,7 @@ func (a *PlanApi) Update(ctx context.Context, params *PlanUpdateRequest) (*PlanU
if err != nil {
return nil, err
}
- var result PlanUpdateResult
+ var result SessionPlanUpdateResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
@@ -3653,9 +4122,11 @@ func (a *PlanApi) Update(ctx context.Context, params *PlanUpdateRequest) (*PlanU
// Experimental: PluginsApi contains experimental APIs that may change or be removed.
type PluginsApi sessionApi
-// List calls session.plugins.list.
+// Lists plugins installed for the session.
//
// RPC method: session.plugins.list.
+//
+// Returns: Plugins installed for the session, with their enabled state and version metadata.
func (a *PluginsApi) List(ctx context.Context) (*PluginList, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.plugins.list", req)
@@ -3672,25 +4143,31 @@ func (a *PluginsApi) List(ctx context.Context) (*PluginList, error) {
// Experimental: RemoteApi contains experimental APIs that may change or be removed.
type RemoteApi sessionApi
-// Disable calls session.remote.disable.
+// Disables remote session export and steering.
//
// RPC method: session.remote.disable.
-func (a *RemoteApi) Disable(ctx context.Context) (*RemoteDisableResult, error) {
+func (a *RemoteApi) Disable(ctx context.Context) (*SessionRemoteDisableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.remote.disable", req)
if err != nil {
return nil, err
}
- var result RemoteDisableResult
+ var result SessionRemoteDisableResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// Enable calls session.remote.enable.
+// Enables remote session export or steering.
//
// RPC method: session.remote.enable.
+//
+// Parameters: Optional remote session mode ("off", "export", or "on"); defaults to enabling
+// both export and remote steering.
+//
+// Returns: GitHub URL for the session and a flag indicating whether remote steering is
+// enabled.
func (a *RemoteApi) Enable(ctx context.Context, params *RemoteEnableRequest) (*RemoteEnableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3711,9 +4188,15 @@ func (a *RemoteApi) Enable(ctx context.Context, params *RemoteEnableRequest) (*R
type ShellApi sessionApi
-// Exec calls session.shell.exec.
+// Exec starts a shell command and streams output through session notifications.
//
// RPC method: session.shell.exec.
+//
+// Parameters: Shell command to run, with optional working directory and timeout in
+// milliseconds.
+//
+// Returns: Identifier of the spawned process, used to correlate streamed output and exit
+// notifications.
func (a *ShellApi) Exec(ctx context.Context, params *ShellExecRequest) (*ShellExecResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3736,9 +4219,15 @@ func (a *ShellApi) Exec(ctx context.Context, params *ShellExecRequest) (*ShellEx
return &result, nil
}
-// Kill calls session.shell.kill.
+// Kill sends a signal to a shell process previously started via "shell.exec".
//
// RPC method: session.shell.kill.
+//
+// Parameters: Identifier of a process previously returned by "shell.exec" and the signal to
+// send.
+//
+// Returns: Indicates whether the signal was delivered; false if the process was unknown or
+// already exited.
func (a *ShellApi) Kill(ctx context.Context, params *ShellKillRequest) (*ShellKillResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3761,10 +4250,12 @@ func (a *ShellApi) Kill(ctx context.Context, params *ShellKillRequest) (*ShellKi
// Experimental: SkillsApi contains experimental APIs that may change or be removed.
type SkillsApi sessionApi
-// Disable calls session.skills.disable.
+// Disables a skill for the session.
//
// RPC method: session.skills.disable.
-func (a *SkillsApi) Disable(ctx context.Context, params *SkillsDisableRequest) (*SkillsDisableResult, error) {
+//
+// Parameters: Name of the skill to disable for the session.
+func (a *SkillsApi) Disable(ctx context.Context, params *SkillsDisableRequest) (*SessionSkillsDisableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["name"] = params.Name
@@ -3773,17 +4264,19 @@ func (a *SkillsApi) Disable(ctx context.Context, params *SkillsDisableRequest) (
if err != nil {
return nil, err
}
- var result SkillsDisableResult
+ var result SessionSkillsDisableResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// Enable calls session.skills.enable.
+// Enables a skill for the session.
//
// RPC method: session.skills.enable.
-func (a *SkillsApi) Enable(ctx context.Context, params *SkillsEnableRequest) (*SkillsEnableResult, error) {
+//
+// Parameters: Name of the skill to enable for the session.
+func (a *SkillsApi) Enable(ctx context.Context, params *SkillsEnableRequest) (*SessionSkillsEnableResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["name"] = params.Name
@@ -3792,16 +4285,18 @@ func (a *SkillsApi) Enable(ctx context.Context, params *SkillsEnableRequest) (*S
if err != nil {
return nil, err
}
- var result SkillsEnableResult
+ var result SessionSkillsEnableResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// List calls session.skills.list.
+// Lists skills available to the session.
//
// RPC method: session.skills.list.
+//
+// Returns: Skills available to the session, with their enabled state.
func (a *SkillsApi) List(ctx context.Context) (*SkillList, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.skills.list", req)
@@ -3815,9 +4310,12 @@ func (a *SkillsApi) List(ctx context.Context) (*SkillList, error) {
return &result, nil
}
-// Reload calls session.skills.reload.
+// Reloads skill definitions for the session.
//
// RPC method: session.skills.reload.
+//
+// Returns: Diagnostics from reloading skill definitions, with warnings and errors as
+// separate lists.
func (a *SkillsApi) Reload(ctx context.Context) (*SkillsLoadDiagnostics, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.skills.reload", req)
@@ -3834,9 +4332,13 @@ func (a *SkillsApi) Reload(ctx context.Context) (*SkillsLoadDiagnostics, error)
// Experimental: TasksApi contains experimental APIs that may change or be removed.
type TasksApi sessionApi
-// Cancel calls session.tasks.cancel.
+// Cancels a background task.
//
// RPC method: session.tasks.cancel.
+//
+// Parameters: Identifier of the background task to cancel.
+//
+// Returns: Indicates whether the background task was successfully cancelled.
func (a *TasksApi) Cancel(ctx context.Context, params *TasksCancelRequest) (*TasksCancelResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3853,9 +4355,11 @@ func (a *TasksApi) Cancel(ctx context.Context, params *TasksCancelRequest) (*Tas
return &result, nil
}
-// List calls session.tasks.list.
+// Lists background tasks tracked by the session.
//
// RPC method: session.tasks.list.
+//
+// Returns: Background tasks currently tracked by the session.
func (a *TasksApi) List(ctx context.Context) (*TaskList, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.tasks.list", req)
@@ -3869,9 +4373,14 @@ func (a *TasksApi) List(ctx context.Context) (*TaskList, error) {
return &result, nil
}
-// PromoteToBackground calls session.tasks.promoteToBackground.
+// PromoteToBackground promotes an eligible synchronously-waited task so it continues
+// running in the background.
//
// RPC method: session.tasks.promoteToBackground.
+//
+// Parameters: Identifier of the task to promote to background mode.
+//
+// Returns: Indicates whether the task was successfully promoted to background mode.
func (a *TasksApi) PromoteToBackground(ctx context.Context, params *TasksPromoteToBackgroundRequest) (*TasksPromoteToBackgroundResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3888,9 +4397,14 @@ func (a *TasksApi) PromoteToBackground(ctx context.Context, params *TasksPromote
return &result, nil
}
-// Remove calls session.tasks.remove.
+// Removes a completed or cancelled background task from tracking.
//
// RPC method: session.tasks.remove.
+//
+// Parameters: Identifier of the completed or cancelled task to remove from tracking.
+//
+// Returns: Indicates whether the task was removed. False when the task does not exist or is
+// still running/idle.
func (a *TasksApi) Remove(ctx context.Context, params *TasksRemoveRequest) (*TasksRemoveResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3907,9 +4421,15 @@ func (a *TasksApi) Remove(ctx context.Context, params *TasksRemoveRequest) (*Tas
return &result, nil
}
-// SendMessage calls session.tasks.sendMessage.
+// SendMessage sends a message to a background agent task.
//
// RPC method: session.tasks.sendMessage.
+//
+// Parameters: Identifier of the target agent task, message content, and optional sender
+// agent ID.
+//
+// Returns: Indicates whether the message was delivered, with an error message when delivery
+// failed.
func (a *TasksApi) SendMessage(ctx context.Context, params *TasksSendMessageRequest) (*TasksSendMessageResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3930,9 +4450,14 @@ func (a *TasksApi) SendMessage(ctx context.Context, params *TasksSendMessageRequ
return &result, nil
}
-// StartAgent calls session.tasks.startAgent.
+// StartAgent starts a background agent task in the session.
//
// RPC method: session.tasks.startAgent.
+//
+// Parameters: Agent type, prompt, name, and optional description and model override for the
+// new task.
+//
+// Returns: Identifier assigned to the newly started background agent task.
func (a *TasksApi) StartAgent(ctx context.Context, params *TasksStartAgentRequest) (*TasksStartAgentResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3959,9 +4484,14 @@ func (a *TasksApi) StartAgent(ctx context.Context, params *TasksStartAgentReques
type ToolsApi sessionApi
-// HandlePendingToolCall calls session.tools.handlePendingToolCall.
+// HandlePendingToolCall provides the result for a pending external tool call.
//
// RPC method: session.tools.handlePendingToolCall.
+//
+// Parameters: Pending external tool call request ID, with the tool result or an error
+// describing why it failed.
+//
+// Returns: Indicates whether the external tool call result was handled successfully.
func (a *ToolsApi) HandlePendingToolCall(ctx context.Context, params *HandlePendingToolCallRequest) (*HandlePendingToolCallResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -3986,10 +4516,13 @@ func (a *ToolsApi) HandlePendingToolCall(ctx context.Context, params *HandlePend
type UIApi sessionApi
-// Elicitation calls session.ui.elicitation.
+// Elicitation requests structured input from a UI-capable client.
//
// RPC method: session.ui.elicitation.
//
+// Parameters: Prompt message and JSON schema describing the form fields to elicit from the
+// user.
+//
// Returns: The elicitation response (accept with form values, decline, or cancel)
func (a *UIApi) Elicitation(ctx context.Context, params *UIElicitationRequest) (*UIElicitationResponse, error) {
req := map[string]any{"sessionId": a.sessionID}
@@ -4008,9 +4541,15 @@ func (a *UIApi) Elicitation(ctx context.Context, params *UIElicitationRequest) (
return &result, nil
}
-// HandlePendingElicitation calls session.ui.handlePendingElicitation.
+// HandlePendingElicitation provides the user response for a pending elicitation request.
//
// RPC method: session.ui.handlePendingElicitation.
+//
+// Parameters: Pending elicitation request ID and the user's response (accept/decline/cancel
+// + form values).
+//
+// Returns: Indicates whether the elicitation response was accepted; false if it was already
+// resolved by another client.
func (a *UIApi) HandlePendingElicitation(ctx context.Context, params *UIHandlePendingElicitationRequest) (*UIElicitationResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -4031,9 +4570,12 @@ func (a *UIApi) HandlePendingElicitation(ctx context.Context, params *UIHandlePe
// Experimental: UsageApi contains experimental APIs that may change or be removed.
type UsageApi sessionApi
-// GetMetrics calls session.usage.getMetrics.
+// GetMetrics gets accumulated usage metrics for the session.
//
// RPC method: session.usage.getMetrics.
+//
+// Returns: Accumulated session usage metrics, including premium request cost, token counts,
+// model breakdown, and code-change totals.
func (a *UsageApi) GetMetrics(ctx context.Context) (*UsageGetMetricsResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.usage.getMetrics", req)
@@ -4049,10 +4591,12 @@ func (a *UsageApi) GetMetrics(ctx context.Context) (*UsageGetMetricsResult, erro
type WorkspacesApi sessionApi
-// CreateFile calls session.workspaces.createFile.
+// CreateFile creates or overwrites a file in the session workspace files directory.
//
// RPC method: session.workspaces.createFile.
-func (a *WorkspacesApi) CreateFile(ctx context.Context, params *WorkspacesCreateFileRequest) (*WorkspacesCreateFileResult, error) {
+//
+// Parameters: Relative path and UTF-8 content for the workspace file to create or overwrite.
+func (a *WorkspacesApi) CreateFile(ctx context.Context, params *WorkspacesCreateFileRequest) (*SessionWorkspacesCreateFileResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
req["content"] = params.Content
@@ -4062,16 +4606,18 @@ func (a *WorkspacesApi) CreateFile(ctx context.Context, params *WorkspacesCreate
if err != nil {
return nil, err
}
- var result WorkspacesCreateFileResult
+ var result SessionWorkspacesCreateFileResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
return &result, nil
}
-// GetWorkspace calls session.workspaces.getWorkspace.
+// GetWorkspace gets current workspace metadata for the session.
//
// RPC method: session.workspaces.getWorkspace.
+//
+// Returns: Current workspace metadata for the session, or null when not available.
func (a *WorkspacesApi) GetWorkspace(ctx context.Context) (*WorkspacesGetWorkspaceResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.workspaces.getWorkspace", req)
@@ -4085,9 +4631,11 @@ func (a *WorkspacesApi) GetWorkspace(ctx context.Context) (*WorkspacesGetWorkspa
return &result, nil
}
-// ListFiles calls session.workspaces.listFiles.
+// ListFiles lists files stored in the session workspace files directory.
//
// RPC method: session.workspaces.listFiles.
+//
+// Returns: Relative paths of files stored in the session workspace files directory.
func (a *WorkspacesApi) ListFiles(ctx context.Context) (*WorkspacesListFilesResult, error) {
req := map[string]any{"sessionId": a.sessionID}
raw, err := a.client.Request("session.workspaces.listFiles", req)
@@ -4101,9 +4649,13 @@ func (a *WorkspacesApi) ListFiles(ctx context.Context) (*WorkspacesListFilesResu
return &result, nil
}
-// ReadFile calls session.workspaces.readFile.
+// ReadFile reads a file from the session workspace files directory.
//
// RPC method: session.workspaces.readFile.
+//
+// Parameters: Relative path of the workspace file to read.
+//
+// Returns: Contents of the requested workspace file as a UTF-8 string.
func (a *WorkspacesApi) ReadFile(ctx context.Context, params *WorkspacesReadFileRequest) (*WorkspacesReadFileResult, error) {
req := map[string]any{"sessionId": a.sessionID}
if params != nil {
@@ -4149,9 +4701,14 @@ type SessionRpc struct {
Workspaces *WorkspacesApi
}
-// Log calls session.log.
+// Log emits a user-visible session log event.
//
// RPC method: session.log.
+//
+// Parameters: Message text, optional severity level, persistence flag, and optional
+// follow-up URL.
+//
+// Returns: Identifier of the session event that was emitted for the log message.
func (a *SessionRpc) Log(ctx context.Context, params *LogRequest) (*LogResult, error) {
req := map[string]any{"sessionId": a.common.sessionID}
if params != nil {
@@ -4177,16 +4734,16 @@ func (a *SessionRpc) Log(ctx context.Context, params *LogRequest) (*LogResult, e
return &result, nil
}
-// Suspend calls session.suspend.
+// Suspends the session while preserving persisted state for later resume.
//
// RPC method: session.suspend.
-func (a *SessionRpc) Suspend(ctx context.Context) (*SuspendResult, error) {
+func (a *SessionRpc) Suspend(ctx context.Context) (*SessionSuspendResult, error) {
req := map[string]any{"sessionId": a.common.sessionID}
raw, err := a.common.client.Request("session.suspend", req)
if err != nil {
return nil, err
}
- var result SuspendResult
+ var result SessionSuspendResult
if err := json.Unmarshal(raw, &result); err != nil {
return nil, err
}
@@ -4222,54 +4779,97 @@ func NewSessionRpc(client *jsonrpc2.Client, sessionID string) *SessionRpc {
}
type SessionFsHandler interface {
- // AppendFile handles sessionFs.appendFile.
+ // AppendFile appends content to a file in the client-provided session filesystem.
//
// RPC method: sessionFs.appendFile.
//
+ // Parameters: File path, content to append, and optional mode for the client-provided
+ // session filesystem.
+ //
// Returns: Describes a filesystem error.
AppendFile(request *SessionFsAppendFileRequest) (*SessionFsError, error)
- // Exists handles sessionFs.exists.
+ // Exists checks whether a path exists in the client-provided session filesystem.
//
// RPC method: sessionFs.exists.
+ //
+ // Parameters: Path to test for existence in the client-provided session filesystem.
+ //
+ // Returns: Indicates whether the requested path exists in the client-provided session
+ // filesystem.
Exists(request *SessionFsExistsRequest) (*SessionFsExistsResult, error)
- // Mkdir handles sessionFs.mkdir.
+ // Mkdir creates a directory in the client-provided session filesystem.
//
// RPC method: sessionFs.mkdir.
//
+ // Parameters: Directory path to create in the client-provided session filesystem, with
+ // options for recursive creation and POSIX mode.
+ //
// Returns: Describes a filesystem error.
Mkdir(request *SessionFsMkdirRequest) (*SessionFsError, error)
- // Readdir handles sessionFs.readdir.
+ // Readdir lists entry names in a directory from the client-provided session filesystem.
//
// RPC method: sessionFs.readdir.
+ //
+ // Parameters: Directory path whose entries should be listed from the client-provided
+ // session filesystem.
+ //
+ // Returns: Names of entries in the requested directory, or a filesystem error if the read
+ // failed.
Readdir(request *SessionFsReaddirRequest) (*SessionFsReaddirResult, error)
- // ReaddirWithTypes handles sessionFs.readdirWithTypes.
+ // ReaddirWithTypes lists directory entries with type information from the client-provided
+ // session filesystem.
//
// RPC method: sessionFs.readdirWithTypes.
+ //
+ // Parameters: Directory path whose entries (with type information) should be listed from
+ // the client-provided session filesystem.
+ //
+ // Returns: Entries in the requested directory paired with file/directory type information,
+ // or a filesystem error if the read failed.
ReaddirWithTypes(request *SessionFsReaddirWithTypesRequest) (*SessionFsReaddirWithTypesResult, error)
- // ReadFile handles sessionFs.readFile.
+ // ReadFile reads a file from the client-provided session filesystem.
//
// RPC method: sessionFs.readFile.
+ //
+ // Parameters: Path of the file to read from the client-provided session filesystem.
+ //
+ // Returns: File content as a UTF-8 string, or a filesystem error if the read failed.
ReadFile(request *SessionFsReadFileRequest) (*SessionFsReadFileResult, error)
- // Rename handles sessionFs.rename.
+ // Renames or moves a path in the client-provided session filesystem.
//
// RPC method: sessionFs.rename.
//
+ // Parameters: Source and destination paths for renaming or moving an entry in the
+ // client-provided session filesystem.
+ //
// Returns: Describes a filesystem error.
Rename(request *SessionFsRenameRequest) (*SessionFsError, error)
- // Rm handles sessionFs.rm.
+ // Rm removes a file or directory from the client-provided session filesystem.
//
// RPC method: sessionFs.rm.
//
+ // Parameters: Path to remove from the client-provided session filesystem, with options for
+ // recursive removal and force.
+ //
// Returns: Describes a filesystem error.
Rm(request *SessionFsRmRequest) (*SessionFsError, error)
- // Stat handles sessionFs.stat.
+ // Stat gets metadata for a path in the client-provided session filesystem.
//
// RPC method: sessionFs.stat.
+ //
+ // Parameters: Path whose metadata should be returned from the client-provided session
+ // filesystem.
+ //
+ // Returns: Filesystem metadata for the requested path, or a filesystem error if the stat
+ // failed.
Stat(request *SessionFsStatRequest) (*SessionFsStatResult, error)
- // WriteFile handles sessionFs.writeFile.
+ // WriteFile writes a file in the client-provided session filesystem.
//
// RPC method: sessionFs.writeFile.
//
+ // Parameters: File path, content to write, and optional mode for the client-provided
+ // session filesystem.
+ //
// Returns: Describes a filesystem error.
WriteFile(request *SessionFsWriteFileRequest) (*SessionFsError, error)
}
diff --git a/go/rpc/zsession_events.go b/go/rpc/zsession_events.go
index f9a38fdbc..265c2a772 100644
--- a/go/rpc/zsession_events.go
+++ b/go/rpc/zsession_events.go
@@ -552,7 +552,7 @@ type AssistantUsageData struct {
ProviderCallID *string `json:"providerCallId,omitempty"`
// Per-quota resource usage snapshots, keyed by quota identifier
QuotaSnapshots map[string]AssistantUsageQuotaSnapshot `json:"quotaSnapshots,omitempty"`
- // Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh")
+ // Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh")
ReasoningEffort *string `json:"reasoningEffort,omitempty"`
// Number of output tokens used for reasoning (e.g., chain-of-thought)
ReasoningTokens *float64 `json:"reasoningTokens,omitempty"`
@@ -582,16 +582,20 @@ type SessionModelChangeData struct {
PreviousModel *string `json:"previousModel,omitempty"`
// Reasoning effort level before the model change, if applicable
PreviousReasoningEffort *string `json:"previousReasoningEffort,omitempty"`
+ // Reasoning summary mode before the model change, if applicable
+ PreviousReasoningSummary *ReasoningSummary `json:"previousReasoningSummary,omitempty"`
// Reasoning effort level after the model change, if applicable
ReasoningEffort *string `json:"reasoningEffort,omitempty"`
+ // Reasoning summary mode after the model change, if applicable
+ ReasoningSummary *ReasoningSummary `json:"reasoningSummary,omitempty"`
}
func (*SessionModelChangeData) sessionEventData() {}
func (*SessionModelChangeData) Type() SessionEventType { return SessionEventTypeSessionModelChange }
-// Notifies Mission Control that the session's remote steering capability has changed
+// Notifies that the session's remote steering capability has changed
type SessionRemoteSteerableChangedData struct {
- // Whether this session now supports remote steering via Mission Control
+ // Whether this session now supports remote steering via GitHub
RemoteSteerable bool `json:"remoteSteerable"`
}
@@ -797,6 +801,8 @@ func (*SessionScheduleCancelledData) Type() SessionEventType {
// Scheduled prompt registered via /every or /after
type SessionScheduleCreatedData struct {
+ // Optional user-facing label shown in the timeline instead of the actual prompt (e.g. `/skill-name args` when the prompt is a skill invocation expansion)
+ DisplayPrompt *string `json:"displayPrompt,omitempty"`
// Sequential id assigned to the scheduled prompt within the session
ID int64 `json:"id"`
// Interval between ticks in milliseconds
@@ -812,6 +818,110 @@ func (*SessionScheduleCreatedData) Type() SessionEventType {
return SessionEventTypeSessionScheduleCreated
}
+// Schema for the `BackgroundTasksChangedData` type.
+type SessionBackgroundTasksChangedData struct {
+}
+
+func (*SessionBackgroundTasksChangedData) sessionEventData() {}
+func (*SessionBackgroundTasksChangedData) Type() SessionEventType {
+ return SessionEventTypeSessionBackgroundTasksChanged
+}
+
+// Schema for the `CustomAgentsUpdatedData` type.
+type SessionCustomAgentsUpdatedData struct {
+ // Array of loaded custom agent metadata
+ Agents []CustomAgentsUpdatedAgent `json:"agents"`
+ // Fatal errors from agent loading
+ Errors []string `json:"errors"`
+ // Non-fatal warnings from agent loading
+ Warnings []string `json:"warnings"`
+}
+
+func (*SessionCustomAgentsUpdatedData) sessionEventData() {}
+func (*SessionCustomAgentsUpdatedData) Type() SessionEventType {
+ return SessionEventTypeSessionCustomAgentsUpdated
+}
+
+// Schema for the `ExtensionsLoadedData` type.
+type SessionExtensionsLoadedData struct {
+ // Array of discovered extensions and their status
+ Extensions []ExtensionsLoadedExtension `json:"extensions"`
+}
+
+func (*SessionExtensionsLoadedData) sessionEventData() {}
+func (*SessionExtensionsLoadedData) Type() SessionEventType {
+ return SessionEventTypeSessionExtensionsLoaded
+}
+
+// Schema for the `McpServerStatusChangedData` type.
+type SessionMcpServerStatusChangedData struct {
+ // Name of the MCP server whose status changed
+ ServerName string `json:"serverName"`
+ // New connection status: connected, failed, needs-auth, pending, disabled, or not_configured
+ Status McpServerStatusChangedStatus `json:"status"`
+}
+
+func (*SessionMcpServerStatusChangedData) sessionEventData() {}
+func (*SessionMcpServerStatusChangedData) Type() SessionEventType {
+ return SessionEventTypeSessionMcpServerStatusChanged
+}
+
+// Schema for the `McpServersLoadedData` type.
+type SessionMcpServersLoadedData struct {
+ // Array of MCP server status summaries
+ Servers []McpServersLoadedServer `json:"servers"`
+}
+
+func (*SessionMcpServersLoadedData) sessionEventData() {}
+func (*SessionMcpServersLoadedData) Type() SessionEventType {
+ return SessionEventTypeSessionMcpServersLoaded
+}
+
+// Schema for the `SkillsLoadedData` type.
+type SessionSkillsLoadedData struct {
+ // Array of resolved skill metadata
+ Skills []SkillsLoadedSkill `json:"skills"`
+}
+
+func (*SessionSkillsLoadedData) sessionEventData() {}
+func (*SessionSkillsLoadedData) Type() SessionEventType { return SessionEventTypeSessionSkillsLoaded }
+
+// Schema for the `ToolsUpdatedData` type.
+type SessionToolsUpdatedData struct {
+ // Identifier of the model the resolved tools apply to.
+ Model string `json:"model"`
+}
+
+func (*SessionToolsUpdatedData) sessionEventData() {}
+func (*SessionToolsUpdatedData) Type() SessionEventType { return SessionEventTypeSessionToolsUpdated }
+
+// Schema for the `UserMessageData` type.
+type UserMessageData struct {
+ // The agent mode that was active when this message was sent
+ AgentMode *UserMessageAgentMode `json:"agentMode,omitempty"`
+ // Files, selections, or GitHub references attached to the message
+ Attachments []UserMessageAttachment `json:"attachments,omitempty"`
+ // The user's message text as displayed in the timeline
+ Content string `json:"content"`
+ // CAPI interaction ID for correlating this user message with its turn
+ InteractionID *string `json:"interactionId,omitempty"`
+ // True when this user message was auto-injected by autopilot's continuation loop rather than typed by the user; used to distinguish autopilot-driven turns in telemetry.
+ IsAutopilotContinuation *bool `json:"isAutopilotContinuation,omitempty"`
+ // Path-backed native document attachments that stayed on the tagged_files path flow because native upload would exceed the request size limit
+ NativeDocumentPathFallbackPaths []string `json:"nativeDocumentPathFallbackPaths,omitempty"`
+ // Parent agent task ID for background telemetry correlated to this user turn
+ ParentAgentTaskID *string `json:"parentAgentTaskId,omitempty"`
+ // Origin of this message, used for timeline filtering (e.g., "skill-pdf" for skill-injected messages that should be hidden from the user)
+ Source *string `json:"source,omitempty"`
+ // Normalized document MIME types that were sent natively instead of through tagged_files XML
+ SupportedNativeDocumentMIMETypes []string `json:"supportedNativeDocumentMimeTypes,omitempty"`
+ // Transformed version of the message sent to the model, with XML wrapping, timestamps, and other augmentations for prompt caching
+ TransformedContent *string `json:"transformedContent,omitempty"`
+}
+
+func (*UserMessageData) sessionEventData() {}
+func (*UserMessageData) Type() SessionEventType { return SessionEventTypeUserMessage }
+
// Session capability change notification
type CapabilitiesChangedData struct {
// UI capability changes
@@ -854,9 +964,11 @@ type SessionStartData struct {
DetachedFromSpawningParentSessionID *string `json:"detachedFromSpawningParentSessionId,omitempty"`
// Identifier of the software producing the events (e.g., "copilot-agent")
Producer string `json:"producer"`
- // Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh")
+ // Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh")
ReasoningEffort *string `json:"reasoningEffort,omitempty"`
- // Whether this session supports remote steering via Mission Control
+ // Reasoning summary mode used for model calls, if applicable (e.g. "none", "concise", "detailed")
+ ReasoningSummary *ReasoningSummary `json:"reasoningSummary,omitempty"`
+ // Whether this session supports remote steering via GitHub
RemoteSteerable *bool `json:"remoteSteerable,omitempty"`
// Model selected at session creation time, if any
SelectedModel *string `json:"selectedModel,omitempty"`
@@ -881,9 +993,11 @@ type SessionResumeData struct {
ContinuePendingWork *bool `json:"continuePendingWork,omitempty"`
// Total number of persisted events in the session at the time of resume
EventCount float64 `json:"eventCount"`
- // Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh")
+ // Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh")
ReasoningEffort *string `json:"reasoningEffort,omitempty"`
- // Whether this session supports remote steering via Mission Control
+ // Reasoning summary mode used for model calls, if applicable (e.g. "none", "concise", "detailed")
+ ReasoningSummary *ReasoningSummary `json:"reasoningSummary,omitempty"`
+ // Whether this session supports remote steering via GitHub
RemoteSteerable *bool `json:"remoteSteerable,omitempty"`
// ISO 8601 timestamp when the session was resumed
ResumeTime time.Time `json:"resumeTime"`
@@ -953,82 +1067,6 @@ type SessionTitleChangedData struct {
func (*SessionTitleChangedData) sessionEventData() {}
func (*SessionTitleChangedData) Type() SessionEventType { return SessionEventTypeSessionTitleChanged }
-// SessionBackgroundTasksChangedData holds the payload for session.background_tasks_changed events.
-type SessionBackgroundTasksChangedData struct {
-}
-
-func (*SessionBackgroundTasksChangedData) sessionEventData() {}
-func (*SessionBackgroundTasksChangedData) Type() SessionEventType {
- return SessionEventTypeSessionBackgroundTasksChanged
-}
-
-// SessionCustomAgentsUpdatedData holds the payload for session.custom_agents_updated events.
-type SessionCustomAgentsUpdatedData struct {
- // Array of loaded custom agent metadata
- Agents []CustomAgentsUpdatedAgent `json:"agents"`
- // Fatal errors from agent loading
- Errors []string `json:"errors"`
- // Non-fatal warnings from agent loading
- Warnings []string `json:"warnings"`
-}
-
-func (*SessionCustomAgentsUpdatedData) sessionEventData() {}
-func (*SessionCustomAgentsUpdatedData) Type() SessionEventType {
- return SessionEventTypeSessionCustomAgentsUpdated
-}
-
-// SessionExtensionsLoadedData holds the payload for session.extensions_loaded events.
-type SessionExtensionsLoadedData struct {
- // Array of discovered extensions and their status
- Extensions []ExtensionsLoadedExtension `json:"extensions"`
-}
-
-func (*SessionExtensionsLoadedData) sessionEventData() {}
-func (*SessionExtensionsLoadedData) Type() SessionEventType {
- return SessionEventTypeSessionExtensionsLoaded
-}
-
-// SessionMcpServerStatusChangedData holds the payload for session.mcp_server_status_changed events.
-type SessionMcpServerStatusChangedData struct {
- // Name of the MCP server whose status changed
- ServerName string `json:"serverName"`
- // New connection status: connected, failed, needs-auth, pending, disabled, or not_configured
- Status McpServerStatusChangedStatus `json:"status"`
-}
-
-func (*SessionMcpServerStatusChangedData) sessionEventData() {}
-func (*SessionMcpServerStatusChangedData) Type() SessionEventType {
- return SessionEventTypeSessionMcpServerStatusChanged
-}
-
-// SessionMcpServersLoadedData holds the payload for session.mcp_servers_loaded events.
-type SessionMcpServersLoadedData struct {
- // Array of MCP server status summaries
- Servers []McpServersLoadedServer `json:"servers"`
-}
-
-func (*SessionMcpServersLoadedData) sessionEventData() {}
-func (*SessionMcpServersLoadedData) Type() SessionEventType {
- return SessionEventTypeSessionMcpServersLoaded
-}
-
-// SessionSkillsLoadedData holds the payload for session.skills_loaded events.
-type SessionSkillsLoadedData struct {
- // Array of resolved skill metadata
- Skills []SkillsLoadedSkill `json:"skills"`
-}
-
-func (*SessionSkillsLoadedData) sessionEventData() {}
-func (*SessionSkillsLoadedData) Type() SessionEventType { return SessionEventTypeSessionSkillsLoaded }
-
-// SessionToolsUpdatedData holds the payload for session.tools_updated events.
-type SessionToolsUpdatedData struct {
- Model string `json:"model"`
-}
-
-func (*SessionToolsUpdatedData) sessionEventData() {}
-func (*SessionToolsUpdatedData) Type() SessionEventType { return SessionEventTypeSessionToolsUpdated }
-
// Skill invocation details including content, allowed tools, and plugin metadata
type SkillInvokedData struct {
// Tool names that should be auto-approved when this skill is active
@@ -1351,33 +1389,6 @@ type ToolUserRequestedData struct {
func (*ToolUserRequestedData) sessionEventData() {}
func (*ToolUserRequestedData) Type() SessionEventType { return SessionEventTypeToolUserRequested }
-// UserMessageData holds the payload for user.message events.
-type UserMessageData struct {
- // The agent mode that was active when this message was sent
- AgentMode *UserMessageAgentMode `json:"agentMode,omitempty"`
- // Files, selections, or GitHub references attached to the message
- Attachments []UserMessageAttachment `json:"attachments,omitempty"`
- // The user's message text as displayed in the timeline
- Content string `json:"content"`
- // CAPI interaction ID for correlating this user message with its turn
- InteractionID *string `json:"interactionId,omitempty"`
- // True when this user message was auto-injected by autopilot's continuation loop rather than typed by the user; used to distinguish autopilot-driven turns in telemetry.
- IsAutopilotContinuation *bool `json:"isAutopilotContinuation,omitempty"`
- // Path-backed native document attachments that stayed on the tagged_files path flow because native upload would exceed the request size limit
- NativeDocumentPathFallbackPaths []string `json:"nativeDocumentPathFallbackPaths,omitempty"`
- // Parent agent task ID for background telemetry correlated to this user turn
- ParentAgentTaskID *string `json:"parentAgentTaskId,omitempty"`
- // Origin of this message, used for timeline filtering (e.g., "skill-pdf" for skill-injected messages that should be hidden from the user)
- Source *string `json:"source,omitempty"`
- // Normalized document MIME types that were sent natively instead of through tagged_files XML
- SupportedNativeDocumentMIMETypes []string `json:"supportedNativeDocumentMimeTypes,omitempty"`
- // Transformed version of the message sent to the model, with XML wrapping, timestamps, and other augmentations for prompt caching
- TransformedContent *string `json:"transformedContent,omitempty"`
-}
-
-func (*UserMessageData) sessionEventData() {}
-func (*UserMessageData) Type() SessionEventType { return SessionEventTypeUserMessage }
-
// Warning message for timeline display with categorization
type SessionWarningData struct {
// Human-readable warning message for display in the timeline
@@ -1469,6 +1480,7 @@ type AssistantUsageCopilotUsageTokenDetail struct {
TokenType string `json:"tokenType"`
}
+// Schema for the `AssistantUsageQuotaSnapshot` type.
type AssistantUsageQuotaSnapshot struct {
// Total requests allowed by the entitlement
EntitlementRequests float64 `json:"entitlementRequests"`
@@ -1494,9 +1506,12 @@ type CapabilitiesChangedUI struct {
Elicitation *bool `json:"elicitation,omitempty"`
}
+// Schema for the `CommandsChangedCommand` type.
type CommandsChangedCommand struct {
+ // Optional human-readable command description.
Description *string `json:"description,omitempty"`
- Name string `json:"name"`
+ // Slash command name without the leading slash.
+ Name string `json:"name"`
}
// Token usage breakdown for the compaction LLM call (aligned with assistant.usage format)
@@ -1537,6 +1552,7 @@ type CompactionCompleteCompactionTokensUsedCopilotUsageTokenDetail struct {
TokenType string `json:"tokenType"`
}
+// Schema for the `CustomAgentsUpdatedAgent` type.
type CustomAgentsUpdatedAgent struct {
// Description of what the agent does
Description string `json:"description"`
@@ -1565,6 +1581,7 @@ type CustomNotificationPayload struct {
String *string
}
+// Schema for the `ElicitationCompletedContent` type.
type ElicitationCompletedContent interface {
elicitationCompletedContent()
}
@@ -1595,6 +1612,7 @@ type ElicitationRequestedSchema struct {
Type ElicitationRequestedSchemaType `json:"type"`
}
+// Schema for the `ExtensionsLoadedExtension` type.
type ExtensionsLoadedExtension struct {
// Source-qualified extension ID (e.g., 'project:my-ext', 'user:auth-helper')
ID string `json:"id"`
@@ -1634,6 +1652,7 @@ type McpOauthRequiredStaticClientConfig struct {
PublicClient *bool `json:"publicClient,omitempty"`
}
+// Schema for the `McpServersLoadedServer` type.
type McpServersLoadedServer struct {
// Error message if the server failed to connect
Error *string `json:"error,omitempty"`
@@ -2056,6 +2075,7 @@ func (PermissionRequestWrite) Kind() PermissionRequestKind {
return PermissionRequestKindWrite
}
+// Schema for the `PermissionRequestShellCommand` type.
type PermissionRequestShellCommand struct {
// Command identifier (e.g., executable name)
Identifier string `json:"identifier"`
@@ -2063,6 +2083,7 @@ type PermissionRequestShellCommand struct {
ReadOnly bool `json:"readOnly"`
}
+// Schema for the `PermissionRequestShellPossibleUrl` type.
type PermissionRequestShellPossibleURL struct {
// URL that may be accessed by the command
URL string `json:"url"`
@@ -2084,6 +2105,7 @@ func (r RawPermissionResult) Kind() PermissionResultKind {
return r.Discriminator
}
+// Schema for the `PermissionApproved` type.
type PermissionApproved struct {
}
@@ -2092,6 +2114,7 @@ func (PermissionApproved) Kind() PermissionResultKind {
return PermissionResultKindApproved
}
+// Schema for the `PermissionApprovedForLocation` type.
type PermissionApprovedForLocation struct {
// The approval to persist for this location
Approval UserToolSessionApproval `json:"approval"`
@@ -2104,6 +2127,7 @@ func (PermissionApprovedForLocation) Kind() PermissionResultKind {
return PermissionResultKindApprovedForLocation
}
+// Schema for the `PermissionApprovedForSession` type.
type PermissionApprovedForSession struct {
// The approval to add as a session-scoped rule
Approval UserToolSessionApproval `json:"approval"`
@@ -2114,6 +2138,7 @@ func (PermissionApprovedForSession) Kind() PermissionResultKind {
return PermissionResultKindApprovedForSession
}
+// Schema for the `PermissionCancelled` type.
type PermissionCancelled struct {
// Optional explanation of why the request was cancelled
Reason *string `json:"reason,omitempty"`
@@ -2124,6 +2149,7 @@ func (PermissionCancelled) Kind() PermissionResultKind {
return PermissionResultKindCancelled
}
+// Schema for the `PermissionDeniedByContentExclusionPolicy` type.
type PermissionDeniedByContentExclusionPolicy struct {
// Human-readable explanation of why the path was excluded
Message string `json:"message"`
@@ -2136,6 +2162,7 @@ func (PermissionDeniedByContentExclusionPolicy) Kind() PermissionResultKind {
return PermissionResultKindDeniedByContentExclusionPolicy
}
+// Schema for the `PermissionDeniedByPermissionRequestHook` type.
type PermissionDeniedByPermissionRequestHook struct {
// Whether to interrupt the current agent turn
Interrupt *bool `json:"interrupt,omitempty"`
@@ -2148,6 +2175,7 @@ func (PermissionDeniedByPermissionRequestHook) Kind() PermissionResultKind {
return PermissionResultKindDeniedByPermissionRequestHook
}
+// Schema for the `PermissionDeniedByRules` type.
type PermissionDeniedByRules struct {
// Rules that denied the request
Rules []PermissionRule `json:"rules"`
@@ -2158,6 +2186,7 @@ func (PermissionDeniedByRules) Kind() PermissionResultKind {
return PermissionResultKindDeniedByRules
}
+// Schema for the `PermissionDeniedInteractivelyByUser` type.
type PermissionDeniedInteractivelyByUser struct {
// Optional feedback from the user explaining the denial
Feedback *string `json:"feedback,omitempty"`
@@ -2170,6 +2199,7 @@ func (PermissionDeniedInteractivelyByUser) Kind() PermissionResultKind {
return PermissionResultKindDeniedInteractivelyByUser
}
+// Schema for the `PermissionDeniedNoApprovalRuleAndCouldNotRequestFromUser` type.
type PermissionDeniedNoApprovalRuleAndCouldNotRequestFromUser struct {
}
@@ -2178,6 +2208,7 @@ func (PermissionDeniedNoApprovalRuleAndCouldNotRequestFromUser) Kind() Permissio
return PermissionResultKindDeniedNoApprovalRuleAndCouldNotRequestFromUser
}
+// Schema for the `PermissionRule` type.
type PermissionRule struct {
// Optional rule argument matched against the request
Argument *string `json:"argument"`
@@ -2195,6 +2226,7 @@ type ShutdownCodeChanges struct {
LinesRemoved float64 `json:"linesRemoved"`
}
+// Schema for the `ShutdownModelMetric` type.
type ShutdownModelMetric struct {
// Request count and cost metrics
Requests ShutdownModelMetricRequests `json:"requests"`
@@ -2214,6 +2246,7 @@ type ShutdownModelMetricRequests struct {
Count float64 `json:"count"`
}
+// Schema for the `ShutdownModelMetricTokenDetail` type.
type ShutdownModelMetricTokenDetail struct {
// Accumulated token count for this token type
TokenCount float64 `json:"tokenCount"`
@@ -2233,11 +2266,13 @@ type ShutdownModelMetricUsage struct {
ReasoningTokens *float64 `json:"reasoningTokens,omitempty"`
}
+// Schema for the `ShutdownTokenDetail` type.
type ShutdownTokenDetail struct {
// Accumulated token count for this token type
TokenCount float64 `json:"tokenCount"`
}
+// Schema for the `SkillsLoadedSkill` type.
type SkillsLoadedSkill struct {
// Description of what the skill does
Description string `json:"description"`
@@ -2277,6 +2312,7 @@ func (r RawSystemNotification) Type() SystemNotificationType {
return r.Discriminator
}
+// Schema for the `SystemNotificationAgentCompleted` type.
type SystemNotificationAgentCompleted struct {
// Unique identifier of the background agent
AgentID string `json:"agentId"`
@@ -2295,6 +2331,7 @@ func (SystemNotificationAgentCompleted) Type() SystemNotificationType {
return SystemNotificationTypeAgentCompleted
}
+// Schema for the `SystemNotificationAgentIdle` type.
type SystemNotificationAgentIdle struct {
// Unique identifier of the background agent
AgentID string `json:"agentId"`
@@ -2309,6 +2346,7 @@ func (SystemNotificationAgentIdle) Type() SystemNotificationType {
return SystemNotificationTypeAgentIdle
}
+// Schema for the `SystemNotificationInstructionDiscovered` type.
type SystemNotificationInstructionDiscovered struct {
// Human-readable label for the timeline (e.g., 'AGENTS.md from packages/billing/')
Description *string `json:"description,omitempty"`
@@ -2325,6 +2363,7 @@ func (SystemNotificationInstructionDiscovered) Type() SystemNotificationType {
return SystemNotificationTypeInstructionDiscovered
}
+// Schema for the `SystemNotificationNewInboxMessage` type.
type SystemNotificationNewInboxMessage struct {
// Unique identifier of the inbox entry
EntryID string `json:"entryId"`
@@ -2341,6 +2380,7 @@ func (SystemNotificationNewInboxMessage) Type() SystemNotificationType {
return SystemNotificationTypeNewInboxMessage
}
+// Schema for the `SystemNotificationShellCompleted` type.
type SystemNotificationShellCompleted struct {
// Human-readable description of the command
Description *string `json:"description,omitempty"`
@@ -2355,6 +2395,7 @@ func (SystemNotificationShellCompleted) Type() SystemNotificationType {
return SystemNotificationTypeShellCompleted
}
+// Schema for the `SystemNotificationShellDetachedCompleted` type.
type SystemNotificationShellDetachedCompleted struct {
// Human-readable description of the command
Description *string `json:"description,omitempty"`
@@ -2648,6 +2689,7 @@ func (r RawUserToolSessionApproval) Kind() UserToolSessionApprovalKind {
return r.Discriminator
}
+// Schema for the `UserToolSessionApprovalCommands` type.
type UserToolSessionApprovalCommands struct {
// Command identifiers approved by the user
CommandIdentifiers []string `json:"commandIdentifiers"`
@@ -2658,6 +2700,7 @@ func (UserToolSessionApprovalCommands) Kind() UserToolSessionApprovalKind {
return UserToolSessionApprovalKindCommands
}
+// Schema for the `UserToolSessionApprovalCustomTool` type.
type UserToolSessionApprovalCustomTool struct {
// Custom tool name
ToolName string `json:"toolName"`
@@ -2668,6 +2711,7 @@ func (UserToolSessionApprovalCustomTool) Kind() UserToolSessionApprovalKind {
return UserToolSessionApprovalKindCustomTool
}
+// Schema for the `UserToolSessionApprovalExtensionManagement` type.
type UserToolSessionApprovalExtensionManagement struct {
// Optional operation identifier
Operation *string `json:"operation,omitempty"`
@@ -2678,6 +2722,7 @@ func (UserToolSessionApprovalExtensionManagement) Kind() UserToolSessionApproval
return UserToolSessionApprovalKindExtensionManagement
}
+// Schema for the `UserToolSessionApprovalExtensionPermissionAccess` type.
type UserToolSessionApprovalExtensionPermissionAccess struct {
// Extension name
ExtensionName string `json:"extensionName"`
@@ -2688,6 +2733,7 @@ func (UserToolSessionApprovalExtensionPermissionAccess) Kind() UserToolSessionAp
return UserToolSessionApprovalKindExtensionPermissionAccess
}
+// Schema for the `UserToolSessionApprovalMcp` type.
type UserToolSessionApprovalMcp struct {
// MCP server name
ServerName string `json:"serverName"`
@@ -2700,6 +2746,7 @@ func (UserToolSessionApprovalMcp) Kind() UserToolSessionApprovalKind {
return UserToolSessionApprovalKindMcp
}
+// Schema for the `UserToolSessionApprovalMemory` type.
type UserToolSessionApprovalMemory struct {
}
@@ -2708,6 +2755,7 @@ func (UserToolSessionApprovalMemory) Kind() UserToolSessionApprovalKind {
return UserToolSessionApprovalKindMemory
}
+// Schema for the `UserToolSessionApprovalRead` type.
type UserToolSessionApprovalRead struct {
}
@@ -2716,6 +2764,7 @@ func (UserToolSessionApprovalRead) Kind() UserToolSessionApprovalKind {
return UserToolSessionApprovalKindRead
}
+// Schema for the `UserToolSessionApprovalWrite` type.
type UserToolSessionApprovalWrite struct {
}
diff --git a/go/zsession_events.go b/go/zsession_events.go
index f871aa483..170b58c93 100644
--- a/go/zsession_events.go
+++ b/go/zsession_events.go
@@ -133,6 +133,7 @@ type (
RawToolExecutionCompleteContent = rpc.RawToolExecutionCompleteContent
RawUserMessageAttachment = rpc.RawUserMessageAttachment
RawUserToolSessionApproval = rpc.RawUserToolSessionApproval
+ ReasoningSummary = rpc.ReasoningSummary
SamplingCompletedData = rpc.SamplingCompletedData
SamplingRequestedData = rpc.SamplingRequestedData
SessionBackgroundTasksChangedData = rpc.SessionBackgroundTasksChangedData
@@ -335,6 +336,9 @@ const (
PlanChangedOperationCreate = rpc.PlanChangedOperationCreate
PlanChangedOperationDelete = rpc.PlanChangedOperationDelete
PlanChangedOperationUpdate = rpc.PlanChangedOperationUpdate
+ ReasoningSummaryConcise = rpc.ReasoningSummaryConcise
+ ReasoningSummaryDetailed = rpc.ReasoningSummaryDetailed
+ ReasoningSummaryNone = rpc.ReasoningSummaryNone
SessionEventTypeAbort = rpc.SessionEventTypeAbort
SessionEventTypeAssistantIntent = rpc.SessionEventTypeAssistantIntent
SessionEventTypeAssistantMessage = rpc.SessionEventTypeAssistantMessage
diff --git a/nodejs/package-lock.json b/nodejs/package-lock.json
index 4822407aa..e41278612 100644
--- a/nodejs/package-lock.json
+++ b/nodejs/package-lock.json
@@ -9,7 +9,7 @@
"version": "0.1.8",
"license": "MIT",
"dependencies": {
- "@github/copilot": "^1.0.48",
+ "@github/copilot": "^1.0.49-0",
"vscode-jsonrpc": "^8.2.1",
"zod": "^4.3.6"
},
@@ -663,26 +663,26 @@
}
},
"node_modules/@github/copilot": {
- "version": "1.0.48",
- "resolved": "https://registry.npmjs.org/@github/copilot/-/copilot-1.0.48.tgz",
- "integrity": "sha512-U5SzyTEq376UU9A4Sd3TEKz+Y2nRUd90cLO4Hc1otaB8yFSy9Ur2UVGcI2/wCoodL3a39k6WbdgNzFxr0gWFRQ==",
+ "version": "1.0.49-0",
+ "resolved": "https://registry.npmjs.org/@github/copilot/-/copilot-1.0.49-0.tgz",
+ "integrity": "sha512-Q4YFB1pxk0LmvPBx3GNHgoYM1dqTraGoyt199+sOY8px6+MX/X7GGpuiX9BGt4GhRsH/V5ipjAOCwMIMaacTpA==",
"license": "SEE LICENSE IN LICENSE.md",
"bin": {
"copilot": "npm-loader.js"
},
"optionalDependencies": {
- "@github/copilot-darwin-arm64": "1.0.48",
- "@github/copilot-darwin-x64": "1.0.48",
- "@github/copilot-linux-arm64": "1.0.48",
- "@github/copilot-linux-x64": "1.0.48",
- "@github/copilot-win32-arm64": "1.0.48",
- "@github/copilot-win32-x64": "1.0.48"
+ "@github/copilot-darwin-arm64": "1.0.49-0",
+ "@github/copilot-darwin-x64": "1.0.49-0",
+ "@github/copilot-linux-arm64": "1.0.49-0",
+ "@github/copilot-linux-x64": "1.0.49-0",
+ "@github/copilot-win32-arm64": "1.0.49-0",
+ "@github/copilot-win32-x64": "1.0.49-0"
}
},
"node_modules/@github/copilot-darwin-arm64": {
- "version": "1.0.48",
- "resolved": "https://registry.npmjs.org/@github/copilot-darwin-arm64/-/copilot-darwin-arm64-1.0.48.tgz",
- "integrity": "sha512-82MLoMQwPVVFM8EYssihFxSEPUYtZADE8rMzQ3jG9HgRg2qjQSfnHQS1mKe64dlXswZUK/onw6/8kjnW5I4pPg==",
+ "version": "1.0.49-0",
+ "resolved": "https://registry.npmjs.org/@github/copilot-darwin-arm64/-/copilot-darwin-arm64-1.0.49-0.tgz",
+ "integrity": "sha512-+MN1THu9qZ6Hrs5n3sVhb02q8AKYM7cqy5vYK0ZOhFmhdntETYzGgisYmvEVRwl0vzkXVTT8QyiArEZcJUkyHA==",
"cpu": [
"arm64"
],
@@ -696,9 +696,9 @@
}
},
"node_modules/@github/copilot-darwin-x64": {
- "version": "1.0.48",
- "resolved": "https://registry.npmjs.org/@github/copilot-darwin-x64/-/copilot-darwin-x64-1.0.48.tgz",
- "integrity": "sha512-1VQ5r5F0h8GwboXmZTcutqcJT+iCpPXAF27QqodmpKEvW9aYfG8g9X2kFJOzDZoX+SA3Uaka9qXdYKF2xT6Uog==",
+ "version": "1.0.49-0",
+ "resolved": "https://registry.npmjs.org/@github/copilot-darwin-x64/-/copilot-darwin-x64-1.0.49-0.tgz",
+ "integrity": "sha512-wBO+yXFqAjWsCEGCuvgR8gCiyauh2Vv2NCrgxTp2K53UitKgjIHfYVfHwlGDB5zo+TeNUlGNvcRs4lICE0PBKg==",
"cpu": [
"x64"
],
@@ -712,9 +712,9 @@
}
},
"node_modules/@github/copilot-linux-arm64": {
- "version": "1.0.48",
- "resolved": "https://registry.npmjs.org/@github/copilot-linux-arm64/-/copilot-linux-arm64-1.0.48.tgz",
- "integrity": "sha512-PmsGnb0DZlI+Bf53l9HM1PAHHkUcMyB4y8v/7tnC/jDOV5dGF124n0HnDNfJLOLiJGiQGodthIif6QtPaAxpeA==",
+ "version": "1.0.49-0",
+ "resolved": "https://registry.npmjs.org/@github/copilot-linux-arm64/-/copilot-linux-arm64-1.0.49-0.tgz",
+ "integrity": "sha512-1WxdUgP1So25XKK4MTZvWGh4xhlrKCZG7pw0Qb1pkFpahVS/L9exSCeemGNEatrKaq97TbyIyhTziC1RgYATbg==",
"cpu": [
"arm64"
],
@@ -728,9 +728,9 @@
}
},
"node_modules/@github/copilot-linux-x64": {
- "version": "1.0.48",
- "resolved": "https://registry.npmjs.org/@github/copilot-linux-x64/-/copilot-linux-x64-1.0.48.tgz",
- "integrity": "sha512-b2cc4euSlke9fYHXXsS2EL9UYbctN0h4lZvtAcKUDY+RCnpYAQOVBZK+c1R9dQrtsT6Z/yUv7PuFPSs8qdtc2Q==",
+ "version": "1.0.49-0",
+ "resolved": "https://registry.npmjs.org/@github/copilot-linux-x64/-/copilot-linux-x64-1.0.49-0.tgz",
+ "integrity": "sha512-WMycMEEMUHz5Swfs8iEako6cioYOO3gt9nvFSs7I/dv4o8Wwwu3WwRQj3c3JQPtW0rN8PBwoV+INUVV+Zi334Q==",
"cpu": [
"x64"
],
@@ -744,9 +744,9 @@
}
},
"node_modules/@github/copilot-win32-arm64": {
- "version": "1.0.48",
- "resolved": "https://registry.npmjs.org/@github/copilot-win32-arm64/-/copilot-win32-arm64-1.0.48.tgz",
- "integrity": "sha512-VEEOwddtpJ3DTbXGhnK6K8im4ofl9m08q1m/K++sNvWV8wkkOSOQBTiPdyUsuU/TXAoFhb8tZMIJv+6NnMBtMw==",
+ "version": "1.0.49-0",
+ "resolved": "https://registry.npmjs.org/@github/copilot-win32-arm64/-/copilot-win32-arm64-1.0.49-0.tgz",
+ "integrity": "sha512-8T0kO+iv4bOynW05/Ac7HPqT6lIzW5WF2LvHp83zkdA+jpxxi8LtFmFDU/01//sq2lFO2AqtLAc6CnboP/O7kg==",
"cpu": [
"arm64"
],
@@ -760,9 +760,9 @@
}
},
"node_modules/@github/copilot-win32-x64": {
- "version": "1.0.48",
- "resolved": "https://registry.npmjs.org/@github/copilot-win32-x64/-/copilot-win32-x64-1.0.48.tgz",
- "integrity": "sha512-93BzvXLPHTyy1gWBXQY/IWIHor4IAwZuuo7/obG80/Qa6U0WeaN9slz/FBJvrsgVNrrRfEID5Xm3At+S6Kj67Q==",
+ "version": "1.0.49-0",
+ "resolved": "https://registry.npmjs.org/@github/copilot-win32-x64/-/copilot-win32-x64-1.0.49-0.tgz",
+ "integrity": "sha512-cBbneI9Qkjke9q09DaaCXlMKqOmT78EWHvom7jw00e3Xk9F2243aGXdUUSiBpDyHeDCgav5k8/voBFRVSgKcfw==",
"cpu": [
"x64"
],
diff --git a/nodejs/package.json b/nodejs/package.json
index ff90fbad7..7c76036cc 100644
--- a/nodejs/package.json
+++ b/nodejs/package.json
@@ -56,7 +56,7 @@
"author": "GitHub",
"license": "MIT",
"dependencies": {
- "@github/copilot": "^1.0.48",
+ "@github/copilot": "^1.0.49-0",
"vscode-jsonrpc": "^8.2.1",
"zod": "^4.3.6"
},
diff --git a/nodejs/samples/package-lock.json b/nodejs/samples/package-lock.json
index 4c968bfdd..12ec9c2d2 100644
--- a/nodejs/samples/package-lock.json
+++ b/nodejs/samples/package-lock.json
@@ -18,7 +18,7 @@
"version": "0.1.8",
"license": "MIT",
"dependencies": {
- "@github/copilot": "^1.0.48",
+ "@github/copilot": "^1.0.49-0",
"vscode-jsonrpc": "^8.2.1",
"zod": "^4.3.6"
},
diff --git a/nodejs/src/generated/rpc.ts b/nodejs/src/generated/rpc.ts
index b6cded9c2..293c70f50 100644
--- a/nodejs/src/generated/rpc.ts
+++ b/nodejs/src/generated/rpc.ts
@@ -5,7 +5,7 @@
import type { MessageConnection } from "vscode-jsonrpc/node.js";
-import type { EmbeddedBlobResourceContents, EmbeddedTextResourceContents } from "./session-events.js";
+import type { EmbeddedBlobResourceContents, EmbeddedTextResourceContents, ReasoningSummary } from "./session-events.js";
/**
* Authentication type
@@ -99,15 +99,30 @@ export type ExternalToolTextResultForLlmContentResourceLinkIconTheme = "light" |
export type ExternalToolTextResultForLlmContentResourceDetails =
| EmbeddedTextResourceContents
| EmbeddedBlobResourceContents;
-
+/**
+ * Content filtering mode to apply to all tools, or a map of tool name to content filtering mode.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "FilterMapping".
+ */
export type FilterMapping =
| {
[k: string]: FilterMappingValue;
}
| FilterMappingString;
-
+/**
+ * Allowed values for the `FilterMappingValue` enumeration.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "FilterMappingValue".
+ */
export type FilterMappingValue = "none" | "markdown" | "hidden_characters";
-
+/**
+ * Allowed values for the `FilterMappingString` enumeration.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "FilterMappingString".
+ */
export type FilterMappingString = "none" | "markdown" | "hidden_characters";
/**
* Category of instruction source — used for merge logic
@@ -137,7 +152,12 @@ export type SessionLogLevel = "info" | "warning" | "error";
* via the `definition` "McpServerConfig".
*/
export type McpServerConfig = McpServerConfigLocal | McpServerConfigHttp;
-
+/**
+ * Local transport type. Defaults to "local".
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpServerConfigLocalType".
+ */
export type McpServerConfigLocalType = "local" | "stdio";
/**
* Remote transport type. Defaults to "http" when omitted.
@@ -146,7 +166,12 @@ export type McpServerConfigLocalType = "local" | "stdio";
* via the `definition` "McpServerConfigHttpType".
*/
export type McpServerConfigHttpType = "http" | "sse";
-
+/**
+ * OAuth grant type to use when authenticating to the remote MCP server.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpServerConfigHttpOauthGrantType".
+ */
export type McpServerConfigHttpOauthGrantType = "authorization_code" | "client_credentials";
/**
* Connection status: connected, failed, needs-auth, pending, disabled, or not_configured
@@ -183,7 +208,12 @@ export type ModelPickerPriceCategory = "low" | "medium" | "high" | "very_high";
* via the `definition` "SessionMode".
*/
export type SessionMode = "interactive" | "plan" | "autopilot";
-
+/**
+ * Decision to apply to a pending permission request.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecision".
+ */
export type PermissionDecision =
| PermissionDecisionApproveOnce
| PermissionDecisionApproveForSession
@@ -224,7 +254,7 @@ export type PermissionDecisionApproveForLocationApproval =
| PermissionDecisionApproveForLocationApprovalExtensionManagement
| PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess;
/**
- * Per-session remote mode. "off" disables remote, "export" exports session events to Mission Control without enabling remote steering, "on" enables both export and remote steering.
+ * Per-session remote mode. "off" disables remote, "export" exports session events to GitHub without enabling remote steering, "on" enables both export and remote steering.
*
* This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
* via the `definition` "RemoteSessionMode".
@@ -265,7 +295,12 @@ export type ShellKillSignal = "SIGTERM" | "SIGKILL" | "SIGINT";
* via the `definition` "SlashCommandAgentPromptMode".
*/
export type SlashCommandAgentPromptMode = "interactive" | "plan" | "autopilot";
-
+/**
+ * Result of invoking the slash command (text output, prompt to send to the agent, or completion).
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SlashCommandInvocationResult".
+ */
export type SlashCommandInvocationResult =
| SlashCommandTextResult
| SlashCommandAgentPromptResult
@@ -284,7 +319,12 @@ export type TaskAgentInfoStatus = "running" | "idle" | "completed" | "failed" |
* via the `definition` "TaskAgentInfoExecutionMode".
*/
export type TaskAgentInfoExecutionMode = "sync" | "background";
-
+/**
+ * Schema for the `TaskInfo` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TaskInfo".
+ */
export type TaskInfo = TaskAgentInfo | TaskShellInfo;
/**
* Current lifecycle status of the task
@@ -307,9 +347,19 @@ export type TaskShellInfoAttachmentMode = "attached" | "detached";
* via the `definition` "TaskShellInfoExecutionMode".
*/
export type TaskShellInfoExecutionMode = "sync" | "background";
-
+/**
+ * Schema for the `UIElicitationFieldValue` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationFieldValue".
+ */
export type UIElicitationFieldValue = string | number | boolean | string[];
-
+/**
+ * Definition for a single elicitation form field.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationSchemaProperty".
+ */
export type UIElicitationSchemaProperty =
| UIElicitationStringEnumField
| UIElicitationStringOneOfField
@@ -318,9 +368,19 @@ export type UIElicitationSchemaProperty =
| UIElicitationSchemaPropertyBoolean
| UIElicitationSchemaPropertyString
| UIElicitationSchemaPropertyNumber;
-
+/**
+ * Optional format hint that constrains the accepted input.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationSchemaPropertyStringFormat".
+ */
export type UIElicitationSchemaPropertyStringFormat = "email" | "uri" | "date" | "date-time";
-
+/**
+ * Numeric type accepted by the field.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationSchemaPropertyNumberType".
+ */
export type UIElicitationSchemaPropertyNumberType = "number" | "integer";
/**
* The user's response: accept (submitted), decline (rejected), or cancel (dismissed)
@@ -336,7 +396,12 @@ export interface AccountGetQuotaRequest {
*/
gitHubToken?: string;
}
-
+/**
+ * Quota usage snapshots for the resolved user, keyed by quota type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AccountGetQuotaResult".
+ */
export interface AccountGetQuotaResult {
/**
* Quota snapshots keyed by type (e.g., chat, completions, premium_interactions)
@@ -345,7 +410,12 @@ export interface AccountGetQuotaResult {
[k: string]: AccountQuotaSnapshot;
};
}
-
+/**
+ * Schema for the `AccountQuotaSnapshot` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AccountQuotaSnapshot".
+ */
export interface AccountQuotaSnapshot {
/**
* Whether the user has an unlimited usage entitlement
@@ -380,7 +450,12 @@ export interface AccountQuotaSnapshot {
*/
resetDate?: string;
}
-
+/**
+ * The currently selected custom agent, or null when using the default agent.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AgentGetCurrentResult".
+ */
/** @experimental */
export interface AgentGetCurrentResult {
/**
@@ -388,7 +463,12 @@ export interface AgentGetCurrentResult {
*/
agent?: AgentInfo | null;
}
-
+/**
+ * Schema for the `AgentInfo` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AgentInfo".
+ */
export interface AgentInfo {
/**
* Unique identifier of the custom agent
@@ -407,7 +487,12 @@ export interface AgentInfo {
*/
path?: string;
}
-
+/**
+ * Custom agents available to the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AgentList".
+ */
/** @experimental */
export interface AgentList {
/**
@@ -415,7 +500,12 @@ export interface AgentList {
*/
agents: AgentInfo[];
}
-
+/**
+ * Custom agents available to the session after reloading definitions from disk.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AgentReloadResult".
+ */
/** @experimental */
export interface AgentReloadResult {
/**
@@ -423,7 +513,12 @@ export interface AgentReloadResult {
*/
agents: AgentInfo[];
}
-
+/**
+ * Name of the custom agent to select for subsequent turns.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AgentSelectRequest".
+ */
/** @experimental */
export interface AgentSelectRequest {
/**
@@ -431,19 +526,34 @@ export interface AgentSelectRequest {
*/
name: string;
}
-
+/**
+ * The newly selected custom agent.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "AgentSelectResult".
+ */
/** @experimental */
export interface AgentSelectResult {
agent: AgentInfo;
}
-
+/**
+ * Slash commands available in the session, after applying any include/exclude filters.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CommandList".
+ */
export interface CommandList {
/**
* Commands available in this session
*/
commands: SlashCommandInfo[];
}
-
+/**
+ * Schema for the `SlashCommandInfo` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SlashCommandInfo".
+ */
export interface SlashCommandInfo {
/**
* Canonical command name without a leading slash
@@ -489,7 +599,12 @@ export interface SlashCommandInput {
*/
preserveMultilineInput?: boolean;
}
-
+/**
+ * Pending command request ID and an optional error if the client handler failed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CommandsHandlePendingCommandRequest".
+ */
export interface CommandsHandlePendingCommandRequest {
/**
* Request ID from the command invocation event
@@ -500,14 +615,24 @@ export interface CommandsHandlePendingCommandRequest {
*/
error?: string;
}
-
+/**
+ * Indicates whether the pending client-handled command was completed successfully.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CommandsHandlePendingCommandResult".
+ */
export interface CommandsHandlePendingCommandResult {
/**
* Whether the command was handled successfully
*/
success: boolean;
}
-
+/**
+ * Slash command name and optional raw input string to invoke.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CommandsInvokeRequest".
+ */
export interface CommandsInvokeRequest {
/**
* Command name. Leading slashes are stripped and the name is matched case-insensitively.
@@ -518,7 +643,12 @@ export interface CommandsInvokeRequest {
*/
input?: string;
}
-
+/**
+ * Optional filters controlling which command sources to include in the listing.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CommandsListRequest".
+ */
export interface CommandsListRequest {
/**
* Include runtime built-in commands
@@ -533,7 +663,12 @@ export interface CommandsListRequest {
*/
includeClientCommands?: boolean;
}
-
+/**
+ * Queued command request ID and the result indicating whether the client handled it.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CommandsRespondToQueuedCommandRequest".
+ */
export interface CommandsRespondToQueuedCommandRequest {
/**
* Request ID from the queued command event
@@ -541,7 +676,12 @@ export interface CommandsRespondToQueuedCommandRequest {
requestId: string;
result: QueuedCommandResult;
}
-
+/**
+ * Schema for the `QueuedCommandHandled` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "QueuedCommandHandled".
+ */
export interface QueuedCommandHandled {
/**
* The command was handled
@@ -552,21 +692,36 @@ export interface QueuedCommandHandled {
*/
stopProcessingQueue?: boolean;
}
-
+/**
+ * Schema for the `QueuedCommandNotHandled` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "QueuedCommandNotHandled".
+ */
export interface QueuedCommandNotHandled {
/**
* The command was not handled
*/
handled: false;
}
-
+/**
+ * Indicates whether the queued-command response was accepted by the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CommandsRespondToQueuedCommandResult".
+ */
export interface CommandsRespondToQueuedCommandResult {
/**
* Whether the response was accepted (false if the requestId was not found or already resolved)
*/
success: boolean;
}
-
+/**
+ * Optional connection token presented by the SDK client during the handshake.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ConnectRequest".
+ */
/** @internal */
export interface ConnectRequest {
/**
@@ -574,7 +729,12 @@ export interface ConnectRequest {
*/
token?: string;
}
-
+/**
+ * Handshake result reporting the server's protocol version and package version on success.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ConnectResult".
+ */
/** @internal */
export interface ConnectResult {
/**
@@ -590,14 +750,24 @@ export interface ConnectResult {
*/
version: string;
}
-
+/**
+ * The currently selected model for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "CurrentModel".
+ */
export interface CurrentModel {
/**
* Currently active model identifier
*/
modelId?: string;
}
-
+/**
+ * Schema for the `DiscoveredMcpServer` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "DiscoveredMcpServer".
+ */
export interface DiscoveredMcpServer {
/**
* Server name (config key)
@@ -610,7 +780,12 @@ export interface DiscoveredMcpServer {
*/
enabled: boolean;
}
-
+/**
+ * Schema for the `Extension` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "Extension".
+ */
export interface Extension {
/**
* Source-qualified ID (e.g., 'project:my-ext', 'user:auth-helper')
@@ -627,7 +802,12 @@ export interface Extension {
*/
pid?: number;
}
-
+/**
+ * Extensions discovered for the session, with their current status.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ExtensionList".
+ */
/** @experimental */
export interface ExtensionList {
/**
@@ -635,7 +815,12 @@ export interface ExtensionList {
*/
extensions: Extension[];
}
-
+/**
+ * Source-qualified extension identifier to disable for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ExtensionsDisableRequest".
+ */
/** @experimental */
export interface ExtensionsDisableRequest {
/**
@@ -643,7 +828,12 @@ export interface ExtensionsDisableRequest {
*/
id: string;
}
-
+/**
+ * Source-qualified extension identifier to enable for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ExtensionsEnableRequest".
+ */
/** @experimental */
export interface ExtensionsEnableRequest {
/**
@@ -840,7 +1030,12 @@ export interface ExternalToolTextResultForLlmContentResource {
type: "resource";
resource: ExternalToolTextResultForLlmContentResourceDetails;
}
-
+/**
+ * Optional user prompt to combine with the fleet orchestration instructions.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "FleetStartRequest".
+ */
/** @experimental */
export interface FleetStartRequest {
/**
@@ -848,7 +1043,12 @@ export interface FleetStartRequest {
*/
prompt?: string;
}
-
+/**
+ * Indicates whether fleet mode was successfully activated.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "FleetStartResult".
+ */
/** @experimental */
export interface FleetStartResult {
/**
@@ -856,7 +1056,12 @@ export interface FleetStartResult {
*/
started: boolean;
}
-
+/**
+ * Pending external tool call request ID, with the tool result or an error describing why it failed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "HandlePendingToolCallRequest".
+ */
export interface HandlePendingToolCallRequest {
/**
* Request ID of the pending tool call
@@ -868,7 +1073,12 @@ export interface HandlePendingToolCallRequest {
*/
error?: string;
}
-
+/**
+ * Indicates whether the external tool call result was handled successfully.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "HandlePendingToolCallResult".
+ */
export interface HandlePendingToolCallResult {
/**
* Whether the tool call result was handled successfully
@@ -907,7 +1117,12 @@ export interface HistoryCompactContextWindow {
*/
toolDefinitionsTokens?: number;
}
-
+/**
+ * Compaction outcome with the number of tokens and messages removed and the resulting context window breakdown.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "HistoryCompactResult".
+ */
/** @experimental */
export interface HistoryCompactResult {
/**
@@ -924,7 +1139,12 @@ export interface HistoryCompactResult {
messagesRemoved: number;
contextWindow?: HistoryCompactContextWindow;
}
-
+/**
+ * Identifier of the event to truncate to; this event and all later events are removed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "HistoryTruncateRequest".
+ */
/** @experimental */
export interface HistoryTruncateRequest {
/**
@@ -932,7 +1152,12 @@ export interface HistoryTruncateRequest {
*/
eventId: string;
}
-
+/**
+ * Number of events that were removed by the truncation.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "HistoryTruncateResult".
+ */
/** @experimental */
export interface HistoryTruncateResult {
/**
@@ -940,14 +1165,24 @@ export interface HistoryTruncateResult {
*/
eventsRemoved: number;
}
-
+/**
+ * Instruction sources loaded for the session, in merge order.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "InstructionsGetSourcesResult".
+ */
export interface InstructionsGetSourcesResult {
/**
* Instruction sources for the session
*/
sources: InstructionsSources[];
}
-
+/**
+ * Schema for the `InstructionsSources` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "InstructionsSources".
+ */
export interface InstructionsSources {
/**
* Unique identifier for this source (used for toggling)
@@ -976,7 +1211,12 @@ export interface InstructionsSources {
*/
description?: string;
}
-
+/**
+ * Message text, optional severity level, persistence flag, and optional follow-up URL.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "LogRequest".
+ */
export interface LogRequest {
/**
* Human-readable message
@@ -992,14 +1232,24 @@ export interface LogRequest {
*/
url?: string;
}
-
+/**
+ * Identifier of the session event that was emitted for the log message.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "LogResult".
+ */
export interface LogResult {
/**
* The unique identifier of the emitted session event
*/
eventId: string;
}
-
+/**
+ * MCP server name and configuration to add to user configuration.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpConfigAddRequest".
+ */
export interface McpConfigAddRequest {
/**
* Unique name for the MCP server
@@ -1007,62 +1257,117 @@ export interface McpConfigAddRequest {
name: string;
config: McpServerConfig;
}
-
+/**
+ * Local MCP server configuration launched as a child process.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpServerConfigLocal".
+ */
export interface McpServerConfigLocal {
/**
* Tools to include. Defaults to all tools if not specified.
*/
tools?: string[];
type?: McpServerConfigLocalType;
- isDefaultServer?: boolean;
+ /**
+ * Whether this server is a built-in fallback used when the user has not configured their own server.
+ */
+ isDefaultServer?: boolean;
filterMapping?: FilterMapping;
/**
* Timeout in milliseconds for tool calls to this server.
*/
timeout?: number;
+ /**
+ * Executable command used to start the local MCP server process.
+ */
command: string;
+ /**
+ * Command-line arguments passed to the local MCP server process.
+ */
args: string[];
+ /**
+ * Working directory for the local MCP server process.
+ */
cwd?: string;
+ /**
+ * Environment variables to pass to the local MCP server process.
+ */
env?: {
[k: string]: string;
};
}
-
+/**
+ * Remote MCP server configuration accessed over HTTP or SSE.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpServerConfigHttp".
+ */
export interface McpServerConfigHttp {
/**
* Tools to include. Defaults to all tools if not specified.
*/
tools?: string[];
type?: McpServerConfigHttpType;
+ /**
+ * Whether this server is a built-in fallback used when the user has not configured their own server.
+ */
isDefaultServer?: boolean;
filterMapping?: FilterMapping;
/**
* Timeout in milliseconds for tool calls to this server.
*/
timeout?: number;
+ /**
+ * URL of the remote MCP server endpoint.
+ */
url: string;
+ /**
+ * HTTP headers to include in requests to the remote MCP server.
+ */
headers?: {
[k: string]: string;
};
+ /**
+ * OAuth client ID for a pre-registered remote MCP OAuth client.
+ */
oauthClientId?: string;
+ /**
+ * Whether the configured OAuth client is public and does not require a client secret.
+ */
oauthPublicClient?: boolean;
oauthGrantType?: McpServerConfigHttpOauthGrantType;
}
-
+/**
+ * MCP server names to disable for new sessions.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpConfigDisableRequest".
+ */
export interface McpConfigDisableRequest {
/**
* Names of MCP servers to disable. Each server is added to the persisted disabled list so new sessions skip it. Already-disabled names are ignored. Active sessions keep their current connections until they end.
*/
names: string[];
}
-
+/**
+ * MCP server names to enable for new sessions.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpConfigEnableRequest".
+ */
export interface McpConfigEnableRequest {
/**
* Names of MCP servers to enable. Each server is removed from the persisted disabled list so new sessions spawn it. Unknown or already-enabled names are ignored.
*/
names: string[];
}
-
+/**
+ * User-configured MCP servers, keyed by server name.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpConfigList".
+ */
export interface McpConfigList {
/**
* All MCP servers from user config, keyed by name
@@ -1071,14 +1376,24 @@ export interface McpConfigList {
[k: string]: McpServerConfig;
};
}
-
+/**
+ * MCP server name to remove from user configuration.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpConfigRemoveRequest".
+ */
export interface McpConfigRemoveRequest {
/**
* Name of the MCP server to remove
*/
name: string;
}
-
+/**
+ * MCP server name and replacement configuration to write to user configuration.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpConfigUpdateRequest".
+ */
export interface McpConfigUpdateRequest {
/**
* Name of the MCP server to update
@@ -1086,7 +1401,12 @@ export interface McpConfigUpdateRequest {
name: string;
config: McpServerConfig;
}
-
+/**
+ * Name of the MCP server to disable for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpDisableRequest".
+ */
/** @experimental */
export interface McpDisableRequest {
/**
@@ -1094,21 +1414,36 @@ export interface McpDisableRequest {
*/
serverName: string;
}
-
+/**
+ * Optional working directory used as context for MCP server discovery.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpDiscoverRequest".
+ */
export interface McpDiscoverRequest {
/**
* Working directory used as context for discovery (e.g., plugin resolution)
*/
workingDirectory?: string;
}
-
+/**
+ * MCP servers discovered from user, workspace, plugin, and built-in sources.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpDiscoverResult".
+ */
export interface McpDiscoverResult {
/**
* MCP servers discovered from all sources
*/
servers: DiscoveredMcpServer[];
}
-
+/**
+ * Name of the MCP server to enable for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpEnableRequest".
+ */
/** @experimental */
export interface McpEnableRequest {
/**
@@ -1116,7 +1451,12 @@ export interface McpEnableRequest {
*/
serverName: string;
}
-
+/**
+ * Remote MCP server name and optional overrides controlling reauthentication, OAuth client display name, and the callback success-page copy.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpOauthLoginRequest".
+ */
/** @experimental */
export interface McpOauthLoginRequest {
/**
@@ -1136,7 +1476,12 @@ export interface McpOauthLoginRequest {
*/
callbackSuccessMessage?: string;
}
-
+/**
+ * OAuth authorization URL the caller should open, or empty when cached tokens already authenticated the server.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpOauthLoginResult".
+ */
/** @experimental */
export interface McpOauthLoginResult {
/**
@@ -1144,7 +1489,12 @@ export interface McpOauthLoginResult {
*/
authorizationUrl?: string;
}
-
+/**
+ * Schema for the `McpServer` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpServer".
+ */
export interface McpServer {
/**
* Server name (config key)
@@ -1157,7 +1507,12 @@ export interface McpServer {
*/
error?: string;
}
-
+/**
+ * MCP servers configured for the session, with their connection status.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "McpServerList".
+ */
/** @experimental */
export interface McpServerList {
/**
@@ -1165,7 +1520,12 @@ export interface McpServerList {
*/
servers: McpServer[];
}
-
+/**
+ * Schema for the `Model` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "Model".
+ */
export interface Model {
/**
* Model identifier (e.g., "claude-sonnet-4.5")
@@ -1326,7 +1686,13 @@ export interface ModelCapabilitiesOverride {
* via the `definition` "ModelCapabilitiesOverrideSupports".
*/
export interface ModelCapabilitiesOverrideSupports {
+ /**
+ * Whether this model supports vision/image input
+ */
vision?: boolean;
+ /**
+ * Whether this model supports reasoning effort configuration
+ */
reasoningEffort?: boolean;
}
/**
@@ -1336,7 +1702,13 @@ export interface ModelCapabilitiesOverrideSupports {
* via the `definition` "ModelCapabilitiesOverrideLimits".
*/
export interface ModelCapabilitiesOverrideLimits {
+ /**
+ * Maximum number of prompt/input tokens
+ */
max_prompt_tokens?: number;
+ /**
+ * Maximum number of output/completion tokens
+ */
max_output_tokens?: number;
/**
* Maximum total context window size in tokens
@@ -1344,7 +1716,12 @@ export interface ModelCapabilitiesOverrideLimits {
max_context_window_tokens?: number;
vision?: ModelCapabilitiesOverrideLimitsVision;
}
-
+/**
+ * Vision-specific limits
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ModelCapabilitiesOverrideLimitsVision".
+ */
export interface ModelCapabilitiesOverrideLimitsVision {
/**
* MIME types the model accepts
@@ -1359,7 +1736,12 @@ export interface ModelCapabilitiesOverrideLimitsVision {
*/
max_prompt_image_size?: number;
}
-
+/**
+ * List of Copilot models available to the resolved user, including capabilities and billing metadata.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ModelList".
+ */
export interface ModelList {
/**
* List of available models with full metadata
@@ -1373,51 +1755,87 @@ export interface ModelsListRequest {
*/
gitHubToken?: string;
}
-
+/**
+ * Target model identifier and optional reasoning effort, summary, and capability overrides.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ModelSwitchToRequest".
+ */
export interface ModelSwitchToRequest {
/**
* Model identifier to switch to
*/
modelId: string;
/**
- * Reasoning effort level to use for the model
+ * Reasoning effort level to use for the model. "none" disables reasoning.
*/
reasoningEffort?: string;
+ reasoningSummary?: ReasoningSummary;
modelCapabilities?: ModelCapabilitiesOverride;
}
-
+/**
+ * The model identifier active on the session after the switch.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ModelSwitchToResult".
+ */
export interface ModelSwitchToResult {
/**
* Currently active model identifier after the switch
*/
modelId?: string;
}
-
+/**
+ * Agent interaction mode to apply to the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ModeSetRequest".
+ */
export interface ModeSetRequest {
mode: SessionMode;
}
-
+/**
+ * The session's friendly name, or null when not yet set.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "NameGetResult".
+ */
export interface NameGetResult {
/**
* The session name (user-set or auto-generated), or null if not yet set
*/
name: string | null;
}
-
+/**
+ * New friendly name to apply to the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "NameSetRequest".
+ */
export interface NameSetRequest {
/**
* New session name (1–100 characters, trimmed of leading/trailing whitespace)
*/
name: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveOnce` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveOnce".
+ */
export interface PermissionDecisionApproveOnce {
/**
* The permission request was approved for this one instance
*/
kind: "approve-once";
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSession` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSession".
+ */
export interface PermissionDecisionApproveForSession {
/**
* Approved and remembered for the rest of the session
@@ -1429,50 +1847,148 @@ export interface PermissionDecisionApproveForSession {
*/
domain?: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalCommands` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalCommands".
+ */
export interface PermissionDecisionApproveForSessionApprovalCommands {
+ /**
+ * Approval scoped to specific command identifiers.
+ */
kind: "commands";
+ /**
+ * Command identifiers covered by this approval.
+ */
commandIdentifiers: string[];
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalRead` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalRead".
+ */
export interface PermissionDecisionApproveForSessionApprovalRead {
+ /**
+ * Approval covering read-only filesystem operations.
+ */
kind: "read";
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalWrite` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalWrite".
+ */
export interface PermissionDecisionApproveForSessionApprovalWrite {
+ /**
+ * Approval covering filesystem write operations.
+ */
kind: "write";
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalMcp` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalMcp".
+ */
export interface PermissionDecisionApproveForSessionApprovalMcp {
+ /**
+ * Approval covering an MCP tool.
+ */
kind: "mcp";
+ /**
+ * MCP server name.
+ */
serverName: string;
+ /**
+ * MCP tool name, or null to cover every tool on the server.
+ */
toolName: string | null;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalMcpSampling` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalMcpSampling".
+ */
export interface PermissionDecisionApproveForSessionApprovalMcpSampling {
+ /**
+ * Approval covering MCP sampling requests for a server.
+ */
kind: "mcp-sampling";
+ /**
+ * MCP server name.
+ */
serverName: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalMemory` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalMemory".
+ */
export interface PermissionDecisionApproveForSessionApprovalMemory {
+ /**
+ * Approval covering writes to long-term memory.
+ */
kind: "memory";
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalCustomTool` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalCustomTool".
+ */
export interface PermissionDecisionApproveForSessionApprovalCustomTool {
+ /**
+ * Approval covering a custom tool.
+ */
kind: "custom-tool";
+ /**
+ * Custom tool name.
+ */
toolName: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalExtensionManagement` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalExtensionManagement".
+ */
export interface PermissionDecisionApproveForSessionApprovalExtensionManagement {
+ /**
+ * Approval covering extension lifecycle operations such as enable, disable, or reload.
+ */
kind: "extension-management";
+ /**
+ * Optional operation identifier; when omitted, the approval covers all extension management operations.
+ */
operation?: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess".
+ */
export interface PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess {
+ /**
+ * Approval covering an extension's request to access a permission-gated capability.
+ */
kind: "extension-permission-access";
+ /**
+ * Extension name.
+ */
extensionName: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocation` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocation".
+ */
export interface PermissionDecisionApproveForLocation {
/**
* Approved and persisted for this project location
@@ -1484,50 +2000,148 @@ export interface PermissionDecisionApproveForLocation {
*/
locationKey: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalCommands` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalCommands".
+ */
export interface PermissionDecisionApproveForLocationApprovalCommands {
+ /**
+ * Approval scoped to specific command identifiers.
+ */
kind: "commands";
+ /**
+ * Command identifiers covered by this approval.
+ */
commandIdentifiers: string[];
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalRead` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalRead".
+ */
export interface PermissionDecisionApproveForLocationApprovalRead {
+ /**
+ * Approval covering read-only filesystem operations.
+ */
kind: "read";
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalWrite` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalWrite".
+ */
export interface PermissionDecisionApproveForLocationApprovalWrite {
+ /**
+ * Approval covering filesystem write operations.
+ */
kind: "write";
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalMcp` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalMcp".
+ */
export interface PermissionDecisionApproveForLocationApprovalMcp {
+ /**
+ * Approval covering an MCP tool.
+ */
kind: "mcp";
+ /**
+ * MCP server name.
+ */
serverName: string;
+ /**
+ * MCP tool name, or null to cover every tool on the server.
+ */
toolName: string | null;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalMcpSampling` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalMcpSampling".
+ */
export interface PermissionDecisionApproveForLocationApprovalMcpSampling {
+ /**
+ * Approval covering MCP sampling requests for a server.
+ */
kind: "mcp-sampling";
+ /**
+ * MCP server name.
+ */
serverName: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalMemory` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalMemory".
+ */
export interface PermissionDecisionApproveForLocationApprovalMemory {
+ /**
+ * Approval covering writes to long-term memory.
+ */
kind: "memory";
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalCustomTool` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalCustomTool".
+ */
export interface PermissionDecisionApproveForLocationApprovalCustomTool {
+ /**
+ * Approval covering a custom tool.
+ */
kind: "custom-tool";
+ /**
+ * Custom tool name.
+ */
toolName: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalExtensionManagement` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalExtensionManagement".
+ */
export interface PermissionDecisionApproveForLocationApprovalExtensionManagement {
+ /**
+ * Approval covering extension lifecycle operations such as enable, disable, or reload.
+ */
kind: "extension-management";
+ /**
+ * Optional operation identifier; when omitted, the approval covers all extension management operations.
+ */
operation?: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess".
+ */
export interface PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess {
+ /**
+ * Approval covering an extension's request to access a permission-gated capability.
+ */
kind: "extension-permission-access";
+ /**
+ * Extension name.
+ */
extensionName: string;
}
-
+/**
+ * Schema for the `PermissionDecisionApprovePermanently` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionApprovePermanently".
+ */
export interface PermissionDecisionApprovePermanently {
/**
* Approved and persisted across sessions
@@ -1538,7 +2152,12 @@ export interface PermissionDecisionApprovePermanently {
*/
domain: string;
}
-
+/**
+ * Schema for the `PermissionDecisionReject` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionReject".
+ */
export interface PermissionDecisionReject {
/**
* Denied by the user during an interactive prompt
@@ -1549,14 +2168,24 @@ export interface PermissionDecisionReject {
*/
feedback?: string;
}
-
+/**
+ * Schema for the `PermissionDecisionUserNotAvailable` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionUserNotAvailable".
+ */
export interface PermissionDecisionUserNotAvailable {
/**
* Denied because user confirmation was unavailable
*/
kind: "user-not-available";
}
-
+/**
+ * Pending permission request ID and the decision to apply (approve/reject and scope).
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionDecisionRequest".
+ */
export interface PermissionDecisionRequest {
/**
* Request ID of the pending permission request
@@ -1564,44 +2193,79 @@ export interface PermissionDecisionRequest {
requestId: string;
result: PermissionDecision;
}
-
+/**
+ * Indicates whether the permission decision was applied; false when the request was already resolved.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionRequestResult".
+ */
export interface PermissionRequestResult {
/**
* Whether the permission request was handled successfully
*/
success: boolean;
}
-
+/**
+ * No parameters; clears all session-scoped tool permission approvals.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionsResetSessionApprovalsRequest".
+ */
export interface PermissionsResetSessionApprovalsRequest {}
-
+/**
+ * Indicates whether the operation succeeded.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionsResetSessionApprovalsResult".
+ */
export interface PermissionsResetSessionApprovalsResult {
/**
* Whether the operation succeeded
*/
success: boolean;
}
-
+/**
+ * Whether to auto-approve all tool permission requests for the rest of the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionsSetApproveAllRequest".
+ */
export interface PermissionsSetApproveAllRequest {
/**
* Whether to auto-approve all tool permission requests
*/
enabled: boolean;
}
-
+/**
+ * Indicates whether the operation succeeded.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PermissionsSetApproveAllResult".
+ */
export interface PermissionsSetApproveAllResult {
/**
* Whether the operation succeeded
*/
success: boolean;
}
-
+/**
+ * Optional message to echo back to the caller.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PingRequest".
+ */
export interface PingRequest {
/**
* Optional message to echo back
*/
message?: string;
}
-
+/**
+ * Server liveness response, including the echoed message, current timestamp, and protocol version.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PingResult".
+ */
export interface PingResult {
/**
* Echoed message (or default greeting)
@@ -1616,7 +2280,12 @@ export interface PingResult {
*/
protocolVersion: number;
}
-
+/**
+ * Existence, contents, and resolved path of the session plan file.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PlanReadResult".
+ */
export interface PlanReadResult {
/**
* Whether the plan file exists in the workspace
@@ -1631,14 +2300,24 @@ export interface PlanReadResult {
*/
path: string | null;
}
-
+/**
+ * Replacement contents to write to the session plan file.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PlanUpdateRequest".
+ */
export interface PlanUpdateRequest {
/**
* The new content for the plan file
*/
content: string;
}
-
+/**
+ * Schema for the `Plugin` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "Plugin".
+ */
export interface Plugin {
/**
* Plugin name
@@ -1657,7 +2336,12 @@ export interface Plugin {
*/
enabled: boolean;
}
-
+/**
+ * Plugins installed for the session, with their enabled state and version metadata.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "PluginList".
+ */
/** @experimental */
export interface PluginList {
/**
@@ -1665,16 +2349,26 @@ export interface PluginList {
*/
plugins: Plugin[];
}
-
+/**
+ * Optional remote session mode ("off", "export", or "on"); defaults to enabling both export and remote steering.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "RemoteEnableRequest".
+ */
/** @experimental */
export interface RemoteEnableRequest {
mode?: RemoteSessionMode;
}
-
+/**
+ * GitHub URL for the session and a flag indicating whether remote steering is enabled.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "RemoteEnableResult".
+ */
/** @experimental */
export interface RemoteEnableResult {
/**
- * Mission Control frontend URL for this session
+ * GitHub frontend URL for this session
*/
url?: string;
/**
@@ -1682,7 +2376,12 @@ export interface RemoteEnableResult {
*/
remoteSteerable: boolean;
}
-
+/**
+ * Schema for the `ServerSkill` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ServerSkill".
+ */
export interface ServerSkill {
/**
* Unique identifier for the skill
@@ -1713,14 +2412,24 @@ export interface ServerSkill {
*/
projectPath?: string;
}
-
+/**
+ * Skills discovered across global and project sources.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ServerSkillList".
+ */
export interface ServerSkillList {
/**
* All discovered skills across all sources
*/
skills: ServerSkill[];
}
-
+/**
+ * Authentication status and account metadata for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionAuthStatus".
+ */
export interface SessionAuthStatus {
/**
* Whether the session has resolved authentication
@@ -1744,7 +2453,12 @@ export interface SessionAuthStatus {
*/
copilotPlan?: string;
}
-
+/**
+ * File path, content to append, and optional mode for the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsAppendFileRequest".
+ */
export interface SessionFsAppendFileRequest {
/**
* Target session identifier
@@ -1776,7 +2490,12 @@ export interface SessionFsError {
*/
message?: string;
}
-
+/**
+ * Path to test for existence in the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsExistsRequest".
+ */
export interface SessionFsExistsRequest {
/**
* Target session identifier
@@ -1787,14 +2506,24 @@ export interface SessionFsExistsRequest {
*/
path: string;
}
-
+/**
+ * Indicates whether the requested path exists in the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsExistsResult".
+ */
export interface SessionFsExistsResult {
/**
* Whether the path exists
*/
exists: boolean;
}
-
+/**
+ * Directory path to create in the client-provided session filesystem, with options for recursive creation and POSIX mode.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsMkdirRequest".
+ */
export interface SessionFsMkdirRequest {
/**
* Target session identifier
@@ -1813,7 +2542,12 @@ export interface SessionFsMkdirRequest {
*/
mode?: number;
}
-
+/**
+ * Directory path whose entries should be listed from the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsReaddirRequest".
+ */
export interface SessionFsReaddirRequest {
/**
* Target session identifier
@@ -1824,7 +2558,12 @@ export interface SessionFsReaddirRequest {
*/
path: string;
}
-
+/**
+ * Names of entries in the requested directory, or a filesystem error if the read failed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsReaddirResult".
+ */
export interface SessionFsReaddirResult {
/**
* Entry names in the directory
@@ -1832,7 +2571,12 @@ export interface SessionFsReaddirResult {
entries: string[];
error?: SessionFsError;
}
-
+/**
+ * Schema for the `SessionFsReaddirWithTypesEntry` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsReaddirWithTypesEntry".
+ */
export interface SessionFsReaddirWithTypesEntry {
/**
* Entry name
@@ -1840,7 +2584,12 @@ export interface SessionFsReaddirWithTypesEntry {
name: string;
type: SessionFsReaddirWithTypesEntryType;
}
-
+/**
+ * Directory path whose entries (with type information) should be listed from the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsReaddirWithTypesRequest".
+ */
export interface SessionFsReaddirWithTypesRequest {
/**
* Target session identifier
@@ -1851,7 +2600,12 @@ export interface SessionFsReaddirWithTypesRequest {
*/
path: string;
}
-
+/**
+ * Entries in the requested directory paired with file/directory type information, or a filesystem error if the read failed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsReaddirWithTypesResult".
+ */
export interface SessionFsReaddirWithTypesResult {
/**
* Directory entries with type information
@@ -1859,7 +2613,12 @@ export interface SessionFsReaddirWithTypesResult {
entries: SessionFsReaddirWithTypesEntry[];
error?: SessionFsError;
}
-
+/**
+ * Path of the file to read from the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsReadFileRequest".
+ */
export interface SessionFsReadFileRequest {
/**
* Target session identifier
@@ -1870,7 +2629,12 @@ export interface SessionFsReadFileRequest {
*/
path: string;
}
-
+/**
+ * File content as a UTF-8 string, or a filesystem error if the read failed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsReadFileResult".
+ */
export interface SessionFsReadFileResult {
/**
* File content as UTF-8 string
@@ -1878,7 +2642,12 @@ export interface SessionFsReadFileResult {
content: string;
error?: SessionFsError;
}
-
+/**
+ * Source and destination paths for renaming or moving an entry in the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsRenameRequest".
+ */
export interface SessionFsRenameRequest {
/**
* Target session identifier
@@ -1893,7 +2662,12 @@ export interface SessionFsRenameRequest {
*/
dest: string;
}
-
+/**
+ * Path to remove from the client-provided session filesystem, with options for recursive removal and force.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsRmRequest".
+ */
export interface SessionFsRmRequest {
/**
* Target session identifier
@@ -1912,7 +2686,12 @@ export interface SessionFsRmRequest {
*/
force?: boolean;
}
-
+/**
+ * Initial working directory, session-state path layout, and path conventions used to register the calling SDK client as the session filesystem provider.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsSetProviderRequest".
+ */
export interface SessionFsSetProviderRequest {
/**
* Initial working directory for sessions
@@ -1924,14 +2703,24 @@ export interface SessionFsSetProviderRequest {
sessionStatePath: string;
conventions: SessionFsSetProviderConventions;
}
-
+/**
+ * Indicates whether the calling client was registered as the session filesystem provider.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsSetProviderResult".
+ */
export interface SessionFsSetProviderResult {
/**
* Whether the provider was set successfully
*/
success: boolean;
}
-
+/**
+ * Path whose metadata should be returned from the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsStatRequest".
+ */
export interface SessionFsStatRequest {
/**
* Target session identifier
@@ -1942,7 +2731,12 @@ export interface SessionFsStatRequest {
*/
path: string;
}
-
+/**
+ * Filesystem metadata for the requested path, or a filesystem error if the stat failed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsStatResult".
+ */
export interface SessionFsStatResult {
/**
* Whether the path is a file
@@ -1966,7 +2760,12 @@ export interface SessionFsStatResult {
birthtime: string;
error?: SessionFsError;
}
-
+/**
+ * File path, content to write, and optional mode for the client-provided session filesystem.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionFsWriteFileRequest".
+ */
export interface SessionFsWriteFileRequest {
/**
* Target session identifier
@@ -1985,7 +2784,12 @@ export interface SessionFsWriteFileRequest {
*/
mode?: number;
}
-
+/**
+ * Source session identifier to fork from, optional event-ID boundary, and optional friendly name for the new session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionsForkRequest".
+ */
/** @experimental */
export interface SessionsForkRequest {
/**
@@ -2001,7 +2805,12 @@ export interface SessionsForkRequest {
*/
name?: string;
}
-
+/**
+ * Identifier and optional friendly name assigned to the newly forked session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SessionsForkResult".
+ */
/** @experimental */
export interface SessionsForkResult {
/**
@@ -2013,7 +2822,12 @@ export interface SessionsForkResult {
*/
name?: string;
}
-
+/**
+ * Shell command to run, with optional working directory and timeout in milliseconds.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ShellExecRequest".
+ */
export interface ShellExecRequest {
/**
* Shell command to execute
@@ -2028,14 +2842,24 @@ export interface ShellExecRequest {
*/
timeout?: number;
}
-
+/**
+ * Identifier of the spawned process, used to correlate streamed output and exit notifications.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ShellExecResult".
+ */
export interface ShellExecResult {
/**
* Unique identifier for tracking streamed output
*/
processId: string;
}
-
+/**
+ * Identifier of a process previously returned by "shell.exec" and the signal to send.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ShellKillRequest".
+ */
export interface ShellKillRequest {
/**
* Process identifier returned by shell.exec
@@ -2043,14 +2867,24 @@ export interface ShellKillRequest {
processId: string;
signal?: ShellKillSignal;
}
-
+/**
+ * Indicates whether the signal was delivered; false if the process was unknown or already exited.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ShellKillResult".
+ */
export interface ShellKillResult {
/**
* Whether the signal was sent successfully
*/
killed: boolean;
}
-
+/**
+ * Schema for the `Skill` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "Skill".
+ */
export interface Skill {
/**
* Unique identifier for the skill
@@ -2077,7 +2911,12 @@ export interface Skill {
*/
path?: string;
}
-
+/**
+ * Skills available to the session, with their enabled state.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SkillList".
+ */
/** @experimental */
export interface SkillList {
/**
@@ -2085,14 +2924,24 @@ export interface SkillList {
*/
skills: Skill[];
}
-
+/**
+ * Skill names to mark as disabled in global configuration, replacing any previous list.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SkillsConfigSetDisabledSkillsRequest".
+ */
export interface SkillsConfigSetDisabledSkillsRequest {
/**
* List of skill names to disable
*/
disabledSkills: string[];
}
-
+/**
+ * Name of the skill to disable for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SkillsDisableRequest".
+ */
/** @experimental */
export interface SkillsDisableRequest {
/**
@@ -2100,7 +2949,12 @@ export interface SkillsDisableRequest {
*/
name: string;
}
-
+/**
+ * Optional project paths and additional skill directories to include in discovery.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SkillsDiscoverRequest".
+ */
export interface SkillsDiscoverRequest {
/**
* Optional list of project directory paths to scan for project-scoped skills
@@ -2111,7 +2965,12 @@ export interface SkillsDiscoverRequest {
*/
skillDirectories?: string[];
}
-
+/**
+ * Name of the skill to enable for the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SkillsEnableRequest".
+ */
/** @experimental */
export interface SkillsEnableRequest {
/**
@@ -2119,7 +2978,12 @@ export interface SkillsEnableRequest {
*/
name: string;
}
-
+/**
+ * Diagnostics from reloading skill definitions, with warnings and errors as separate lists.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SkillsLoadDiagnostics".
+ */
/** @experimental */
export interface SkillsLoadDiagnostics {
/**
@@ -2131,7 +2995,12 @@ export interface SkillsLoadDiagnostics {
*/
errors: string[];
}
-
+/**
+ * Schema for the `SlashCommandAgentPromptResult` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SlashCommandAgentPromptResult".
+ */
export interface SlashCommandAgentPromptResult {
/**
* Agent prompt result discriminator
@@ -2151,7 +3020,12 @@ export interface SlashCommandAgentPromptResult {
*/
runtimeSettingsChanged?: boolean;
}
-
+/**
+ * Schema for the `SlashCommandCompletedResult` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SlashCommandCompletedResult".
+ */
export interface SlashCommandCompletedResult {
/**
* Completed result discriminator
@@ -2166,7 +3040,12 @@ export interface SlashCommandCompletedResult {
*/
runtimeSettingsChanged?: boolean;
}
-
+/**
+ * Schema for the `SlashCommandTextResult` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "SlashCommandTextResult".
+ */
export interface SlashCommandTextResult {
/**
* Text result discriminator
@@ -2189,7 +3068,12 @@ export interface SlashCommandTextResult {
*/
runtimeSettingsChanged?: boolean;
}
-
+/**
+ * Schema for the `TaskAgentInfo` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TaskAgentInfo".
+ */
export interface TaskAgentInfo {
/**
* Task kind
@@ -2258,7 +3142,12 @@ export interface TaskAgentInfo {
*/
idleSince?: string;
}
-
+/**
+ * Schema for the `TaskShellInfo` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TaskShellInfo".
+ */
export interface TaskShellInfo {
/**
* Task kind
@@ -2300,7 +3189,12 @@ export interface TaskShellInfo {
*/
pid?: number;
}
-
+/**
+ * Background tasks currently tracked by the session.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TaskList".
+ */
/** @experimental */
export interface TaskList {
/**
@@ -2308,7 +3202,12 @@ export interface TaskList {
*/
tasks: TaskInfo[];
}
-
+/**
+ * Identifier of the background task to cancel.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksCancelRequest".
+ */
/** @experimental */
export interface TasksCancelRequest {
/**
@@ -2316,7 +3215,12 @@ export interface TasksCancelRequest {
*/
id: string;
}
-
+/**
+ * Indicates whether the background task was successfully cancelled.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksCancelResult".
+ */
/** @experimental */
export interface TasksCancelResult {
/**
@@ -2324,7 +3228,12 @@ export interface TasksCancelResult {
*/
cancelled: boolean;
}
-
+/**
+ * Identifier of the task to promote to background mode.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksPromoteToBackgroundRequest".
+ */
/** @experimental */
export interface TasksPromoteToBackgroundRequest {
/**
@@ -2332,7 +3241,12 @@ export interface TasksPromoteToBackgroundRequest {
*/
id: string;
}
-
+/**
+ * Indicates whether the task was successfully promoted to background mode.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksPromoteToBackgroundResult".
+ */
/** @experimental */
export interface TasksPromoteToBackgroundResult {
/**
@@ -2340,7 +3254,12 @@ export interface TasksPromoteToBackgroundResult {
*/
promoted: boolean;
}
-
+/**
+ * Identifier of the completed or cancelled task to remove from tracking.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksRemoveRequest".
+ */
/** @experimental */
export interface TasksRemoveRequest {
/**
@@ -2348,7 +3267,12 @@ export interface TasksRemoveRequest {
*/
id: string;
}
-
+/**
+ * Indicates whether the task was removed. False when the task does not exist or is still running/idle.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksRemoveResult".
+ */
/** @experimental */
export interface TasksRemoveResult {
/**
@@ -2356,7 +3280,12 @@ export interface TasksRemoveResult {
*/
removed: boolean;
}
-
+/**
+ * Identifier of the target agent task, message content, and optional sender agent ID.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksSendMessageRequest".
+ */
/** @experimental */
export interface TasksSendMessageRequest {
/**
@@ -2372,7 +3301,12 @@ export interface TasksSendMessageRequest {
*/
fromAgentId?: string;
}
-
+/**
+ * Indicates whether the message was delivered, with an error message when delivery failed.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksSendMessageResult".
+ */
/** @experimental */
export interface TasksSendMessageResult {
/**
@@ -2384,7 +3318,12 @@ export interface TasksSendMessageResult {
*/
error?: string;
}
-
+/**
+ * Agent type, prompt, name, and optional description and model override for the new task.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksStartAgentRequest".
+ */
/** @experimental */
export interface TasksStartAgentRequest {
/**
@@ -2408,7 +3347,12 @@ export interface TasksStartAgentRequest {
*/
model?: string;
}
-
+/**
+ * Identifier assigned to the newly started background agent task.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "TasksStartAgentResult".
+ */
/** @experimental */
export interface TasksStartAgentResult {
/**
@@ -2416,7 +3360,12 @@ export interface TasksStartAgentResult {
*/
agentId: string;
}
-
+/**
+ * Schema for the `Tool` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "Tool".
+ */
export interface Tool {
/**
* Tool identifier (e.g., "bash", "grep", "str_replace_editor")
@@ -2441,55 +3390,146 @@ export interface Tool {
*/
instructions?: string;
}
-
+/**
+ * Built-in tools available for the requested model, with their parameters and instructions.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ToolList".
+ */
export interface ToolList {
/**
* List of available built-in tools with metadata
*/
tools: Tool[];
}
-
+/**
+ * Optional model identifier whose tool overrides should be applied to the listing.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "ToolsListRequest".
+ */
export interface ToolsListRequest {
/**
* Optional model ID — when provided, the returned tool list reflects model-specific overrides
*/
model?: string;
}
-
+/**
+ * Multi-select string field where each option pairs a value with a display label.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationArrayAnyOfField".
+ */
export interface UIElicitationArrayAnyOfField {
+ /**
+ * Type discriminator. Always "array".
+ */
type: "array";
+ /**
+ * Human-readable label for the field.
+ */
title?: string;
+ /**
+ * Help text describing the field.
+ */
description?: string;
+ /**
+ * Minimum number of items the user must select.
+ */
minItems?: number;
+ /**
+ * Maximum number of items the user may select.
+ */
maxItems?: number;
items: UIElicitationArrayAnyOfFieldItems;
+ /**
+ * Default values selected when the form is first shown.
+ */
default?: string[];
}
-
+/**
+ * Schema applied to each item in the array.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationArrayAnyOfFieldItems".
+ */
export interface UIElicitationArrayAnyOfFieldItems {
+ /**
+ * Selectable options, each with a value and a display label.
+ */
anyOf: UIElicitationArrayAnyOfFieldItemsAnyOf[];
}
-
+/**
+ * Schema for the `UIElicitationArrayAnyOfFieldItemsAnyOf` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationArrayAnyOfFieldItemsAnyOf".
+ */
export interface UIElicitationArrayAnyOfFieldItemsAnyOf {
+ /**
+ * Value submitted when this option is selected.
+ */
const: string;
+ /**
+ * Display label for this option.
+ */
title: string;
}
-
+/**
+ * Multi-select string field whose allowed values are defined inline.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationArrayEnumField".
+ */
export interface UIElicitationArrayEnumField {
+ /**
+ * Type discriminator. Always "array".
+ */
type: "array";
+ /**
+ * Human-readable label for the field.
+ */
title?: string;
+ /**
+ * Help text describing the field.
+ */
description?: string;
+ /**
+ * Minimum number of items the user must select.
+ */
minItems?: number;
+ /**
+ * Maximum number of items the user may select.
+ */
maxItems?: number;
items: UIElicitationArrayEnumFieldItems;
+ /**
+ * Default values selected when the form is first shown.
+ */
default?: string[];
}
-
+/**
+ * Schema applied to each item in the array.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationArrayEnumFieldItems".
+ */
export interface UIElicitationArrayEnumFieldItems {
+ /**
+ * Type discriminator. Always "string".
+ */
type: "string";
+ /**
+ * Allowed string values for each selected item.
+ */
enum: string[];
}
-
+/**
+ * Prompt message and JSON schema describing the form fields to elicit from the user.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationRequest".
+ */
export interface UIElicitationRequest {
/**
* Message describing what information is needed from the user
@@ -2519,52 +3559,166 @@ export interface UIElicitationSchema {
*/
required?: string[];
}
-
+/**
+ * Single-select string field whose allowed values are defined inline.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationStringEnumField".
+ */
export interface UIElicitationStringEnumField {
+ /**
+ * Type discriminator. Always "string".
+ */
type: "string";
+ /**
+ * Human-readable label for the field.
+ */
title?: string;
+ /**
+ * Help text describing the field.
+ */
description?: string;
+ /**
+ * Allowed string values.
+ */
enum: string[];
+ /**
+ * Optional display labels for each enum value, in the same order as `enum`.
+ */
enumNames?: string[];
+ /**
+ * Default value selected when the form is first shown.
+ */
default?: string;
}
-
+/**
+ * Single-select string field where each option pairs a value with a display label.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationStringOneOfField".
+ */
export interface UIElicitationStringOneOfField {
+ /**
+ * Type discriminator. Always "string".
+ */
type: "string";
+ /**
+ * Human-readable label for the field.
+ */
title?: string;
+ /**
+ * Help text describing the field.
+ */
description?: string;
+ /**
+ * Selectable options, each with a value and a display label.
+ */
oneOf: UIElicitationStringOneOfFieldOneOf[];
+ /**
+ * Default value selected when the form is first shown.
+ */
default?: string;
}
-
+/**
+ * Schema for the `UIElicitationStringOneOfFieldOneOf` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationStringOneOfFieldOneOf".
+ */
export interface UIElicitationStringOneOfFieldOneOf {
+ /**
+ * Value submitted when this option is selected.
+ */
const: string;
+ /**
+ * Display label for this option.
+ */
title: string;
}
-
+/**
+ * Boolean field rendered as a yes/no toggle.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationSchemaPropertyBoolean".
+ */
export interface UIElicitationSchemaPropertyBoolean {
+ /**
+ * Type discriminator. Always "boolean".
+ */
type: "boolean";
+ /**
+ * Human-readable label for the field.
+ */
title?: string;
+ /**
+ * Help text describing the field.
+ */
description?: string;
+ /**
+ * Default value selected when the form is first shown.
+ */
default?: boolean;
}
-
+/**
+ * Free-text string field with optional length and format constraints.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationSchemaPropertyString".
+ */
export interface UIElicitationSchemaPropertyString {
+ /**
+ * Type discriminator. Always "string".
+ */
type: "string";
+ /**
+ * Human-readable label for the field.
+ */
title?: string;
+ /**
+ * Help text describing the field.
+ */
description?: string;
+ /**
+ * Minimum number of characters required.
+ */
minLength?: number;
+ /**
+ * Maximum number of characters allowed.
+ */
maxLength?: number;
format?: UIElicitationSchemaPropertyStringFormat;
+ /**
+ * Default value populated in the input when the form is first shown.
+ */
default?: string;
}
-
+/**
+ * Numeric field accepting either a number or an integer.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationSchemaPropertyNumber".
+ */
export interface UIElicitationSchemaPropertyNumber {
type: UIElicitationSchemaPropertyNumberType;
+ /**
+ * Human-readable label for the field.
+ */
title?: string;
+ /**
+ * Help text describing the field.
+ */
description?: string;
+ /**
+ * Minimum allowed value (inclusive).
+ */
minimum?: number;
+ /**
+ * Maximum allowed value (inclusive).
+ */
maximum?: number;
+ /**
+ * Default value populated in the input when the form is first shown.
+ */
default?: number;
}
/**
@@ -2586,14 +3740,24 @@ export interface UIElicitationResponse {
export interface UIElicitationResponseContent {
[k: string]: UIElicitationFieldValue;
}
-
+/**
+ * Indicates whether the elicitation response was accepted; false if it was already resolved by another client.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIElicitationResult".
+ */
export interface UIElicitationResult {
/**
* Whether the response was accepted. False if the request was already resolved by another client.
*/
success: boolean;
}
-
+/**
+ * Pending elicitation request ID and the user's response (accept/decline/cancel + form values).
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UIHandlePendingElicitationRequest".
+ */
export interface UIHandlePendingElicitationRequest {
/**
* The unique request ID from the elicitation.requested event
@@ -2601,7 +3765,12 @@ export interface UIHandlePendingElicitationRequest {
requestId: string;
result: UIElicitationResponse;
}
-
+/**
+ * Accumulated session usage metrics, including premium request cost, token counts, model breakdown, and code-change totals.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UsageGetMetricsResult".
+ */
/** @experimental */
export interface UsageGetMetricsResult {
/**
@@ -2650,7 +3819,12 @@ export interface UsageGetMetricsResult {
*/
lastCallOutputTokens: number;
}
-
+/**
+ * Schema for the `UsageMetricsTokenDetail` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UsageMetricsTokenDetail".
+ */
export interface UsageMetricsTokenDetail {
/**
* Accumulated token count for this token type
@@ -2677,7 +3851,12 @@ export interface UsageMetricsCodeChanges {
*/
filesModifiedCount: number;
}
-
+/**
+ * Schema for the `UsageMetricsModelMetric` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UsageMetricsModelMetric".
+ */
export interface UsageMetricsModelMetric {
requests: UsageMetricsModelMetricRequests;
usage: UsageMetricsModelMetricUsage;
@@ -2736,14 +3915,24 @@ export interface UsageMetricsModelMetricUsage {
*/
reasoningTokens?: number;
}
-
+/**
+ * Schema for the `UsageMetricsModelMetricTokenDetail` type.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "UsageMetricsModelMetricTokenDetail".
+ */
export interface UsageMetricsModelMetricTokenDetail {
/**
* Accumulated token count for this token type
*/
tokenCount: number;
}
-
+/**
+ * Relative path and UTF-8 content for the workspace file to create or overwrite.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "WorkspacesCreateFileRequest".
+ */
export interface WorkspacesCreateFileRequest {
/**
* Relative path within the workspace files directory
@@ -2754,7 +3943,12 @@ export interface WorkspacesCreateFileRequest {
*/
content: string;
}
-
+/**
+ * Current workspace metadata for the session, or null when not available.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "WorkspacesGetWorkspaceResult".
+ */
export interface WorkspacesGetWorkspaceResult {
/**
* Current workspace metadata, or null if not available
@@ -2778,21 +3972,36 @@ export interface WorkspacesGetWorkspaceResult {
chronicle_sync_dismissed?: boolean;
} | null;
}
-
+/**
+ * Relative paths of files stored in the session workspace files directory.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "WorkspacesListFilesResult".
+ */
export interface WorkspacesListFilesResult {
/**
* Relative file paths in the workspace files directory
*/
files: string[];
}
-
+/**
+ * Relative path of the workspace file to read.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "WorkspacesReadFileRequest".
+ */
export interface WorkspacesReadFileRequest {
/**
* Relative path within the workspace files directory
*/
path: string;
}
-
+/**
+ * Contents of the requested workspace file as a UTF-8 string.
+ *
+ * This interface was referenced by `_RpcSchemaRoot`'s JSON-Schema
+ * via the `definition` "WorkspacesReadFileResult".
+ */
export interface WorkspacesReadFileResult {
/**
* File content as a UTF-8 string
@@ -2804,27 +4013,43 @@ export interface WorkspacesReadFileResult {
export function createServerRpc(connection: MessageConnection) {
return {
/**
- * Calls `ping`.
+ * Checks server responsiveness and returns protocol information.
+ *
+ * @param params Optional message to echo back to the caller.
+ *
+ * @returns Server liveness response, including the echoed message, current timestamp, and protocol version.
*/
ping: async (params: PingRequest): Promise =>
connection.sendRequest("ping", params),
models: {
/**
- * Calls `models.list`.
+ * Lists Copilot models available to the authenticated user.
+ *
+ * @param params Optional GitHub token used to list models for a specific user instead of the global auth context.
+ *
+ * @returns List of Copilot models available to the resolved user, including capabilities and billing metadata.
*/
list: async (params: ModelsListRequest): Promise =>
connection.sendRequest("models.list", params),
},
tools: {
/**
- * Calls `tools.list`.
+ * Lists built-in tools available for a model.
+ *
+ * @param params Optional model identifier whose tool overrides should be applied to the listing.
+ *
+ * @returns Built-in tools available for the requested model, with their parameters and instructions.
*/
list: async (params: ToolsListRequest): Promise =>
connection.sendRequest("tools.list", params),
},
account: {
/**
- * Calls `account.getQuota`.
+ * Gets Copilot quota usage for the authenticated user or supplied GitHub token.
+ *
+ * @param params Optional GitHub token used to look up quota for a specific user instead of the global auth context.
+ *
+ * @returns Quota usage snapshots for the resolved user, keyed by quota type.
*/
getQuota: async (params: AccountGetQuotaRequest): Promise =>
connection.sendRequest("account.getQuota", params),
@@ -2832,38 +4057,54 @@ export function createServerRpc(connection: MessageConnection) {
mcp: {
config: {
/**
- * Calls `mcp.config.list`.
+ * Lists MCP servers from user configuration.
+ *
+ * @returns User-configured MCP servers, keyed by server name.
*/
list: async (): Promise =>
connection.sendRequest("mcp.config.list", {}),
/**
- * Calls `mcp.config.add`.
+ * Adds an MCP server to user configuration.
+ *
+ * @param params MCP server name and configuration to add to user configuration.
*/
add: async (params: McpConfigAddRequest): Promise =>
connection.sendRequest("mcp.config.add", params),
/**
- * Calls `mcp.config.update`.
+ * Updates an MCP server in user configuration.
+ *
+ * @param params MCP server name and replacement configuration to write to user configuration.
*/
update: async (params: McpConfigUpdateRequest): Promise =>
connection.sendRequest("mcp.config.update", params),
/**
- * Calls `mcp.config.remove`.
+ * Removes an MCP server from user configuration.
+ *
+ * @param params MCP server name to remove from user configuration.
*/
remove: async (params: McpConfigRemoveRequest): Promise =>
connection.sendRequest("mcp.config.remove", params),
/**
- * Calls `mcp.config.enable`.
+ * Enables MCP servers in user configuration for new sessions.
+ *
+ * @param params MCP server names to enable for new sessions.
*/
enable: async (params: McpConfigEnableRequest): Promise =>
connection.sendRequest("mcp.config.enable", params),
/**
- * Calls `mcp.config.disable`.
+ * Disables MCP servers in user configuration for new sessions.
+ *
+ * @param params MCP server names to disable for new sessions.
*/
disable: async (params: McpConfigDisableRequest): Promise =>
connection.sendRequest("mcp.config.disable", params),
},
/**
- * Calls `mcp.discover`.
+ * Discovers MCP servers from user, workspace, plugin, and builtin sources.
+ *
+ * @param params Optional working directory used as context for MCP server discovery.
+ *
+ * @returns MCP servers discovered from user, workspace, plugin, and built-in sources.
*/
discover: async (params: McpDiscoverRequest): Promise =>
connection.sendRequest("mcp.discover", params),
@@ -2871,20 +4112,30 @@ export function createServerRpc(connection: MessageConnection) {
skills: {
config: {
/**
- * Calls `skills.config.setDisabledSkills`.
+ * Replaces the global list of disabled skills.
+ *
+ * @param params Skill names to mark as disabled in global configuration, replacing any previous list.
*/
setDisabledSkills: async (params: SkillsConfigSetDisabledSkillsRequest): Promise =>
connection.sendRequest("skills.config.setDisabledSkills", params),
},
/**
- * Calls `skills.discover`.
+ * Discovers skills across global and project sources.
+ *
+ * @param params Optional project paths and additional skill directories to include in discovery.
+ *
+ * @returns Skills discovered across global and project sources.
*/
discover: async (params: SkillsDiscoverRequest): Promise =>
connection.sendRequest("skills.discover", params),
},
sessionFs: {
/**
- * Calls `sessionFs.setProvider`.
+ * Registers an SDK client as the session filesystem provider.
+ *
+ * @param params Initial working directory, session-state path layout, and path conventions used to register the calling SDK client as the session filesystem provider.
+ *
+ * @returns Indicates whether the calling client was registered as the session filesystem provider.
*/
setProvider: async (params: SessionFsSetProviderRequest): Promise =>
connection.sendRequest("sessionFs.setProvider", params),
@@ -2892,7 +4143,11 @@ export function createServerRpc(connection: MessageConnection) {
/** @experimental */
sessions: {
/**
- * Calls `sessions.fork`.
+ * Creates a new session by forking persisted history from an existing session.
+ *
+ * @param params Source session identifier to fork from, optional event-ID boundary, and optional friendly name for the new session.
+ *
+ * @returns Identifier and optional friendly name assigned to the newly forked session.
*/
fork: async (params: SessionsForkRequest): Promise =>
connection.sendRequest("sessions.fork", params),
@@ -2908,7 +4163,11 @@ export function createServerRpc(connection: MessageConnection) {
export function createInternalServerRpc(connection: MessageConnection) {
return {
/**
- * Calls `connect`.
+ * Performs the SDK server connection handshake and validates the optional connection token.
+ *
+ * @param params Optional connection token presented by the SDK client during the handshake.
+ *
+ * @returns Handshake result reporting the server's protocol version and package version on success.
*/
connect: async (params: ConnectRequest): Promise =>
connection.sendRequest("connect", params),
@@ -2919,97 +4178,127 @@ export function createInternalServerRpc(connection: MessageConnection) {
export function createSessionRpc(connection: MessageConnection, sessionId: string) {
return {
/**
- * Calls `session.suspend`.
+ * Suspends the session while preserving persisted state for later resume.
*/
suspend: async (): Promise =>
connection.sendRequest("session.suspend", { sessionId }),
auth: {
/**
- * Calls `session.auth.getStatus`.
+ * Gets authentication status and account metadata for the session.
+ *
+ * @returns Authentication status and account metadata for the session.
*/
getStatus: async (): Promise =>
connection.sendRequest("session.auth.getStatus", { sessionId }),
},
model: {
/**
- * Calls `session.model.getCurrent`.
+ * Gets the currently selected model for the session.
+ *
+ * @returns The currently selected model for the session.
*/
getCurrent: async (): Promise =>
connection.sendRequest("session.model.getCurrent", { sessionId }),
/**
- * Calls `session.model.switchTo`.
+ * Switches the session to a model and optional reasoning configuration.
+ *
+ * @param params Target model identifier and optional reasoning effort, summary, and capability overrides.
+ *
+ * @returns The model identifier active on the session after the switch.
*/
switchTo: async (params: ModelSwitchToRequest): Promise =>
connection.sendRequest("session.model.switchTo", { sessionId, ...params }),
},
mode: {
/**
- * Calls `session.mode.get`.
+ * Gets the current agent interaction mode.
*
* @returns The agent mode. Valid values: "interactive", "plan", "autopilot".
*/
get: async (): Promise =>
connection.sendRequest("session.mode.get", { sessionId }),
/**
- * Calls `session.mode.set`.
+ * Sets the current agent interaction mode.
+ *
+ * @param params Agent interaction mode to apply to the session.
*/
set: async (params: ModeSetRequest): Promise =>
connection.sendRequest("session.mode.set", { sessionId, ...params }),
},
name: {
/**
- * Calls `session.name.get`.
+ * Gets the session's friendly name.
+ *
+ * @returns The session's friendly name, or null when not yet set.
*/
get: async (): Promise =>
connection.sendRequest("session.name.get", { sessionId }),
/**
- * Calls `session.name.set`.
+ * Sets the session's friendly name.
+ *
+ * @param params New friendly name to apply to the session.
*/
set: async (params: NameSetRequest): Promise =>
connection.sendRequest("session.name.set", { sessionId, ...params }),
},
plan: {
/**
- * Calls `session.plan.read`.
+ * Reads the session plan file from the workspace.
+ *
+ * @returns Existence, contents, and resolved path of the session plan file.
*/
read: async (): Promise =>
connection.sendRequest("session.plan.read", { sessionId }),
/**
- * Calls `session.plan.update`.
+ * Writes new content to the session plan file.
+ *
+ * @param params Replacement contents to write to the session plan file.
*/
update: async (params: PlanUpdateRequest): Promise =>
connection.sendRequest("session.plan.update", { sessionId, ...params }),
/**
- * Calls `session.plan.delete`.
+ * Deletes the session plan file from the workspace.
*/
delete: async (): Promise =>
connection.sendRequest("session.plan.delete", { sessionId }),
},
workspaces: {
/**
- * Calls `session.workspaces.getWorkspace`.
+ * Gets current workspace metadata for the session.
+ *
+ * @returns Current workspace metadata for the session, or null when not available.
*/
getWorkspace: async (): Promise =>
connection.sendRequest("session.workspaces.getWorkspace", { sessionId }),
/**
- * Calls `session.workspaces.listFiles`.
+ * Lists files stored in the session workspace files directory.
+ *
+ * @returns Relative paths of files stored in the session workspace files directory.
*/
listFiles: async (): Promise =>
connection.sendRequest("session.workspaces.listFiles", { sessionId }),
/**
- * Calls `session.workspaces.readFile`.
+ * Reads a file from the session workspace files directory.
+ *
+ * @param params Relative path of the workspace file to read.
+ *
+ * @returns Contents of the requested workspace file as a UTF-8 string.
*/
readFile: async (params: WorkspacesReadFileRequest): Promise =>
connection.sendRequest("session.workspaces.readFile", { sessionId, ...params }),
/**
- * Calls `session.workspaces.createFile`.
+ * Creates or overwrites a file in the session workspace files directory.
+ *
+ * @param params Relative path and UTF-8 content for the workspace file to create or overwrite.
*/
createFile: async (params: WorkspacesCreateFileRequest): Promise =>
connection.sendRequest("session.workspaces.createFile", { sessionId, ...params }),
},
instructions: {
/**
- * Calls `session.instructions.getSources`.
+ * Gets instruction sources loaded for the session.
+ *
+ * @returns Instruction sources loaded for the session, in merge order.
*/
getSources: async (): Promise =>
connection.sendRequest("session.instructions.getSources", { sessionId }),
@@ -3017,7 +4306,11 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
fleet: {
/**
- * Calls `session.fleet.start`.
+ * Starts fleet mode by submitting the fleet orchestration prompt to the session.
+ *
+ * @param params Optional user prompt to combine with the fleet orchestration instructions.
+ *
+ * @returns Indicates whether fleet mode was successfully activated.
*/
start: async (params: FleetStartRequest): Promise =>
connection.sendRequest("session.fleet.start", { sessionId, ...params }),
@@ -3025,27 +4318,37 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
agent: {
/**
- * Calls `session.agent.list`.
+ * Lists custom agents available to the session.
+ *
+ * @returns Custom agents available to the session.
*/
list: async (): Promise =>
connection.sendRequest("session.agent.list", { sessionId }),
/**
- * Calls `session.agent.getCurrent`.
+ * Gets the currently selected custom agent for the session.
+ *
+ * @returns The currently selected custom agent, or null when using the default agent.
*/
getCurrent: async (): Promise =>
connection.sendRequest("session.agent.getCurrent", { sessionId }),
/**
- * Calls `session.agent.select`.
+ * Selects a custom agent for subsequent turns in the session.
+ *
+ * @param params Name of the custom agent to select for subsequent turns.
+ *
+ * @returns The newly selected custom agent.
*/
select: async (params: AgentSelectRequest): Promise =>
connection.sendRequest("session.agent.select", { sessionId, ...params }),
/**
- * Calls `session.agent.deselect`.
+ * Clears the selected custom agent and returns the session to the default agent.
*/
deselect: async (): Promise =>
connection.sendRequest("session.agent.deselect", { sessionId }),
/**
- * Calls `session.agent.reload`.
+ * Reloads custom agent definitions and returns the refreshed list.
+ *
+ * @returns Custom agents available to the session after reloading definitions from disk.
*/
reload: async (): Promise =>
connection.sendRequest("session.agent.reload", { sessionId }),
@@ -3053,32 +4356,54 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
tasks: {
/**
- * Calls `session.tasks.startAgent`.
+ * Starts a background agent task in the session.
+ *
+ * @param params Agent type, prompt, name, and optional description and model override for the new task.
+ *
+ * @returns Identifier assigned to the newly started background agent task.
*/
startAgent: async (params: TasksStartAgentRequest): Promise =>
connection.sendRequest("session.tasks.startAgent", { sessionId, ...params }),
/**
- * Calls `session.tasks.list`.
+ * Lists background tasks tracked by the session.
+ *
+ * @returns Background tasks currently tracked by the session.
*/
list: async (): Promise =>
connection.sendRequest("session.tasks.list", { sessionId }),
/**
- * Calls `session.tasks.promoteToBackground`.
+ * Promotes an eligible synchronously-waited task so it continues running in the background.
+ *
+ * @param params Identifier of the task to promote to background mode.
+ *
+ * @returns Indicates whether the task was successfully promoted to background mode.
*/
promoteToBackground: async (params: TasksPromoteToBackgroundRequest): Promise =>
connection.sendRequest("session.tasks.promoteToBackground", { sessionId, ...params }),
/**
- * Calls `session.tasks.cancel`.
+ * Cancels a background task.
+ *
+ * @param params Identifier of the background task to cancel.
+ *
+ * @returns Indicates whether the background task was successfully cancelled.
*/
cancel: async (params: TasksCancelRequest): Promise =>
connection.sendRequest("session.tasks.cancel", { sessionId, ...params }),
/**
- * Calls `session.tasks.remove`.
+ * Removes a completed or cancelled background task from tracking.
+ *
+ * @param params Identifier of the completed or cancelled task to remove from tracking.
+ *
+ * @returns Indicates whether the task was removed. False when the task does not exist or is still running/idle.
*/
remove: async (params: TasksRemoveRequest): Promise =>
connection.sendRequest("session.tasks.remove", { sessionId, ...params }),
/**
- * Calls `session.tasks.sendMessage`.
+ * Sends a message to a background agent task.
+ *
+ * @param params Identifier of the target agent task, message content, and optional sender agent ID.
+ *
+ * @returns Indicates whether the message was delivered, with an error message when delivery failed.
*/
sendMessage: async (params: TasksSendMessageRequest): Promise =>
connection.sendRequest("session.tasks.sendMessage", { sessionId, ...params }),
@@ -3086,22 +4411,30 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
skills: {
/**
- * Calls `session.skills.list`.
+ * Lists skills available to the session.
+ *
+ * @returns Skills available to the session, with their enabled state.
*/
list: async (): Promise =>
connection.sendRequest("session.skills.list", { sessionId }),
/**
- * Calls `session.skills.enable`.
+ * Enables a skill for the session.
+ *
+ * @param params Name of the skill to enable for the session.
*/
enable: async (params: SkillsEnableRequest): Promise =>
connection.sendRequest("session.skills.enable", { sessionId, ...params }),
/**
- * Calls `session.skills.disable`.
+ * Disables a skill for the session.
+ *
+ * @param params Name of the skill to disable for the session.
*/
disable: async (params: SkillsDisableRequest): Promise =>
connection.sendRequest("session.skills.disable", { sessionId, ...params }),
/**
- * Calls `session.skills.reload`.
+ * Reloads skill definitions for the session.
+ *
+ * @returns Diagnostics from reloading skill definitions, with warnings and errors as separate lists.
*/
reload: async (): Promise =>
connection.sendRequest("session.skills.reload", { sessionId }),
@@ -3109,29 +4442,39 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
mcp: {
/**
- * Calls `session.mcp.list`.
+ * Lists MCP servers configured for the session and their connection status.
+ *
+ * @returns MCP servers configured for the session, with their connection status.
*/
list: async (): Promise =>
connection.sendRequest("session.mcp.list", { sessionId }),
/**
- * Calls `session.mcp.enable`.
+ * Enables an MCP server for the session.
+ *
+ * @param params Name of the MCP server to enable for the session.
*/
enable: async (params: McpEnableRequest): Promise =>
connection.sendRequest("session.mcp.enable", { sessionId, ...params }),
/**
- * Calls `session.mcp.disable`.
+ * Disables an MCP server for the session.
+ *
+ * @param params Name of the MCP server to disable for the session.
*/
disable: async (params: McpDisableRequest): Promise =>
connection.sendRequest("session.mcp.disable", { sessionId, ...params }),
/**
- * Calls `session.mcp.reload`.
+ * Reloads MCP server connections for the session.
*/
reload: async (): Promise =>
connection.sendRequest("session.mcp.reload", { sessionId }),
/** @experimental */
oauth: {
/**
- * Calls `session.mcp.oauth.login`.
+ * Starts OAuth authentication for a remote MCP server.
+ *
+ * @param params Remote MCP server name and optional overrides controlling reauthentication, OAuth client display name, and the callback success-page copy.
+ *
+ * @returns OAuth authorization URL the caller should open, or empty when cached tokens already authenticated the server.
*/
login: async (params: McpOauthLoginRequest): Promise =>
connection.sendRequest("session.mcp.oauth.login", { sessionId, ...params }),
@@ -3140,7 +4483,9 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
plugins: {
/**
- * Calls `session.plugins.list`.
+ * Lists plugins installed for the session.
+ *
+ * @returns Plugins installed for the session, with their enabled state and version metadata.
*/
list: async (): Promise =>
connection.sendRequest("session.plugins.list", { sessionId }),
@@ -3148,99 +4493,153 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
extensions: {
/**
- * Calls `session.extensions.list`.
+ * Lists extensions discovered for the session and their current status.
+ *
+ * @returns Extensions discovered for the session, with their current status.
*/
list: async (): Promise =>
connection.sendRequest("session.extensions.list", { sessionId }),
/**
- * Calls `session.extensions.enable`.
+ * Enables an extension for the session.
+ *
+ * @param params Source-qualified extension identifier to enable for the session.
*/
enable: async (params: ExtensionsEnableRequest): Promise =>
connection.sendRequest("session.extensions.enable", { sessionId, ...params }),
/**
- * Calls `session.extensions.disable`.
+ * Disables an extension for the session.
+ *
+ * @param params Source-qualified extension identifier to disable for the session.
*/
disable: async (params: ExtensionsDisableRequest): Promise =>
connection.sendRequest("session.extensions.disable", { sessionId, ...params }),
/**
- * Calls `session.extensions.reload`.
+ * Reloads extension definitions and processes for the session.
*/
reload: async (): Promise =>
connection.sendRequest("session.extensions.reload", { sessionId }),
},
tools: {
/**
- * Calls `session.tools.handlePendingToolCall`.
+ * Provides the result for a pending external tool call.
+ *
+ * @param params Pending external tool call request ID, with the tool result or an error describing why it failed.
+ *
+ * @returns Indicates whether the external tool call result was handled successfully.
*/
handlePendingToolCall: async (params: HandlePendingToolCallRequest): Promise =>
connection.sendRequest("session.tools.handlePendingToolCall", { sessionId, ...params }),
},
commands: {
/**
- * Calls `session.commands.list`.
+ * Lists slash commands available in the session.
+ *
+ * @param params Optional filters controlling which command sources to include in the listing.
+ *
+ * @returns Slash commands available in the session, after applying any include/exclude filters.
*/
list: async (params?: CommandsListRequest): Promise =>
connection.sendRequest("session.commands.list", { sessionId, ...params }),
/**
- * Calls `session.commands.invoke`.
+ * Invokes a slash command in the session.
+ *
+ * @param params Slash command name and optional raw input string to invoke.
+ *
+ * @returns Result of invoking the slash command (text output, prompt to send to the agent, or completion).
*/
invoke: async (params: CommandsInvokeRequest): Promise =>
connection.sendRequest("session.commands.invoke", { sessionId, ...params }),
/**
- * Calls `session.commands.handlePendingCommand`.
+ * Reports completion of a pending client-handled slash command.
+ *
+ * @param params Pending command request ID and an optional error if the client handler failed.
+ *
+ * @returns Indicates whether the pending client-handled command was completed successfully.
*/
handlePendingCommand: async (params: CommandsHandlePendingCommandRequest): Promise =>
connection.sendRequest("session.commands.handlePendingCommand", { sessionId, ...params }),
/**
- * Calls `session.commands.respondToQueuedCommand`.
+ * Responds to a queued command request from the session.
+ *
+ * @param params Queued command request ID and the result indicating whether the client handled it.
+ *
+ * @returns Indicates whether the queued-command response was accepted by the session.
*/
respondToQueuedCommand: async (params: CommandsRespondToQueuedCommandRequest): Promise =>
connection.sendRequest("session.commands.respondToQueuedCommand", { sessionId, ...params }),
},
ui: {
/**
- * Calls `session.ui.elicitation`.
+ * Requests structured input from a UI-capable client.
+ *
+ * @param params Prompt message and JSON schema describing the form fields to elicit from the user.
*
* @returns The elicitation response (accept with form values, decline, or cancel)
*/
elicitation: async (params: UIElicitationRequest): Promise =>
connection.sendRequest("session.ui.elicitation", { sessionId, ...params }),
/**
- * Calls `session.ui.handlePendingElicitation`.
+ * Provides the user response for a pending elicitation request.
+ *
+ * @param params Pending elicitation request ID and the user's response (accept/decline/cancel + form values).
+ *
+ * @returns Indicates whether the elicitation response was accepted; false if it was already resolved by another client.
*/
handlePendingElicitation: async (params: UIHandlePendingElicitationRequest): Promise =>
connection.sendRequest("session.ui.handlePendingElicitation", { sessionId, ...params }),
},
permissions: {
/**
- * Calls `session.permissions.handlePendingPermissionRequest`.
+ * Provides a decision for a pending tool permission request.
+ *
+ * @param params Pending permission request ID and the decision to apply (approve/reject and scope).
+ *
+ * @returns Indicates whether the permission decision was applied; false when the request was already resolved.
*/
handlePendingPermissionRequest: async (params: PermissionDecisionRequest): Promise =>
connection.sendRequest("session.permissions.handlePendingPermissionRequest", { sessionId, ...params }),
/**
- * Calls `session.permissions.setApproveAll`.
+ * Enables or disables automatic approval of tool permission requests for the session.
+ *
+ * @param params Whether to auto-approve all tool permission requests for the rest of the session.
+ *
+ * @returns Indicates whether the operation succeeded.
*/
setApproveAll: async (params: PermissionsSetApproveAllRequest): Promise =>
connection.sendRequest("session.permissions.setApproveAll", { sessionId, ...params }),
/**
- * Calls `session.permissions.resetSessionApprovals`.
+ * Clears session-scoped tool permission approvals.
+ *
+ * @returns Indicates whether the operation succeeded.
*/
resetSessionApprovals: async (): Promise =>
connection.sendRequest("session.permissions.resetSessionApprovals", { sessionId }),
},
/**
- * Calls `session.log`.
+ * Emits a user-visible session log event.
+ *
+ * @param params Message text, optional severity level, persistence flag, and optional follow-up URL.
+ *
+ * @returns Identifier of the session event that was emitted for the log message.
*/
log: async (params: LogRequest): Promise =>
connection.sendRequest("session.log", { sessionId, ...params }),
shell: {
/**
- * Calls `session.shell.exec`.
+ * Starts a shell command and streams output through session notifications.
+ *
+ * @param params Shell command to run, with optional working directory and timeout in milliseconds.
+ *
+ * @returns Identifier of the spawned process, used to correlate streamed output and exit notifications.
*/
exec: async (params: ShellExecRequest): Promise =>
connection.sendRequest("session.shell.exec", { sessionId, ...params }),
/**
- * Calls `session.shell.kill`.
+ * Sends a signal to a shell process previously started via "shell.exec".
+ *
+ * @param params Identifier of a process previously returned by "shell.exec" and the signal to send.
+ *
+ * @returns Indicates whether the signal was delivered; false if the process was unknown or already exited.
*/
kill: async (params: ShellKillRequest): Promise =>
connection.sendRequest("session.shell.kill", { sessionId, ...params }),
@@ -3248,12 +4647,18 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
history: {
/**
- * Calls `session.history.compact`.
+ * Compacts the session history to reduce context usage.
+ *
+ * @returns Compaction outcome with the number of tokens and messages removed and the resulting context window breakdown.
*/
compact: async (): Promise =>
connection.sendRequest("session.history.compact", { sessionId }),
/**
- * Calls `session.history.truncate`.
+ * Truncates persisted session history to a specific event.
+ *
+ * @param params Identifier of the event to truncate to; this event and all later events are removed.
+ *
+ * @returns Number of events that were removed by the truncation.
*/
truncate: async (params: HistoryTruncateRequest): Promise =>
connection.sendRequest("session.history.truncate", { sessionId, ...params }),
@@ -3261,7 +4666,9 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
usage: {
/**
- * Calls `session.usage.getMetrics`.
+ * Gets accumulated usage metrics for the session.
+ *
+ * @returns Accumulated session usage metrics, including premium request cost, token counts, model breakdown, and code-change totals.
*/
getMetrics: async (): Promise =>
connection.sendRequest("session.usage.getMetrics", { sessionId }),
@@ -3269,12 +4676,16 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** @experimental */
remote: {
/**
- * Calls `session.remote.enable`.
+ * Enables remote session export or steering.
+ *
+ * @param params Optional remote session mode ("off", "export", or "on"); defaults to enabling both export and remote steering.
+ *
+ * @returns GitHub URL for the session and a flag indicating whether remote steering is enabled.
*/
enable: async (params: RemoteEnableRequest): Promise =>
connection.sendRequest("session.remote.enable", { sessionId, ...params }),
/**
- * Calls `session.remote.disable`.
+ * Disables remote session export and steering.
*/
disable: async (): Promise =>
connection.sendRequest("session.remote.disable", { sessionId }),
@@ -3285,51 +4696,81 @@ export function createSessionRpc(connection: MessageConnection, sessionId: strin
/** Handler for `sessionFs` client session API methods. */
export interface SessionFsHandler {
/**
- * Handles `sessionFs.readFile`.
+ * Reads a file from the client-provided session filesystem.
+ *
+ * @param params Path of the file to read from the client-provided session filesystem.
+ *
+ * @returns File content as a UTF-8 string, or a filesystem error if the read failed.
*/
readFile(params: SessionFsReadFileRequest): Promise;
/**
- * Handles `sessionFs.writeFile`.
+ * Writes a file in the client-provided session filesystem.
+ *
+ * @param params File path, content to write, and optional mode for the client-provided session filesystem.
*
* @returns Describes a filesystem error.
*/
writeFile(params: SessionFsWriteFileRequest): Promise;
/**
- * Handles `sessionFs.appendFile`.
+ * Appends content to a file in the client-provided session filesystem.
+ *
+ * @param params File path, content to append, and optional mode for the client-provided session filesystem.
*
* @returns Describes a filesystem error.
*/
appendFile(params: SessionFsAppendFileRequest): Promise;
/**
- * Handles `sessionFs.exists`.
+ * Checks whether a path exists in the client-provided session filesystem.
+ *
+ * @param params Path to test for existence in the client-provided session filesystem.
+ *
+ * @returns Indicates whether the requested path exists in the client-provided session filesystem.
*/
exists(params: SessionFsExistsRequest): Promise;
/**
- * Handles `sessionFs.stat`.
+ * Gets metadata for a path in the client-provided session filesystem.
+ *
+ * @param params Path whose metadata should be returned from the client-provided session filesystem.
+ *
+ * @returns Filesystem metadata for the requested path, or a filesystem error if the stat failed.
*/
stat(params: SessionFsStatRequest): Promise;
/**
- * Handles `sessionFs.mkdir`.
+ * Creates a directory in the client-provided session filesystem.
+ *
+ * @param params Directory path to create in the client-provided session filesystem, with options for recursive creation and POSIX mode.
*
* @returns Describes a filesystem error.
*/
mkdir(params: SessionFsMkdirRequest): Promise;
/**
- * Handles `sessionFs.readdir`.
+ * Lists entry names in a directory from the client-provided session filesystem.
+ *
+ * @param params Directory path whose entries should be listed from the client-provided session filesystem.
+ *
+ * @returns Names of entries in the requested directory, or a filesystem error if the read failed.
*/
readdir(params: SessionFsReaddirRequest): Promise;
/**
- * Handles `sessionFs.readdirWithTypes`.
+ * Lists directory entries with type information from the client-provided session filesystem.
+ *
+ * @param params Directory path whose entries (with type information) should be listed from the client-provided session filesystem.
+ *
+ * @returns Entries in the requested directory paired with file/directory type information, or a filesystem error if the read failed.
*/
readdirWithTypes(params: SessionFsReaddirWithTypesRequest): Promise;
/**
- * Handles `sessionFs.rm`.
+ * Removes a file or directory from the client-provided session filesystem.
+ *
+ * @param params Path to remove from the client-provided session filesystem, with options for recursive removal and force.
*
* @returns Describes a filesystem error.
*/
rm(params: SessionFsRmRequest): Promise;
/**
- * Handles `sessionFs.rename`.
+ * Renames or moves a path in the client-provided session filesystem.
+ *
+ * @param params Source and destination paths for renaming or moving an entry in the client-provided session filesystem.
*
* @returns Describes a filesystem error.
*/
diff --git a/nodejs/src/generated/session-events.ts b/nodejs/src/generated/session-events.ts
index e90f9e7a3..5b5404975 100644
--- a/nodejs/src/generated/session-events.ts
+++ b/nodejs/src/generated/session-events.ts
@@ -3,6 +3,9 @@
* Generated from: session-events.schema.json
*/
+/**
+ * Union of all session event variants emitted by the Copilot CLI runtime.
+ */
export type SessionEvent =
| StartEvent
| ResumeEvent
@@ -89,6 +92,10 @@ export type SessionEvent =
* Hosting platform type of the repository (github or ado)
*/
export type WorkingDirectoryContextHostType = "github" | "ado";
+/**
+ * Reasoning summary mode used for model calls, if applicable (e.g. "none", "concise", "detailed")
+ */
+export type ReasoningSummary = "none" | "concise" | "detailed";
/**
* The type of operation performed on the plan file
*/
@@ -256,6 +263,9 @@ export type ElicitationRequestedMode = "form" | "url";
* The user action: "accept" (submitted form), "decline" (explicitly refused), or "cancel" (dismissed)
*/
export type ElicitationCompletedAction = "accept" | "decline" | "cancel";
+/**
+ * Schema for the `ElicitationCompletedContent` type.
+ */
export type ElicitationCompletedContent = string | number | boolean | string[];
/**
* Source-defined JSON payload for the custom notification
@@ -298,6 +308,9 @@ export type ExtensionsLoadedExtensionSource = "project" | "user";
*/
export type ExtensionsLoadedExtensionStatus = "running" | "disabled" | "failed" | "starting";
+/**
+ * Session event "session.start". Session initialization metadata including context and configuration
+ */
export interface StartEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -320,6 +333,9 @@ export interface StartEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.start".
+ */
type: "session.start";
}
/**
@@ -344,11 +360,12 @@ export interface StartData {
*/
producer: string;
/**
- * Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh")
+ * Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh")
*/
reasoningEffort?: string;
+ reasoningSummary?: ReasoningSummary;
/**
- * Whether this session supports remote steering via Mission Control
+ * Whether this session supports remote steering via GitHub
*/
remoteSteerable?: boolean;
/**
@@ -402,6 +419,9 @@ export interface WorkingDirectoryContext {
*/
repositoryHost?: string;
}
+/**
+ * Session event "session.resume". Session resume metadata including current context and event count
+ */
export interface ResumeEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -424,6 +444,9 @@ export interface ResumeEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.resume".
+ */
type: "session.resume";
}
/**
@@ -444,11 +467,12 @@ export interface ResumeData {
*/
eventCount: number;
/**
- * Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh")
+ * Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh")
*/
reasoningEffort?: string;
+ reasoningSummary?: ReasoningSummary;
/**
- * Whether this session supports remote steering via Mission Control
+ * Whether this session supports remote steering via GitHub
*/
remoteSteerable?: boolean;
/**
@@ -464,6 +488,9 @@ export interface ResumeData {
*/
sessionWasActive?: boolean;
}
+/**
+ * Session event "session.remote_steerable_changed". Notifies that the session's remote steering capability has changed
+ */
export interface RemoteSteerableChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -486,17 +513,23 @@ export interface RemoteSteerableChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.remote_steerable_changed".
+ */
type: "session.remote_steerable_changed";
}
/**
- * Notifies Mission Control that the session's remote steering capability has changed
+ * Notifies that the session's remote steering capability has changed
*/
export interface RemoteSteerableChangedData {
/**
- * Whether this session now supports remote steering via Mission Control
+ * Whether this session now supports remote steering via GitHub
*/
remoteSteerable: boolean;
}
+/**
+ * Session event "session.error". Error details for timeline display including message and optional diagnostic information
+ */
export interface ErrorEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -519,6 +552,9 @@ export interface ErrorEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.error".
+ */
type: "session.error";
}
/**
@@ -558,12 +594,18 @@ export interface ErrorData {
*/
url?: string;
}
+/**
+ * Session event "session.idle". Payload indicating the session is idle with no background agents in flight
+ */
export interface IdleEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: IdleData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -577,6 +619,9 @@ export interface IdleEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.idle".
+ */
type: "session.idle";
}
/**
@@ -588,12 +633,18 @@ export interface IdleData {
*/
aborted?: boolean;
}
+/**
+ * Session event "session.title_changed". Session title change payload containing the new display title
+ */
export interface TitleChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: TitleChangedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -607,6 +658,9 @@ export interface TitleChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.title_changed".
+ */
type: "session.title_changed";
}
/**
@@ -618,6 +672,9 @@ export interface TitleChangedData {
*/
title: string;
}
+/**
+ * Session event "session.schedule_created". Scheduled prompt registered via /every or /after
+ */
export interface ScheduleCreatedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -640,12 +697,19 @@ export interface ScheduleCreatedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.schedule_created".
+ */
type: "session.schedule_created";
}
/**
* Scheduled prompt registered via /every or /after
*/
export interface ScheduleCreatedData {
+ /**
+ * Optional user-facing label shown in the timeline instead of the actual prompt (e.g. `/skill-name args` when the prompt is a skill invocation expansion)
+ */
+ displayPrompt?: string;
/**
* Sequential id assigned to the scheduled prompt within the session
*/
@@ -663,6 +727,9 @@ export interface ScheduleCreatedData {
*/
recurring?: boolean;
}
+/**
+ * Session event "session.schedule_cancelled". Scheduled prompt cancelled from the schedule manager dialog
+ */
export interface ScheduleCancelledEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -685,6 +752,9 @@ export interface ScheduleCancelledEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.schedule_cancelled".
+ */
type: "session.schedule_cancelled";
}
/**
@@ -696,6 +766,9 @@ export interface ScheduleCancelledData {
*/
id: number;
}
+/**
+ * Session event "session.info". Informational message for timeline display with categorization
+ */
export interface InfoEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -718,6 +791,9 @@ export interface InfoEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.info".
+ */
type: "session.info";
}
/**
@@ -741,6 +817,9 @@ export interface InfoData {
*/
url?: string;
}
+/**
+ * Session event "session.warning". Warning message for timeline display with categorization
+ */
export interface WarningEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -763,6 +842,9 @@ export interface WarningEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.warning".
+ */
type: "session.warning";
}
/**
@@ -782,6 +864,9 @@ export interface WarningData {
*/
warningType: string;
}
+/**
+ * Session event "session.model_change". Model change details including previous and new model identifiers
+ */
export interface ModelChangeEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -804,6 +889,9 @@ export interface ModelChangeEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.model_change".
+ */
type: "session.model_change";
}
/**
@@ -826,11 +914,16 @@ export interface ModelChangeData {
* Reasoning effort level before the model change, if applicable
*/
previousReasoningEffort?: string;
+ previousReasoningSummary?: ReasoningSummary;
/**
* Reasoning effort level after the model change, if applicable
*/
- reasoningEffort?: string;
+ reasoningEffort?: string | null;
+ reasoningSummary?: ReasoningSummary;
}
+/**
+ * Session event "session.mode_changed". Agent mode change details including previous and new modes
+ */
export interface ModeChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -853,6 +946,9 @@ export interface ModeChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.mode_changed".
+ */
type: "session.mode_changed";
}
/**
@@ -868,6 +964,9 @@ export interface ModeChangedData {
*/
previousMode: string;
}
+/**
+ * Session event "session.plan_changed". Plan file operation details indicating what changed
+ */
export interface PlanChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -890,6 +989,9 @@ export interface PlanChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.plan_changed".
+ */
type: "session.plan_changed";
}
/**
@@ -898,6 +1000,9 @@ export interface PlanChangedEvent {
export interface PlanChangedData {
operation: PlanChangedOperation;
}
+/**
+ * Session event "session.workspace_file_changed". Workspace file change details including path and operation type
+ */
export interface WorkspaceFileChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -920,6 +1025,9 @@ export interface WorkspaceFileChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.workspace_file_changed".
+ */
type: "session.workspace_file_changed";
}
/**
@@ -932,6 +1040,9 @@ export interface WorkspaceFileChangedData {
*/
path: string;
}
+/**
+ * Session event "session.handoff". Session handoff metadata including source, context, and repository information
+ */
export interface HandoffEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -954,6 +1065,9 @@ export interface HandoffEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.handoff".
+ */
type: "session.handoff";
}
/**
@@ -1000,6 +1114,9 @@ export interface HandoffRepository {
*/
owner: string;
}
+/**
+ * Session event "session.truncation". Conversation truncation statistics including token counts and removed content metrics
+ */
export interface TruncationEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1022,6 +1139,9 @@ export interface TruncationEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.truncation".
+ */
type: "session.truncation";
}
/**
@@ -1061,12 +1181,18 @@ export interface TruncationData {
*/
tokensRemovedDuringTruncation: number;
}
+/**
+ * Session event "session.snapshot_rewind". Session rewind details including target event and count of removed events
+ */
export interface SnapshotRewindEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: SnapshotRewindData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -1080,6 +1206,9 @@ export interface SnapshotRewindEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.snapshot_rewind".
+ */
type: "session.snapshot_rewind";
}
/**
@@ -1095,6 +1224,9 @@ export interface SnapshotRewindData {
*/
upToEventId: string;
}
+/**
+ * Session event "session.shutdown". Session termination metrics including usage statistics, code changes, and shutdown reason
+ */
export interface ShutdownEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1117,6 +1249,9 @@ export interface ShutdownEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.shutdown".
+ */
type: "session.shutdown";
}
/**
@@ -1195,6 +1330,9 @@ export interface ShutdownCodeChanges {
*/
linesRemoved: number;
}
+/**
+ * Schema for the `ShutdownModelMetric` type.
+ */
export interface ShutdownModelMetric {
requests: ShutdownModelMetricRequests;
/**
@@ -1222,6 +1360,9 @@ export interface ShutdownModelMetricRequests {
*/
count: number;
}
+/**
+ * Schema for the `ShutdownModelMetricTokenDetail` type.
+ */
export interface ShutdownModelMetricTokenDetail {
/**
* Accumulated token count for this token type
@@ -1253,12 +1394,18 @@ export interface ShutdownModelMetricUsage {
*/
reasoningTokens?: number;
}
+/**
+ * Schema for the `ShutdownTokenDetail` type.
+ */
export interface ShutdownTokenDetail {
/**
* Accumulated token count for this token type
*/
tokenCount: number;
}
+/**
+ * Session event "session.context_changed". Updated working directory and git context after the change
+ */
export interface ContextChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1281,14 +1428,23 @@ export interface ContextChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.context_changed".
+ */
type: "session.context_changed";
}
+/**
+ * Session event "session.usage_info". Current context window usage statistics including token and message counts
+ */
export interface UsageInfoEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: UsageInfoData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -1302,6 +1458,9 @@ export interface UsageInfoEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.usage_info".
+ */
type: "session.usage_info";
}
/**
@@ -1337,6 +1496,9 @@ export interface UsageInfoData {
*/
toolDefinitionsTokens?: number;
}
+/**
+ * Session event "session.compaction_start". Context window breakdown at the start of LLM-powered conversation compaction
+ */
export interface CompactionStartEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1359,6 +1521,9 @@ export interface CompactionStartEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.compaction_start".
+ */
type: "session.compaction_start";
}
/**
@@ -1378,6 +1543,9 @@ export interface CompactionStartData {
*/
toolDefinitionsTokens?: number;
}
+/**
+ * Session event "session.compaction_complete". Conversation compaction results including success status, metrics, and optional error details
+ */
export interface CompactionCompleteEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1400,6 +1568,9 @@ export interface CompactionCompleteEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.compaction_complete".
+ */
type: "session.compaction_complete";
}
/**
@@ -1528,6 +1699,9 @@ export interface CompactionCompleteCompactionTokensUsedCopilotUsageTokenDetail {
*/
tokenType: string;
}
+/**
+ * Session event "session.task_complete". Task completion notification with summary from the agent
+ */
export interface TaskCompleteEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1550,6 +1724,9 @@ export interface TaskCompleteEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.task_complete".
+ */
type: "session.task_complete";
}
/**
@@ -1565,6 +1742,9 @@ export interface TaskCompleteData {
*/
summary?: string;
}
+/**
+ * Session event "user.message".
+ */
export interface UserMessageEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1587,8 +1767,14 @@ export interface UserMessageEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "user.message".
+ */
type: "user.message";
}
+/**
+ * Schema for the `UserMessageData` type.
+ */
export interface UserMessageData {
agentMode?: UserMessageAgentMode;
/**
@@ -1778,12 +1964,18 @@ export interface UserMessageAttachmentBlob {
*/
type: "blob";
}
+/**
+ * Session event "pending_messages.modified". Empty payload; the event signals that the pending message queue has changed
+ */
export interface PendingMessagesModifiedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: PendingMessagesModifiedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -1797,12 +1989,18 @@ export interface PendingMessagesModifiedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "pending_messages.modified".
+ */
type: "pending_messages.modified";
}
/**
* Empty payload; the event signals that the pending message queue has changed
*/
export interface PendingMessagesModifiedData {}
+/**
+ * Session event "assistant.turn_start". Turn initialization metadata including identifier and interaction tracking
+ */
export interface AssistantTurnStartEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1825,6 +2023,9 @@ export interface AssistantTurnStartEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.turn_start".
+ */
type: "assistant.turn_start";
}
/**
@@ -1840,12 +2041,18 @@ export interface AssistantTurnStartData {
*/
turnId: string;
}
+/**
+ * Session event "assistant.intent". Agent intent description for current activity or plan
+ */
export interface AssistantIntentEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AssistantIntentData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -1859,6 +2066,9 @@ export interface AssistantIntentEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.intent".
+ */
type: "assistant.intent";
}
/**
@@ -1870,6 +2080,9 @@ export interface AssistantIntentData {
*/
intent: string;
}
+/**
+ * Session event "assistant.reasoning". Assistant reasoning content for timeline display with complete thinking text
+ */
export interface AssistantReasoningEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1892,6 +2105,9 @@ export interface AssistantReasoningEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.reasoning".
+ */
type: "assistant.reasoning";
}
/**
@@ -1907,12 +2123,18 @@ export interface AssistantReasoningData {
*/
reasoningId: string;
}
+/**
+ * Session event "assistant.reasoning_delta". Streaming reasoning delta for incremental extended thinking updates
+ */
export interface AssistantReasoningDeltaEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AssistantReasoningDeltaData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -1926,6 +2148,9 @@ export interface AssistantReasoningDeltaEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.reasoning_delta".
+ */
type: "assistant.reasoning_delta";
}
/**
@@ -1941,12 +2166,18 @@ export interface AssistantReasoningDeltaData {
*/
reasoningId: string;
}
+/**
+ * Session event "assistant.streaming_delta". Streaming response progress with cumulative byte count
+ */
export interface AssistantStreamingDeltaEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AssistantStreamingDeltaData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -1960,6 +2191,9 @@ export interface AssistantStreamingDeltaEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.streaming_delta".
+ */
type: "assistant.streaming_delta";
}
/**
@@ -1971,6 +2205,9 @@ export interface AssistantStreamingDeltaData {
*/
totalResponseSizeBytes: number;
}
+/**
+ * Session event "assistant.message". Assistant response containing text content, optional tool requests, and interaction metadata
+ */
export interface AssistantMessageEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -1993,6 +2230,9 @@ export interface AssistantMessageEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.message".
+ */
type: "assistant.message";
}
/**
@@ -2097,12 +2337,18 @@ export interface AssistantMessageToolRequest {
toolTitle?: string;
type?: AssistantMessageToolRequestType;
}
+/**
+ * Session event "assistant.message_start". Streaming assistant message start metadata
+ */
export interface AssistantMessageStartEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AssistantMessageStartData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -2116,6 +2362,9 @@ export interface AssistantMessageStartEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.message_start".
+ */
type: "assistant.message_start";
}
/**
@@ -2131,12 +2380,18 @@ export interface AssistantMessageStartData {
*/
phase?: string;
}
+/**
+ * Session event "assistant.message_delta". Streaming assistant message delta for incremental response updates
+ */
export interface AssistantMessageDeltaEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AssistantMessageDeltaData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -2150,6 +2405,9 @@ export interface AssistantMessageDeltaEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.message_delta".
+ */
type: "assistant.message_delta";
}
/**
@@ -2170,6 +2428,9 @@ export interface AssistantMessageDeltaData {
*/
parentToolCallId?: string;
}
+/**
+ * Session event "assistant.turn_end". Turn completion metadata including the turn identifier
+ */
export interface AssistantTurnEndEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -2192,6 +2453,9 @@ export interface AssistantTurnEndEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.turn_end".
+ */
type: "assistant.turn_end";
}
/**
@@ -2203,12 +2467,18 @@ export interface AssistantTurnEndData {
*/
turnId: string;
}
+/**
+ * Session event "assistant.usage". LLM API call usage metrics including tokens, costs, quotas, and billing information
+ */
export interface AssistantUsageEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AssistantUsageData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -2222,6 +2492,9 @@ export interface AssistantUsageEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "assistant.usage".
+ */
type: "assistant.usage";
}
/**
@@ -2286,7 +2559,7 @@ export interface AssistantUsageData {
[k: string]: AssistantUsageQuotaSnapshot;
};
/**
- * Reasoning effort level used for model calls, if applicable (e.g. "low", "medium", "high", "xhigh")
+ * Reasoning effort level used for model calls, if applicable (e.g. "none", "low", "medium", "high", "xhigh")
*/
reasoningEffort?: string;
/**
@@ -2332,6 +2605,9 @@ export interface AssistantUsageCopilotUsageTokenDetail {
*/
tokenType: string;
}
+/**
+ * Schema for the `AssistantUsageQuotaSnapshot` type.
+ */
export interface AssistantUsageQuotaSnapshot {
/**
* Total requests allowed by the entitlement
@@ -2366,12 +2642,18 @@ export interface AssistantUsageQuotaSnapshot {
*/
usedRequests: number;
}
+/**
+ * Session event "model.call_failure". Failed LLM API call metadata for telemetry
+ */
export interface ModelCallFailureEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ModelCallFailureData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -2385,6 +2667,9 @@ export interface ModelCallFailureEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "model.call_failure".
+ */
type: "model.call_failure";
}
/**
@@ -2421,6 +2706,9 @@ export interface ModelCallFailureData {
*/
statusCode?: number;
}
+/**
+ * Session event "abort". Turn abort information including the reason for termination
+ */
export interface AbortEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -2443,6 +2731,9 @@ export interface AbortEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "abort".
+ */
type: "abort";
}
/**
@@ -2451,6 +2742,9 @@ export interface AbortEvent {
export interface AbortData {
reason: AbortReason;
}
+/**
+ * Session event "tool.user_requested". User-initiated tool invocation request with tool name and arguments
+ */
export interface ToolUserRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -2473,6 +2767,9 @@ export interface ToolUserRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "tool.user_requested".
+ */
type: "tool.user_requested";
}
/**
@@ -2494,6 +2791,9 @@ export interface ToolUserRequestedData {
*/
toolName: string;
}
+/**
+ * Session event "tool.execution_start". Tool execution startup details including MCP server information when applicable
+ */
export interface ToolExecutionStartEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -2516,6 +2816,9 @@ export interface ToolExecutionStartEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "tool.execution_start".
+ */
type: "tool.execution_start";
}
/**
@@ -2554,12 +2857,18 @@ export interface ToolExecutionStartData {
*/
turnId?: string;
}
+/**
+ * Session event "tool.execution_partial_result". Streaming tool execution output for incremental result display
+ */
export interface ToolExecutionPartialResultEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ToolExecutionPartialData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -2573,6 +2882,9 @@ export interface ToolExecutionPartialResultEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "tool.execution_partial_result".
+ */
type: "tool.execution_partial_result";
}
/**
@@ -2588,12 +2900,18 @@ export interface ToolExecutionPartialData {
*/
toolCallId: string;
}
+/**
+ * Session event "tool.execution_progress". Tool execution progress notification with status message
+ */
export interface ToolExecutionProgressEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ToolExecutionProgressData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -2607,6 +2925,9 @@ export interface ToolExecutionProgressEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "tool.execution_progress".
+ */
type: "tool.execution_progress";
}
/**
@@ -2622,6 +2943,9 @@ export interface ToolExecutionProgressData {
*/
toolCallId: string;
}
+/**
+ * Session event "tool.execution_complete". Tool execution completion results including success status, detailed output, and error information
+ */
export interface ToolExecutionCompleteEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -2644,6 +2968,9 @@ export interface ToolExecutionCompleteEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "tool.execution_complete".
+ */
type: "tool.execution_complete";
}
/**
@@ -2851,6 +3178,9 @@ export interface ToolExecutionCompleteContentResource {
*/
type: "resource";
}
+/**
+ * Schema for the `EmbeddedTextResourceContents` type.
+ */
export interface EmbeddedTextResourceContents {
/**
* MIME type of the text content
@@ -2865,6 +3195,9 @@ export interface EmbeddedTextResourceContents {
*/
uri: string;
}
+/**
+ * Schema for the `EmbeddedBlobResourceContents` type.
+ */
export interface EmbeddedBlobResourceContents {
/**
* Base64-encoded binary content of the resource
@@ -2879,6 +3212,9 @@ export interface EmbeddedBlobResourceContents {
*/
uri: string;
}
+/**
+ * Session event "skill.invoked". Skill invocation details including content, allowed tools, and plugin metadata
+ */
export interface SkillInvokedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -2901,6 +3237,9 @@ export interface SkillInvokedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "skill.invoked".
+ */
type: "skill.invoked";
}
/**
@@ -2936,6 +3275,9 @@ export interface SkillInvokedData {
*/
pluginVersion?: string;
}
+/**
+ * Session event "subagent.started". Sub-agent startup details including parent tool call and agent information
+ */
export interface SubagentStartedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -2958,6 +3300,9 @@ export interface SubagentStartedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "subagent.started".
+ */
type: "subagent.started";
}
/**
@@ -2985,6 +3330,9 @@ export interface SubagentStartedData {
*/
toolCallId: string;
}
+/**
+ * Session event "subagent.completed". Sub-agent completion details for successful execution
+ */
export interface SubagentCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3007,6 +3355,9 @@ export interface SubagentCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "subagent.completed".
+ */
type: "subagent.completed";
}
/**
@@ -3042,6 +3393,9 @@ export interface SubagentCompletedData {
*/
totalToolCalls?: number;
}
+/**
+ * Session event "subagent.failed". Sub-agent failure details including error message and agent information
+ */
export interface SubagentFailedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3064,6 +3418,9 @@ export interface SubagentFailedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "subagent.failed".
+ */
type: "subagent.failed";
}
/**
@@ -3103,6 +3460,9 @@ export interface SubagentFailedData {
*/
totalToolCalls?: number;
}
+/**
+ * Session event "subagent.selected". Custom agent selection details including name and available tools
+ */
export interface SubagentSelectedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3125,6 +3485,9 @@ export interface SubagentSelectedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "subagent.selected".
+ */
type: "subagent.selected";
}
/**
@@ -3144,6 +3507,9 @@ export interface SubagentSelectedData {
*/
tools: string[] | null;
}
+/**
+ * Session event "subagent.deselected". Empty payload; the event signals that the custom agent was deselected, returning to the default agent
+ */
export interface SubagentDeselectedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3166,12 +3532,18 @@ export interface SubagentDeselectedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "subagent.deselected".
+ */
type: "subagent.deselected";
}
/**
* Empty payload; the event signals that the custom agent was deselected, returning to the default agent
*/
export interface SubagentDeselectedData {}
+/**
+ * Session event "hook.start". Hook invocation start details including type and input data
+ */
export interface HookStartEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3194,6 +3566,9 @@ export interface HookStartEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "hook.start".
+ */
type: "hook.start";
}
/**
@@ -3215,6 +3590,9 @@ export interface HookStartData {
[k: string]: unknown;
};
}
+/**
+ * Session event "hook.end". Hook invocation completion details including output, success status, and error information
+ */
export interface HookEndEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3237,6 +3615,9 @@ export interface HookEndEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "hook.end".
+ */
type: "hook.end";
}
/**
@@ -3276,6 +3657,9 @@ export interface HookEndError {
*/
stack?: string;
}
+/**
+ * Session event "system.message". System/developer instruction content with role and optional template metadata
+ */
export interface SystemMessageEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3298,6 +3682,9 @@ export interface SystemMessageEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "system.message".
+ */
type: "system.message";
}
/**
@@ -3330,7 +3717,10 @@ export interface SystemMessageMetadata {
[k: string]: unknown;
};
}
-export interface SystemNotificationEvent {
+/**
+ * Session event "system.notification". System-generated notification for runtime events like background task completion
+ */
+export interface SystemNotificationEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
@@ -3352,6 +3742,9 @@ export interface SystemNotificationEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "system.notification".
+ */
type: "system.notification";
}
/**
@@ -3364,6 +3757,9 @@ export interface SystemNotificationData {
content: string;
kind: SystemNotification;
}
+/**
+ * Schema for the `SystemNotificationAgentCompleted` type.
+ */
export interface SystemNotificationAgentCompleted {
/**
* Unique identifier of the background agent
@@ -3382,8 +3778,14 @@ export interface SystemNotificationAgentCompleted {
*/
prompt?: string;
status: SystemNotificationAgentCompletedStatus;
+ /**
+ * Type discriminator. Always "agent_completed".
+ */
type: "agent_completed";
}
+/**
+ * Schema for the `SystemNotificationAgentIdle` type.
+ */
export interface SystemNotificationAgentIdle {
/**
* Unique identifier of the background agent
@@ -3397,8 +3799,14 @@ export interface SystemNotificationAgentIdle {
* Human-readable description of the agent task
*/
description?: string;
+ /**
+ * Type discriminator. Always "agent_idle".
+ */
type: "agent_idle";
}
+/**
+ * Schema for the `SystemNotificationNewInboxMessage` type.
+ */
export interface SystemNotificationNewInboxMessage {
/**
* Unique identifier of the inbox entry
@@ -3416,8 +3824,14 @@ export interface SystemNotificationNewInboxMessage {
* Short summary shown before the agent decides whether to read the inbox
*/
summary: string;
+ /**
+ * Type discriminator. Always "new_inbox_message".
+ */
type: "new_inbox_message";
}
+/**
+ * Schema for the `SystemNotificationShellCompleted` type.
+ */
export interface SystemNotificationShellCompleted {
/**
* Human-readable description of the command
@@ -3431,8 +3845,14 @@ export interface SystemNotificationShellCompleted {
* Unique identifier of the shell session
*/
shellId: string;
+ /**
+ * Type discriminator. Always "shell_completed".
+ */
type: "shell_completed";
}
+/**
+ * Schema for the `SystemNotificationShellDetachedCompleted` type.
+ */
export interface SystemNotificationShellDetachedCompleted {
/**
* Human-readable description of the command
@@ -3442,8 +3862,14 @@ export interface SystemNotificationShellDetachedCompleted {
* Unique identifier of the detached shell session
*/
shellId: string;
+ /**
+ * Type discriminator. Always "shell_detached_completed".
+ */
type: "shell_detached_completed";
}
+/**
+ * Schema for the `SystemNotificationInstructionDiscovered` type.
+ */
export interface SystemNotificationInstructionDiscovered {
/**
* Human-readable label for the timeline (e.g., 'AGENTS.md from packages/billing/')
@@ -3461,8 +3887,14 @@ export interface SystemNotificationInstructionDiscovered {
* Tool command that triggered discovery (currently always 'view')
*/
triggerTool: string;
+ /**
+ * Type discriminator. Always "instruction_discovered".
+ */
type: "instruction_discovered";
}
+/**
+ * Session event "permission.requested". Permission request notification requiring client approval with request details
+ */
export interface PermissionRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -3485,6 +3917,9 @@ export interface PermissionRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "permission.requested".
+ */
type: "permission.requested";
}
/**
@@ -3547,6 +3982,9 @@ export interface PermissionRequestShell {
*/
warning?: string;
}
+/**
+ * Schema for the `PermissionRequestShellCommand` type.
+ */
export interface PermissionRequestShellCommand {
/**
* Command identifier (e.g., executable name)
@@ -3557,6 +3995,9 @@ export interface PermissionRequestShellCommand {
*/
readOnly: boolean;
}
+/**
+ * Schema for the `PermissionRequestShellPossibleUrl` type.
+ */
export interface PermissionRequestShellPossibleUrl {
/**
* URL that may be accessed by the command
@@ -4079,6 +4520,9 @@ export interface PermissionPromptRequestExtensionPermissionAccess {
*/
toolCallId?: string;
}
+/**
+ * Session event "permission.completed". Permission request completion notification signaling UI dismissal
+ */
export interface PermissionCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -4101,6 +4545,9 @@ export interface PermissionCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "permission.completed".
+ */
type: "permission.completed";
}
/**
@@ -4117,12 +4564,18 @@ export interface PermissionCompletedData {
*/
toolCallId?: string;
}
+/**
+ * Schema for the `PermissionApproved` type.
+ */
export interface PermissionApproved {
/**
* The permission request was approved
*/
kind: "approved";
}
+/**
+ * Schema for the `PermissionApprovedForSession` type.
+ */
export interface PermissionApprovedForSession {
approval: UserToolSessionApproval;
/**
@@ -4130,6 +4583,9 @@ export interface PermissionApprovedForSession {
*/
kind: "approved-for-session";
}
+/**
+ * Schema for the `UserToolSessionApprovalCommands` type.
+ */
export interface UserToolSessionApprovalCommands {
/**
* Command identifiers approved by the user
@@ -4140,18 +4596,27 @@ export interface UserToolSessionApprovalCommands {
*/
kind: "commands";
}
+/**
+ * Schema for the `UserToolSessionApprovalRead` type.
+ */
export interface UserToolSessionApprovalRead {
/**
* Read approval kind
*/
kind: "read";
}
+/**
+ * Schema for the `UserToolSessionApprovalWrite` type.
+ */
export interface UserToolSessionApprovalWrite {
/**
* Write approval kind
*/
kind: "write";
}
+/**
+ * Schema for the `UserToolSessionApprovalMcp` type.
+ */
export interface UserToolSessionApprovalMcp {
/**
* MCP tool approval kind
@@ -4166,12 +4631,18 @@ export interface UserToolSessionApprovalMcp {
*/
toolName: string | null;
}
+/**
+ * Schema for the `UserToolSessionApprovalMemory` type.
+ */
export interface UserToolSessionApprovalMemory {
/**
* Memory approval kind
*/
kind: "memory";
}
+/**
+ * Schema for the `UserToolSessionApprovalCustomTool` type.
+ */
export interface UserToolSessionApprovalCustomTool {
/**
* Custom tool approval kind
@@ -4182,6 +4653,9 @@ export interface UserToolSessionApprovalCustomTool {
*/
toolName: string;
}
+/**
+ * Schema for the `UserToolSessionApprovalExtensionManagement` type.
+ */
export interface UserToolSessionApprovalExtensionManagement {
/**
* Extension management approval kind
@@ -4192,6 +4666,9 @@ export interface UserToolSessionApprovalExtensionManagement {
*/
operation?: string;
}
+/**
+ * Schema for the `UserToolSessionApprovalExtensionPermissionAccess` type.
+ */
export interface UserToolSessionApprovalExtensionPermissionAccess {
/**
* Extension name
@@ -4202,6 +4679,9 @@ export interface UserToolSessionApprovalExtensionPermissionAccess {
*/
kind: "extension-permission-access";
}
+/**
+ * Schema for the `PermissionApprovedForLocation` type.
+ */
export interface PermissionApprovedForLocation {
approval: UserToolSessionApproval;
/**
@@ -4213,6 +4693,9 @@ export interface PermissionApprovedForLocation {
*/
locationKey: string;
}
+/**
+ * Schema for the `PermissionCancelled` type.
+ */
export interface PermissionCancelled {
/**
* The permission request was cancelled before a response was used
@@ -4223,6 +4706,9 @@ export interface PermissionCancelled {
*/
reason?: string;
}
+/**
+ * Schema for the `PermissionDeniedByRules` type.
+ */
export interface PermissionDeniedByRules {
/**
* Denied because approval rules explicitly blocked it
@@ -4233,6 +4719,9 @@ export interface PermissionDeniedByRules {
*/
rules: PermissionRule[];
}
+/**
+ * Schema for the `PermissionRule` type.
+ */
export interface PermissionRule {
/**
* Optional rule argument matched against the request
@@ -4243,12 +4732,18 @@ export interface PermissionRule {
*/
kind: string;
}
+/**
+ * Schema for the `PermissionDeniedNoApprovalRuleAndCouldNotRequestFromUser` type.
+ */
export interface PermissionDeniedNoApprovalRuleAndCouldNotRequestFromUser {
/**
* Denied because no approval rule matched and user confirmation was unavailable
*/
kind: "denied-no-approval-rule-and-could-not-request-from-user";
}
+/**
+ * Schema for the `PermissionDeniedInteractivelyByUser` type.
+ */
export interface PermissionDeniedInteractivelyByUser {
/**
* Optional feedback from the user explaining the denial
@@ -4263,6 +4758,9 @@ export interface PermissionDeniedInteractivelyByUser {
*/
kind: "denied-interactively-by-user";
}
+/**
+ * Schema for the `PermissionDeniedByContentExclusionPolicy` type.
+ */
export interface PermissionDeniedByContentExclusionPolicy {
/**
* Denied by the organization's content exclusion policy
@@ -4277,6 +4775,9 @@ export interface PermissionDeniedByContentExclusionPolicy {
*/
path: string;
}
+/**
+ * Schema for the `PermissionDeniedByPermissionRequestHook` type.
+ */
export interface PermissionDeniedByPermissionRequestHook {
/**
* Whether to interrupt the current agent turn
@@ -4291,12 +4792,18 @@ export interface PermissionDeniedByPermissionRequestHook {
*/
message?: string;
}
+/**
+ * Session event "user_input.requested". User input request notification with question and optional predefined choices
+ */
export interface UserInputRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: UserInputRequestedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4310,6 +4817,9 @@ export interface UserInputRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "user_input.requested".
+ */
type: "user_input.requested";
}
/**
@@ -4337,12 +4847,18 @@ export interface UserInputRequestedData {
*/
toolCallId?: string;
}
+/**
+ * Session event "user_input.completed". User input request completion with the user's response
+ */
export interface UserInputCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: UserInputCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4356,6 +4872,9 @@ export interface UserInputCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "user_input.completed".
+ */
type: "user_input.completed";
}
/**
@@ -4375,12 +4894,18 @@ export interface UserInputCompletedData {
*/
wasFreeform?: boolean;
}
+/**
+ * Session event "elicitation.requested". Elicitation request; may be form-based (structured input) or URL-based (browser redirect)
+ */
export interface ElicitationRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ElicitationRequestedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4394,6 +4919,9 @@ export interface ElicitationRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "elicitation.requested".
+ */
type: "elicitation.requested";
}
/**
@@ -4443,12 +4971,18 @@ export interface ElicitationRequestedSchema {
*/
type: "object";
}
+/**
+ * Session event "elicitation.completed". Elicitation request completion with the user's response
+ */
export interface ElicitationCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ElicitationCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4462,6 +4996,9 @@ export interface ElicitationCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "elicitation.completed".
+ */
type: "elicitation.completed";
}
/**
@@ -4480,12 +5017,18 @@ export interface ElicitationCompletedData {
*/
requestId: string;
}
+/**
+ * Session event "sampling.requested". Sampling request from an MCP server; contains the server name and a requestId for correlation
+ */
export interface SamplingRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: SamplingRequestedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4499,6 +5042,9 @@ export interface SamplingRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "sampling.requested".
+ */
type: "sampling.requested";
}
/**
@@ -4519,12 +5065,18 @@ export interface SamplingRequestedData {
serverName: string;
[k: string]: unknown;
}
+/**
+ * Session event "sampling.completed". Sampling request completion notification signaling UI dismissal
+ */
export interface SamplingCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: SamplingCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4538,6 +5090,9 @@ export interface SamplingCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "sampling.completed".
+ */
type: "sampling.completed";
}
/**
@@ -4549,12 +5104,18 @@ export interface SamplingCompletedData {
*/
requestId: string;
}
+/**
+ * Session event "mcp.oauth_required". OAuth authentication request for an MCP server
+ */
export interface McpOauthRequiredEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: McpOauthRequiredData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4568,6 +5129,9 @@ export interface McpOauthRequiredEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "mcp.oauth_required".
+ */
type: "mcp.oauth_required";
}
/**
@@ -4605,12 +5169,18 @@ export interface McpOauthRequiredStaticClientConfig {
*/
publicClient?: boolean;
}
+/**
+ * Session event "mcp.oauth_completed". MCP OAuth request completion notification
+ */
export interface McpOauthCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: McpOauthCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4624,6 +5194,9 @@ export interface McpOauthCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "mcp.oauth_completed".
+ */
type: "mcp.oauth_completed";
}
/**
@@ -4635,12 +5208,18 @@ export interface McpOauthCompletedData {
*/
requestId: string;
}
+/**
+ * Session event "session.custom_notification". Opaque custom notification data. Consumers may branch on source and name, but payload semantics are source-defined.
+ */
export interface CustomNotificationEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: CustomNotificationData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4654,6 +5233,9 @@ export interface CustomNotificationEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.custom_notification".
+ */
type: "session.custom_notification";
}
/**
@@ -4681,6 +5263,9 @@ export interface CustomNotificationData {
export interface CustomNotificationSubject {
[k: string]: string;
}
+/**
+ * Session event "external_tool.requested". External tool invocation request for client-side tool execution
+ */
export interface ExternalToolRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
@@ -4703,6 +5288,9 @@ export interface ExternalToolRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "external_tool.requested".
+ */
type: "external_tool.requested";
}
/**
@@ -4740,12 +5328,18 @@ export interface ExternalToolRequestedData {
*/
tracestate?: string;
}
+/**
+ * Session event "external_tool.completed". External tool completion notification signaling UI dismissal
+ */
export interface ExternalToolCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ExternalToolCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral?: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4759,6 +5353,9 @@ export interface ExternalToolCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "external_tool.completed".
+ */
type: "external_tool.completed";
}
/**
@@ -4770,12 +5367,18 @@ export interface ExternalToolCompletedData {
*/
requestId: string;
}
+/**
+ * Session event "command.queued". Queued slash command dispatch request for client execution
+ */
export interface CommandQueuedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: CommandQueuedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4789,6 +5392,9 @@ export interface CommandQueuedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "command.queued".
+ */
type: "command.queued";
}
/**
@@ -4804,12 +5410,18 @@ export interface CommandQueuedData {
*/
requestId: string;
}
+/**
+ * Session event "command.execute". Registered command dispatch request routed to the owning client
+ */
export interface CommandExecuteEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: CommandExecuteData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4823,6 +5435,9 @@ export interface CommandExecuteEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "command.execute".
+ */
type: "command.execute";
}
/**
@@ -4846,12 +5461,18 @@ export interface CommandExecuteData {
*/
requestId: string;
}
+/**
+ * Session event "command.completed". Queued command completion notification signaling UI dismissal
+ */
export interface CommandCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: CommandCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4865,6 +5486,9 @@ export interface CommandCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "command.completed".
+ */
type: "command.completed";
}
/**
@@ -4876,12 +5500,18 @@ export interface CommandCompletedData {
*/
requestId: string;
}
+/**
+ * Session event "auto_mode_switch.requested". Auto mode switch request notification requiring user approval
+ */
export interface AutoModeSwitchRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AutoModeSwitchRequestedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4895,6 +5525,9 @@ export interface AutoModeSwitchRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "auto_mode_switch.requested".
+ */
type: "auto_mode_switch.requested";
}
/**
@@ -4914,12 +5547,18 @@ export interface AutoModeSwitchRequestedData {
*/
retryAfterSeconds?: number;
}
+/**
+ * Session event "auto_mode_switch.completed". Auto mode switch completion notification
+ */
export interface AutoModeSwitchCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: AutoModeSwitchCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4933,6 +5572,9 @@ export interface AutoModeSwitchCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "auto_mode_switch.completed".
+ */
type: "auto_mode_switch.completed";
}
/**
@@ -4948,12 +5590,18 @@ export interface AutoModeSwitchCompletedData {
*/
response: string;
}
+/**
+ * Session event "commands.changed". SDK command registration change notification
+ */
export interface CommandsChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: CommandsChangedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -4967,6 +5615,9 @@ export interface CommandsChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "commands.changed".
+ */
type: "commands.changed";
}
/**
@@ -4978,16 +5629,31 @@ export interface CommandsChangedData {
*/
commands: CommandsChangedCommand[];
}
+/**
+ * Schema for the `CommandsChangedCommand` type.
+ */
export interface CommandsChangedCommand {
+ /**
+ * Optional human-readable command description.
+ */
description?: string;
+ /**
+ * Slash command name without the leading slash.
+ */
name: string;
}
+/**
+ * Session event "capabilities.changed". Session capability change notification
+ */
export interface CapabilitiesChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: CapabilitiesChangedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5001,6 +5667,9 @@ export interface CapabilitiesChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "capabilities.changed".
+ */
type: "capabilities.changed";
}
/**
@@ -5018,12 +5687,18 @@ export interface CapabilitiesChangedUI {
*/
elicitation?: boolean;
}
+/**
+ * Session event "exit_plan_mode.requested". Plan approval request with plan content and available user actions
+ */
export interface ExitPlanModeRequestedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ExitPlanModeRequestedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5037,6 +5712,9 @@ export interface ExitPlanModeRequestedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "exit_plan_mode.requested".
+ */
type: "exit_plan_mode.requested";
}
/**
@@ -5064,12 +5742,18 @@ export interface ExitPlanModeRequestedData {
*/
summary: string;
}
+/**
+ * Session event "exit_plan_mode.completed". Plan mode exit completion with the user's approval decision and optional feedback
+ */
export interface ExitPlanModeCompletedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ExitPlanModeCompletedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5083,6 +5767,9 @@ export interface ExitPlanModeCompletedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "exit_plan_mode.completed".
+ */
type: "exit_plan_mode.completed";
}
/**
@@ -5110,12 +5797,18 @@ export interface ExitPlanModeCompletedData {
*/
selectedAction?: string;
}
+/**
+ * Session event "session.tools_updated".
+ */
export interface ToolsUpdatedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ToolsUpdatedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5129,17 +5822,32 @@ export interface ToolsUpdatedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.tools_updated".
+ */
type: "session.tools_updated";
}
+/**
+ * Schema for the `ToolsUpdatedData` type.
+ */
export interface ToolsUpdatedData {
+ /**
+ * Identifier of the model the resolved tools apply to.
+ */
model: string;
}
+/**
+ * Session event "session.background_tasks_changed".
+ */
export interface BackgroundTasksChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: BackgroundTasksChangedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5153,15 +5861,27 @@ export interface BackgroundTasksChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.background_tasks_changed".
+ */
type: "session.background_tasks_changed";
}
+/**
+ * Schema for the `BackgroundTasksChangedData` type.
+ */
export interface BackgroundTasksChangedData {}
+/**
+ * Session event "session.skills_loaded".
+ */
export interface SkillsLoadedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: SkillsLoadedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5175,14 +5895,23 @@ export interface SkillsLoadedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.skills_loaded".
+ */
type: "session.skills_loaded";
}
+/**
+ * Schema for the `SkillsLoadedData` type.
+ */
export interface SkillsLoadedData {
/**
* Array of resolved skill metadata
*/
skills: SkillsLoadedSkill[];
}
+/**
+ * Schema for the `SkillsLoadedSkill` type.
+ */
export interface SkillsLoadedSkill {
/**
* Description of what the skill does
@@ -5209,12 +5938,18 @@ export interface SkillsLoadedSkill {
*/
userInvocable: boolean;
}
+/**
+ * Session event "session.custom_agents_updated".
+ */
export interface CustomAgentsUpdatedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: CustomAgentsUpdatedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5228,8 +5963,14 @@ export interface CustomAgentsUpdatedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.custom_agents_updated".
+ */
type: "session.custom_agents_updated";
}
+/**
+ * Schema for the `CustomAgentsUpdatedData` type.
+ */
export interface CustomAgentsUpdatedData {
/**
* Array of loaded custom agent metadata
@@ -5244,6 +5985,9 @@ export interface CustomAgentsUpdatedData {
*/
warnings: string[];
}
+/**
+ * Schema for the `CustomAgentsUpdatedAgent` type.
+ */
export interface CustomAgentsUpdatedAgent {
/**
* Description of what the agent does
@@ -5278,12 +6022,18 @@ export interface CustomAgentsUpdatedAgent {
*/
userInvocable: boolean;
}
+/**
+ * Session event "session.mcp_servers_loaded".
+ */
export interface McpServersLoadedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: McpServersLoadedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5297,14 +6047,23 @@ export interface McpServersLoadedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.mcp_servers_loaded".
+ */
type: "session.mcp_servers_loaded";
}
+/**
+ * Schema for the `McpServersLoadedData` type.
+ */
export interface McpServersLoadedData {
/**
* Array of MCP server status summaries
*/
servers: McpServersLoadedServer[];
}
+/**
+ * Schema for the `McpServersLoadedServer` type.
+ */
export interface McpServersLoadedServer {
/**
* Error message if the server failed to connect
@@ -5320,12 +6079,18 @@ export interface McpServersLoadedServer {
source?: string;
status: McpServersLoadedServerStatus;
}
+/**
+ * Session event "session.mcp_server_status_changed".
+ */
export interface McpServerStatusChangedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: McpServerStatusChangedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5339,8 +6104,14 @@ export interface McpServerStatusChangedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.mcp_server_status_changed".
+ */
type: "session.mcp_server_status_changed";
}
+/**
+ * Schema for the `McpServerStatusChangedData` type.
+ */
export interface McpServerStatusChangedData {
/**
* Name of the MCP server whose status changed
@@ -5348,12 +6119,18 @@ export interface McpServerStatusChangedData {
serverName: string;
status: McpServerStatusChangedStatus;
}
+/**
+ * Session event "session.extensions_loaded".
+ */
export interface ExtensionsLoadedEvent {
/**
* Sub-agent instance identifier. Absent for events from the root/main agent and session-level events.
*/
agentId?: string;
data: ExtensionsLoadedData;
+ /**
+ * Always true for events that are transient and not persisted to the session event log on disk.
+ */
ephemeral: true;
/**
* Unique event identifier (UUID v4), generated when the event is emitted
@@ -5367,14 +6144,23 @@ export interface ExtensionsLoadedEvent {
* ISO 8601 timestamp when the event was created
*/
timestamp: string;
+ /**
+ * Type discriminator. Always "session.extensions_loaded".
+ */
type: "session.extensions_loaded";
}
+/**
+ * Schema for the `ExtensionsLoadedData` type.
+ */
export interface ExtensionsLoadedData {
/**
* Array of discovered extensions and their status
*/
extensions: ExtensionsLoadedExtension[];
}
+/**
+ * Schema for the `ExtensionsLoadedExtension` type.
+ */
export interface ExtensionsLoadedExtension {
/**
* Source-qualified extension ID (e.g., 'project:my-ext', 'user:auth-helper')
diff --git a/python/copilot/generated/rpc.py b/python/copilot/generated/rpc.py
index ee5583ab6..4e2e4367a 100644
--- a/python/copilot/generated/rpc.py
+++ b/python/copilot/generated/rpc.py
@@ -5,7 +5,7 @@
from typing import TYPE_CHECKING
-from .session_events import EmbeddedBlobResourceContents, EmbeddedTextResourceContents
+from .session_events import EmbeddedBlobResourceContents, EmbeddedTextResourceContents, ReasoningSummary
if TYPE_CHECKING:
from .._jsonrpc import JsonRpcClient
@@ -95,6 +95,8 @@ def to_dict(self) -> dict:
@dataclass
class AccountQuotaSnapshot:
+ """Schema for the `AccountQuotaSnapshot` type."""
+
entitlement_requests: int
"""Number of requests included in the entitlement"""
@@ -147,8 +149,10 @@ def to_dict(self) -> dict:
@dataclass
class AgentInfo:
- """The newly selected custom agent"""
+ """Schema for the `AgentInfo` type.
+ The newly selected custom agent
+ """
description: str
"""Description of the agent's purpose"""
@@ -184,6 +188,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class AgentSelectRequest:
+ """Name of the custom agent to select for subsequent turns."""
+
name: str
"""Name of the custom agent to select"""
@@ -224,6 +230,8 @@ class SlashCommandKind(Enum):
@dataclass
class CommandsHandlePendingCommandRequest:
+ """Pending command request ID and an optional error if the client handler failed."""
+
request_id: str
"""Request ID from the command invocation event"""
@@ -246,6 +254,8 @@ def to_dict(self) -> dict:
@dataclass
class CommandsHandlePendingCommandResult:
+ """Indicates whether the pending client-handled command was completed successfully."""
+
success: bool
"""Whether the command was handled successfully"""
@@ -262,6 +272,8 @@ def to_dict(self) -> dict:
@dataclass
class CommandsInvokeRequest:
+ """Slash command name and optional raw input string to invoke."""
+
name: str
"""Command name. Leading slashes are stripped and the name is matched case-insensitively."""
@@ -284,6 +296,8 @@ def to_dict(self) -> dict:
@dataclass
class CommandsListRequest:
+ """Optional filters controlling which command sources to include in the listing."""
+
include_builtins: bool | None = None
"""Include runtime built-in commands"""
@@ -311,34 +325,10 @@ def to_dict(self) -> dict:
result["includeSkills"] = from_union([from_bool, from_none], self.include_skills)
return result
-@dataclass
-class QueuedCommandResult:
- """Result of the queued command execution"""
-
- handled: bool
- """The command was handled
-
- The command was not handled
- """
- stop_processing_queue: bool | None = None
- """If true, stop processing remaining queued items"""
-
- @staticmethod
- def from_dict(obj: Any) -> 'QueuedCommandResult':
- assert isinstance(obj, dict)
- handled = from_bool(obj.get("handled"))
- stop_processing_queue = from_union([from_bool, from_none], obj.get("stopProcessingQueue"))
- return QueuedCommandResult(handled, stop_processing_queue)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["handled"] = from_bool(self.handled)
- if self.stop_processing_queue is not None:
- result["stopProcessingQueue"] = from_union([from_bool, from_none], self.stop_processing_queue)
- return result
-
@dataclass
class CommandsRespondToQueuedCommandResult:
+ """Indicates whether the queued-command response was accepted by the session."""
+
success: bool
"""Whether the response was accepted (false if the requestId was not found or already
resolved)
@@ -358,6 +348,8 @@ def to_dict(self) -> dict:
# Internal: this type is an internal SDK API and is not part of the public surface.
@dataclass
class ConnectRequest:
+ """Optional connection token presented by the SDK client during the handshake."""
+
token: str | None = None
"""Connection token; required when the server was started with COPILOT_CONNECTION_TOKEN"""
@@ -376,6 +368,8 @@ def to_dict(self) -> dict:
# Internal: this type is an internal SDK API and is not part of the public surface.
@dataclass
class ConnectResult:
+ """Handshake result reporting the server's protocol version and package version on success."""
+
ok: bool
"""Always true on success"""
@@ -402,6 +396,8 @@ def to_dict(self) -> dict:
@dataclass
class CurrentModel:
+ """The currently selected model for the session."""
+
model_id: str | None = None
"""Currently active model identifier"""
@@ -452,6 +448,8 @@ class ExtensionStatus(Enum):
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class ExtensionsDisableRequest:
+ """Source-qualified extension identifier to disable for the session."""
+
id: str
"""Source-qualified extension ID to disable"""
@@ -469,6 +467,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class ExtensionsEnableRequest:
+ """Source-qualified extension identifier to enable for the session."""
+
id: str
"""Source-qualified extension ID to enable"""
@@ -516,6 +516,10 @@ class KindEnum(Enum):
TEXT = "text"
class FilterMappingString(Enum):
+ """Allowed values for the `FilterMappingValue` enumeration.
+
+ Allowed values for the `FilterMappingString` enumeration.
+ """
HIDDEN_CHARACTERS = "hidden_characters"
MARKDOWN = "markdown"
NONE = "none"
@@ -523,6 +527,8 @@ class FilterMappingString(Enum):
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class FleetStartRequest:
+ """Optional user prompt to combine with the fleet orchestration instructions."""
+
prompt: str | None = None
"""Optional user prompt to combine with fleet instructions"""
@@ -541,6 +547,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class FleetStartResult:
+ """Indicates whether fleet mode was successfully activated."""
+
started: bool
"""Whether fleet mode was successfully activated"""
@@ -557,6 +565,8 @@ def to_dict(self) -> dict:
@dataclass
class HandlePendingToolCallResult:
+ """Indicates whether the external tool call result was handled successfully."""
+
success: bool
"""Whether the tool call result was handled successfully"""
@@ -620,6 +630,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class HistoryTruncateRequest:
+ """Identifier of the event to truncate to; this event and all later events are removed."""
+
event_id: str
"""Event ID to truncate to. This event and all events after it are removed from the session."""
@@ -637,6 +649,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class HistoryTruncateResult:
+ """Number of events that were removed by the truncation."""
+
events_removed: int
"""Number of events that were removed"""
@@ -678,6 +692,8 @@ class SessionLogLevel(Enum):
@dataclass
class LogResult:
+ """Identifier of the session event that was emitted for the log message."""
+
event_id: UUID
"""The unique identifier of the emitted session event"""
@@ -693,12 +709,16 @@ def to_dict(self) -> dict:
return result
class MCPServerConfigHTTPOauthGrantType(Enum):
+ """OAuth grant type to use when authenticating to the remote MCP server."""
+
AUTHORIZATION_CODE = "authorization_code"
CLIENT_CREDENTIALS = "client_credentials"
class MCPServerConfigType(Enum):
- """Remote transport type. Defaults to "http" when omitted."""
+ """Local transport type. Defaults to "local".
+ Remote transport type. Defaults to "http" when omitted.
+ """
HTTP = "http"
LOCAL = "local"
SSE = "sse"
@@ -706,6 +726,8 @@ class MCPServerConfigType(Enum):
@dataclass
class MCPConfigDisableRequest:
+ """MCP server names to disable for new sessions."""
+
names: list[str]
"""Names of MCP servers to disable. Each server is added to the persisted disabled list so
new sessions skip it. Already-disabled names are ignored. Active sessions keep their
@@ -725,6 +747,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPConfigEnableRequest:
+ """MCP server names to enable for new sessions."""
+
names: list[str]
"""Names of MCP servers to enable. Each server is removed from the persisted disabled list
so new sessions spawn it. Unknown or already-enabled names are ignored.
@@ -743,6 +767,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPConfigRemoveRequest:
+ """MCP server name to remove from user configuration."""
+
name: str
"""Name of the MCP server to remove"""
@@ -759,6 +785,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPDisableRequest:
+ """Name of the MCP server to disable for the session."""
+
server_name: str
"""Name of the MCP server to disable"""
@@ -775,6 +803,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPDiscoverRequest:
+ """Optional working directory used as context for MCP server discovery."""
+
working_directory: str | None = None
"""Working directory used as context for discovery (e.g., plugin resolution)"""
@@ -792,6 +822,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPEnableRequest:
+ """Name of the MCP server to enable for the session."""
+
server_name: str
"""Name of the MCP server to enable"""
@@ -808,6 +840,9 @@ def to_dict(self) -> dict:
@dataclass
class MCPOauthLoginRequest:
+ """Remote MCP server name and optional overrides controlling reauthentication, OAuth client
+ display name, and the callback success-page copy.
+ """
server_name: str
"""Name of the remote MCP server to authenticate"""
@@ -851,6 +886,9 @@ def to_dict(self) -> dict:
@dataclass
class MCPOauthLoginResult:
+ """OAuth authorization URL the caller should open, or empty when cached tokens already
+ authenticated the server.
+ """
authorization_url: str | None = None
"""URL the caller should open in a browser to complete OAuth. Omitted when cached tokens
were still valid and no browser interaction was needed — the server is already
@@ -888,6 +926,8 @@ class MCPServerConfigHTTPType(Enum):
SSE = "sse"
class MCPServerConfigLocalType(Enum):
+ """Local transport type. Defaults to "local"."""
+
LOCAL = "local"
STDIO = "stdio"
@@ -1028,6 +1068,8 @@ def to_dict(self) -> dict:
@dataclass
class ModelCapabilitiesOverrideLimitsVision:
+ """Vision-specific limits"""
+
max_prompt_image_size: int | None = None
"""Maximum image size in bytes"""
@@ -1060,7 +1102,10 @@ class ModelCapabilitiesOverrideSupports:
"""Feature flags indicating what the model supports"""
reasoning_effort: bool | None = None
+ """Whether this model supports reasoning effort configuration"""
+
vision: bool | None = None
+ """Whether this model supports vision/image input"""
@staticmethod
def from_dict(obj: Any) -> 'ModelCapabilitiesOverrideSupports':
@@ -1079,6 +1124,8 @@ def to_dict(self) -> dict:
@dataclass
class ModelSwitchToResult:
+ """The model identifier active on the session after the switch."""
+
model_id: str | None = None
"""Currently active model identifier after the switch"""
@@ -1115,6 +1162,8 @@ def to_dict(self) -> dict:
@dataclass
class NameGetResult:
+ """The session's friendly name, or null when not yet set."""
+
name: str | None = None
"""The session name (user-set or auto-generated), or null if not yet set"""
@@ -1131,6 +1180,8 @@ def to_dict(self) -> dict:
@dataclass
class NameSetRequest:
+ """New friendly name to apply to the session."""
+
name: str
"""New session name (1–100 characters, trimmed of leading/trailing whitespace)"""
@@ -1211,6 +1262,9 @@ class PermissionDecisionUserNotAvailableKind(Enum):
@dataclass
class PermissionRequestResult:
+ """Indicates whether the permission decision was applied; false when the request was already
+ resolved.
+ """
success: bool
"""Whether the permission request was handled successfully"""
@@ -1227,6 +1281,7 @@ def to_dict(self) -> dict:
@dataclass
class PermissionsResetSessionApprovalsRequest:
+ """No parameters; clears all session-scoped tool permission approvals."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionsResetSessionApprovalsRequest':
assert isinstance(obj, dict)
@@ -1238,6 +1293,8 @@ def to_dict(self) -> dict:
@dataclass
class PermissionsResetSessionApprovalsResult:
+ """Indicates whether the operation succeeded."""
+
success: bool
"""Whether the operation succeeded"""
@@ -1254,6 +1311,8 @@ def to_dict(self) -> dict:
@dataclass
class PermissionsSetApproveAllRequest:
+ """Whether to auto-approve all tool permission requests for the rest of the session."""
+
enabled: bool
"""Whether to auto-approve all tool permission requests"""
@@ -1270,6 +1329,8 @@ def to_dict(self) -> dict:
@dataclass
class PermissionsSetApproveAllResult:
+ """Indicates whether the operation succeeded."""
+
success: bool
"""Whether the operation succeeded"""
@@ -1286,6 +1347,8 @@ def to_dict(self) -> dict:
@dataclass
class PingRequest:
+ """Optional message to echo back to the caller."""
+
message: str | None = None
"""Optional message to echo back"""
@@ -1303,6 +1366,9 @@ def to_dict(self) -> dict:
@dataclass
class PingResult:
+ """Server liveness response, including the echoed message, current timestamp, and protocol
+ version.
+ """
message: str
"""Echoed message (or default greeting)"""
@@ -1329,6 +1395,8 @@ def to_dict(self) -> dict:
@dataclass
class PlanReadResult:
+ """Existence, contents, and resolved path of the session plan file."""
+
exists: bool
"""Whether the plan file exists in the workspace"""
@@ -1355,6 +1423,8 @@ def to_dict(self) -> dict:
@dataclass
class PlanUpdateRequest:
+ """Replacement contents to write to the session plan file."""
+
content: str
"""The new content for the plan file"""
@@ -1371,6 +1441,8 @@ def to_dict(self) -> dict:
@dataclass
class Plugin:
+ """Schema for the `Plugin` type."""
+
enabled: bool
"""Whether the plugin is currently enabled"""
@@ -1403,6 +1475,8 @@ def to_dict(self) -> dict:
@dataclass
class QueuedCommandHandled:
+ """Schema for the `QueuedCommandHandled` type."""
+
handled: bool
"""The command was handled"""
@@ -1425,6 +1499,8 @@ def to_dict(self) -> dict:
@dataclass
class QueuedCommandNotHandled:
+ """Schema for the `QueuedCommandNotHandled` type."""
+
handled: bool
"""The command was not handled"""
@@ -1440,9 +1516,8 @@ def to_dict(self) -> dict:
return result
class RemoteSessionMode(Enum):
- """Per-session remote mode. "off" disables remote, "export" exports session events to
- Mission Control without enabling remote steering, "on" enables both export and remote
- steering.
+ """Per-session remote mode. "off" disables remote, "export" exports session events to GitHub
+ without enabling remote steering, "on" enables both export and remote steering.
"""
EXPORT = "export"
OFF = "off"
@@ -1451,11 +1526,13 @@ class RemoteSessionMode(Enum):
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class RemoteEnableResult:
+ """GitHub URL for the session and a flag indicating whether remote steering is enabled."""
+
remote_steerable: bool
"""Whether remote steering is enabled"""
url: str | None = None
- """Mission Control frontend URL for this session"""
+ """GitHub frontend URL for this session"""
@staticmethod
def from_dict(obj: Any) -> 'RemoteEnableResult':
@@ -1473,6 +1550,8 @@ def to_dict(self) -> dict:
@dataclass
class ServerSkill:
+ """Schema for the `ServerSkill` type."""
+
description: str
"""Description of what the skill does"""
@@ -1521,6 +1600,9 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSAppendFileRequest:
+ """File path, content to append, and optional mode for the client-provided session
+ filesystem.
+ """
content: str
"""Content to append"""
@@ -1559,6 +1641,8 @@ class SessionFSErrorCode(Enum):
@dataclass
class SessionFSExistsRequest:
+ """Path to test for existence in the client-provided session filesystem."""
+
path: str
"""Path using SessionFs conventions"""
@@ -1580,6 +1664,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSExistsResult:
+ """Indicates whether the requested path exists in the client-provided session filesystem."""
+
exists: bool
"""Whether the path exists"""
@@ -1596,6 +1682,9 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSMkdirRequest:
+ """Directory path to create in the client-provided session filesystem, with options for
+ recursive creation and POSIX mode.
+ """
path: str
"""Path using SessionFs conventions"""
@@ -1629,6 +1718,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSReadFileRequest:
+ """Path of the file to read from the client-provided session filesystem."""
+
path: str
"""Path using SessionFs conventions"""
@@ -1650,6 +1741,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSReaddirRequest:
+ """Directory path whose entries should be listed from the client-provided session filesystem."""
+
path: str
"""Path using SessionFs conventions"""
@@ -1677,6 +1770,9 @@ class SessionFSReaddirWithTypesEntryType(Enum):
@dataclass
class SessionFSReaddirWithTypesRequest:
+ """Directory path whose entries (with type information) should be listed from the
+ client-provided session filesystem.
+ """
path: str
"""Path using SessionFs conventions"""
@@ -1698,6 +1794,9 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSRenameRequest:
+ """Source and destination paths for renaming or moving an entry in the client-provided
+ session filesystem.
+ """
dest: str
"""Destination path using SessionFs conventions"""
@@ -1724,6 +1823,9 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSRmRequest:
+ """Path to remove from the client-provided session filesystem, with options for recursive
+ removal and force.
+ """
path: str
"""Path using SessionFs conventions"""
@@ -1763,6 +1865,8 @@ class SessionFSSetProviderConventions(Enum):
@dataclass
class SessionFSSetProviderResult:
+ """Indicates whether the calling client was registered as the session filesystem provider."""
+
success: bool
"""Whether the provider was set successfully"""
@@ -1779,6 +1883,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSStatRequest:
+ """Path whose metadata should be returned from the client-provided session filesystem."""
+
path: str
"""Path using SessionFs conventions"""
@@ -1800,6 +1906,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSWriteFileRequest:
+ """File path, content to write, and optional mode for the client-provided session filesystem."""
+
content: str
"""Content to write"""
@@ -1833,6 +1941,9 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class SessionsForkRequest:
+ """Source session identifier to fork from, optional event-ID boundary, and optional friendly
+ name for the new session.
+ """
session_id: str
"""Source session ID to fork from"""
@@ -1864,6 +1975,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class SessionsForkResult:
+ """Identifier and optional friendly name assigned to the newly forked session."""
+
session_id: str
"""The new forked session's ID"""
@@ -1886,6 +1999,8 @@ def to_dict(self) -> dict:
@dataclass
class ShellExecRequest:
+ """Shell command to run, with optional working directory and timeout in milliseconds."""
+
command: str
"""Shell command to execute"""
@@ -1914,6 +2029,9 @@ def to_dict(self) -> dict:
@dataclass
class ShellExecResult:
+ """Identifier of the spawned process, used to correlate streamed output and exit
+ notifications.
+ """
process_id: str
"""Unique identifier for tracking streamed output"""
@@ -1937,6 +2055,9 @@ class ShellKillSignal(Enum):
@dataclass
class ShellKillResult:
+ """Indicates whether the signal was delivered; false if the process was unknown or already
+ exited.
+ """
killed: bool
"""Whether the signal was sent successfully"""
@@ -1953,6 +2074,8 @@ def to_dict(self) -> dict:
@dataclass
class Skill:
+ """Schema for the `Skill` type."""
+
description: str
"""Description of what the skill does"""
@@ -1993,25 +2116,11 @@ def to_dict(self) -> dict:
result["path"] = from_union([from_str, from_none], self.path)
return result
-@dataclass
-class SkillsConfigSetDisabledSkillsRequest:
- disabled_skills: list[str]
- """List of skill names to disable"""
-
- @staticmethod
- def from_dict(obj: Any) -> 'SkillsConfigSetDisabledSkillsRequest':
- assert isinstance(obj, dict)
- disabled_skills = from_list(from_str, obj.get("disabledSkills"))
- return SkillsConfigSetDisabledSkillsRequest(disabled_skills)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["disabledSkills"] = from_list(from_str, self.disabled_skills)
- return result
-
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class SkillsDisableRequest:
+ """Name of the skill to disable for the session."""
+
name: str
"""Name of the skill to disable"""
@@ -2028,6 +2137,8 @@ def to_dict(self) -> dict:
@dataclass
class SkillsDiscoverRequest:
+ """Optional project paths and additional skill directories to include in discovery."""
+
project_paths: list[str] | None = None
"""Optional list of project directory paths to scan for project-scoped skills"""
@@ -2052,6 +2163,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class SkillsEnableRequest:
+ """Name of the skill to enable for the session."""
+
name: str
"""Name of the skill to enable"""
@@ -2069,6 +2182,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class SkillsLoadDiagnostics:
+ """Diagnostics from reloading skill definitions, with warnings and errors as separate lists."""
+
errors: list[str]
"""Errors emitted while loading skills (e.g. skills that failed to load entirely)"""
@@ -2136,6 +2251,8 @@ class TaskShellInfoType(Enum):
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksCancelRequest:
+ """Identifier of the background task to cancel."""
+
id: str
"""Task identifier"""
@@ -2153,6 +2270,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksCancelResult:
+ """Indicates whether the background task was successfully cancelled."""
+
cancelled: bool
"""Whether the task was successfully cancelled"""
@@ -2170,6 +2289,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksPromoteToBackgroundRequest:
+ """Identifier of the task to promote to background mode."""
+
id: str
"""Task identifier"""
@@ -2187,6 +2308,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksPromoteToBackgroundResult:
+ """Indicates whether the task was successfully promoted to background mode."""
+
promoted: bool
"""Whether the task was successfully promoted to background mode"""
@@ -2204,6 +2327,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksRemoveRequest:
+ """Identifier of the completed or cancelled task to remove from tracking."""
+
id: str
"""Task identifier"""
@@ -2221,6 +2346,9 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksRemoveResult:
+ """Indicates whether the task was removed. False when the task does not exist or is still
+ running/idle.
+ """
removed: bool
"""Whether the task was removed. Returns false if the task does not exist or is still
running/idle (cancel it first).
@@ -2240,6 +2368,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksSendMessageRequest:
+ """Identifier of the target agent task, message content, and optional sender agent ID."""
+
id: str
"""Agent task identifier"""
@@ -2268,6 +2398,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksSendMessageResult:
+ """Indicates whether the message was delivered, with an error message when delivery failed."""
+
sent: bool
"""Whether the message was successfully delivered or steered"""
@@ -2291,6 +2423,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksStartAgentRequest:
+ """Agent type, prompt, name, and optional description and model override for the new task."""
+
agent_type: str
"""Type of agent to start (e.g., 'explore', 'task', 'general-purpose')"""
@@ -2330,6 +2464,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TasksStartAgentResult:
+ """Identifier assigned to the newly started background agent task."""
+
agent_id: str
"""Generated agent ID for the background task"""
@@ -2346,6 +2482,8 @@ def to_dict(self) -> dict:
@dataclass
class Tool:
+ """Schema for the `Tool` type."""
+
description: str
"""Description of what the tool does"""
@@ -2386,6 +2524,8 @@ def to_dict(self) -> dict:
@dataclass
class ToolsListRequest:
+ """Optional model identifier whose tool overrides should be applied to the listing."""
+
model: str | None = None
"""Optional model ID — when provided, the returned tool list reflects model-specific
overrides
@@ -2405,8 +2545,13 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationArrayAnyOfFieldItemsAnyOf:
+ """Schema for the `UIElicitationArrayAnyOfFieldItemsAnyOf` type."""
+
const: str
+ """Value submitted when this option is selected."""
+
title: str
+ """Display label for this option."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationArrayAnyOfFieldItemsAnyOf':
@@ -2428,6 +2573,8 @@ class UIElicitationArrayEnumFieldItemsType(Enum):
STRING = "string"
class UIElicitationSchemaPropertyStringFormat(Enum):
+ """Optional format hint that constrains the accepted input."""
+
DATE = "date"
DATE_TIME = "date-time"
EMAIL = "email"
@@ -2435,8 +2582,13 @@ class UIElicitationSchemaPropertyStringFormat(Enum):
@dataclass
class UIElicitationStringOneOfFieldOneOf:
+ """Schema for the `UIElicitationStringOneOfFieldOneOf` type."""
+
const: str
+ """Value submitted when this option is selected."""
+
title: str
+ """Display label for this option."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationStringOneOfFieldOneOf':
@@ -2452,6 +2604,8 @@ def to_dict(self) -> dict:
return result
class UIElicitationSchemaPropertyType(Enum):
+ """Numeric type accepted by the field."""
+
ARRAY = "array"
BOOLEAN = "boolean"
INTEGER = "integer"
@@ -2470,6 +2624,9 @@ class UIElicitationResponseAction(Enum):
@dataclass
class UIElicitationResult:
+ """Indicates whether the elicitation response was accepted; false if it was already resolved
+ by another client.
+ """
success: bool
"""Whether the response was accepted. False if the request was already resolved by another
client.
@@ -2490,6 +2647,8 @@ class UIElicitationSchemaPropertyBooleanType(Enum):
BOOLEAN = "boolean"
class UIElicitationSchemaPropertyNumberType(Enum):
+ """Numeric type accepted by the field."""
+
INTEGER = "integer"
NUMBER = "number"
@@ -2546,6 +2705,8 @@ def to_dict(self) -> dict:
@dataclass
class UsageMetricsModelMetricTokenDetail:
+ """Schema for the `UsageMetricsModelMetricTokenDetail` type."""
+
token_count: int
"""Accumulated token count for this token type"""
@@ -2601,6 +2762,8 @@ def to_dict(self) -> dict:
@dataclass
class UsageMetricsTokenDetail:
+ """Schema for the `UsageMetricsTokenDetail` type."""
+
token_count: int
"""Accumulated token count for this token type"""
@@ -2617,6 +2780,8 @@ def to_dict(self) -> dict:
@dataclass
class WorkspacesCreateFileRequest:
+ """Relative path and UTF-8 content for the workspace file to create or overwrite."""
+
content: str
"""File content to write as a UTF-8 string"""
@@ -2642,6 +2807,8 @@ class HostType(Enum):
@dataclass
class WorkspacesListFilesResult:
+ """Relative paths of files stored in the session workspace files directory."""
+
files: list[str]
"""Relative file paths in the workspace files directory"""
@@ -2658,6 +2825,8 @@ def to_dict(self) -> dict:
@dataclass
class WorkspacesReadFileRequest:
+ """Relative path of the workspace file to read."""
+
path: str
"""Relative path within the workspace files directory"""
@@ -2674,6 +2843,8 @@ def to_dict(self) -> dict:
@dataclass
class WorkspacesReadFileResult:
+ """Contents of the requested workspace file as a UTF-8 string."""
+
content: str
"""File content as a UTF-8 string"""
@@ -2690,6 +2861,8 @@ def to_dict(self) -> dict:
@dataclass
class AccountGetQuotaResult:
+ """Quota usage snapshots for the resolved user, keyed by quota type."""
+
quota_snapshots: dict[str, AccountQuotaSnapshot]
"""Quota snapshots keyed by type (e.g., chat, completions, premium_interactions)"""
@@ -2707,6 +2880,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class AgentGetCurrentResult:
+ """The currently selected custom agent, or null when using the default agent."""
+
agent: AgentInfo | None = None
"""Currently selected custom agent, or null if using the default agent"""
@@ -2725,6 +2900,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class AgentList:
+ """Custom agents available to the session."""
+
agents: list[AgentInfo]
"""Available custom agents"""
@@ -2742,6 +2919,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class AgentReloadResult:
+ """Custom agents available to the session after reloading definitions from disk."""
+
agents: list[AgentInfo]
"""Reloaded custom agents"""
@@ -2759,6 +2938,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class AgentSelectResult:
+ """The newly selected custom agent."""
+
agent: AgentInfo
"""The newly selected custom agent"""
@@ -2775,6 +2956,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionAuthStatus:
+ """Authentication status and account metadata for the session."""
+
is_authenticated: bool
"""Whether the session has resolved authentication"""
@@ -2858,29 +3041,10 @@ def to_dict(self) -> dict:
result["required"] = from_union([from_bool, from_none], self.required)
return result
-@dataclass
-class CommandsRespondToQueuedCommandRequest:
- request_id: str
- """Request ID from the queued command event"""
-
- result: QueuedCommandResult
- """Result of the queued command execution"""
-
- @staticmethod
- def from_dict(obj: Any) -> 'CommandsRespondToQueuedCommandRequest':
- assert isinstance(obj, dict)
- request_id = from_str(obj.get("requestId"))
- result = QueuedCommandResult.from_dict(obj.get("result"))
- return CommandsRespondToQueuedCommandRequest(request_id, result)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["requestId"] = from_str(self.request_id)
- result["result"] = to_class(QueuedCommandResult, self.result)
- return result
-
@dataclass
class DiscoveredMCPServer:
+ """Schema for the `DiscoveredMcpServer` type."""
+
enabled: bool
"""Whether the server is enabled (not in the disabled list)"""
@@ -2913,6 +3077,8 @@ def to_dict(self) -> dict:
@dataclass
class Extension:
+ """Schema for the `Extension` type."""
+
id: str
"""Source-qualified ID (e.g., 'project:my-ext', 'user:auth-helper')"""
@@ -3125,6 +3291,8 @@ def to_dict(self) -> dict:
@dataclass
class SlashCommandTextResult:
+ """Schema for the `SlashCommandTextResult` type."""
+
kind: KindEnum
"""Text result discriminator"""
@@ -3167,6 +3335,9 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class HistoryCompactResult:
+ """Compaction outcome with the number of tokens and messages removed and the resulting
+ context window breakdown.
+ """
messages_removed: int
"""Number of messages removed during compaction"""
@@ -3199,6 +3370,8 @@ def to_dict(self) -> dict:
@dataclass
class InstructionsSources:
+ """Schema for the `InstructionsSources` type."""
+
content: str
"""Raw content of the instruction file"""
@@ -3252,6 +3425,8 @@ def to_dict(self) -> dict:
@dataclass
class LogRequest:
+ """Message text, optional severity level, persistence flag, and optional follow-up URL."""
+
message: str
"""Human-readable message"""
@@ -3287,14 +3462,32 @@ def to_dict(self) -> dict:
@dataclass
class MCPServerConfig:
- """MCP server configuration (local/stdio or remote/http)"""
+ """MCP server configuration (local/stdio or remote/http)
+
+ Local MCP server configuration launched as a child process.
+ Remote MCP server configuration accessed over HTTP or SSE.
+ """
args: list[str] | None = None
+ """Command-line arguments passed to the local MCP server process."""
+
command: str | None = None
+ """Executable command used to start the local MCP server process."""
+
cwd: str | None = None
+ """Working directory for the local MCP server process."""
+
env: dict[str, str] | None = None
+ """Environment variables to pass to the local MCP server process."""
+
filter_mapping: dict[str, FilterMappingString] | FilterMappingString | None = None
+ """Content filtering mode to apply to all tools, or a map of tool name to content filtering
+ mode.
+ """
is_default_server: bool | None = None
+ """Whether this server is a built-in fallback used when the user has not configured their
+ own server.
+ """
timeout: int | None = None
"""Timeout in milliseconds for tool calls to this server."""
@@ -3302,13 +3495,24 @@ class MCPServerConfig:
"""Tools to include. Defaults to all tools if not specified."""
type: MCPServerConfigType | None = None
- """Remote transport type. Defaults to "http" when omitted."""
+ """Local transport type. Defaults to "local".
+ Remote transport type. Defaults to "http" when omitted.
+ """
headers: dict[str, str] | None = None
+ """HTTP headers to include in requests to the remote MCP server."""
+
oauth_client_id: str | None = None
+ """OAuth client ID for a pre-registered remote MCP OAuth client."""
+
oauth_grant_type: MCPServerConfigHTTPOauthGrantType | None = None
+ """OAuth grant type to use when authenticating to the remote MCP server."""
+
oauth_public_client: bool | None = None
+ """Whether the configured OAuth client is public and does not require a client secret."""
+
url: str | None = None
+ """URL of the remote MCP server endpoint."""
@staticmethod
def from_dict(obj: Any) -> 'MCPServerConfig':
@@ -3363,6 +3567,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPServer:
+ """Schema for the `McpServer` type."""
+
name: str
"""Server name (config key)"""
@@ -3396,13 +3602,31 @@ def to_dict(self) -> dict:
@dataclass
class MCPServerConfigHTTP:
+ """Remote MCP server configuration accessed over HTTP or SSE."""
+
url: str
+ """URL of the remote MCP server endpoint."""
+
filter_mapping: dict[str, FilterMappingString] | FilterMappingString | None = None
+ """Content filtering mode to apply to all tools, or a map of tool name to content filtering
+ mode.
+ """
headers: dict[str, str] | None = None
+ """HTTP headers to include in requests to the remote MCP server."""
+
is_default_server: bool | None = None
+ """Whether this server is a built-in fallback used when the user has not configured their
+ own server.
+ """
oauth_client_id: str | None = None
+ """OAuth client ID for a pre-registered remote MCP OAuth client."""
+
oauth_grant_type: MCPServerConfigHTTPOauthGrantType | None = None
+ """OAuth grant type to use when authenticating to the remote MCP server."""
+
oauth_public_client: bool | None = None
+ """Whether the configured OAuth client is public and does not require a client secret."""
+
timeout: int | None = None
"""Timeout in milliseconds for tool calls to this server."""
@@ -3452,12 +3676,28 @@ def to_dict(self) -> dict:
@dataclass
class MCPServerConfigLocal:
+ """Local MCP server configuration launched as a child process."""
+
args: list[str]
+ """Command-line arguments passed to the local MCP server process."""
+
command: str
+ """Executable command used to start the local MCP server process."""
+
cwd: str | None = None
+ """Working directory for the local MCP server process."""
+
env: dict[str, str] | None = None
+ """Environment variables to pass to the local MCP server process."""
+
filter_mapping: dict[str, FilterMappingString] | FilterMappingString | None = None
+ """Content filtering mode to apply to all tools, or a map of tool name to content filtering
+ mode.
+ """
is_default_server: bool | None = None
+ """Whether this server is a built-in fallback used when the user has not configured their
+ own server.
+ """
timeout: int | None = None
"""Timeout in milliseconds for tool calls to this server."""
@@ -3465,6 +3705,7 @@ class MCPServerConfigLocal:
"""Tools to include. Defaults to all tools if not specified."""
type: MCPServerConfigLocalType | None = None
+ """Local transport type. Defaults to "local"."""
@staticmethod
def from_dict(obj: Any) -> 'MCPServerConfigLocal':
@@ -3502,6 +3743,8 @@ def to_dict(self) -> dict:
@dataclass
class ModeSetRequest:
+ """Agent interaction mode to apply to the session."""
+
mode: Mode
"""The agent mode. Valid values: "interactive", "plan", "autopilot"."""
@@ -3586,8 +3829,13 @@ class ModelCapabilitiesOverrideLimits:
"""Maximum total context window size in tokens"""
max_output_tokens: int | None = None
+ """Maximum number of output/completion tokens"""
+
max_prompt_tokens: int | None = None
+ """Maximum number of prompt/input tokens"""
+
vision: ModelCapabilitiesOverrideLimitsVision | None = None
+ """Vision-specific limits"""
@staticmethod
def from_dict(obj: Any) -> 'ModelCapabilitiesOverrideLimits':
@@ -3611,140 +3859,37 @@ def to_dict(self) -> dict:
return result
@dataclass
-class PermissionDecisionApproveForIonApproval:
- """The approval to add as a session-scoped rule
+class PermissionDecisionApproveForLocationApprovalCommands:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalCommands` type."""
- The approval to persist for this location
- """
- kind: ApprovalKind
- command_identifiers: list[str] | None = None
- server_name: str | None = None
- tool_name: str | None = None
- operation: str | None = None
- extension_name: str | None = None
+ command_identifiers: list[str]
+ """Command identifiers covered by this approval."""
+
+ kind: PermissionDecisionApproveForLocationApprovalCommandsKind
+ """Approval scoped to specific command identifiers."""
@staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForIonApproval':
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalCommands':
assert isinstance(obj, dict)
- kind = ApprovalKind(obj.get("kind"))
- command_identifiers = from_union([lambda x: from_list(from_str, x), from_none], obj.get("commandIdentifiers"))
- server_name = from_union([from_str, from_none], obj.get("serverName"))
- tool_name = from_union([from_none, from_str], obj.get("toolName"))
- operation = from_union([from_str, from_none], obj.get("operation"))
- extension_name = from_union([from_str, from_none], obj.get("extensionName"))
- return PermissionDecisionApproveForIonApproval(kind, command_identifiers, server_name, tool_name, operation, extension_name)
+ command_identifiers = from_list(from_str, obj.get("commandIdentifiers"))
+ kind = PermissionDecisionApproveForLocationApprovalCommandsKind(obj.get("kind"))
+ return PermissionDecisionApproveForLocationApprovalCommands(command_identifiers, kind)
def to_dict(self) -> dict:
result: dict = {}
- result["kind"] = to_enum(ApprovalKind, self.kind)
- if self.command_identifiers is not None:
- result["commandIdentifiers"] = from_union([lambda x: from_list(from_str, x), from_none], self.command_identifiers)
- if self.server_name is not None:
- result["serverName"] = from_union([from_str, from_none], self.server_name)
- if self.tool_name is not None:
- result["toolName"] = from_union([from_none, from_str], self.tool_name)
- if self.operation is not None:
- result["operation"] = from_union([from_str, from_none], self.operation)
- if self.extension_name is not None:
- result["extensionName"] = from_union([from_str, from_none], self.extension_name)
+ result["commandIdentifiers"] = from_list(from_str, self.command_identifiers)
+ result["kind"] = to_enum(PermissionDecisionApproveForLocationApprovalCommandsKind, self.kind)
return result
@dataclass
-class PermissionDecisionApproveForLocationApproval:
- """The approval to persist for this location"""
-
- kind: ApprovalKind
- command_identifiers: list[str] | None = None
- server_name: str | None = None
- tool_name: str | None = None
- operation: str | None = None
- extension_name: str | None = None
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApproval':
- assert isinstance(obj, dict)
- kind = ApprovalKind(obj.get("kind"))
- command_identifiers = from_union([lambda x: from_list(from_str, x), from_none], obj.get("commandIdentifiers"))
- server_name = from_union([from_str, from_none], obj.get("serverName"))
- tool_name = from_union([from_none, from_str], obj.get("toolName"))
- operation = from_union([from_str, from_none], obj.get("operation"))
- extension_name = from_union([from_str, from_none], obj.get("extensionName"))
- return PermissionDecisionApproveForLocationApproval(kind, command_identifiers, server_name, tool_name, operation, extension_name)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["kind"] = to_enum(ApprovalKind, self.kind)
- if self.command_identifiers is not None:
- result["commandIdentifiers"] = from_union([lambda x: from_list(from_str, x), from_none], self.command_identifiers)
- if self.server_name is not None:
- result["serverName"] = from_union([from_str, from_none], self.server_name)
- if self.tool_name is not None:
- result["toolName"] = from_union([from_none, from_str], self.tool_name)
- if self.operation is not None:
- result["operation"] = from_union([from_str, from_none], self.operation)
- if self.extension_name is not None:
- result["extensionName"] = from_union([from_str, from_none], self.extension_name)
- return result
-
-@dataclass
-class PermissionDecisionApproveForSessionApproval:
- """The approval to add as a session-scoped rule"""
-
- kind: ApprovalKind
- command_identifiers: list[str] | None = None
- server_name: str | None = None
- tool_name: str | None = None
- operation: str | None = None
- extension_name: str | None = None
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApproval':
- assert isinstance(obj, dict)
- kind = ApprovalKind(obj.get("kind"))
- command_identifiers = from_union([lambda x: from_list(from_str, x), from_none], obj.get("commandIdentifiers"))
- server_name = from_union([from_str, from_none], obj.get("serverName"))
- tool_name = from_union([from_none, from_str], obj.get("toolName"))
- operation = from_union([from_str, from_none], obj.get("operation"))
- extension_name = from_union([from_str, from_none], obj.get("extensionName"))
- return PermissionDecisionApproveForSessionApproval(kind, command_identifiers, server_name, tool_name, operation, extension_name)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["kind"] = to_enum(ApprovalKind, self.kind)
- if self.command_identifiers is not None:
- result["commandIdentifiers"] = from_union([lambda x: from_list(from_str, x), from_none], self.command_identifiers)
- if self.server_name is not None:
- result["serverName"] = from_union([from_str, from_none], self.server_name)
- if self.tool_name is not None:
- result["toolName"] = from_union([from_none, from_str], self.tool_name)
- if self.operation is not None:
- result["operation"] = from_union([from_str, from_none], self.operation)
- if self.extension_name is not None:
- result["extensionName"] = from_union([from_str, from_none], self.extension_name)
- return result
+class PermissionDecisionApproveForSessionApprovalCommands:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalCommands` type."""
-@dataclass
-class PermissionDecisionApproveForLocationApprovalCommands:
command_identifiers: list[str]
- kind: PermissionDecisionApproveForLocationApprovalCommandsKind
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalCommands':
- assert isinstance(obj, dict)
- command_identifiers = from_list(from_str, obj.get("commandIdentifiers"))
- kind = PermissionDecisionApproveForLocationApprovalCommandsKind(obj.get("kind"))
- return PermissionDecisionApproveForLocationApprovalCommands(command_identifiers, kind)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["commandIdentifiers"] = from_list(from_str, self.command_identifiers)
- result["kind"] = to_enum(PermissionDecisionApproveForLocationApprovalCommandsKind, self.kind)
- return result
+ """Command identifiers covered by this approval."""
-@dataclass
-class PermissionDecisionApproveForSessionApprovalCommands:
- command_identifiers: list[str]
kind: PermissionDecisionApproveForLocationApprovalCommandsKind
+ """Approval scoped to specific command identifiers."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalCommands':
@@ -3761,8 +3906,13 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForLocationApprovalCustomTool:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalCustomTool` type."""
+
kind: PermissionDecisionApproveForLocationApprovalCustomToolKind
+ """Approval covering a custom tool."""
+
tool_name: str
+ """Custom tool name."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalCustomTool':
@@ -3779,8 +3929,13 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForSessionApprovalCustomTool:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalCustomTool` type."""
+
kind: PermissionDecisionApproveForLocationApprovalCustomToolKind
+ """Approval covering a custom tool."""
+
tool_name: str
+ """Custom tool name."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalCustomTool':
@@ -3797,8 +3952,15 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForLocationApprovalExtensionManagement:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalExtensionManagement` type."""
+
kind: PermissionDecisionApproveForLocationApprovalExtensionManagementKind
+ """Approval covering extension lifecycle operations such as enable, disable, or reload."""
+
operation: str | None = None
+ """Optional operation identifier; when omitted, the approval covers all extension management
+ operations.
+ """
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalExtensionManagement':
@@ -3816,8 +3978,15 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForSessionApprovalExtensionManagement:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalExtensionManagement` type."""
+
kind: PermissionDecisionApproveForLocationApprovalExtensionManagementKind
+ """Approval covering extension lifecycle operations such as enable, disable, or reload."""
+
operation: str | None = None
+ """Optional operation identifier; when omitted, the approval covers all extension management
+ operations.
+ """
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalExtensionManagement':
@@ -3833,47 +4002,18 @@ def to_dict(self) -> dict:
result["operation"] = from_union([from_str, from_none], self.operation)
return result
-@dataclass
-class PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess:
- extension_name: str
- kind: PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess':
- assert isinstance(obj, dict)
- extension_name = from_str(obj.get("extensionName"))
- kind = PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind(obj.get("kind"))
- return PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess(extension_name, kind)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["extensionName"] = from_str(self.extension_name)
- result["kind"] = to_enum(PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind, self.kind)
- return result
-
-@dataclass
-class PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess:
- extension_name: str
- kind: PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess':
- assert isinstance(obj, dict)
- extension_name = from_str(obj.get("extensionName"))
- kind = PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind(obj.get("kind"))
- return PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess(extension_name, kind)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["extensionName"] = from_str(self.extension_name)
- result["kind"] = to_enum(PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind, self.kind)
- return result
-
@dataclass
class PermissionDecisionApproveForLocationApprovalMCP:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalMcp` type."""
+
kind: PermissionDecisionApproveForLocationApprovalMCPKind
+ """Approval covering an MCP tool."""
+
server_name: str
+ """MCP server name."""
+
tool_name: str | None = None
+ """MCP tool name, or null to cover every tool on the server."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalMCP':
@@ -3892,9 +4032,16 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForSessionApprovalMCP:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalMcp` type."""
+
kind: PermissionDecisionApproveForLocationApprovalMCPKind
+ """Approval covering an MCP tool."""
+
server_name: str
+ """MCP server name."""
+
tool_name: str | None = None
+ """MCP tool name, or null to cover every tool on the server."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalMCP':
@@ -3913,8 +4060,13 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForLocationApprovalMCPSampling:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalMcpSampling` type."""
+
kind: PermissionDecisionApproveForLocationApprovalMCPSamplingKind
+ """Approval covering MCP sampling requests for a server."""
+
server_name: str
+ """MCP server name."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalMCPSampling':
@@ -3931,8 +4083,13 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForSessionApprovalMCPSampling:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalMcpSampling` type."""
+
kind: PermissionDecisionApproveForLocationApprovalMCPSamplingKind
+ """Approval covering MCP sampling requests for a server."""
+
server_name: str
+ """MCP server name."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalMCPSampling':
@@ -3949,7 +4106,10 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForLocationApprovalMemory:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalMemory` type."""
+
kind: PermissionDecisionApproveForLocationApprovalMemoryKind
+ """Approval covering writes to long-term memory."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalMemory':
@@ -3964,7 +4124,10 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForSessionApprovalMemory:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalMemory` type."""
+
kind: PermissionDecisionApproveForLocationApprovalMemoryKind
+ """Approval covering writes to long-term memory."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalMemory':
@@ -3979,7 +4142,10 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForLocationApprovalRead:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalRead` type."""
+
kind: PermissionDecisionApproveForLocationApprovalReadKind
+ """Approval covering read-only filesystem operations."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalRead':
@@ -3994,7 +4160,10 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForSessionApprovalRead:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalRead` type."""
+
kind: PermissionDecisionApproveForLocationApprovalReadKind
+ """Approval covering read-only filesystem operations."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalRead':
@@ -4009,7 +4178,10 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForLocationApprovalWrite:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalWrite` type."""
+
kind: PermissionDecisionApproveForLocationApprovalWriteKind
+ """Approval covering filesystem write operations."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalWrite':
@@ -4024,7 +4196,10 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveForSessionApprovalWrite:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalWrite` type."""
+
kind: PermissionDecisionApproveForLocationApprovalWriteKind
+ """Approval covering filesystem write operations."""
@staticmethod
def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalWrite':
@@ -4039,6 +4214,8 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApproveOnce:
+ """Schema for the `PermissionDecisionApproveOnce` type."""
+
kind: PermissionDecisionApproveOnceKind
"""The permission request was approved for this one instance"""
@@ -4055,6 +4232,8 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionApprovePermanently:
+ """Schema for the `PermissionDecisionApprovePermanently` type."""
+
domain: str
"""The URL domain to approve permanently"""
@@ -4076,6 +4255,8 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionReject:
+ """Schema for the `PermissionDecisionReject` type."""
+
kind: PermissionDecisionRejectKind
"""Denied by the user during an interactive prompt"""
@@ -4098,6 +4279,8 @@ def to_dict(self) -> dict:
@dataclass
class PermissionDecisionUserNotAvailable:
+ """Schema for the `PermissionDecisionUserNotAvailable` type."""
+
kind: PermissionDecisionUserNotAvailableKind
"""Denied because user confirmation was unavailable"""
@@ -4115,6 +4298,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class PluginList:
+ """Plugins installed for the session, with their enabled state and version metadata."""
+
plugins: list[Plugin]
"""Installed plugins"""
@@ -4129,13 +4314,45 @@ def to_dict(self) -> dict:
result["plugins"] = from_list(lambda x: to_class(Plugin, x), self.plugins)
return result
+@dataclass
+class QueuedCommandResult:
+ """Result of the queued command execution
+
+ Schema for the `QueuedCommandHandled` type.
+
+ Schema for the `QueuedCommandNotHandled` type.
+ """
+ handled: bool
+ """The command was handled
+
+ The command was not handled
+ """
+ stop_processing_queue: bool | None = None
+ """If true, stop processing remaining queued items"""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'QueuedCommandResult':
+ assert isinstance(obj, dict)
+ handled = from_bool(obj.get("handled"))
+ stop_processing_queue = from_union([from_bool, from_none], obj.get("stopProcessingQueue"))
+ return QueuedCommandResult(handled, stop_processing_queue)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["handled"] = from_bool(self.handled)
+ if self.stop_processing_queue is not None:
+ result["stopProcessingQueue"] = from_union([from_bool, from_none], self.stop_processing_queue)
+ return result
+
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class RemoteEnableRequest:
+ """Optional remote session mode ("off", "export", or "on"); defaults to enabling both export
+ and remote steering.
+ """
mode: RemoteSessionMode | None = None
- """Per-session remote mode. "off" disables remote, "export" exports session events to
- Mission Control without enabling remote steering, "on" enables both export and remote
- steering.
+ """Per-session remote mode. "off" disables remote, "export" exports session events to GitHub
+ without enabling remote steering, "on" enables both export and remote steering.
"""
@staticmethod
@@ -4152,6 +4369,8 @@ def to_dict(self) -> dict:
@dataclass
class ServerSkillList:
+ """Skills discovered across global and project sources."""
+
skills: list[ServerSkill]
"""All discovered skills across all sources"""
@@ -4192,6 +4411,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSReaddirWithTypesEntry:
+ """Schema for the `SessionFsReaddirWithTypesEntry` type."""
+
name: str
"""Entry name"""
@@ -4213,6 +4434,9 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSSetProviderRequest:
+ """Initial working directory, session-state path layout, and path conventions used to
+ register the calling SDK client as the session filesystem provider.
+ """
conventions: SessionFSSetProviderConventions
"""Path conventions used by this filesystem"""
@@ -4239,6 +4463,8 @@ def to_dict(self) -> dict:
@dataclass
class ShellKillRequest:
+ """Identifier of a process previously returned by "shell.exec" and the signal to send."""
+
process_id: str
"""Process identifier returned by shell.exec"""
@@ -4262,6 +4488,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class SkillList:
+ """Skills available to the session, with their enabled state."""
+
skills: list[Skill]
"""Available skills"""
@@ -4276,8 +4504,28 @@ def to_dict(self) -> dict:
result["skills"] = from_list(lambda x: to_class(Skill, x), self.skills)
return result
+@dataclass
+class SkillsConfigSetDisabledSkillsRequest:
+ """Skill names to mark as disabled in global configuration, replacing any previous list."""
+
+ disabled_skills: list[str]
+ """List of skill names to disable"""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'SkillsConfigSetDisabledSkillsRequest':
+ assert isinstance(obj, dict)
+ disabled_skills = from_list(from_str, obj.get("disabledSkills"))
+ return SkillsConfigSetDisabledSkillsRequest(disabled_skills)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["disabledSkills"] = from_list(from_str, self.disabled_skills)
+ return result
+
@dataclass
class SlashCommandAgentPromptResult:
+ """Schema for the `SlashCommandAgentPromptResult` type."""
+
display_prompt: str
"""Prompt text to display to the user"""
@@ -4318,6 +4566,8 @@ def to_dict(self) -> dict:
@dataclass
class SlashCommandCompletedResult:
+ """Schema for the `SlashCommandCompletedResult` type."""
+
kind: SlashCommandCompletedResultKind
"""Completed result discriminator"""
@@ -4347,100 +4597,33 @@ def to_dict(self) -> dict:
return result
@dataclass
-class SlashCommandInvocationResult:
- kind: SlashCommandInvocationResultKind
- """Text result discriminator
-
- Agent prompt result discriminator
+class TaskShellInfo:
+ """Schema for the `TaskShellInfo` type."""
- Completed result discriminator
+ attachment_mode: TaskShellInfoAttachmentMode
+ """Whether the shell runs inside a managed PTY session or as an independent background
+ process
"""
- markdown: bool | None = None
- """Whether text contains Markdown"""
+ command: str
+ """Command being executed"""
- preserve_ansi: bool | None = None
- """Whether ANSI sequences should be preserved"""
+ description: str
+ """Short description of the task"""
- runtime_settings_changed: bool | None = None
- """True when the invocation mutated user runtime settings; consumers caching settings should
- refresh
- """
- text: str | None = None
- """Text output for the client to render"""
+ id: str
+ """Unique task identifier"""
- display_prompt: str | None = None
- """Prompt text to display to the user"""
+ started_at: datetime
+ """ISO 8601 timestamp when the task was started"""
- mode: Mode | None = None
- """Optional target session mode"""
+ status: TaskInfoStatus
+ """Current lifecycle status of the task"""
- prompt: str | None = None
- """Prompt to submit to the agent"""
+ type: TaskShellInfoType
+ """Task kind"""
- message: str | None = None
- """Optional user-facing message describing the completed command"""
-
- @staticmethod
- def from_dict(obj: Any) -> 'SlashCommandInvocationResult':
- assert isinstance(obj, dict)
- kind = SlashCommandInvocationResultKind(obj.get("kind"))
- markdown = from_union([from_bool, from_none], obj.get("markdown"))
- preserve_ansi = from_union([from_bool, from_none], obj.get("preserveAnsi"))
- runtime_settings_changed = from_union([from_bool, from_none], obj.get("runtimeSettingsChanged"))
- text = from_union([from_str, from_none], obj.get("text"))
- display_prompt = from_union([from_str, from_none], obj.get("displayPrompt"))
- mode = from_union([Mode, from_none], obj.get("mode"))
- prompt = from_union([from_str, from_none], obj.get("prompt"))
- message = from_union([from_str, from_none], obj.get("message"))
- return SlashCommandInvocationResult(kind, markdown, preserve_ansi, runtime_settings_changed, text, display_prompt, mode, prompt, message)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["kind"] = to_enum(SlashCommandInvocationResultKind, self.kind)
- if self.markdown is not None:
- result["markdown"] = from_union([from_bool, from_none], self.markdown)
- if self.preserve_ansi is not None:
- result["preserveAnsi"] = from_union([from_bool, from_none], self.preserve_ansi)
- if self.runtime_settings_changed is not None:
- result["runtimeSettingsChanged"] = from_union([from_bool, from_none], self.runtime_settings_changed)
- if self.text is not None:
- result["text"] = from_union([from_str, from_none], self.text)
- if self.display_prompt is not None:
- result["displayPrompt"] = from_union([from_str, from_none], self.display_prompt)
- if self.mode is not None:
- result["mode"] = from_union([lambda x: to_enum(Mode, x), from_none], self.mode)
- if self.prompt is not None:
- result["prompt"] = from_union([from_str, from_none], self.prompt)
- if self.message is not None:
- result["message"] = from_union([from_str, from_none], self.message)
- return result
-
-@dataclass
-class TaskShellInfo:
- attachment_mode: TaskShellInfoAttachmentMode
- """Whether the shell runs inside a managed PTY session or as an independent background
- process
- """
- command: str
- """Command being executed"""
-
- description: str
- """Short description of the task"""
-
- id: str
- """Unique task identifier"""
-
- started_at: datetime
- """ISO 8601 timestamp when the task was started"""
-
- status: TaskInfoStatus
- """Current lifecycle status of the task"""
-
- type: TaskShellInfoType
- """Task kind"""
-
- can_promote_to_background: bool | None = None
- """Whether this shell task can be promoted to background mode"""
+ can_promote_to_background: bool | None = None
+ """Whether this shell task can be promoted to background mode"""
completed_at: datetime | None = None
"""ISO 8601 timestamp when the task finished"""
@@ -4494,6 +4677,8 @@ def to_dict(self) -> dict:
@dataclass
class ToolList:
+ """Built-in tools available for the requested model, with their parameters and instructions."""
+
tools: list[Tool]
"""List of available built-in tools with metadata"""
@@ -4510,7 +4695,10 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationArrayAnyOfFieldItems:
+ """Schema applied to each item in the array."""
+
any_of: list[UIElicitationArrayAnyOfFieldItemsAnyOf]
+ """Selectable options, each with a value and a display label."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationArrayAnyOfFieldItems':
@@ -4525,8 +4713,13 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationArrayEnumFieldItems:
+ """Schema applied to each item in the array."""
+
enum: list[str]
+ """Allowed string values for each selected item."""
+
type: UIElicitationArrayEnumFieldItemsType
+ """Type discriminator. Always "string"."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationArrayEnumFieldItems':
@@ -4543,9 +4736,16 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationArrayFieldItems:
+ """Schema applied to each item in the array."""
+
enum: list[str] | None = None
+ """Allowed string values for each selected item."""
+
type: UIElicitationArrayEnumFieldItemsType | None = None
+ """Type discriminator. Always "string"."""
+
any_of: list[UIElicitationArrayAnyOfFieldItemsAnyOf] | None = None
+ """Selectable options, each with a value and a display label."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationArrayFieldItems':
@@ -4567,12 +4767,25 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationStringEnumField:
+ """Single-select string field whose allowed values are defined inline."""
+
enum: list[str]
+ """Allowed string values."""
+
type: UIElicitationArrayEnumFieldItemsType
+ """Type discriminator. Always "string"."""
+
default: str | None = None
+ """Default value selected when the form is first shown."""
+
description: str | None = None
+ """Help text describing the field."""
+
enum_names: list[str] | None = None
+ """Optional display labels for each enum value, in the same order as `enum`."""
+
title: str | None = None
+ """Human-readable label for the field."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationStringEnumField':
@@ -4601,13 +4814,28 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationSchemaPropertyString:
+ """Free-text string field with optional length and format constraints."""
+
type: UIElicitationArrayEnumFieldItemsType
+ """Type discriminator. Always "string"."""
+
default: str | None = None
+ """Default value populated in the input when the form is first shown."""
+
description: str | None = None
+ """Help text describing the field."""
+
format: UIElicitationSchemaPropertyStringFormat | None = None
+ """Optional format hint that constrains the accepted input."""
+
max_length: float | None = None
+ """Maximum number of characters allowed."""
+
min_length: float | None = None
+ """Minimum number of characters required."""
+
title: str | None = None
+ """Human-readable label for the field."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationSchemaPropertyString':
@@ -4640,11 +4868,22 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationStringOneOfField:
+ """Single-select string field where each option pairs a value with a display label."""
+
one_of: list[UIElicitationStringOneOfFieldOneOf]
+ """Selectable options, each with a value and a display label."""
+
type: UIElicitationArrayEnumFieldItemsType
+ """Type discriminator. Always "string"."""
+
default: str | None = None
+ """Default value selected when the form is first shown."""
+
description: str | None = None
+ """Help text describing the field."""
+
title: str | None = None
+ """Human-readable label for the field."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationStringOneOfField':
@@ -4694,10 +4933,19 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationSchemaPropertyBoolean:
+ """Boolean field rendered as a yes/no toggle."""
+
type: UIElicitationSchemaPropertyBooleanType
+ """Type discriminator. Always "boolean"."""
+
default: bool | None = None
+ """Default value selected when the form is first shown."""
+
description: str | None = None
+ """Help text describing the field."""
+
title: str | None = None
+ """Human-readable label for the field."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationSchemaPropertyBoolean':
@@ -4721,12 +4969,25 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationSchemaPropertyNumber:
+ """Numeric field accepting either a number or an integer."""
+
type: UIElicitationSchemaPropertyNumberType
+ """Numeric type accepted by the field."""
+
default: float | None = None
+ """Default value populated in the input when the form is first shown."""
+
description: str | None = None
+ """Help text describing the field."""
+
maximum: float | None = None
+ """Maximum allowed value (inclusive)."""
+
minimum: float | None = None
+ """Minimum allowed value (inclusive)."""
+
title: str | None = None
+ """Human-readable label for the field."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationSchemaPropertyNumber':
@@ -4756,6 +5017,8 @@ def to_dict(self) -> dict:
@dataclass
class UsageMetricsModelMetric:
+ """Schema for the `UsageMetricsModelMetric` type."""
+
requests: UsageMetricsModelMetricRequests
"""Request count and cost metrics for this model"""
@@ -4864,6 +5127,8 @@ def to_dict(self) -> dict:
@dataclass
class SlashCommandInfo:
+ """Schema for the `SlashCommandInfo` type."""
+
allow_during_agent_execution: bool
"""Whether the command may run while an agent turn is active"""
@@ -4914,6 +5179,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPDiscoverResult:
+ """MCP servers discovered from user, workspace, plugin, and built-in sources."""
+
servers: list[DiscoveredMCPServer]
"""MCP servers discovered from all sources"""
@@ -4931,6 +5198,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class ExtensionList:
+ """Extensions discovered for the session, with their current status."""
+
extensions: list[Extension]
"""Discovered extensions and their current status"""
@@ -4945,6 +5214,54 @@ def to_dict(self) -> dict:
result["extensions"] = from_list(lambda x: to_class(Extension, x), self.extensions)
return result
+@dataclass
+class PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess:
+ """Schema for the `PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess`
+ type.
+ """
+ extension_name: str
+ """Extension name."""
+
+ kind: PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind
+ """Approval covering an extension's request to access a permission-gated capability."""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess':
+ assert isinstance(obj, dict)
+ extension_name = from_str(obj.get("extensionName"))
+ kind = PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind(obj.get("kind"))
+ return PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess(extension_name, kind)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["extensionName"] = from_str(self.extension_name)
+ result["kind"] = to_enum(PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind, self.kind)
+ return result
+
+@dataclass
+class PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess:
+ """Schema for the `PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess`
+ type.
+ """
+ extension_name: str
+ """Extension name."""
+
+ kind: PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind
+ """Approval covering an extension's request to access a permission-gated capability."""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess':
+ assert isinstance(obj, dict)
+ extension_name = from_str(obj.get("extensionName"))
+ kind = PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind(obj.get("kind"))
+ return PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess(extension_name, kind)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["extensionName"] = from_str(self.extension_name)
+ result["kind"] = to_enum(PermissionDecisionApproveForLocationApprovalExtensionPermissionAccessKind, self.kind)
+ return result
+
@dataclass
class ExternalToolTextResultForLlmContent:
"""A content block within a tool result, which may be text, terminal output, image, audio,
@@ -5116,6 +5433,8 @@ def to_dict(self) -> dict:
@dataclass
class InstructionsGetSourcesResult:
+ """Instruction sources loaded for the session, in merge order."""
+
sources: list[InstructionsSources]
"""Instruction sources for the session"""
@@ -5132,6 +5451,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPConfigAddRequest:
+ """MCP server name and configuration to add to user configuration."""
+
config: MCPServerConfig
"""MCP server configuration (local/stdio or remote/http)"""
@@ -5153,6 +5474,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPConfigList:
+ """User-configured MCP servers, keyed by server name."""
+
servers: dict[str, MCPServerConfig]
"""All MCP servers from user config, keyed by name"""
@@ -5169,6 +5492,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPConfigUpdateRequest:
+ """MCP server name and replacement configuration to write to user configuration."""
+
config: MCPServerConfig
"""MCP server configuration (local/stdio or remote/http)"""
@@ -5190,6 +5515,8 @@ def to_dict(self) -> dict:
@dataclass
class MCPServerList:
+ """MCP servers configured for the session, with their connection status."""
+
servers: list[MCPServer]
"""Configured MCP servers"""
@@ -5230,115 +5557,32 @@ def to_dict(self) -> dict:
return result
@dataclass
-class PermissionDecision:
- kind: PermissionDecisionKind
- """The permission request was approved for this one instance
-
- Approved and remembered for the rest of the session
-
- Approved and persisted for this project location
-
- Approved and persisted across sessions
-
- Denied by the user during an interactive prompt
-
- Denied because user confirmation was unavailable
- """
- approval: PermissionDecisionApproveForIonApproval | None = None
- """The approval to add as a session-scoped rule
-
- The approval to persist for this location
- """
- domain: str | None = None
- """The URL domain to approve for this session
-
- The URL domain to approve permanently
- """
- location_key: str | None = None
- """The location key (git root or cwd) to persist the approval to"""
-
- feedback: str | None = None
- """Optional feedback from the user explaining the denial"""
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecision':
- assert isinstance(obj, dict)
- kind = PermissionDecisionKind(obj.get("kind"))
- approval = from_union([PermissionDecisionApproveForIonApproval.from_dict, from_none], obj.get("approval"))
- domain = from_union([from_str, from_none], obj.get("domain"))
- location_key = from_union([from_str, from_none], obj.get("locationKey"))
- feedback = from_union([from_str, from_none], obj.get("feedback"))
- return PermissionDecision(kind, approval, domain, location_key, feedback)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["kind"] = to_enum(PermissionDecisionKind, self.kind)
- if self.approval is not None:
- result["approval"] = from_union([lambda x: to_class(PermissionDecisionApproveForIonApproval, x), from_none], self.approval)
- if self.domain is not None:
- result["domain"] = from_union([from_str, from_none], self.domain)
- if self.location_key is not None:
- result["locationKey"] = from_union([from_str, from_none], self.location_key)
- if self.feedback is not None:
- result["feedback"] = from_union([from_str, from_none], self.feedback)
- return result
-
-@dataclass
-class PermissionDecisionApproveForLocation:
- approval: PermissionDecisionApproveForLocationApproval
- """The approval to persist for this location"""
-
- kind: PermissionDecisionApproveForLocationKind
- """Approved and persisted for this project location"""
-
- location_key: str
- """The location key (git root or cwd) to persist the approval to"""
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocation':
- assert isinstance(obj, dict)
- approval = PermissionDecisionApproveForLocationApproval.from_dict(obj.get("approval"))
- kind = PermissionDecisionApproveForLocationKind(obj.get("kind"))
- location_key = from_str(obj.get("locationKey"))
- return PermissionDecisionApproveForLocation(approval, kind, location_key)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["approval"] = to_class(PermissionDecisionApproveForLocationApproval, self.approval)
- result["kind"] = to_enum(PermissionDecisionApproveForLocationKind, self.kind)
- result["locationKey"] = from_str(self.location_key)
- return result
-
-@dataclass
-class PermissionDecisionApproveForSession:
- kind: PermissionDecisionApproveForSessionKind
- """Approved and remembered for the rest of the session"""
+class CommandsRespondToQueuedCommandRequest:
+ """Queued command request ID and the result indicating whether the client handled it."""
- approval: PermissionDecisionApproveForSessionApproval | None = None
- """The approval to add as a session-scoped rule"""
+ request_id: str
+ """Request ID from the queued command event"""
- domain: str | None = None
- """The URL domain to approve for this session"""
+ result: QueuedCommandResult
+ """Result of the queued command execution"""
@staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionApproveForSession':
+ def from_dict(obj: Any) -> 'CommandsRespondToQueuedCommandRequest':
assert isinstance(obj, dict)
- kind = PermissionDecisionApproveForSessionKind(obj.get("kind"))
- approval = from_union([PermissionDecisionApproveForSessionApproval.from_dict, from_none], obj.get("approval"))
- domain = from_union([from_str, from_none], obj.get("domain"))
- return PermissionDecisionApproveForSession(kind, approval, domain)
+ request_id = from_str(obj.get("requestId"))
+ result = QueuedCommandResult.from_dict(obj.get("result"))
+ return CommandsRespondToQueuedCommandRequest(request_id, result)
def to_dict(self) -> dict:
result: dict = {}
- result["kind"] = to_enum(PermissionDecisionApproveForSessionKind, self.kind)
- if self.approval is not None:
- result["approval"] = from_union([lambda x: to_class(PermissionDecisionApproveForSessionApproval, x), from_none], self.approval)
- if self.domain is not None:
- result["domain"] = from_union([from_str, from_none], self.domain)
+ result["requestId"] = from_str(self.request_id)
+ result["result"] = to_class(QueuedCommandResult, self.result)
return result
@dataclass
class SessionFSReadFileResult:
+ """File content as a UTF-8 string, or a filesystem error if the read failed."""
+
content: str
"""File content as UTF-8 string"""
@@ -5361,6 +5605,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSReaddirResult:
+ """Names of entries in the requested directory, or a filesystem error if the read failed."""
+
entries: list[str]
"""Entry names in the directory"""
@@ -5383,6 +5629,8 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSStatResult:
+ """Filesystem metadata for the requested path, or a filesystem error if the stat failed."""
+
birthtime: datetime
"""ISO 8601 timestamp of creation"""
@@ -5425,6 +5673,9 @@ def to_dict(self) -> dict:
@dataclass
class SessionFSReaddirWithTypesResult:
+ """Entries in the requested directory paired with file/directory type information, or a
+ filesystem error if the read failed.
+ """
entries: list[SessionFSReaddirWithTypesEntry]
"""Directory entries with type information"""
@@ -5446,14 +5697,107 @@ def to_dict(self) -> dict:
return result
@dataclass
-class UIElicitationArrayAnyOfField:
- items: UIElicitationArrayAnyOfFieldItems
- type: UIElicitationArrayAnyOfFieldType
+class SlashCommandInvocationResult:
+ """Result of invoking the slash command (text output, prompt to send to the agent, or
+ completion).
+
+ Schema for the `SlashCommandTextResult` type.
+
+ Schema for the `SlashCommandAgentPromptResult` type.
+
+ Schema for the `SlashCommandCompletedResult` type.
+ """
+ kind: SlashCommandInvocationResultKind
+ """Text result discriminator
+
+ Agent prompt result discriminator
+
+ Completed result discriminator
+ """
+ markdown: bool | None = None
+ """Whether text contains Markdown"""
+
+ preserve_ansi: bool | None = None
+ """Whether ANSI sequences should be preserved"""
+
+ runtime_settings_changed: bool | None = None
+ """True when the invocation mutated user runtime settings; consumers caching settings should
+ refresh
+ """
+ text: str | None = None
+ """Text output for the client to render"""
+
+ display_prompt: str | None = None
+ """Prompt text to display to the user"""
+
+ mode: Mode | None = None
+ """Optional target session mode"""
+
+ prompt: str | None = None
+ """Prompt to submit to the agent"""
+
+ message: str | None = None
+ """Optional user-facing message describing the completed command"""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'SlashCommandInvocationResult':
+ assert isinstance(obj, dict)
+ kind = SlashCommandInvocationResultKind(obj.get("kind"))
+ markdown = from_union([from_bool, from_none], obj.get("markdown"))
+ preserve_ansi = from_union([from_bool, from_none], obj.get("preserveAnsi"))
+ runtime_settings_changed = from_union([from_bool, from_none], obj.get("runtimeSettingsChanged"))
+ text = from_union([from_str, from_none], obj.get("text"))
+ display_prompt = from_union([from_str, from_none], obj.get("displayPrompt"))
+ mode = from_union([Mode, from_none], obj.get("mode"))
+ prompt = from_union([from_str, from_none], obj.get("prompt"))
+ message = from_union([from_str, from_none], obj.get("message"))
+ return SlashCommandInvocationResult(kind, markdown, preserve_ansi, runtime_settings_changed, text, display_prompt, mode, prompt, message)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["kind"] = to_enum(SlashCommandInvocationResultKind, self.kind)
+ if self.markdown is not None:
+ result["markdown"] = from_union([from_bool, from_none], self.markdown)
+ if self.preserve_ansi is not None:
+ result["preserveAnsi"] = from_union([from_bool, from_none], self.preserve_ansi)
+ if self.runtime_settings_changed is not None:
+ result["runtimeSettingsChanged"] = from_union([from_bool, from_none], self.runtime_settings_changed)
+ if self.text is not None:
+ result["text"] = from_union([from_str, from_none], self.text)
+ if self.display_prompt is not None:
+ result["displayPrompt"] = from_union([from_str, from_none], self.display_prompt)
+ if self.mode is not None:
+ result["mode"] = from_union([lambda x: to_enum(Mode, x), from_none], self.mode)
+ if self.prompt is not None:
+ result["prompt"] = from_union([from_str, from_none], self.prompt)
+ if self.message is not None:
+ result["message"] = from_union([from_str, from_none], self.message)
+ return result
+
+@dataclass
+class UIElicitationArrayAnyOfField:
+ """Multi-select string field where each option pairs a value with a display label."""
+
+ items: UIElicitationArrayAnyOfFieldItems
+ """Schema applied to each item in the array."""
+
+ type: UIElicitationArrayAnyOfFieldType
+ """Type discriminator. Always "array"."""
+
default: list[str] | None = None
+ """Default values selected when the form is first shown."""
+
description: str | None = None
+ """Help text describing the field."""
+
max_items: float | None = None
+ """Maximum number of items the user may select."""
+
min_items: float | None = None
+ """Minimum number of items the user must select."""
+
title: str | None = None
+ """Human-readable label for the field."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationArrayAnyOfField':
@@ -5485,13 +5829,28 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationArrayEnumField:
+ """Multi-select string field whose allowed values are defined inline."""
+
items: UIElicitationArrayEnumFieldItems
+ """Schema applied to each item in the array."""
+
type: UIElicitationArrayAnyOfFieldType
+ """Type discriminator. Always "array"."""
+
default: list[str] | None = None
+ """Default values selected when the form is first shown."""
+
description: str | None = None
+ """Help text describing the field."""
+
max_items: float | None = None
+ """Maximum number of items the user may select."""
+
min_items: float | None = None
+ """Minimum number of items the user must select."""
+
title: str | None = None
+ """Human-readable label for the field."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationArrayEnumField':
@@ -5523,21 +5882,76 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationSchemaProperty:
+ """Definition for a single elicitation form field.
+
+ Single-select string field whose allowed values are defined inline.
+
+ Single-select string field where each option pairs a value with a display label.
+
+ Multi-select string field whose allowed values are defined inline.
+
+ Multi-select string field where each option pairs a value with a display label.
+
+ Boolean field rendered as a yes/no toggle.
+
+ Free-text string field with optional length and format constraints.
+
+ Numeric field accepting either a number or an integer.
+ """
type: UIElicitationSchemaPropertyType
+ """Type discriminator. Always "string".
+
+ Type discriminator. Always "array".
+
+ Type discriminator. Always "boolean".
+
+ Numeric type accepted by the field.
+ """
default: float | bool | list[str] | str | None = None
+ """Default value selected when the form is first shown.
+
+ Default values selected when the form is first shown.
+
+ Default value populated in the input when the form is first shown.
+ """
description: str | None = None
+ """Help text describing the field."""
+
enum: list[str] | None = None
+ """Allowed string values."""
+
enum_names: list[str] | None = None
+ """Optional display labels for each enum value, in the same order as `enum`."""
+
title: str | None = None
+ """Human-readable label for the field."""
+
one_of: list[UIElicitationStringOneOfFieldOneOf] | None = None
+ """Selectable options, each with a value and a display label."""
+
items: UIElicitationArrayFieldItems | None = None
+ """Schema applied to each item in the array."""
+
max_items: float | None = None
+ """Maximum number of items the user may select."""
+
min_items: float | None = None
+ """Minimum number of items the user must select."""
+
format: UIElicitationSchemaPropertyStringFormat | None = None
+ """Optional format hint that constrains the accepted input."""
+
max_length: float | None = None
+ """Maximum number of characters allowed."""
+
min_length: float | None = None
+ """Minimum number of characters required."""
+
maximum: float | None = None
+ """Maximum allowed value (inclusive)."""
+
minimum: float | None = None
+ """Minimum allowed value (inclusive)."""
@staticmethod
def from_dict(obj: Any) -> 'UIElicitationSchemaProperty':
@@ -5594,6 +6008,9 @@ def to_dict(self) -> dict:
@dataclass
class UIHandlePendingElicitationRequest:
+ """Pending elicitation request ID and the user's response (accept/decline/cancel + form
+ values).
+ """
request_id: str
"""The unique request ID from the elicitation.requested event"""
@@ -5616,6 +6033,9 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class UsageGetMetricsResult:
+ """Accumulated session usage metrics, including premium request cost, token counts, model
+ breakdown, and code-change totals.
+ """
code_changes: UsageMetricsCodeChanges
"""Aggregated code change metrics"""
@@ -5686,6 +6106,8 @@ def to_dict(self) -> dict:
@dataclass
class WorkspacesGetWorkspaceResult:
+ """Current workspace metadata for the session, or null when not available."""
+
workspace: Workspace | None = None
"""Current workspace metadata, or null if not available"""
@@ -5702,6 +6124,8 @@ def to_dict(self) -> dict:
@dataclass
class CommandList:
+ """Slash commands available in the session, after applying any include/exclude filters."""
+
commands: list[SlashCommandInfo]
"""Commands available in this session"""
@@ -5716,6 +6140,285 @@ def to_dict(self) -> dict:
result["commands"] = from_list(lambda x: to_class(SlashCommandInfo, x), self.commands)
return result
+@dataclass
+class PermissionDecisionApproveForLocationApproval:
+ """The approval to persist for this location
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalCommands` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalRead` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalWrite` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalMcp` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalMcpSampling` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalMemory` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalCustomTool` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalExtensionManagement` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess`
+ type.
+ """
+ kind: ApprovalKind
+ """Approval scoped to specific command identifiers.
+
+ Approval covering read-only filesystem operations.
+
+ Approval covering filesystem write operations.
+
+ Approval covering an MCP tool.
+
+ Approval covering MCP sampling requests for a server.
+
+ Approval covering writes to long-term memory.
+
+ Approval covering a custom tool.
+
+ Approval covering extension lifecycle operations such as enable, disable, or reload.
+
+ Approval covering an extension's request to access a permission-gated capability.
+ """
+ command_identifiers: list[str] | None = None
+ """Command identifiers covered by this approval."""
+
+ server_name: str | None = None
+ """MCP server name."""
+
+ tool_name: str | None = None
+ """MCP tool name, or null to cover every tool on the server.
+
+ Custom tool name.
+ """
+ operation: str | None = None
+ """Optional operation identifier; when omitted, the approval covers all extension management
+ operations.
+ """
+ extension_name: str | None = None
+ """Extension name."""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocationApproval':
+ assert isinstance(obj, dict)
+ kind = ApprovalKind(obj.get("kind"))
+ command_identifiers = from_union([lambda x: from_list(from_str, x), from_none], obj.get("commandIdentifiers"))
+ server_name = from_union([from_str, from_none], obj.get("serverName"))
+ tool_name = from_union([from_none, from_str], obj.get("toolName"))
+ operation = from_union([from_str, from_none], obj.get("operation"))
+ extension_name = from_union([from_str, from_none], obj.get("extensionName"))
+ return PermissionDecisionApproveForLocationApproval(kind, command_identifiers, server_name, tool_name, operation, extension_name)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["kind"] = to_enum(ApprovalKind, self.kind)
+ if self.command_identifiers is not None:
+ result["commandIdentifiers"] = from_union([lambda x: from_list(from_str, x), from_none], self.command_identifiers)
+ if self.server_name is not None:
+ result["serverName"] = from_union([from_str, from_none], self.server_name)
+ if self.tool_name is not None:
+ result["toolName"] = from_union([from_none, from_str], self.tool_name)
+ if self.operation is not None:
+ result["operation"] = from_union([from_str, from_none], self.operation)
+ if self.extension_name is not None:
+ result["extensionName"] = from_union([from_str, from_none], self.extension_name)
+ return result
+
+@dataclass
+class PermissionDecisionApproveForIonApproval:
+ """The approval to add as a session-scoped rule
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalCommands` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalRead` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalWrite` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalMcp` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalMcpSampling` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalMemory` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalCustomTool` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalExtensionManagement` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess`
+ type.
+
+ The approval to persist for this location
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalCommands` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalRead` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalWrite` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalMcp` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalMcpSampling` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalMemory` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalCustomTool` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalExtensionManagement` type.
+
+ Schema for the `PermissionDecisionApproveForLocationApprovalExtensionPermissionAccess`
+ type.
+ """
+ kind: ApprovalKind
+ """Approval scoped to specific command identifiers.
+
+ Approval covering read-only filesystem operations.
+
+ Approval covering filesystem write operations.
+
+ Approval covering an MCP tool.
+
+ Approval covering MCP sampling requests for a server.
+
+ Approval covering writes to long-term memory.
+
+ Approval covering a custom tool.
+
+ Approval covering extension lifecycle operations such as enable, disable, or reload.
+
+ Approval covering an extension's request to access a permission-gated capability.
+ """
+ command_identifiers: list[str] | None = None
+ """Command identifiers covered by this approval."""
+
+ server_name: str | None = None
+ """MCP server name."""
+
+ tool_name: str | None = None
+ """MCP tool name, or null to cover every tool on the server.
+
+ Custom tool name.
+ """
+ operation: str | None = None
+ """Optional operation identifier; when omitted, the approval covers all extension management
+ operations.
+ """
+ extension_name: str | None = None
+ """Extension name."""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForIonApproval':
+ assert isinstance(obj, dict)
+ kind = ApprovalKind(obj.get("kind"))
+ command_identifiers = from_union([lambda x: from_list(from_str, x), from_none], obj.get("commandIdentifiers"))
+ server_name = from_union([from_str, from_none], obj.get("serverName"))
+ tool_name = from_union([from_none, from_str], obj.get("toolName"))
+ operation = from_union([from_str, from_none], obj.get("operation"))
+ extension_name = from_union([from_str, from_none], obj.get("extensionName"))
+ return PermissionDecisionApproveForIonApproval(kind, command_identifiers, server_name, tool_name, operation, extension_name)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["kind"] = to_enum(ApprovalKind, self.kind)
+ if self.command_identifiers is not None:
+ result["commandIdentifiers"] = from_union([lambda x: from_list(from_str, x), from_none], self.command_identifiers)
+ if self.server_name is not None:
+ result["serverName"] = from_union([from_str, from_none], self.server_name)
+ if self.tool_name is not None:
+ result["toolName"] = from_union([from_none, from_str], self.tool_name)
+ if self.operation is not None:
+ result["operation"] = from_union([from_str, from_none], self.operation)
+ if self.extension_name is not None:
+ result["extensionName"] = from_union([from_str, from_none], self.extension_name)
+ return result
+
+@dataclass
+class PermissionDecisionApproveForSessionApproval:
+ """The approval to add as a session-scoped rule
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalCommands` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalRead` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalWrite` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalMcp` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalMcpSampling` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalMemory` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalCustomTool` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalExtensionManagement` type.
+
+ Schema for the `PermissionDecisionApproveForSessionApprovalExtensionPermissionAccess`
+ type.
+ """
+ kind: ApprovalKind
+ """Approval scoped to specific command identifiers.
+
+ Approval covering read-only filesystem operations.
+
+ Approval covering filesystem write operations.
+
+ Approval covering an MCP tool.
+
+ Approval covering MCP sampling requests for a server.
+
+ Approval covering writes to long-term memory.
+
+ Approval covering a custom tool.
+
+ Approval covering extension lifecycle operations such as enable, disable, or reload.
+
+ Approval covering an extension's request to access a permission-gated capability.
+ """
+ command_identifiers: list[str] | None = None
+ """Command identifiers covered by this approval."""
+
+ server_name: str | None = None
+ """MCP server name."""
+
+ tool_name: str | None = None
+ """MCP tool name, or null to cover every tool on the server.
+
+ Custom tool name.
+ """
+ operation: str | None = None
+ """Optional operation identifier; when omitted, the approval covers all extension management
+ operations.
+ """
+ extension_name: str | None = None
+ """Extension name."""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForSessionApproval':
+ assert isinstance(obj, dict)
+ kind = ApprovalKind(obj.get("kind"))
+ command_identifiers = from_union([lambda x: from_list(from_str, x), from_none], obj.get("commandIdentifiers"))
+ server_name = from_union([from_str, from_none], obj.get("serverName"))
+ tool_name = from_union([from_none, from_str], obj.get("toolName"))
+ operation = from_union([from_str, from_none], obj.get("operation"))
+ extension_name = from_union([from_str, from_none], obj.get("extensionName"))
+ return PermissionDecisionApproveForSessionApproval(kind, command_identifiers, server_name, tool_name, operation, extension_name)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["kind"] = to_enum(ApprovalKind, self.kind)
+ if self.command_identifiers is not None:
+ result["commandIdentifiers"] = from_union([lambda x: from_list(from_str, x), from_none], self.command_identifiers)
+ if self.server_name is not None:
+ result["serverName"] = from_union([from_str, from_none], self.server_name)
+ if self.tool_name is not None:
+ result["toolName"] = from_union([from_none, from_str], self.tool_name)
+ if self.operation is not None:
+ result["operation"] = from_union([from_str, from_none], self.operation)
+ if self.extension_name is not None:
+ result["extensionName"] = from_union([from_str, from_none], self.extension_name)
+ return result
+
@dataclass
class ExternalToolTextResultForLlm:
"""Expanded external tool result payload"""
@@ -5765,26 +6468,6 @@ def to_dict(self) -> dict:
result["toolTelemetry"] = from_union([lambda x: from_dict(lambda x: x, x), from_none], self.tool_telemetry)
return result
-@dataclass
-class PermissionDecisionRequest:
- request_id: str
- """Request ID of the pending permission request"""
-
- result: PermissionDecision
-
- @staticmethod
- def from_dict(obj: Any) -> 'PermissionDecisionRequest':
- assert isinstance(obj, dict)
- request_id = from_str(obj.get("requestId"))
- result = PermissionDecision.from_dict(obj.get("result"))
- return PermissionDecisionRequest(request_id, result)
-
- def to_dict(self) -> dict:
- result: dict = {}
- result["requestId"] = from_str(self.request_id)
- result["result"] = to_class(PermissionDecision, self.result)
- return result
-
@dataclass
class UIElicitationSchema:
"""JSON Schema describing the form fields to present to the user"""
@@ -5814,8 +6497,69 @@ def to_dict(self) -> dict:
result["required"] = from_union([lambda x: from_list(from_str, x), from_none], self.required)
return result
+@dataclass
+class PermissionDecisionApproveForLocation:
+ """Schema for the `PermissionDecisionApproveForLocation` type."""
+
+ approval: PermissionDecisionApproveForLocationApproval
+ """The approval to persist for this location"""
+
+ kind: PermissionDecisionApproveForLocationKind
+ """Approved and persisted for this project location"""
+
+ location_key: str
+ """The location key (git root or cwd) to persist the approval to"""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForLocation':
+ assert isinstance(obj, dict)
+ approval = PermissionDecisionApproveForLocationApproval.from_dict(obj.get("approval"))
+ kind = PermissionDecisionApproveForLocationKind(obj.get("kind"))
+ location_key = from_str(obj.get("locationKey"))
+ return PermissionDecisionApproveForLocation(approval, kind, location_key)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["approval"] = to_class(PermissionDecisionApproveForLocationApproval, self.approval)
+ result["kind"] = to_enum(PermissionDecisionApproveForLocationKind, self.kind)
+ result["locationKey"] = from_str(self.location_key)
+ return result
+
+@dataclass
+class PermissionDecisionApproveForSession:
+ """Schema for the `PermissionDecisionApproveForSession` type."""
+
+ kind: PermissionDecisionApproveForSessionKind
+ """Approved and remembered for the rest of the session"""
+
+ approval: PermissionDecisionApproveForSessionApproval | None = None
+ """The approval to add as a session-scoped rule"""
+
+ domain: str | None = None
+ """The URL domain to approve for this session"""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionApproveForSession':
+ assert isinstance(obj, dict)
+ kind = PermissionDecisionApproveForSessionKind(obj.get("kind"))
+ approval = from_union([PermissionDecisionApproveForSessionApproval.from_dict, from_none], obj.get("approval"))
+ domain = from_union([from_str, from_none], obj.get("domain"))
+ return PermissionDecisionApproveForSession(kind, approval, domain)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["kind"] = to_enum(PermissionDecisionApproveForSessionKind, self.kind)
+ if self.approval is not None:
+ result["approval"] = from_union([lambda x: to_class(PermissionDecisionApproveForSessionApproval, x), from_none], self.approval)
+ if self.domain is not None:
+ result["domain"] = from_union([from_str, from_none], self.domain)
+ return result
+
@dataclass
class HandlePendingToolCallRequest:
+ """Pending external tool call request ID, with the tool result or an error describing why it
+ failed.
+ """
request_id: str
"""Request ID of the pending tool call"""
@@ -5844,6 +6588,8 @@ def to_dict(self) -> dict:
@dataclass
class UIElicitationRequest:
+ """Prompt message and JSON schema describing the form fields to elicit from the user."""
+
message: str
"""Message describing what information is needed from the user"""
@@ -5863,6 +6609,97 @@ def to_dict(self) -> dict:
result["requestedSchema"] = to_class(UIElicitationSchema, self.requested_schema)
return result
+@dataclass
+class PermissionDecision:
+ """Decision to apply to a pending permission request.
+
+ Schema for the `PermissionDecisionApproveOnce` type.
+
+ Schema for the `PermissionDecisionApproveForSession` type.
+
+ Schema for the `PermissionDecisionApproveForLocation` type.
+
+ Schema for the `PermissionDecisionApprovePermanently` type.
+
+ Schema for the `PermissionDecisionReject` type.
+
+ Schema for the `PermissionDecisionUserNotAvailable` type.
+ """
+ kind: PermissionDecisionKind
+ """The permission request was approved for this one instance
+
+ Approved and remembered for the rest of the session
+
+ Approved and persisted for this project location
+
+ Approved and persisted across sessions
+
+ Denied by the user during an interactive prompt
+
+ Denied because user confirmation was unavailable
+ """
+ approval: PermissionDecisionApproveForIonApproval | None = None
+ """The approval to add as a session-scoped rule
+
+ The approval to persist for this location
+ """
+ domain: str | None = None
+ """The URL domain to approve for this session
+
+ The URL domain to approve permanently
+ """
+ location_key: str | None = None
+ """The location key (git root or cwd) to persist the approval to"""
+
+ feedback: str | None = None
+ """Optional feedback from the user explaining the denial"""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecision':
+ assert isinstance(obj, dict)
+ kind = PermissionDecisionKind(obj.get("kind"))
+ approval = from_union([PermissionDecisionApproveForIonApproval.from_dict, from_none], obj.get("approval"))
+ domain = from_union([from_str, from_none], obj.get("domain"))
+ location_key = from_union([from_str, from_none], obj.get("locationKey"))
+ feedback = from_union([from_str, from_none], obj.get("feedback"))
+ return PermissionDecision(kind, approval, domain, location_key, feedback)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["kind"] = to_enum(PermissionDecisionKind, self.kind)
+ if self.approval is not None:
+ result["approval"] = from_union([lambda x: to_class(PermissionDecisionApproveForIonApproval, x), from_none], self.approval)
+ if self.domain is not None:
+ result["domain"] = from_union([from_str, from_none], self.domain)
+ if self.location_key is not None:
+ result["locationKey"] = from_union([from_str, from_none], self.location_key)
+ if self.feedback is not None:
+ result["feedback"] = from_union([from_str, from_none], self.feedback)
+ return result
+
+@dataclass
+class PermissionDecisionRequest:
+ """Pending permission request ID and the decision to apply (approve/reject and scope)."""
+
+ request_id: str
+ """Request ID of the pending permission request"""
+
+ result: PermissionDecision
+ """Decision to apply to a pending permission request."""
+
+ @staticmethod
+ def from_dict(obj: Any) -> 'PermissionDecisionRequest':
+ assert isinstance(obj, dict)
+ request_id = from_str(obj.get("requestId"))
+ result = PermissionDecision.from_dict(obj.get("result"))
+ return PermissionDecisionRequest(request_id, result)
+
+ def to_dict(self) -> dict:
+ result: dict = {}
+ result["requestId"] = from_str(self.request_id)
+ result["result"] = to_class(PermissionDecision, self.result)
+ return result
+
@dataclass
class ModelCapabilities:
"""Model capabilities and limits"""
@@ -5897,6 +6734,8 @@ class ModelPickerCategory(Enum):
@dataclass
class Model:
+ """Schema for the `Model` type."""
+
capabilities: ModelCapabilities
"""Model capabilities and limits"""
@@ -5959,6 +6798,9 @@ def to_dict(self) -> dict:
@dataclass
class ModelList:
+ """List of Copilot models available to the resolved user, including capabilities and billing
+ metadata.
+ """
models: list[Model]
"""List of available models with full metadata"""
@@ -5975,6 +6817,8 @@ def to_dict(self) -> dict:
@dataclass
class ModelSwitchToRequest:
+ """Target model identifier and optional reasoning effort, summary, and capability overrides."""
+
model_id: str
"""Model identifier to switch to"""
@@ -5982,7 +6826,10 @@ class ModelSwitchToRequest:
"""Override individual model capabilities resolved by the runtime"""
reasoning_effort: str | None = None
- """Reasoning effort level to use for the model"""
+ """Reasoning effort level to use for the model. "none" disables reasoning."""
+
+ reasoning_summary: ReasoningSummary | None = None
+ """Reasoning summary mode to request for supported model clients"""
@staticmethod
def from_dict(obj: Any) -> 'ModelSwitchToRequest':
@@ -5990,7 +6837,8 @@ def from_dict(obj: Any) -> 'ModelSwitchToRequest':
model_id = from_str(obj.get("modelId"))
model_capabilities = from_union([ModelCapabilitiesOverride.from_dict, from_none], obj.get("modelCapabilities"))
reasoning_effort = from_union([from_str, from_none], obj.get("reasoningEffort"))
- return ModelSwitchToRequest(model_id, model_capabilities, reasoning_effort)
+ reasoning_summary = from_union([ReasoningSummary.from_dict, from_none], obj.get("reasoningSummary"))
+ return ModelSwitchToRequest(model_id, model_capabilities, reasoning_effort, reasoning_summary)
def to_dict(self) -> dict:
result: dict = {}
@@ -5999,10 +6847,14 @@ def to_dict(self) -> dict:
result["modelCapabilities"] = from_union([lambda x: to_class(ModelCapabilitiesOverride, x), from_none], self.model_capabilities)
if self.reasoning_effort is not None:
result["reasoningEffort"] = from_union([from_str, from_none], self.reasoning_effort)
+ if self.reasoning_summary is not None:
+ result["reasoningSummary"] = from_union([lambda x: to_class(ReasoningSummary, x), from_none], self.reasoning_summary)
return result
@dataclass
class TaskAgentInfo:
+ """Schema for the `TaskAgentInfo` type."""
+
agent_type: str
"""Type of agent running this task"""
@@ -6116,6 +6968,12 @@ def to_dict(self) -> dict:
@dataclass
class TaskInfo:
+ """Schema for the `TaskInfo` type.
+
+ Schema for the `TaskAgentInfo` type.
+
+ Schema for the `TaskShellInfo` type.
+ """
description: str
"""Short description of the task"""
@@ -6262,6 +7120,8 @@ def to_dict(self) -> dict:
# Experimental: this type is part of an experimental API and may change or be removed.
@dataclass
class TaskList:
+ """Background tasks currently tracked by the session."""
+
tasks: list[TaskInfo]
"""Currently tracked tasks"""
@@ -7095,7 +7955,7 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def list(self, params: ModelsListRequest, *, timeout: float | None = None) -> ModelList:
- "Calls models.list."
+ "Lists Copilot models available to the authenticated user.\n\nArgs:\n params: Optional GitHub token used to list models for a specific user instead of the global auth context.\n\nReturns:\n List of Copilot models available to the resolved user, including capabilities and billing metadata."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return ModelList.from_dict(_patch_model_capabilities(await self._client.request("models.list", params_dict, **_timeout_kwargs(timeout))))
@@ -7105,7 +7965,7 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def list(self, params: ToolsListRequest, *, timeout: float | None = None) -> ToolList:
- "Calls tools.list."
+ "Lists built-in tools available for a model.\n\nArgs:\n params: Optional model identifier whose tool overrides should be applied to the listing.\n\nReturns:\n Built-in tools available for the requested model, with their parameters and instructions."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return ToolList.from_dict(await self._client.request("tools.list", params_dict, **_timeout_kwargs(timeout)))
@@ -7115,7 +7975,7 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def get_quota(self, params: AccountGetQuotaRequest, *, timeout: float | None = None) -> AccountGetQuotaResult:
- "Calls account.getQuota."
+ "Gets Copilot quota usage for the authenticated user or supplied GitHub token.\n\nArgs:\n params: Optional GitHub token used to look up quota for a specific user instead of the global auth context.\n\nReturns:\n Quota usage snapshots for the resolved user, keyed by quota type."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return AccountGetQuotaResult.from_dict(await self._client.request("account.getQuota", params_dict, **_timeout_kwargs(timeout)))
@@ -7125,31 +7985,31 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def list(self, *, timeout: float | None = None) -> MCPConfigList:
- "Calls mcp.config.list."
+ "Lists MCP servers from user configuration.\n\nReturns:\n User-configured MCP servers, keyed by server name."
return MCPConfigList.from_dict(await self._client.request("mcp.config.list", {}, **_timeout_kwargs(timeout)))
async def add(self, params: MCPConfigAddRequest, *, timeout: float | None = None) -> None:
- "Calls mcp.config.add."
+ "Adds an MCP server to user configuration.\n\nArgs:\n params: MCP server name and configuration to add to user configuration."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
await self._client.request("mcp.config.add", params_dict, **_timeout_kwargs(timeout))
async def update(self, params: MCPConfigUpdateRequest, *, timeout: float | None = None) -> None:
- "Calls mcp.config.update."
+ "Updates an MCP server in user configuration.\n\nArgs:\n params: MCP server name and replacement configuration to write to user configuration."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
await self._client.request("mcp.config.update", params_dict, **_timeout_kwargs(timeout))
async def remove(self, params: MCPConfigRemoveRequest, *, timeout: float | None = None) -> None:
- "Calls mcp.config.remove."
+ "Removes an MCP server from user configuration.\n\nArgs:\n params: MCP server name to remove from user configuration."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
await self._client.request("mcp.config.remove", params_dict, **_timeout_kwargs(timeout))
async def enable(self, params: MCPConfigEnableRequest, *, timeout: float | None = None) -> None:
- "Calls mcp.config.enable."
+ "Enables MCP servers in user configuration for new sessions.\n\nArgs:\n params: MCP server names to enable for new sessions."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
await self._client.request("mcp.config.enable", params_dict, **_timeout_kwargs(timeout))
async def disable(self, params: MCPConfigDisableRequest, *, timeout: float | None = None) -> None:
- "Calls mcp.config.disable."
+ "Disables MCP servers in user configuration for new sessions.\n\nArgs:\n params: MCP server names to disable for new sessions."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
await self._client.request("mcp.config.disable", params_dict, **_timeout_kwargs(timeout))
@@ -7160,7 +8020,7 @@ def __init__(self, client: "JsonRpcClient"):
self.config = ServerMcpConfigApi(client)
async def discover(self, params: MCPDiscoverRequest, *, timeout: float | None = None) -> MCPDiscoverResult:
- "Calls mcp.discover."
+ "Discovers MCP servers from user, workspace, plugin, and builtin sources.\n\nArgs:\n params: Optional working directory used as context for MCP server discovery.\n\nReturns:\n MCP servers discovered from user, workspace, plugin, and built-in sources."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return MCPDiscoverResult.from_dict(await self._client.request("mcp.discover", params_dict, **_timeout_kwargs(timeout)))
@@ -7170,7 +8030,7 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def set_disabled_skills(self, params: SkillsConfigSetDisabledSkillsRequest, *, timeout: float | None = None) -> None:
- "Calls skills.config.setDisabledSkills."
+ "Replaces the global list of disabled skills.\n\nArgs:\n params: Skill names to mark as disabled in global configuration, replacing any previous list."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
await self._client.request("skills.config.setDisabledSkills", params_dict, **_timeout_kwargs(timeout))
@@ -7181,7 +8041,7 @@ def __init__(self, client: "JsonRpcClient"):
self.config = ServerSkillsConfigApi(client)
async def discover(self, params: SkillsDiscoverRequest, *, timeout: float | None = None) -> ServerSkillList:
- "Calls skills.discover."
+ "Discovers skills across global and project sources.\n\nArgs:\n params: Optional project paths and additional skill directories to include in discovery.\n\nReturns:\n Skills discovered across global and project sources."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return ServerSkillList.from_dict(await self._client.request("skills.discover", params_dict, **_timeout_kwargs(timeout)))
@@ -7191,7 +8051,7 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def set_provider(self, params: SessionFSSetProviderRequest, *, timeout: float | None = None) -> SessionFSSetProviderResult:
- "Calls sessionFs.setProvider."
+ "Registers an SDK client as the session filesystem provider.\n\nArgs:\n params: Initial working directory, session-state path layout, and path conventions used to register the calling SDK client as the session filesystem provider.\n\nReturns:\n Indicates whether the calling client was registered as the session filesystem provider."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return SessionFSSetProviderResult.from_dict(await self._client.request("sessionFs.setProvider", params_dict, **_timeout_kwargs(timeout)))
@@ -7202,7 +8062,7 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def fork(self, params: SessionsForkRequest, *, timeout: float | None = None) -> SessionsForkResult:
- "Calls sessions.fork."
+ "Creates a new session by forking persisted history from an existing session.\n\nArgs:\n params: Source session identifier to fork from, optional event-ID boundary, and optional friendly name for the new session.\n\nReturns:\n Identifier and optional friendly name assigned to the newly forked session."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return SessionsForkResult.from_dict(await self._client.request("sessions.fork", params_dict, **_timeout_kwargs(timeout)))
@@ -7220,7 +8080,7 @@ def __init__(self, client: "JsonRpcClient"):
self.sessions = ServerSessionsApi(client)
async def ping(self, params: PingRequest, *, timeout: float | None = None) -> PingResult:
- "Calls ping."
+ "Checks server responsiveness and returns protocol information.\n\nArgs:\n params: Optional message to echo back to the caller.\n\nReturns:\n Server liveness response, including the echoed message, current timestamp, and protocol version."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return PingResult.from_dict(await self._client.request("ping", params_dict, **_timeout_kwargs(timeout)))
@@ -7231,7 +8091,7 @@ def __init__(self, client: "JsonRpcClient"):
self._client = client
async def connect(self, params: ConnectRequest, *, timeout: float | None = None) -> ConnectResult:
- "Calls connect.\n\n:meta private:\n\nInternal SDK API; not part of the public surface."
+ "Performs the SDK server connection handshake and validates the optional connection token.\n\nArgs:\n params: Optional connection token presented by the SDK client during the handshake.\n\nReturns:\n Handshake result reporting the server's protocol version and package version on success.\n\n:meta private:\n\nInternal SDK API; not part of the public surface."
params_dict = {k: v for k, v in params.to_dict().items() if v is not None}
return ConnectResult.from_dict(await self._client.request("connect", params_dict, **_timeout_kwargs(timeout)))
@@ -7242,7 +8102,7 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def get_status(self, *, timeout: float | None = None) -> SessionAuthStatus:
- "Calls session.auth.getStatus."
+ "Gets authentication status and account metadata for the session.\n\nReturns:\n Authentication status and account metadata for the session."
return SessionAuthStatus.from_dict(await self._client.request("session.auth.getStatus", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
@@ -7252,11 +8112,11 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def get_current(self, *, timeout: float | None = None) -> CurrentModel:
- "Calls session.model.getCurrent."
+ "Gets the currently selected model for the session.\n\nReturns:\n The currently selected model for the session."
return CurrentModel.from_dict(await self._client.request("session.model.getCurrent", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def switch_to(self, params: ModelSwitchToRequest, *, timeout: float | None = None) -> ModelSwitchToResult:
- "Calls session.model.switchTo."
+ "Switches the session to a model and optional reasoning configuration.\n\nArgs:\n params: Target model identifier and optional reasoning effort, summary, and capability overrides.\n\nReturns:\n The model identifier active on the session after the switch."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return ModelSwitchToResult.from_dict(await self._client.request("session.model.switchTo", params_dict, **_timeout_kwargs(timeout)))
@@ -7268,11 +8128,11 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def get(self, *, timeout: float | None = None) -> Mode:
- "Calls session.mode.get.\n\nReturns:\n The agent mode. Valid values: \"interactive\", \"plan\", \"autopilot\"."
+ "Gets the current agent interaction mode.\n\nReturns:\n The agent mode. Valid values: \"interactive\", \"plan\", \"autopilot\"."
return Mode(await self._client.request("session.mode.get", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def set(self, params: ModeSetRequest, *, timeout: float | None = None) -> None:
- "Calls session.mode.set."
+ "Sets the current agent interaction mode.\n\nArgs:\n params: Agent interaction mode to apply to the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.mode.set", params_dict, **_timeout_kwargs(timeout))
@@ -7284,11 +8144,11 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def get(self, *, timeout: float | None = None) -> NameGetResult:
- "Calls session.name.get."
+ "Gets the session's friendly name.\n\nReturns:\n The session's friendly name, or null when not yet set."
return NameGetResult.from_dict(await self._client.request("session.name.get", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def set(self, params: NameSetRequest, *, timeout: float | None = None) -> None:
- "Calls session.name.set."
+ "Sets the session's friendly name.\n\nArgs:\n params: New friendly name to apply to the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.name.set", params_dict, **_timeout_kwargs(timeout))
@@ -7300,17 +8160,17 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def read(self, *, timeout: float | None = None) -> PlanReadResult:
- "Calls session.plan.read."
+ "Reads the session plan file from the workspace.\n\nReturns:\n Existence, contents, and resolved path of the session plan file."
return PlanReadResult.from_dict(await self._client.request("session.plan.read", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def update(self, params: PlanUpdateRequest, *, timeout: float | None = None) -> None:
- "Calls session.plan.update."
+ "Writes new content to the session plan file.\n\nArgs:\n params: Replacement contents to write to the session plan file."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.plan.update", params_dict, **_timeout_kwargs(timeout))
async def delete(self, *, timeout: float | None = None) -> None:
- "Calls session.plan.delete."
+ "Deletes the session plan file from the workspace."
await self._client.request("session.plan.delete", {"sessionId": self._session_id}, **_timeout_kwargs(timeout))
@@ -7320,21 +8180,21 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def get_workspace(self, *, timeout: float | None = None) -> WorkspacesGetWorkspaceResult:
- "Calls session.workspaces.getWorkspace."
+ "Gets current workspace metadata for the session.\n\nReturns:\n Current workspace metadata for the session, or null when not available."
return WorkspacesGetWorkspaceResult.from_dict(await self._client.request("session.workspaces.getWorkspace", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def list_files(self, *, timeout: float | None = None) -> WorkspacesListFilesResult:
- "Calls session.workspaces.listFiles."
+ "Lists files stored in the session workspace files directory.\n\nReturns:\n Relative paths of files stored in the session workspace files directory."
return WorkspacesListFilesResult.from_dict(await self._client.request("session.workspaces.listFiles", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def read_file(self, params: WorkspacesReadFileRequest, *, timeout: float | None = None) -> WorkspacesReadFileResult:
- "Calls session.workspaces.readFile."
+ "Reads a file from the session workspace files directory.\n\nArgs:\n params: Relative path of the workspace file to read.\n\nReturns:\n Contents of the requested workspace file as a UTF-8 string."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return WorkspacesReadFileResult.from_dict(await self._client.request("session.workspaces.readFile", params_dict, **_timeout_kwargs(timeout)))
async def create_file(self, params: WorkspacesCreateFileRequest, *, timeout: float | None = None) -> None:
- "Calls session.workspaces.createFile."
+ "Creates or overwrites a file in the session workspace files directory.\n\nArgs:\n params: Relative path and UTF-8 content for the workspace file to create or overwrite."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.workspaces.createFile", params_dict, **_timeout_kwargs(timeout))
@@ -7346,7 +8206,7 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def get_sources(self, *, timeout: float | None = None) -> InstructionsGetSourcesResult:
- "Calls session.instructions.getSources."
+ "Gets instruction sources loaded for the session.\n\nReturns:\n Instruction sources loaded for the session, in merge order."
return InstructionsGetSourcesResult.from_dict(await self._client.request("session.instructions.getSources", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
@@ -7357,7 +8217,7 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def start(self, params: FleetStartRequest, *, timeout: float | None = None) -> FleetStartResult:
- "Calls session.fleet.start."
+ "Starts fleet mode by submitting the fleet orchestration prompt to the session.\n\nArgs:\n params: Optional user prompt to combine with the fleet orchestration instructions.\n\nReturns:\n Indicates whether fleet mode was successfully activated."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return FleetStartResult.from_dict(await self._client.request("session.fleet.start", params_dict, **_timeout_kwargs(timeout)))
@@ -7370,25 +8230,25 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def list(self, *, timeout: float | None = None) -> AgentList:
- "Calls session.agent.list."
+ "Lists custom agents available to the session.\n\nReturns:\n Custom agents available to the session."
return AgentList.from_dict(await self._client.request("session.agent.list", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def get_current(self, *, timeout: float | None = None) -> AgentGetCurrentResult:
- "Calls session.agent.getCurrent."
+ "Gets the currently selected custom agent for the session.\n\nReturns:\n The currently selected custom agent, or null when using the default agent."
return AgentGetCurrentResult.from_dict(await self._client.request("session.agent.getCurrent", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def select(self, params: AgentSelectRequest, *, timeout: float | None = None) -> AgentSelectResult:
- "Calls session.agent.select."
+ "Selects a custom agent for subsequent turns in the session.\n\nArgs:\n params: Name of the custom agent to select for subsequent turns.\n\nReturns:\n The newly selected custom agent."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return AgentSelectResult.from_dict(await self._client.request("session.agent.select", params_dict, **_timeout_kwargs(timeout)))
async def deselect(self, *, timeout: float | None = None) -> None:
- "Calls session.agent.deselect."
+ "Clears the selected custom agent and returns the session to the default agent."
await self._client.request("session.agent.deselect", {"sessionId": self._session_id}, **_timeout_kwargs(timeout))
async def reload(self, *, timeout: float | None = None) -> AgentReloadResult:
- "Calls session.agent.reload."
+ "Reloads custom agent definitions and returns the refreshed list.\n\nReturns:\n Custom agents available to the session after reloading definitions from disk."
return AgentReloadResult.from_dict(await self._client.request("session.agent.reload", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
@@ -7399,35 +8259,35 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def start_agent(self, params: TasksStartAgentRequest, *, timeout: float | None = None) -> TasksStartAgentResult:
- "Calls session.tasks.startAgent."
+ "Starts a background agent task in the session.\n\nArgs:\n params: Agent type, prompt, name, and optional description and model override for the new task.\n\nReturns:\n Identifier assigned to the newly started background agent task."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return TasksStartAgentResult.from_dict(await self._client.request("session.tasks.startAgent", params_dict, **_timeout_kwargs(timeout)))
async def list(self, *, timeout: float | None = None) -> TaskList:
- "Calls session.tasks.list."
+ "Lists background tasks tracked by the session.\n\nReturns:\n Background tasks currently tracked by the session."
return TaskList.from_dict(await self._client.request("session.tasks.list", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def promote_to_background(self, params: TasksPromoteToBackgroundRequest, *, timeout: float | None = None) -> TasksPromoteToBackgroundResult:
- "Calls session.tasks.promoteToBackground."
+ "Promotes an eligible synchronously-waited task so it continues running in the background.\n\nArgs:\n params: Identifier of the task to promote to background mode.\n\nReturns:\n Indicates whether the task was successfully promoted to background mode."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return TasksPromoteToBackgroundResult.from_dict(await self._client.request("session.tasks.promoteToBackground", params_dict, **_timeout_kwargs(timeout)))
async def cancel(self, params: TasksCancelRequest, *, timeout: float | None = None) -> TasksCancelResult:
- "Calls session.tasks.cancel."
+ "Cancels a background task.\n\nArgs:\n params: Identifier of the background task to cancel.\n\nReturns:\n Indicates whether the background task was successfully cancelled."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return TasksCancelResult.from_dict(await self._client.request("session.tasks.cancel", params_dict, **_timeout_kwargs(timeout)))
async def remove(self, params: TasksRemoveRequest, *, timeout: float | None = None) -> TasksRemoveResult:
- "Calls session.tasks.remove."
+ "Removes a completed or cancelled background task from tracking.\n\nArgs:\n params: Identifier of the completed or cancelled task to remove from tracking.\n\nReturns:\n Indicates whether the task was removed. False when the task does not exist or is still running/idle."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return TasksRemoveResult.from_dict(await self._client.request("session.tasks.remove", params_dict, **_timeout_kwargs(timeout)))
async def send_message(self, params: TasksSendMessageRequest, *, timeout: float | None = None) -> TasksSendMessageResult:
- "Calls session.tasks.sendMessage."
+ "Sends a message to a background agent task.\n\nArgs:\n params: Identifier of the target agent task, message content, and optional sender agent ID.\n\nReturns:\n Indicates whether the message was delivered, with an error message when delivery failed."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return TasksSendMessageResult.from_dict(await self._client.request("session.tasks.sendMessage", params_dict, **_timeout_kwargs(timeout)))
@@ -7440,23 +8300,23 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def list(self, *, timeout: float | None = None) -> SkillList:
- "Calls session.skills.list."
+ "Lists skills available to the session.\n\nReturns:\n Skills available to the session, with their enabled state."
return SkillList.from_dict(await self._client.request("session.skills.list", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def enable(self, params: SkillsEnableRequest, *, timeout: float | None = None) -> None:
- "Calls session.skills.enable."
+ "Enables a skill for the session.\n\nArgs:\n params: Name of the skill to enable for the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.skills.enable", params_dict, **_timeout_kwargs(timeout))
async def disable(self, params: SkillsDisableRequest, *, timeout: float | None = None) -> None:
- "Calls session.skills.disable."
+ "Disables a skill for the session.\n\nArgs:\n params: Name of the skill to disable for the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.skills.disable", params_dict, **_timeout_kwargs(timeout))
async def reload(self, *, timeout: float | None = None) -> SkillsLoadDiagnostics:
- "Calls session.skills.reload."
+ "Reloads skill definitions for the session.\n\nReturns:\n Diagnostics from reloading skill definitions, with warnings and errors as separate lists."
return SkillsLoadDiagnostics.from_dict(await self._client.request("session.skills.reload", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
@@ -7467,7 +8327,7 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def login(self, params: MCPOauthLoginRequest, *, timeout: float | None = None) -> MCPOauthLoginResult:
- "Calls session.mcp.oauth.login."
+ "Starts OAuth authentication for a remote MCP server.\n\nArgs:\n params: Remote MCP server name and optional overrides controlling reauthentication, OAuth client display name, and the callback success-page copy.\n\nReturns:\n OAuth authorization URL the caller should open, or empty when cached tokens already authenticated the server."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return MCPOauthLoginResult.from_dict(await self._client.request("session.mcp.oauth.login", params_dict, **_timeout_kwargs(timeout)))
@@ -7481,23 +8341,23 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self.oauth = McpOauthApi(client, session_id)
async def list(self, *, timeout: float | None = None) -> MCPServerList:
- "Calls session.mcp.list."
+ "Lists MCP servers configured for the session and their connection status.\n\nReturns:\n MCP servers configured for the session, with their connection status."
return MCPServerList.from_dict(await self._client.request("session.mcp.list", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def enable(self, params: MCPEnableRequest, *, timeout: float | None = None) -> None:
- "Calls session.mcp.enable."
+ "Enables an MCP server for the session.\n\nArgs:\n params: Name of the MCP server to enable for the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.mcp.enable", params_dict, **_timeout_kwargs(timeout))
async def disable(self, params: MCPDisableRequest, *, timeout: float | None = None) -> None:
- "Calls session.mcp.disable."
+ "Disables an MCP server for the session.\n\nArgs:\n params: Name of the MCP server to disable for the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.mcp.disable", params_dict, **_timeout_kwargs(timeout))
async def reload(self, *, timeout: float | None = None) -> None:
- "Calls session.mcp.reload."
+ "Reloads MCP server connections for the session."
await self._client.request("session.mcp.reload", {"sessionId": self._session_id}, **_timeout_kwargs(timeout))
@@ -7508,7 +8368,7 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def list(self, *, timeout: float | None = None) -> PluginList:
- "Calls session.plugins.list."
+ "Lists plugins installed for the session.\n\nReturns:\n Plugins installed for the session, with their enabled state and version metadata."
return PluginList.from_dict(await self._client.request("session.plugins.list", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
@@ -7519,23 +8379,23 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def list(self, *, timeout: float | None = None) -> ExtensionList:
- "Calls session.extensions.list."
+ "Lists extensions discovered for the session and their current status.\n\nReturns:\n Extensions discovered for the session, with their current status."
return ExtensionList.from_dict(await self._client.request("session.extensions.list", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def enable(self, params: ExtensionsEnableRequest, *, timeout: float | None = None) -> None:
- "Calls session.extensions.enable."
+ "Enables an extension for the session.\n\nArgs:\n params: Source-qualified extension identifier to enable for the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.extensions.enable", params_dict, **_timeout_kwargs(timeout))
async def disable(self, params: ExtensionsDisableRequest, *, timeout: float | None = None) -> None:
- "Calls session.extensions.disable."
+ "Disables an extension for the session.\n\nArgs:\n params: Source-qualified extension identifier to disable for the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
await self._client.request("session.extensions.disable", params_dict, **_timeout_kwargs(timeout))
async def reload(self, *, timeout: float | None = None) -> None:
- "Calls session.extensions.reload."
+ "Reloads extension definitions and processes for the session."
await self._client.request("session.extensions.reload", {"sessionId": self._session_id}, **_timeout_kwargs(timeout))
@@ -7545,7 +8405,7 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def handle_pending_tool_call(self, params: HandlePendingToolCallRequest, *, timeout: float | None = None) -> HandlePendingToolCallResult:
- "Calls session.tools.handlePendingToolCall."
+ "Provides the result for a pending external tool call.\n\nArgs:\n params: Pending external tool call request ID, with the tool result or an error describing why it failed.\n\nReturns:\n Indicates whether the external tool call result was handled successfully."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return HandlePendingToolCallResult.from_dict(await self._client.request("session.tools.handlePendingToolCall", params_dict, **_timeout_kwargs(timeout)))
@@ -7557,25 +8417,25 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def list(self, params: CommandsListRequest | None = None, *, timeout: float | None = None) -> CommandList:
- "Calls session.commands.list."
+ "Lists slash commands available in the session.\n\nArgs:\n params: Optional filters controlling which command sources to include in the listing.\n\nReturns:\n Slash commands available in the session, after applying any include/exclude filters."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None} if params is not None else {}
params_dict["sessionId"] = self._session_id
return CommandList.from_dict(await self._client.request("session.commands.list", params_dict, **_timeout_kwargs(timeout)))
async def invoke(self, params: CommandsInvokeRequest, *, timeout: float | None = None) -> SlashCommandInvocationResult:
- "Calls session.commands.invoke."
+ "Invokes a slash command in the session.\n\nArgs:\n params: Slash command name and optional raw input string to invoke.\n\nReturns:\n Result of invoking the slash command (text output, prompt to send to the agent, or completion)."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return SlashCommandInvocationResult.from_dict(await self._client.request("session.commands.invoke", params_dict, **_timeout_kwargs(timeout)))
async def handle_pending_command(self, params: CommandsHandlePendingCommandRequest, *, timeout: float | None = None) -> CommandsHandlePendingCommandResult:
- "Calls session.commands.handlePendingCommand."
+ "Reports completion of a pending client-handled slash command.\n\nArgs:\n params: Pending command request ID and an optional error if the client handler failed.\n\nReturns:\n Indicates whether the pending client-handled command was completed successfully."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return CommandsHandlePendingCommandResult.from_dict(await self._client.request("session.commands.handlePendingCommand", params_dict, **_timeout_kwargs(timeout)))
async def respond_to_queued_command(self, params: CommandsRespondToQueuedCommandRequest, *, timeout: float | None = None) -> CommandsRespondToQueuedCommandResult:
- "Calls session.commands.respondToQueuedCommand."
+ "Responds to a queued command request from the session.\n\nArgs:\n params: Queued command request ID and the result indicating whether the client handled it.\n\nReturns:\n Indicates whether the queued-command response was accepted by the session."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return CommandsRespondToQueuedCommandResult.from_dict(await self._client.request("session.commands.respondToQueuedCommand", params_dict, **_timeout_kwargs(timeout)))
@@ -7587,13 +8447,13 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def elicitation(self, params: UIElicitationRequest, *, timeout: float | None = None) -> UIElicitationResponse:
- "Calls session.ui.elicitation.\n\nReturns:\n The elicitation response (accept with form values, decline, or cancel)"
+ "Requests structured input from a UI-capable client.\n\nArgs:\n params: Prompt message and JSON schema describing the form fields to elicit from the user.\n\nReturns:\n The elicitation response (accept with form values, decline, or cancel)"
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return UIElicitationResponse.from_dict(await self._client.request("session.ui.elicitation", params_dict, **_timeout_kwargs(timeout)))
async def handle_pending_elicitation(self, params: UIHandlePendingElicitationRequest, *, timeout: float | None = None) -> UIElicitationResult:
- "Calls session.ui.handlePendingElicitation."
+ "Provides the user response for a pending elicitation request.\n\nArgs:\n params: Pending elicitation request ID and the user's response (accept/decline/cancel + form values).\n\nReturns:\n Indicates whether the elicitation response was accepted; false if it was already resolved by another client."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return UIElicitationResult.from_dict(await self._client.request("session.ui.handlePendingElicitation", params_dict, **_timeout_kwargs(timeout)))
@@ -7605,19 +8465,19 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def handle_pending_permission_request(self, params: PermissionDecisionRequest, *, timeout: float | None = None) -> PermissionRequestResult:
- "Calls session.permissions.handlePendingPermissionRequest."
+ "Provides a decision for a pending tool permission request.\n\nArgs:\n params: Pending permission request ID and the decision to apply (approve/reject and scope).\n\nReturns:\n Indicates whether the permission decision was applied; false when the request was already resolved."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return PermissionRequestResult.from_dict(await self._client.request("session.permissions.handlePendingPermissionRequest", params_dict, **_timeout_kwargs(timeout)))
async def set_approve_all(self, params: PermissionsSetApproveAllRequest, *, timeout: float | None = None) -> PermissionsSetApproveAllResult:
- "Calls session.permissions.setApproveAll."
+ "Enables or disables automatic approval of tool permission requests for the session.\n\nArgs:\n params: Whether to auto-approve all tool permission requests for the rest of the session.\n\nReturns:\n Indicates whether the operation succeeded."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return PermissionsSetApproveAllResult.from_dict(await self._client.request("session.permissions.setApproveAll", params_dict, **_timeout_kwargs(timeout)))
async def reset_session_approvals(self, *, timeout: float | None = None) -> PermissionsResetSessionApprovalsResult:
- "Calls session.permissions.resetSessionApprovals."
+ "Clears session-scoped tool permission approvals.\n\nReturns:\n Indicates whether the operation succeeded."
return PermissionsResetSessionApprovalsResult.from_dict(await self._client.request("session.permissions.resetSessionApprovals", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
@@ -7627,13 +8487,13 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def exec(self, params: ShellExecRequest, *, timeout: float | None = None) -> ShellExecResult:
- "Calls session.shell.exec."
+ "Starts a shell command and streams output through session notifications.\n\nArgs:\n params: Shell command to run, with optional working directory and timeout in milliseconds.\n\nReturns:\n Identifier of the spawned process, used to correlate streamed output and exit notifications."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return ShellExecResult.from_dict(await self._client.request("session.shell.exec", params_dict, **_timeout_kwargs(timeout)))
async def kill(self, params: ShellKillRequest, *, timeout: float | None = None) -> ShellKillResult:
- "Calls session.shell.kill."
+ "Sends a signal to a shell process previously started via \"shell.exec\".\n\nArgs:\n params: Identifier of a process previously returned by \"shell.exec\" and the signal to send.\n\nReturns:\n Indicates whether the signal was delivered; false if the process was unknown or already exited."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return ShellKillResult.from_dict(await self._client.request("session.shell.kill", params_dict, **_timeout_kwargs(timeout)))
@@ -7646,11 +8506,11 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def compact(self, *, timeout: float | None = None) -> HistoryCompactResult:
- "Calls session.history.compact."
+ "Compacts the session history to reduce context usage.\n\nReturns:\n Compaction outcome with the number of tokens and messages removed and the resulting context window breakdown."
return HistoryCompactResult.from_dict(await self._client.request("session.history.compact", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
async def truncate(self, params: HistoryTruncateRequest, *, timeout: float | None = None) -> HistoryTruncateResult:
- "Calls session.history.truncate."
+ "Truncates persisted session history to a specific event.\n\nArgs:\n params: Identifier of the event to truncate to; this event and all later events are removed.\n\nReturns:\n Number of events that were removed by the truncation."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return HistoryTruncateResult.from_dict(await self._client.request("session.history.truncate", params_dict, **_timeout_kwargs(timeout)))
@@ -7663,7 +8523,7 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def get_metrics(self, *, timeout: float | None = None) -> UsageGetMetricsResult:
- "Calls session.usage.getMetrics."
+ "Gets accumulated usage metrics for the session.\n\nReturns:\n Accumulated session usage metrics, including premium request cost, token counts, model breakdown, and code-change totals."
return UsageGetMetricsResult.from_dict(await self._client.request("session.usage.getMetrics", {"sessionId": self._session_id}, **_timeout_kwargs(timeout)))
@@ -7674,13 +8534,13 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self._session_id = session_id
async def enable(self, params: RemoteEnableRequest, *, timeout: float | None = None) -> RemoteEnableResult:
- "Calls session.remote.enable."
+ "Enables remote session export or steering.\n\nArgs:\n params: Optional remote session mode (\"off\", \"export\", or \"on\"); defaults to enabling both export and remote steering.\n\nReturns:\n GitHub URL for the session and a flag indicating whether remote steering is enabled."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return RemoteEnableResult.from_dict(await self._client.request("session.remote.enable", params_dict, **_timeout_kwargs(timeout)))
async def disable(self, *, timeout: float | None = None) -> None:
- "Calls session.remote.disable."
+ "Disables remote session export and steering."
await self._client.request("session.remote.disable", {"sessionId": self._session_id}, **_timeout_kwargs(timeout))
@@ -7713,11 +8573,11 @@ def __init__(self, client: "JsonRpcClient", session_id: str):
self.remote = RemoteApi(client, session_id)
async def suspend(self, *, timeout: float | None = None) -> None:
- "Calls session.suspend."
+ "Suspends the session while preserving persisted state for later resume."
await self._client.request("session.suspend", {"sessionId": self._session_id}, **_timeout_kwargs(timeout))
async def log(self, params: LogRequest, *, timeout: float | None = None) -> LogResult:
- "Calls session.log."
+ "Emits a user-visible session log event.\n\nArgs:\n params: Message text, optional severity level, persistence flag, and optional follow-up URL.\n\nReturns:\n Identifier of the session event that was emitted for the log message."
params_dict: dict[str, Any] = {k: v for k, v in params.to_dict().items() if v is not None}
params_dict["sessionId"] = self._session_id
return LogResult.from_dict(await self._client.request("session.log", params_dict, **_timeout_kwargs(timeout)))
@@ -7725,34 +8585,34 @@ async def log(self, params: LogRequest, *, timeout: float | None = None) -> LogR
class SessionFsHandler(Protocol):
async def read_file(self, params: SessionFSReadFileRequest) -> SessionFSReadFileResult:
- "Calls sessionFs.readFile."
+ "Reads a file from the client-provided session filesystem.\n\nArgs:\n params: Path of the file to read from the client-provided session filesystem.\n\nReturns:\n File content as a UTF-8 string, or a filesystem error if the read failed."
pass
async def write_file(self, params: SessionFSWriteFileRequest) -> SessionFSError | None:
- "Calls sessionFs.writeFile.\n\nReturns:\n Describes a filesystem error."
+ "Writes a file in the client-provided session filesystem.\n\nArgs:\n params: File path, content to write, and optional mode for the client-provided session filesystem.\n\nReturns:\n Describes a filesystem error."
pass
async def append_file(self, params: SessionFSAppendFileRequest) -> SessionFSError | None:
- "Calls sessionFs.appendFile.\n\nReturns:\n Describes a filesystem error."
+ "Appends content to a file in the client-provided session filesystem.\n\nArgs:\n params: File path, content to append, and optional mode for the client-provided session filesystem.\n\nReturns:\n Describes a filesystem error."
pass
async def exists(self, params: SessionFSExistsRequest) -> SessionFSExistsResult:
- "Calls sessionFs.exists."
+ "Checks whether a path exists in the client-provided session filesystem.\n\nArgs:\n params: Path to test for existence in the client-provided session filesystem.\n\nReturns:\n Indicates whether the requested path exists in the client-provided session filesystem."
pass
async def stat(self, params: SessionFSStatRequest) -> SessionFSStatResult:
- "Calls sessionFs.stat."
+ "Gets metadata for a path in the client-provided session filesystem.\n\nArgs:\n params: Path whose metadata should be returned from the client-provided session filesystem.\n\nReturns:\n Filesystem metadata for the requested path, or a filesystem error if the stat failed."
pass
async def mkdir(self, params: SessionFSMkdirRequest) -> SessionFSError | None:
- "Calls sessionFs.mkdir.\n\nReturns:\n Describes a filesystem error."
+ "Creates a directory in the client-provided session filesystem.\n\nArgs:\n params: Directory path to create in the client-provided session filesystem, with options for recursive creation and POSIX mode.\n\nReturns:\n Describes a filesystem error."
pass
async def readdir(self, params: SessionFSReaddirRequest) -> SessionFSReaddirResult:
- "Calls sessionFs.readdir."
+ "Lists entry names in a directory from the client-provided session filesystem.\n\nArgs:\n params: Directory path whose entries should be listed from the client-provided session filesystem.\n\nReturns:\n Names of entries in the requested directory, or a filesystem error if the read failed."
pass
async def readdir_with_types(self, params: SessionFSReaddirWithTypesRequest) -> SessionFSReaddirWithTypesResult:
- "Calls sessionFs.readdirWithTypes."
+ "Lists directory entries with type information from the client-provided session filesystem.\n\nArgs:\n params: Directory path whose entries (with type information) should be listed from the client-provided session filesystem.\n\nReturns:\n Entries in the requested directory paired with file/directory type information, or a filesystem error if the read failed."
pass
async def rm(self, params: SessionFSRmRequest) -> SessionFSError | None:
- "Calls sessionFs.rm.\n\nReturns:\n Describes a filesystem error."
+ "Removes a file or directory from the client-provided session filesystem.\n\nArgs:\n params: Path to remove from the client-provided session filesystem, with options for recursive removal and force.\n\nReturns:\n Describes a filesystem error."
pass
async def rename(self, params: SessionFSRenameRequest) -> SessionFSError | None:
- "Calls sessionFs.rename.\n\nReturns:\n Describes a filesystem error."
+ "Renames or moves a path in the client-provided session filesystem.\n\nArgs:\n params: Source and destination paths for renaming or moving an entry in the client-provided session filesystem.\n\nReturns:\n Describes a filesystem error."
pass
@dataclass
diff --git a/python/copilot/generated/session_events.py b/python/copilot/generated/session_events.py
index 11142d608..696d5a0e5 100644
--- a/python/copilot/generated/session_events.py
+++ b/python/copilot/generated/session_events.py
@@ -760,6 +760,7 @@ def to_dict(self) -> dict:
@dataclass
class AssistantUsageQuotaSnapshot:
+ "Schema for the `AssistantUsageQuotaSnapshot` type."
entitlement_requests: float
is_unlimited_entitlement: bool
overage: float
@@ -972,6 +973,7 @@ def to_dict(self) -> dict:
@dataclass
class CommandsChangedCommand:
+ "Schema for the `CommandsChangedCommand` type."
name: str
description: str | None = None
@@ -1118,6 +1120,7 @@ def to_dict(self) -> dict:
@dataclass
class CustomAgentsUpdatedAgent:
+ "Schema for the `CustomAgentsUpdatedAgent` type."
description: str
display_name: str
id: str
@@ -1270,6 +1273,7 @@ def to_dict(self) -> dict:
@dataclass
class EmbeddedBlobResourceContents:
+ "Schema for the `EmbeddedBlobResourceContents` type."
blob: str
uri: str
mime_type: str | None = None
@@ -1297,6 +1301,7 @@ def to_dict(self) -> dict:
@dataclass
class EmbeddedTextResourceContents:
+ "Schema for the `EmbeddedTextResourceContents` type."
text: str
uri: str
mime_type: str | None = None
@@ -1398,6 +1403,7 @@ def to_dict(self) -> dict:
@dataclass
class ExtensionsLoadedExtension:
+ "Schema for the `ExtensionsLoadedExtension` type."
id: str
name: str
source: ExtensionsLoadedExtensionSource
@@ -1690,6 +1696,7 @@ def to_dict(self) -> dict:
@dataclass
class McpServersLoadedServer:
+ "Schema for the `McpServersLoadedServer` type."
name: str
status: McpServersLoadedServerStatus
error: str | None = None
@@ -2154,6 +2161,7 @@ def to_dict(self) -> dict:
@dataclass
class PermissionRequestShellCommand:
+ "Schema for the `PermissionRequestShellCommand` type."
identifier: str
read_only: bool
@@ -2176,6 +2184,7 @@ def to_dict(self) -> dict:
@dataclass
class PermissionRequestShellPossibleUrl:
+ "Schema for the `PermissionRequestShellPossibleUrl` type."
url: str
@staticmethod
@@ -2291,6 +2300,7 @@ def to_dict(self) -> dict:
@dataclass
class PermissionRule:
+ "Schema for the `PermissionRule` type."
argument: str | None
kind: str
@@ -2359,6 +2369,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionBackgroundTasksChangedData:
+ "Schema for the `BackgroundTasksChangedData` type."
@staticmethod
def from_dict(obj: Any) -> "SessionBackgroundTasksChangedData":
assert isinstance(obj, dict)
@@ -2543,6 +2554,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionCustomAgentsUpdatedData:
+ "Schema for the `CustomAgentsUpdatedData` type."
agents: list[CustomAgentsUpdatedAgent]
errors: list[str]
warnings: list[str]
@@ -2659,6 +2671,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionExtensionsLoadedData:
+ "Schema for the `ExtensionsLoadedData` type."
extensions: list[ExtensionsLoadedExtension]
@staticmethod
@@ -2778,6 +2791,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionMcpServerStatusChangedData:
+ "Schema for the `McpServerStatusChangedData` type."
server_name: str
status: McpServerStatusChangedStatus
@@ -2800,6 +2814,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionMcpServersLoadedData:
+ "Schema for the `McpServersLoadedData` type."
servers: list[McpServersLoadedServer]
@staticmethod
@@ -2846,7 +2861,9 @@ class SessionModelChangeData:
cause: str | None = None
previous_model: str | None = None
previous_reasoning_effort: str | None = None
+ previous_reasoning_summary: ReasoningSummary | None = None
reasoning_effort: str | None = None
+ reasoning_summary: ReasoningSummary | None = None
@staticmethod
def from_dict(obj: Any) -> "SessionModelChangeData":
@@ -2855,13 +2872,17 @@ def from_dict(obj: Any) -> "SessionModelChangeData":
cause = from_union([from_none, from_str], obj.get("cause"))
previous_model = from_union([from_none, from_str], obj.get("previousModel"))
previous_reasoning_effort = from_union([from_none, from_str], obj.get("previousReasoningEffort"))
+ previous_reasoning_summary = from_union([from_none, lambda x: parse_enum(ReasoningSummary, x)], obj.get("previousReasoningSummary"))
reasoning_effort = from_union([from_none, from_str], obj.get("reasoningEffort"))
+ reasoning_summary = from_union([from_none, lambda x: parse_enum(ReasoningSummary, x)], obj.get("reasoningSummary"))
return SessionModelChangeData(
new_model=new_model,
cause=cause,
previous_model=previous_model,
previous_reasoning_effort=previous_reasoning_effort,
+ previous_reasoning_summary=previous_reasoning_summary,
reasoning_effort=reasoning_effort,
+ reasoning_summary=reasoning_summary,
)
def to_dict(self) -> dict:
@@ -2873,8 +2894,12 @@ def to_dict(self) -> dict:
result["previousModel"] = from_union([from_none, from_str], self.previous_model)
if self.previous_reasoning_effort is not None:
result["previousReasoningEffort"] = from_union([from_none, from_str], self.previous_reasoning_effort)
+ if self.previous_reasoning_summary is not None:
+ result["previousReasoningSummary"] = from_union([from_none, lambda x: to_enum(ReasoningSummary, x)], self.previous_reasoning_summary)
if self.reasoning_effort is not None:
result["reasoningEffort"] = from_union([from_none, from_str], self.reasoning_effort)
+ if self.reasoning_summary is not None:
+ result["reasoningSummary"] = from_union([from_none, lambda x: to_enum(ReasoningSummary, x)], self.reasoning_summary)
return result
@@ -2899,7 +2924,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionRemoteSteerableChangedData:
- "Notifies Mission Control that the session's remote steering capability has changed"
+ "Notifies that the session's remote steering capability has changed"
remote_steerable: bool
@staticmethod
@@ -2925,6 +2950,7 @@ class SessionResumeData:
context: WorkingDirectoryContext | None = None
continue_pending_work: bool | None = None
reasoning_effort: str | None = None
+ reasoning_summary: ReasoningSummary | None = None
remote_steerable: bool | None = None
selected_model: str | None = None
session_was_active: bool | None = None
@@ -2938,6 +2964,7 @@ def from_dict(obj: Any) -> "SessionResumeData":
context = from_union([from_none, WorkingDirectoryContext.from_dict], obj.get("context"))
continue_pending_work = from_union([from_none, from_bool], obj.get("continuePendingWork"))
reasoning_effort = from_union([from_none, from_str], obj.get("reasoningEffort"))
+ reasoning_summary = from_union([from_none, lambda x: parse_enum(ReasoningSummary, x)], obj.get("reasoningSummary"))
remote_steerable = from_union([from_none, from_bool], obj.get("remoteSteerable"))
selected_model = from_union([from_none, from_str], obj.get("selectedModel"))
session_was_active = from_union([from_none, from_bool], obj.get("sessionWasActive"))
@@ -2948,6 +2975,7 @@ def from_dict(obj: Any) -> "SessionResumeData":
context=context,
continue_pending_work=continue_pending_work,
reasoning_effort=reasoning_effort,
+ reasoning_summary=reasoning_summary,
remote_steerable=remote_steerable,
selected_model=selected_model,
session_was_active=session_was_active,
@@ -2965,6 +2993,8 @@ def to_dict(self) -> dict:
result["continuePendingWork"] = from_union([from_none, from_bool], self.continue_pending_work)
if self.reasoning_effort is not None:
result["reasoningEffort"] = from_union([from_none, from_str], self.reasoning_effort)
+ if self.reasoning_summary is not None:
+ result["reasoningSummary"] = from_union([from_none, lambda x: to_enum(ReasoningSummary, x)], self.reasoning_summary)
if self.remote_steerable is not None:
result["remoteSteerable"] = from_union([from_none, from_bool], self.remote_steerable)
if self.selected_model is not None:
@@ -2999,6 +3029,7 @@ class SessionScheduleCreatedData:
id: int
interval_ms: int
prompt: str
+ display_prompt: str | None = None
recurring: bool | None = None
@staticmethod
@@ -3007,11 +3038,13 @@ def from_dict(obj: Any) -> "SessionScheduleCreatedData":
id = from_int(obj.get("id"))
interval_ms = from_int(obj.get("intervalMs"))
prompt = from_str(obj.get("prompt"))
+ display_prompt = from_union([from_none, from_str], obj.get("displayPrompt"))
recurring = from_union([from_none, from_bool], obj.get("recurring"))
return SessionScheduleCreatedData(
id=id,
interval_ms=interval_ms,
prompt=prompt,
+ display_prompt=display_prompt,
recurring=recurring,
)
@@ -3020,6 +3053,8 @@ def to_dict(self) -> dict:
result["id"] = to_int(self.id)
result["intervalMs"] = to_int(self.interval_ms)
result["prompt"] = from_str(self.prompt)
+ if self.display_prompt is not None:
+ result["displayPrompt"] = from_union([from_none, from_str], self.display_prompt)
if self.recurring is not None:
result["recurring"] = from_union([from_none, from_bool], self.recurring)
return result
@@ -3106,6 +3141,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionSkillsLoadedData:
+ "Schema for the `SkillsLoadedData` type."
skills: list[SkillsLoadedSkill]
@staticmethod
@@ -3157,6 +3193,7 @@ class SessionStartData:
context: WorkingDirectoryContext | None = None
detached_from_spawning_parent_session_id: str | None = None
reasoning_effort: str | None = None
+ reasoning_summary: ReasoningSummary | None = None
remote_steerable: bool | None = None
selected_model: str | None = None
@@ -3172,6 +3209,7 @@ def from_dict(obj: Any) -> "SessionStartData":
context = from_union([from_none, WorkingDirectoryContext.from_dict], obj.get("context"))
detached_from_spawning_parent_session_id = from_union([from_none, from_str], obj.get("detachedFromSpawningParentSessionId"))
reasoning_effort = from_union([from_none, from_str], obj.get("reasoningEffort"))
+ reasoning_summary = from_union([from_none, lambda x: parse_enum(ReasoningSummary, x)], obj.get("reasoningSummary"))
remote_steerable = from_union([from_none, from_bool], obj.get("remoteSteerable"))
selected_model = from_union([from_none, from_str], obj.get("selectedModel"))
return SessionStartData(
@@ -3184,6 +3222,7 @@ def from_dict(obj: Any) -> "SessionStartData":
context=context,
detached_from_spawning_parent_session_id=detached_from_spawning_parent_session_id,
reasoning_effort=reasoning_effort,
+ reasoning_summary=reasoning_summary,
remote_steerable=remote_steerable,
selected_model=selected_model,
)
@@ -3203,6 +3242,8 @@ def to_dict(self) -> dict:
result["detachedFromSpawningParentSessionId"] = from_union([from_none, from_str], self.detached_from_spawning_parent_session_id)
if self.reasoning_effort is not None:
result["reasoningEffort"] = from_union([from_none, from_str], self.reasoning_effort)
+ if self.reasoning_summary is not None:
+ result["reasoningSummary"] = from_union([from_none, lambda x: to_enum(ReasoningSummary, x)], self.reasoning_summary)
if self.remote_steerable is not None:
result["remoteSteerable"] = from_union([from_none, from_bool], self.remote_steerable)
if self.selected_model is not None:
@@ -3256,6 +3297,7 @@ def to_dict(self) -> dict:
@dataclass
class SessionToolsUpdatedData:
+ "Schema for the `ToolsUpdatedData` type."
model: str
@staticmethod
@@ -3446,6 +3488,7 @@ def to_dict(self) -> dict:
@dataclass
class ShutdownModelMetric:
+ "Schema for the `ShutdownModelMetric` type."
requests: ShutdownModelMetricRequests
usage: ShutdownModelMetricUsage
token_details: dict[str, ShutdownModelMetricTokenDetail] | None = None
@@ -3501,6 +3544,7 @@ def to_dict(self) -> dict:
@dataclass
class ShutdownModelMetricTokenDetail:
+ "Schema for the `ShutdownModelMetricTokenDetail` type."
token_count: float
@staticmethod
@@ -3555,6 +3599,7 @@ def to_dict(self) -> dict:
@dataclass
class ShutdownTokenDetail:
+ "Schema for the `ShutdownTokenDetail` type."
token_count: float
@staticmethod
@@ -3620,6 +3665,7 @@ def to_dict(self) -> dict:
@dataclass
class SkillsLoadedSkill:
+ "Schema for the `SkillsLoadedSkill` type."
description: str
enabled: bool
name: str
@@ -4598,6 +4644,7 @@ def to_dict(self) -> dict:
@dataclass
class UserMessageData:
+ "Schema for the `UserMessageData` type."
content: str
agent_mode: UserMessageAgentMode | None = None
attachments: list[UserMessageAttachment] | None = None
@@ -4922,6 +4969,13 @@ class PlanChangedOperation(Enum):
DELETE = "delete"
+class ReasoningSummary(Enum):
+ "Reasoning summary mode used for model calls, if applicable (e.g. \"none\", \"concise\", \"detailed\")"
+ NONE = "none"
+ CONCISE = "concise"
+ DETAILED = "detailed"
+
+
class ShutdownType(Enum):
"Whether the session ended normally (\"routine\") or due to a crash/fatal error (\"error\")"
ROUTINE = "routine"
diff --git a/rust/src/generated/api_types.rs b/rust/src/generated/api_types.rs
index 2f74abb48..5f297753f 100644
--- a/rust/src/generated/api_types.rs
+++ b/rust/src/generated/api_types.rs
@@ -6,6 +6,7 @@ use std::collections::HashMap;
use serde::{Deserialize, Serialize};
+use super::session_events::ReasoningSummary;
use crate::types::{RequestId, SessionId};
/// JSON-RPC method name constants.
@@ -187,6 +188,7 @@ pub mod rpc_methods {
pub const SESSIONFS_RENAME: &str = "sessionFs.rename";
}
+/// Optional GitHub token used to look up quota for a specific user instead of the global auth context.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AccountGetQuotaRequest {
@@ -195,6 +197,7 @@ pub struct AccountGetQuotaRequest {
pub git_hub_token: Option,
}
+/// Schema for the `AccountQuotaSnapshot` type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AccountQuotaSnapshot {
@@ -217,6 +220,7 @@ pub struct AccountQuotaSnapshot {
pub used_requests: i64,
}
+/// Quota usage snapshots for the resolved user, keyed by quota type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AccountGetQuotaResult {
@@ -224,6 +228,7 @@ pub struct AccountGetQuotaResult {
pub quota_snapshots: HashMap,
}
+/// Schema for the `AgentInfo` type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AgentInfo {
@@ -238,6 +243,7 @@ pub struct AgentInfo {
pub path: Option,
}
+/// The currently selected custom agent, or null when using the default agent.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AgentGetCurrentResult {
@@ -245,6 +251,7 @@ pub struct AgentGetCurrentResult {
pub agent: AgentInfo,
}
+/// Custom agents available to the session.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AgentList {
@@ -252,6 +259,7 @@ pub struct AgentList {
pub agents: Vec,
}
+/// Custom agents available to the session after reloading definitions from disk.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AgentReloadResult {
@@ -259,6 +267,7 @@ pub struct AgentReloadResult {
pub agents: Vec,
}
+/// Name of the custom agent to select for subsequent turns.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AgentSelectRequest {
@@ -266,6 +275,7 @@ pub struct AgentSelectRequest {
pub name: String,
}
+/// The newly selected custom agent.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct AgentSelectResult {
@@ -290,6 +300,7 @@ pub struct SlashCommandInput {
pub required: Option,
}
+/// Schema for the `SlashCommandInfo` type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct SlashCommandInfo {
@@ -312,6 +323,7 @@ pub struct SlashCommandInfo {
pub name: String,
}
+/// Slash commands available in the session, after applying any include/exclude filters.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CommandList {
@@ -319,6 +331,7 @@ pub struct CommandList {
pub commands: Vec,
}
+/// Pending command request ID and an optional error if the client handler failed.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CommandsHandlePendingCommandRequest {
@@ -329,6 +342,7 @@ pub struct CommandsHandlePendingCommandRequest {
pub request_id: RequestId,
}
+/// Indicates whether the pending client-handled command was completed successfully.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CommandsHandlePendingCommandResult {
@@ -336,6 +350,7 @@ pub struct CommandsHandlePendingCommandResult {
pub success: bool,
}
+/// Slash command name and optional raw input string to invoke.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CommandsInvokeRequest {
@@ -346,6 +361,7 @@ pub struct CommandsInvokeRequest {
pub name: String,
}
+/// Optional filters controlling which command sources to include in the listing.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CommandsListRequest {
@@ -360,6 +376,7 @@ pub struct CommandsListRequest {
pub include_skills: Option,
}
+/// Queued command request ID and the result indicating whether the client handled it.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CommandsRespondToQueuedCommandRequest {
@@ -369,6 +386,7 @@ pub struct CommandsRespondToQueuedCommandRequest {
pub result: serde_json::Value,
}
+/// Indicates whether the queued-command response was accepted by the session.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CommandsRespondToQueuedCommandResult {
@@ -376,6 +394,7 @@ pub struct CommandsRespondToQueuedCommandResult {
pub success: bool,
}
+/// Optional connection token presented by the SDK client during the handshake.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct ConnectRequest {
@@ -384,6 +403,7 @@ pub struct ConnectRequest {
pub token: Option,
}
+/// Handshake result reporting the server's protocol version and package version on success.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct ConnectResult {
@@ -395,6 +415,7 @@ pub struct ConnectResult {
pub version: String,
}
+/// The currently selected model for the session.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct CurrentModel {
@@ -403,6 +424,7 @@ pub struct CurrentModel {
pub model_id: Option,
}
+/// Schema for the `DiscoveredMcpServer` type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct DiscoveredMcpServer {
@@ -417,6 +439,7 @@ pub struct DiscoveredMcpServer {
pub r#type: Option,
}
+/// Schema for the `Extension` type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct Extension {
@@ -433,6 +456,7 @@ pub struct Extension {
pub status: ExtensionStatus,
}
+/// Extensions discovered for the session, with their current status.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct ExtensionList {
@@ -440,6 +464,7 @@ pub struct ExtensionList {
pub extensions: Vec,
}
+/// Source-qualified extension identifier to disable for the session.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct ExtensionsDisableRequest {
@@ -447,6 +472,7 @@ pub struct ExtensionsDisableRequest {
pub id: String,
}
+/// Source-qualified extension identifier to enable for the session.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct ExtensionsEnableRequest {
@@ -581,6 +607,7 @@ pub struct ExternalToolTextResultForLlmContentText {
pub r#type: ExternalToolTextResultForLlmContentTextType,
}
+/// Optional user prompt to combine with the fleet orchestration instructions.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct FleetStartRequest {
@@ -589,6 +616,7 @@ pub struct FleetStartRequest {
pub prompt: Option,
}
+/// Indicates whether fleet mode was successfully activated.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct FleetStartResult {
@@ -596,6 +624,7 @@ pub struct FleetStartResult {
pub started: bool,
}
+/// Pending external tool call request ID, with the tool result or an error describing why it failed.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct HandlePendingToolCallRequest {
@@ -609,6 +638,7 @@ pub struct HandlePendingToolCallRequest {
pub result: Option,
}
+/// Indicates whether the external tool call result was handled successfully.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct HandlePendingToolCallResult {
@@ -637,6 +667,7 @@ pub struct HistoryCompactContextWindow {
pub tool_definitions_tokens: Option,
}
+/// Compaction outcome with the number of tokens and messages removed and the resulting context window breakdown.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct HistoryCompactResult {
@@ -651,6 +682,7 @@ pub struct HistoryCompactResult {
pub tokens_removed: i64,
}
+/// Identifier of the event to truncate to; this event and all later events are removed.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct HistoryTruncateRequest {
@@ -658,6 +690,7 @@ pub struct HistoryTruncateRequest {
pub event_id: String,
}
+/// Number of events that were removed by the truncation.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct HistoryTruncateResult {
@@ -665,6 +698,7 @@ pub struct HistoryTruncateResult {
pub events_removed: i64,
}
+/// Schema for the `InstructionsSources` type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct InstructionsSources {
@@ -688,6 +722,7 @@ pub struct InstructionsSources {
pub r#type: InstructionsSourcesType,
}
+/// Instruction sources loaded for the session, in merge order.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct InstructionsGetSourcesResult {
@@ -695,6 +730,7 @@ pub struct InstructionsGetSourcesResult {
pub sources: Vec,
}
+/// Message text, optional severity level, persistence flag, and optional follow-up URL.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct LogRequest {
@@ -711,6 +747,7 @@ pub struct LogRequest {
pub url: Option,
}
+/// Identifier of the session event that was emitted for the log message.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct LogResult {
@@ -718,6 +755,7 @@ pub struct LogResult {
pub event_id: String,
}
+/// MCP server name and configuration to add to user configuration.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpConfigAddRequest {
@@ -727,6 +765,7 @@ pub struct McpConfigAddRequest {
pub name: String,
}
+/// MCP server names to disable for new sessions.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpConfigDisableRequest {
@@ -734,6 +773,7 @@ pub struct McpConfigDisableRequest {
pub names: Vec,
}
+/// MCP server names to enable for new sessions.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpConfigEnableRequest {
@@ -741,6 +781,7 @@ pub struct McpConfigEnableRequest {
pub names: Vec,
}
+/// User-configured MCP servers, keyed by server name.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpConfigList {
@@ -748,6 +789,7 @@ pub struct McpConfigList {
pub servers: HashMap,
}
+/// MCP server name to remove from user configuration.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpConfigRemoveRequest {
@@ -755,6 +797,7 @@ pub struct McpConfigRemoveRequest {
pub name: String,
}
+/// MCP server name and replacement configuration to write to user configuration.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpConfigUpdateRequest {
@@ -764,6 +807,7 @@ pub struct McpConfigUpdateRequest {
pub name: String,
}
+/// Name of the MCP server to disable for the session.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpDisableRequest {
@@ -771,6 +815,7 @@ pub struct McpDisableRequest {
pub server_name: String,
}
+/// Optional working directory used as context for MCP server discovery.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpDiscoverRequest {
@@ -779,6 +824,7 @@ pub struct McpDiscoverRequest {
pub working_directory: Option,
}
+/// MCP servers discovered from user, workspace, plugin, and built-in sources.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpDiscoverResult {
@@ -786,6 +832,7 @@ pub struct McpDiscoverResult {
pub servers: Vec,
}
+/// Name of the MCP server to enable for the session.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpEnableRequest {
@@ -793,6 +840,7 @@ pub struct McpEnableRequest {
pub server_name: String,
}
+/// Remote MCP server name and optional overrides controlling reauthentication, OAuth client display name, and the callback success-page copy.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpOauthLoginRequest {
@@ -809,6 +857,7 @@ pub struct McpOauthLoginRequest {
pub server_name: String,
}
+/// OAuth authorization URL the caller should open, or empty when cached tokens already authenticated the server.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpOauthLoginResult {
@@ -817,6 +866,7 @@ pub struct McpOauthLoginResult {
pub authorization_url: Option,
}
+/// Schema for the `McpServer` type.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpServer {
@@ -832,19 +882,26 @@ pub struct McpServer {
pub status: McpServerStatus,
}
+/// Remote MCP server configuration accessed over HTTP or SSE.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpServerConfigHttp {
+ /// Content filtering mode to apply to all tools, or a map of tool name to content filtering mode.
#[serde(skip_serializing_if = "Option::is_none")]
pub filter_mapping: Option,
+ /// HTTP headers to include in requests to the remote MCP server.
#[serde(default)]
pub headers: HashMap,
+ /// Whether this server is a built-in fallback used when the user has not configured their own server.
#[serde(skip_serializing_if = "Option::is_none")]
pub is_default_server: Option,
+ /// OAuth client ID for a pre-registered remote MCP OAuth client.
#[serde(skip_serializing_if = "Option::is_none")]
pub oauth_client_id: Option,
+ /// OAuth grant type to use when authenticating to the remote MCP server.
#[serde(skip_serializing_if = "Option::is_none")]
pub oauth_grant_type: Option,
+ /// Whether the configured OAuth client is public and does not require a client secret.
#[serde(skip_serializing_if = "Option::is_none")]
pub oauth_public_client: Option,
/// Timeout in milliseconds for tool calls to this server.
@@ -856,20 +913,28 @@ pub struct McpServerConfigHttp {
/// Remote transport type. Defaults to "http" when omitted.
#[serde(skip_serializing_if = "Option::is_none")]
pub r#type: Option,
+ /// URL of the remote MCP server endpoint.
pub url: String,
}
+/// Local MCP server configuration launched as a child process.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct McpServerConfigLocal {
+ /// Command-line arguments passed to the local MCP server process.
pub args: Vec,
+ /// Executable command used to start the local MCP server process.
pub command: String,
+ /// Working directory for the local MCP server process.
#[serde(skip_serializing_if = "Option::is_none")]
pub cwd: Option,
+ /// Environment variables to pass to the local MCP server process.
#[serde(default)]
pub env: HashMap,
+ /// Content filtering mode to apply to all tools, or a map of tool name to content filtering mode.
#[serde(skip_serializing_if = "Option::is_none")]
pub filter_mapping: Option,
+ /// Whether this server is a built-in fallback used when the user has not configured their own server.
#[serde(skip_serializing_if = "Option::is_none")]
pub is_default_server: Option,
/// Timeout in milliseconds for tool calls to this server.
@@ -878,10 +943,12 @@ pub struct McpServerConfigLocal {
/// Tools to include. Defaults to all tools if not specified.
#[serde(default)]
pub tools: Vec