Skip to content

Commit c847bc0

Browse files
committed
docs: align Protocol and role-specific setup
1 parent e7ffe7c commit c847bc0

8 files changed

Lines changed: 35 additions & 22 deletions

File tree

README.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -121,17 +121,27 @@ resources:
121121

122122
## Getting Started
123123

124+
For a View or host:
125+
126+
```bash
127+
npm install -S @modelcontextprotocol/ext-apps \
128+
@modelcontextprotocol/client@2.0.0-beta.5 \
129+
@modelcontextprotocol/core@2.0.0-beta.5 \
130+
zod@^4.2.0
131+
```
132+
133+
For an MCP server:
134+
124135
```bash
125136
npm install -S @modelcontextprotocol/ext-apps \
126-
@modelcontextprotocol/client@2.0.0-beta.4 \
127-
@modelcontextprotocol/server@2.0.0-beta.4 \
128-
@modelcontextprotocol/core@2.0.0-beta.4 \
137+
@modelcontextprotocol/server@2.0.0-beta.5 \
138+
@modelcontextprotocol/core@2.0.0-beta.5 \
129139
zod@^4.2.0
130140
```
131141

132-
This release uses the split base MCP SDK v2 packages. Install all three at the
133-
exact published beta.4 version so the Apps SDK and your MCP client/server share
134-
one compatible protocol implementation.
142+
Applications that implement both roles should install both `client` and
143+
`server`. Keep all installed base MCP SDK packages on the exact same published
144+
beta so they share one compatible protocol implementation.
135145

