github / github/copilot-sdk

Surface per-server MCP Apps capability on McpServersLoadedServer / SessionMcpServerStatusChangedData

未关闭
#1,675 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
enhancement
主要语言
Java
星标
10.5k
派生
1.5k
平均合并
1 天 14 小时
30 天内合并 PR
129

描述

### Summary

`McpServersLoadedServer` (from `session.mcp_servers_loaded`) and `SessionMcpServerStatusChangedData` (from `session.mcp_server_status_changed`) describe each MCP server's `name`, `status`, `transport`, `source`, plugin info, and `error`, but carry nothing indicating whether that specific server is **MCP Apps (SEP-1865) capable** (i.e. exposes UI resources). A consumer that models capability per server has no direct signal at that granularity.

### Current state

MCP Apps capability is observable at two other granularities today, just not per-server:

- **Session-wide** — `CapabilitiesChangedUI.mcp_apps` ("Whether MCP Apps (SEP-1865) UI passthrough is now supported") and `session_has_mcp_apps`.
- **Per-tool** — tool definition metadata `ui` ("present for MCP tools with MCP Apps support").

The per-server status types, however, expose no equivalent:

```rust
pub struct McpServersLoadedServer {
pub error: Option,
pub name: String,
pub plugin_name: Option,
pub plugin_version: Option,
pub source: Option,
pub status: McpServerStatus,
pub transport: Option,
// no MCP-Apps capability field
}
```

### Consequence

A consumer that wants to advertise, in its own surface, *which configured MCP servers offer App/UI experiences* has to infer it indirectly — e.g. by scanning every tool of every server for `ui` metadata — instead of reading a per-server flag. The capability granularity (session / tool) doesn't line up with a per-server model.

### Suggested fix

Add an optional per-server MCP-Apps capability flag to `McpServersLoadedServer` (and ideally `SessionMcpServerStatusChangedData`), so consumers can read App-capability at the server granularity directly. Alternatively, if the intended model is that App capability is strictly per-tool, documenting that explicitly on these types would resolve the ambiguity.

贡献指南

打开贡献指南

调研方向

首先定位 McpServersLoadedServer 和 SessionMcpServerStatusChangedData 的定义,然后将它们现有的字段与 session-wide 的 CapabilitiesChangedUI.mcp_apps 以及 per-tool UI metadata 进行比较。完成的标准是:预期的 per-server capability 模型已明确,并且两个状态类型都暴露该信号,或者这些类型明确记录 capability 仍然是 per-tool 的。

由索引模型根据 Issue 内容生成。

评估

技术栈
rust
领域
api
Issue 类型
功能
难度
4/5
预计耗时
3-5 天
活跃度
冷清
描述清晰度
基本清楚
新手友好度
48/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。