From d368df533dbed9bd3fb988052377f61db357289e Mon Sep 17 00:00:00 2001 From: Sameh Khamis Date: Fri, 2 Oct 2026 09:23:31 -0700 Subject: [PATCH] fix: complete the MCP Apps handshake the way hosts validate it The panel sent clientInfo and capabilities in ui/initialize, where the MCP Apps schema requires appInfo, so hosts such as Claude rejected the handshake and never showed the panel. It now sends exactly appCapabilities, appInfo and protocolVersion, sends initialized without parameters, says so when a host rejects it, and offers the link when God's Eye View does not load within 20 seconds. Checked against the MCP Apps SDK's own host bridge. --- src/tools/globePanel.js | 20 ++++++++++++++++---- src/tools/globePanel.test.mjs | 3 +++ 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/src/tools/globePanel.js b/src/tools/globePanel.js index f87179222..982914e3d 100644 --- a/src/tools/globePanel.js +++ b/src/tools/globePanel.js @@ -38,6 +38,7 @@ function panelHtml(appOrigin) { diff --git a/src/tools/globePanel.test.mjs b/src/tools/globePanel.test.mjs index 7500a580a..b231dc9bd 100644 --- a/src/tools/globePanel.test.mjs +++ b/src/tools/globePanel.test.mjs @@ -21,6 +21,9 @@ test('the globe panel is an MCP Apps resource that may frame only the app', () = assert.match(resource.text, /'ui\/initialize'/); assert.match(resource.text, /'ui\/notifications\/tool-result'/); assert.match(resource.text, /protocolVersion: "2026-01-26"/); + // The MCP Apps SDK's initialize parameters; hosts reject anything else. + assert.match(resource.text, /appInfo: \{ name: 'gods-eye-view'/); + assert.doesNotMatch(resource.text, /clientInfo/); }); test('show_in_gods_eye_view names the panel and shows a view another answer returned', async () => {