136146
**New here?** Start with the
137147
[Quickstart Guide](https://apps.extensions.modelcontextprotocol.io/api/documents/Quickstart.html)

docs/overview.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,11 @@ flowchart LR
5656
- **Host** — The chat client (e.g., Claude Desktop) that connects to servers, embeds Views in iframes, and proxies communication between them.
5757
- **View** — The UI running inside a sandboxed iframe. It receives tool data from the Host and can call server tools or send messages back to the chat.
5858

59-
The View's `App` subclasses the base MCP SDK `Client`. The Host's `AppBridge`
60-
subclasses the base MCP SDK `Server` for the inner iframe channel, while a
61-
separate outer `Client` connects the Host to the actual MCP Server. Keeping
62-
those two connections separate prevents iframe negotiation and capabilities
63-
from leaking into the server connection.
59+
The View's `App` and the Host's `AppBridge` both subclass the base MCP SDK's
60+
public `Protocol` for the iframe channel. A separate outer `Client` connects
61+
the Host to the actual MCP Server. Keeping those two connections separate
62+
preserves the Apps-only iframe handshake and prevents iframe capabilities from
63+
leaking into the server connection.
6464

6565
## Lifecycle
6666

docs/quickstart.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Install the dependencies you'll need:
3737

3838
```bash
3939
npm init -y
40-
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.4 @modelcontextprotocol/core@2.0.0-beta.4 @modelcontextprotocol/server@2.0.0-beta.4 @modelcontextprotocol/node@2.0.0-beta.4 @modelcontextprotocol/express@2.0.0-beta.4 zod@^4.2.0 express cors
40+
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.5 @modelcontextprotocol/core@2.0.0-beta.5 @modelcontextprotocol/server@2.0.0-beta.5 @modelcontextprotocol/node@2.0.0-beta.5 @modelcontextprotocol/express@2.0.0-beta.5 zod@^4.2.0 express cors
4141
npm install -D typescript vite vite-plugin-singlefile @types/express @types/cors @types/node tsx concurrently cross-env
4242
```
4343

plugins/mcp-apps/skills/add-app-to-server/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ Before writing any code, analyze the server's existing tools and determine which
7777
## Step 2: Add Dependencies
7878

7979
```bash
80-
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.4 @modelcontextprotocol/core@2.0.0-beta.4 @modelcontextprotocol/server@2.0.0-beta.4 zod@^4.2.0
80+
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.5 @modelcontextprotocol/core@2.0.0-beta.5 @modelcontextprotocol/server@2.0.0-beta.5 zod@^4.2.0
8181
npm install -D vite vite-plugin-singlefile
8282
```
8383

plugins/mcp-apps/skills/convert-web-app/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ Create a new MCP server with tool and resource registration. This wraps the exis
115115
### Dependencies
116116

117117
```bash
118-
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.4 @modelcontextprotocol/core@2.0.0-beta.4 @modelcontextprotocol/server@2.0.0-beta.4 zod@^4.2.0
118+
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.5 @modelcontextprotocol/core@2.0.0-beta.5 @modelcontextprotocol/server@2.0.0-beta.5 zod@^4.2.0
119119
npm install -D tsx vite vite-plugin-singlefile
120120
```
121121

plugins/mcp-apps/skills/create-mcp-app/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ See `/tmp/mcp-ext-apps/docs/patterns.md` for detailed recipes:
110110
**Always** use `npm install` to add dependencies rather than manually writing version numbers:
111111

112112
```bash
113-
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.4 @modelcontextprotocol/core@2.0.0-beta.4 @modelcontextprotocol/server@2.0.0-beta.4 @modelcontextprotocol/node@2.0.0-beta.4 @modelcontextprotocol/express@2.0.0-beta.4 zod@^4.2.0 express cors
113+
npm install @modelcontextprotocol/ext-apps @modelcontextprotocol/client@2.0.0-beta.5 @modelcontextprotocol/core@2.0.0-beta.5 @modelcontextprotocol/server@2.0.0-beta.5 @modelcontextprotocol/node@2.0.0-beta.5 @modelcontextprotocol/express@2.0.0-beta.5 zod@^4.2.0 express cors
114114
npm install -D typescript vite vite-plugin-singlefile concurrently cross-env @types/node @types/express @types/cors
115115
```
116116

src/app-bridge.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -241,11 +241,11 @@ export type AppBridgeEventMap = {
241241
/**
242242
* Host-side bridge for communicating with a single View ({@link app!App `App`}).
243243
*
244-
* `AppBridge` extends the base MCP SDK's public `Server` class and acts as a proxy between
245-
* the host application and a view running in an iframe. When an MCP client
246-
* is provided to the constructor, it automatically forwards MCP server capabilities
247-
* (tools, resources, prompts) to the view. It also handles the initialization
248-
* handshake.
244+
* `AppBridge` extends the base MCP SDK's public `Protocol` class and acts as a
245+
* proxy between the host application and a view running in an iframe. When a
246+
* separate MCP client is provided to the constructor, it automatically forwards
247+
* MCP server capabilities (tools, resources, prompts) to the view. It also
248+
* handles the Apps initialization handshake.
249249
*
250250
* ## Architecture
251251
*

src/app.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,8 @@ export type AppEventMap = {
297297
*
298298
* The `App` class provides a framework-agnostic way to build interactive MCP Apps
299299
* that run inside host applications. It extends the base MCP SDK's public
300-
* `Client` class and adds the Apps handshake, lifecycle, and high-level APIs.
300+
* `Protocol` class, composes an {@link EventDispatcher}, and adds the Apps
301+
* handshake, lifecycle, and high-level APIs.
301302
*
302303
* ## Architecture
303304
*
@@ -314,9 +315,11 @@ export type AppEventMap = {
314315
*
315316
* ## Protocol and event methods
316317
*
317-
* As a subclass of the base MCP SDK's `Client`, `App` provides:
318+
* From the base MCP SDK's `Protocol`, `App` provides:
318319
* - `setRequestHandler()` - Register handlers for requests from host
319320
* - `setNotificationHandler()` - Register handlers for notifications from host
321+
*
322+
* From its composed {@link EventDispatcher}, `App` also provides:
320323
* - `addEventListener()` - Append a listener for a notification event (multi-listener)
321324
* - `removeEventListener()` - Remove a previously added listener
322325
*

0 commit comments

Comments
 (0)