From 15997093157717bdc51a276f8b4a15691382fc73 Mon Sep 17 00:00:00 2001 From: teahubxyz Date: Thu, 22 Oct 2026 19:49:11 +0000 Subject: [PATCH] mcp radio: new resource URI so the host stops serving the cached v2 card (which still messaged for each track) Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_014mBuCaQSgWwqhtzsmTBQuM --- mcp/worker.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mcp/worker.js b/mcp/worker.js index d92c698..bf78b3c 100644 --- a/mcp/worker.js +++ b/mcp/worker.js @@ -9,7 +9,7 @@ const MEDIA = "https://dev.gandora.lol"; const ORIGIN = "https://dev.gandora.lol"; const TRACKS = { sky: "/asmr/audio/kokoro-sky.mp3", rain: "/asmr/audio/bed-rain.mp3" }; const PROBE_URI = "ui://gandora/probe"; -const RADIO_URI = "ui://gandora/radio"; +const RADIO_URI = "ui://gandora/radio-v3"; const UI_MIME = "text/html;profile=mcp-app"; const UI_META = { ui: { csp: { resourceDomains: [MEDIA], connectDomains: [MEDIA] }, prefersBorder: true } }; const APP_ONLY = { ui: { visibility: ["app"] } }; @@ -143,7 +143,7 @@ async function handle(msg, env) { case "resources/templates/list": return ok({ resourceTemplates: [] }); case "resources/read": if (params && params.uri === PROBE_URI) return ok({ contents: [{ uri: PROBE_URI, mimeType: UI_MIME, text: PROBE_HTML, _meta: UI_META }] }); - if (params && params.uri === RADIO_URI) return ok({ contents: [{ uri: RADIO_URI, mimeType: UI_MIME, text: RADIO_HTML, _meta: UI_META }] }); + if (params && (params.uri === RADIO_URI || params.uri === "ui://gandora/radio")) return ok({ contents: [{ uri: RADIO_URI, mimeType: UI_MIME, text: RADIO_HTML, _meta: UI_META }] }); return err(-32002, "resource not found"); default: if (id === undefined) return null;