Repository navigation
Description
Goal
Extension crates that plug into an embedding app (Spec 0038, "Extension API") can extend the local MCP server (Spec 0028): register additional MCP tools, take over how the result of an approved, possibly long-running command is returned to the client, and answer a tool call as an MCP task. Without a registered extension the MCP server behaves exactly as today.
Scope
In scope: the extension trait, its registration in app_shell::Wiring, a handle for an approved command (redacted live output, final outcome, cancel), session-closed notification, and the MCP protocol support needed to answer tools/call with a task. Out of scope: any concrete use of the hooks (job storage, polling tools, settings); the built-in MCP tools keep their behaviour.
Shared decisions
- Trait:
McpExtensionincrates/mcp-server, re-exported through the extension facade (crates/app-logic/src/ext.rsor theapp-shellequivalent) and documented in Spec 0038 §2 and Spec 0028. Registered asWiring::mcp_extensions: Vec<Arc<dyn McpExtension>>; Community registers none. - Call context: every hook gets an
McpCallContextwith an opaque MCP session key (Spec 0104), the normalized client name, and (from the tasks issue on) whether the client announced the MCP tasks extension. No server credentials, no unredacted content. - No second execution path (Spec 0028 §3): extension tools cannot execute on a server through the hook; the only way to run something stays
propose_command& co. with filter engine and confirmation. Every MCP action still always ends in a confirmation (Spec 0028 §5). - Content leaving the hooks is redacted; a helper fences server content exactly as the built-in tools do, and extension tool results that carry server output use it.
- Logging: calls of extension tools are logged with
origin: "mcp"and the tool name; never content (Spec 0094 A1.6). - Tool names: an extension tool whose name collides with a built-in tool or another extension's tool is not offered, and a warning is logged at server start.
Sub-issues
- MCP extension point: additional tools and a handle for approved commands #1632 additional tools and approved-command handle
- MCP extension point: answer tool calls as MCP tasks (protocol revision 2026-07-28) #1633 answer tool calls as MCP tasks
Prerequisite (not part of this epic): #1630 confirmation timeout covers only the decision.
Sub-issues
Collapse Sub-issuesSub-issues
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Activity
smart-ssh-coordinator commentedon Dec 4, 2026
All sub-issues are done, closing the epic.