Class SessionMcpAppsApi
java.lang.Object
com.github.copilot.generated.rpc.SessionMcpAppsApi
API methods for the
mcp.apps namespace.- Since:
- 1.0.0
-
Method Summary
Modifier and TypeMethodDescriptionCompletableFuture<com.fasterxml.jackson.databind.JsonNode> callTool(SessionMcpAppsCallToolParams params) Call an MCP tool from an MCP App view (SEP-1865).diagnose(SessionMcpAppsDiagnoseParams params) Diagnose MCP Apps wiring for a specific MCP server.Read the current host context advertised to MCP App guests.List tools that an MCP App view is allowed to call (SEP-1865 visibility filter).Fetch an MCP resource (typically a `ui://` MCP App bundle, per SEP-1865) from a connected server.Replace the host context returned to MCP App guests on `ui/initialize`.
-
Method Details
-
readResource
@CopilotExperimental public CompletableFuture<SessionMcpAppsReadResourceResult> readResource(SessionMcpAppsReadResourceParams params) Fetch an MCP resource (typically a `ui://` MCP App bundle, per SEP-1865) from a connected server. Requires the `mcp-apps` session capability.Note: the
sessionIdfield in the params record is overridden by the session-scoped wrapper; any value provided is ignored.- Since:
- 1.0.0
-
listTools
@CopilotExperimental public CompletableFuture<SessionMcpAppsListToolsResult> listTools(SessionMcpAppsListToolsParams params) List tools that an MCP App view is allowed to call (SEP-1865 visibility filter). Returns tools whose `_meta.ui.visibility` is unset (default `["model","app"]`) or includes `"app"`.Note: the
sessionIdfield in the params record is overridden by the session-scoped wrapper; any value provided is ignored.- Since:
- 1.0.0
-
callTool
@CopilotExperimental public CompletableFuture<com.fasterxml.jackson.databind.JsonNode> callTool(SessionMcpAppsCallToolParams params) Call an MCP tool from an MCP App view (SEP-1865). Enforces the visibility check that prevents an app iframe from invoking model-only tools. Returns the standard MCP `CallToolResult`.Note: the
sessionIdfield in the params record is overridden by the session-scoped wrapper; any value provided is ignored.- Since:
- 1.0.0
-
setHostContext
@CopilotExperimental public CompletableFuture<Void> setHostContext(SessionMcpAppsSetHostContextParams params) Replace the host context returned to MCP App guests on `ui/initialize`. Hosts use this to advertise theme, locale, or other metadata to the guest UI.Note: the
sessionIdfield in the params record is overridden by the session-scoped wrapper; any value provided is ignored.- Since:
- 1.0.0
-
getHostContext
Read the current host context advertised to MCP App guests.- Since:
- 1.0.0
-
diagnose
@CopilotExperimental public CompletableFuture<SessionMcpAppsDiagnoseResult> diagnose(SessionMcpAppsDiagnoseParams params) Diagnose MCP Apps wiring for a specific MCP server. Reports the session capability, feature-flag state, advertised extension, and how many tools have `_meta.ui` populated.Note: the
sessionIdfield in the params record is overridden by the session-scoped wrapper; any value provided is ignored.- Since:
- 1.0.0
-