/mcp-server-dev:build-mcp-appfrom mcp-server-dev
Use when an MCP server needs optional inline UI, an interactive MCP App, a chart or dashboard, a picker, a review or confirmation surface, or a standards-first bridge between a Go MCP backend and a TypeScript component. Preserve a useful tool-only path and keep ChatGPT-specific capabilities optional.
Ships in mcp-server-dev. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Add portable in-chat UI to a working MCP tool contract.
The default architecture is:
Go MCP server
TypeScript MCP App UI
MCP Apps bridge first
Optional ChatGPT extensions
Useful tool-only fallback
The server does not need to be rewritten in TypeScript. MCP Apps is a wire and browser contract, not a backend-language requirement.
Read ../../SOURCE-OF-TRUTH.md first.
For UI work, use this order:
@modelcontextprotocol/ext-apps APIPrimary pages:
https://modelcontextprotocol.io/extensions/apps/overviewhttps://modelcontextprotocol.io/extensions/apps/buildhttps://apps.extensions.modelcontextprotocol.io/https://developers.openai.com/plugins/build/chatgpt-uihttps://developers.openai.com/plugins/deploy/connect-chatgpthttps://developers.openai.com/plugins/referenceDo not let a host-specific helper redefine the portable contract.
Before changing code, identify:
content, structuredContent, and _meta shapePreserve a healthy backend stack. For a Go server, add UI metadata and resources in Go.
The target tool must already be useful without UI.
Require:
contentstructuredContentDo not use a widget to compensate for an unclear tool contract.
Add UI when the user needs to inspect, compare, edit, confirm, navigate, or manipulate structured information.
Choose the smallest useful archetype:
| Archetype | Use when |
|---|---|
viewer | Read-only chart, preview, summary, or detail view |
picker | Searchable or visual selection improves accuracy |
editor | The user must manipulate structured state |
review-confirm | A consequential action needs contextual review |
interactive-decoupled | Data retrieval and rendering should be separate |
Do not port an entire website into chat. Extract the atomic conversational surface.
Use one tool plus one resource when the component is small and tightly coupled to a single result.
Prefer this for non-trivial apps:
structuredContent without UI metadataThis lets the model reason over data before deciding to render. Use references/decoupled-render-tools.md.
Use:
ui:// resource URItext/html;profile=mcp-app_meta.ui.resourceUri on tools that should render the component_meta.ui.csp with exact allowlistsUse _meta["openai/outputTemplate"] only as a ChatGPT compatibility alias when needed. It must not replace _meta.ui.resourceUri.
Add the deprecated flat _meta["ui/resourceUri"] key only when a tested host
still requires it. Keep the nested standard field present and authoritative.
Partition data intentionally:
| Field | Audience | Use |
|---|---|---|
content | Model and user | Short narration and fallback |
structuredContent | Model and UI | Stable, reusable render contract |
_meta | UI or host | UI-only payloads and host metadata |
Keep structuredContent small enough for the model to reason over. Keep secrets and unnecessary bulk out of all three fields.
Default to TypeScript and Vite. Use vanilla TypeScript for a small component and React only when interaction or state complexity justifies it.
Use @modelcontextprotocol/ext-apps for the browser-side bridge:
app.addEventListener("toolresult", handler)Keep the dependency graph lean. Bundle scripts and styles into one HTML resource when practical.
Use references/widget-templates.md and references/go-typescript-layout.md.
For Go:
mcp.Tool.Metamcp.ResourceDo not import frontend build dependencies into the Go runtime.
ChatGPT-specific window.openai APIs are optional enhancements.
Rules:
Examples of valid ChatGPT-only enhancements include file handling, host-owned modals, checkout, display-mode requests, and widget-state persistence.
Use references/apps-sdk-messages.md for the mapping between portable and ChatGPT-specific APIs.
Assume a sandboxed iframe and deny-by-default policy.
window.openUse references/iframe-sandbox.md.
Run:
Test both paths:
Use ../../CLIENT-VALIDATION-PLAYBOOK.md and references/chatgpt-connect-testing.md.
_meta for data the model must reason over.When implementing or reviewing, report:
For direct implementation requests, create the files and run the available checks instead of stopping at a plan.
../../SOURCE-OF-TRUTH.md../../CLIENT-VALIDATION-PLAYBOOK.md../../CHART-PREVIEW-PATTERN.mdreferences/apps-sdk-component-path.mdreferences/apps-sdk-messages.mdreferences/go-typescript-layout.mdreferences/decoupled-render-tools.mdreferences/widget-templates.mdreferences/iframe-sandbox.mdreferences/chatgpt-connect-testing.mdreferences/claude-compatibility.mdreferences/troubleshooting.mdagents/openai.yaml (opens in a new tab)references/apps-sdk-component-path.md (opens in a new tab)references/apps-sdk-messages.md (opens in a new tab)references/chatgpt-connect-testing.md (opens in a new tab)references/claude-compatibility.md (opens in a new tab)references/decoupled-render-tools.md (opens in a new tab)references/go-typescript-layout.md (opens in a new tab)references/iframe-sandbox.md (opens in a new tab)references/troubleshooting.md (opens in a new tab)references/widget-templates.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
3 skills in this plugin
/build-mcpbUse when a local stdio MCP server must be distributed as a one-click MCP Bundle for desktop hosts. Default new Go servers to self-contained binary bundles, use the current stable MCPB manifest, and keep the ordinary executable usable outside MCPB./build-mcp-serverBuild, refactor, review, or release an MCP server; choose Go, TypeScript, Python, or Rust; define tools and schemas; select remote HTTP or local stdio; design auth; add optional MCP Apps UI; or validate MCP 2026-07-28 and client portability.npx claudepluginhub mylesmcook/mcook-plugins --plugin mcp-server-dev