One read of Model Context Protocolmcp-20261024T110706Z
303 pages moved out of 357 read.
Pages moved
303
significant first
Pages read
357
in this capture
Captured
11:07 UTC
Corpus hash
0c1129ea4604
full-sweep
What this read moved
101-125 of 303, page 5 of 13This capture is too large to show at once. Changes 101-125 of 303 are below, significant first; the rest are on the following screens.
docs/draft/develop/build-server Changed · +11 / -11 lines
from line 12
1212
1313> [!NOTE]
1414>
15> Servers can connect to any client. We've chosen Claude for Desktop here for simplicity, but we also have a guide on [building your own client](/docs/draft/develop/build-client.md).
15> Servers can connect to any client. We've chosen Claude for Desktop here for simplicity, but we also have a guide on [building your own client](https://modelcontextprotocol.io/docs/draft/develop/build-client.md).
1616
1717### Core MCP Concepts
1818
1919MCP servers can provide three main types of capabilities:
2020
211. **[Resources](/docs/draft/learn/server-concepts.md#resources)**: File-like data that can be read by clients (like API responses or file contents)
222. **[Tools](/docs/draft/learn/server-concepts.md#tools)**: Functions that can be called by the LLM (with user approval)
233. **[Prompts](/docs/draft/learn/server-concepts.md#prompts)**: Pre-written templates that help users accomplish specific tasks
211. **[Resources](https://modelcontextprotocol.io/docs/draft/learn/server-concepts.md#resources)**: File-like data that can be read by clients (like API responses or file contents)
222. **[Tools](https://modelcontextprotocol.io/docs/draft/learn/server-concepts.md#tools)**: Functions that can be called by the LLM (with user approval)
233. **[Prompts](https://modelcontextprotocol.io/docs/draft/learn/server-concepts.md#prompts)**: Pre-written templates that help users accomplish specific tasks
2424
2525This tutorial will primarily focus on tools.
2626
from line 707
707707
708708Make sure to run `npm run build` to build your server! This is a very important step in getting your server to connect.
709709
710To check that the server answers 2026-07-28 clients, list its tools with the [Inspector CLI](/docs/draft/tools/inspector/cli.md) in the `modern` [protocol era](/docs/draft/tools/inspector/protocol-eras.md):
710To check that the server answers 2026-07-28 clients, list its tools with the [Inspector CLI](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md) in the `modern` [protocol era](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md):
711711
712712```bash theme={null}
713713npx @modelcontextprotocol/inspector --cli node build/index.js --protocol-era modern --method tools/list
from line 2895
28952895>
28962896> **None of this is working. What do I do?**
28972897>
2898> Please refer to our [debugging guide](/docs/draft/tools/debugging.md) for better debugging tools and more detailed guidance.
2898> Please refer to our [debugging guide](https://modelcontextprotocol.io/docs/draft/tools/debugging.md) for better debugging tools and more detailed guidance.
28992899
29002900> **Weather API Issues**
29012901>
from line 2919
29192919
29202920> [!NOTE]
29212921>
2922> For more advanced troubleshooting, check out our guide on [Debugging MCP](/docs/draft/tools/debugging.md)
2922> For more advanced troubleshooting, check out our guide on [Debugging MCP](https://modelcontextprotocol.io/docs/draft/tools/debugging.md)
29232923
29242924## Next steps
29252925
2926> **[Building a client](/docs/draft/develop/build-client.md)**
2926> **[Building a client](https://modelcontextprotocol.io/docs/draft/develop/build-client.md)**
29272927>
29282928> Learn how to build your own MCP client that can connect to your server
29292929
2930> **[Example servers](/examples.md)**
2930> **[Example servers](https://modelcontextprotocol.io/examples.md)**
29312931>
29322932> Check out our gallery of official MCP servers and implementations
29332933
2934> **[Debugging Guide](/docs/draft/tools/debugging.md)**
2934> **[Debugging Guide](https://modelcontextprotocol.io/docs/draft/tools/debugging.md)**
29352935>
29362936> Learn how to effectively debug MCP servers and integrations
29372937
2938> **[Build with Agent Skills](/docs/draft/develop/build-with-agent-skills.md)**
2938> **[Build with Agent Skills](https://modelcontextprotocol.io/docs/draft/develop/build-with-agent-skills.md)**
29392939>
29402940> Use agent skills to guide AI coding assistants through server design
29412941
docs/draft/develop/build-with-agent-skills Changed · +8 / -8 lines
from line 47
4747* **Who will use it** — just you, your team, or anyone who installs it
4848* **Action surface size** — a handful of operations versus wrapping a large API
4949* **User interaction needs** — plain text results, structured input via
50 [elicitation](/specification/draft/client/elicitation.md), or rich UI widgets
50 [elicitation](https://modelcontextprotocol.io/specification/draft/client/elicitation.md), or rich UI widgets
5151* **Upstream auth** — API keys, OAuth 2.0, or none
5252
5353If your opening message already covers these, the agent skips ahead to the
from line 58
5858Based on discovery, the skill recommends one of four paths and scaffolds
5959accordingly:
6060
61**Remote [Streamable HTTP](/specification/draft/basic/transports/streamable-http.md)**
61**Remote [Streamable HTTP](https://modelcontextprotocol.io/specification/draft/basic/transports/streamable-http.md)**
6262is the default for anything wrapping a cloud API. Zero install friction, one
6363deployment serves all users, and OAuth flows work properly because the server
6464can handle redirects and token storage. The reference skill includes scaffolds
6565for Cloudflare Workers and portable Express/FastMCP setups.
6666
67**[MCP apps](/extensions/apps/overview.md)** extend a server with interactive
67**[MCP apps](https://modelcontextprotocol.io/extensions/apps/overview.md)** extend a server with interactive
6868widgets rendered in chat, such as searchable pickers, charts, and live
6969dashboards. The skill hands off to `build-mcp-app` when
70[elicitation's](/specification/draft/client/elicitation.md) flat-form constraints
70[elicitation's](https://modelcontextprotocol.io/specification/draft/client/elicitation.md) flat-form constraints
7171don't fit.
7272
7373**[MCP Bundles (MCPB)](https://github.com/modelcontextprotocol/mcpb)** package a
from line 76
7676must touch the user's machine: reading local files, driving desktop apps, or
7777talking to localhost services. The skill hands off to `build-mcpb`.
7878
79**Local [stdio](/specification/draft/basic/transports/stdio.md)** remains available
79**Local [stdio](https://modelcontextprotocol.io/specification/draft/basic/transports/stdio.md)** remains available
8080for prototyping, with a noted upgrade path to MCPB when you're ready to
8181distribute.
8282
from line 85
8585Once your agent scaffolds the server, iterate on tool descriptions and error
8686handling, then test and ship:
8787
88> **[MCP Inspector](/docs/draft/tools/inspector.md)**
88> **[MCP Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md)**
8989>
9090> Test your server's tools, resources, and prompts interactively
9191
92> **[Connect to a client](/docs/draft/develop/connect-local-servers.md)**
92> **[Connect to a client](https://modelcontextprotocol.io/docs/draft/develop/connect-local-servers.md)**
9393>
9494> Wire your server into an MCP client via local or remote configuration
9595
96> **[Publish to the Registry](/registry/quickstart.md)**
96> **[Publish to the Registry](https://modelcontextprotocol.io/registry/quickstart.md)**
9797>
9898> Make your server discoverable in the MCP Registry
9999
docs/draft/develop/clients/client-best-practices Changed · +5 / -5 lines
from line 123
123123 Host-->>Model: Server disconnected, context freed
124124```
125125
126This works especially well for general-purpose agents, where the user's intent isn't known upfront. The agent starts with a minimal set of always-on servers and connects others as needed. Combined with [agent skills](/docs/draft/develop/build-with-agent-skills.md), a skill file can declare which MCP servers it needs, and the host connects them only when that skill is invoked.
126This works especially well for general-purpose agents, where the user's intent isn't known upfront. The agent starts with a minimal set of always-on servers and connects others as needed. Combined with [agent skills](https://modelcontextprotocol.io/docs/draft/develop/build-with-agent-skills.md), a skill file can declare which MCP servers it needs, and the host connects them only when that skill is invoked.
127127
128128### Implementation Guidelines
129129
from line 140
140140
141141Each list result (such as `tools/list`), as well as each `server/discover` and
142142`resources/read` result, carries `ttlMs` and `cacheScope` hints. Follow them as defined in the
143specification's [caching utility](/specification/draft/server/utilities/caching.md). In particular,
143specification's [caching utility](https://modelcontextprotocol.io/specification/draft/server/utilities/caching.md). In particular,
144144treat a cached list as stale once a `list_changed` notification arrives, even before its TTL
145145expires.
146146
from line 198
198198}
199199```
200200
201MCP Servers can provide an optional [`outputSchema`](/specification/draft/server/tools#output-schema) for each tool. When an output schema is present, the host can produce precise return types (like `LogEntry` above).
201MCP Servers can provide an optional [`outputSchema`](https://modelcontextprotocol.io/specification/draft/server/tools#output-schema) for each tool. When an output schema is present, the host can produce precise return types (like `LogEntry` above).
202202
203203When an output schema is absent, prefer the simple path:
204204
from line 280
280280
281281Programmatic tool calling introduces a code execution surface that requires careful sandboxing:
282282
283* **Per-call authorization**: The broker is still the MCP host for spec purposes. Apply the same human-in-the-loop confirmation policy to sandbox-originated calls that you apply to direct calls (see [Tools: Security](/specification/draft/server/tools.md#security-considerations)). Approving the script does not grant blanket approval for every tool call it makes at runtime; hosts may grant categorical approval (for example, "allow `ticketing_createIssue` for this script run") rather than prompting per iteration, but the broker must still evaluate each call against that grant.
283* **Per-call authorization**: The broker is still the MCP host for spec purposes. Apply the same human-in-the-loop confirmation policy to sandbox-originated calls that you apply to direct calls (see [Tools: Security](https://modelcontextprotocol.io/specification/draft/server/tools.md#security-considerations)). Approving the script does not grant blanket approval for every tool call it makes at runtime; hosts may grant categorical approval (for example, "allow `ticketing_createIssue` for this script run") rather than prompting per iteration, but the broker must still evaluate each call against that grant.
284284* **Cross-server data flow**: Tool results from one server are untrusted input to another. The broker should apply the same input-review policy to brokered calls as to direct ones; output truncation alone does not prevent exfiltration.
285285* **Network isolation**: The sandbox should have no direct network access. All external communication flows through the host broker, which enforces authorization and access control.
286286* **No credential exposure**: API keys and tokens are held by the host. The generated code calls typed functions; the host adds authentication when forwarding to servers.
from line 290
290290### Error Handling
291291
292292MCP tool errors arrive as a successful response with
293[`isError: true`](/specification/draft/server/tools#error-handling) rather than a transport
293[`isError: true`](https://modelcontextprotocol.io/specification/draft/server/tools#error-handling) rather than a transport
294294failure. Generated wrappers should convert this into a thrown exception so model-authored code
295295can use `try`/`catch`. If an uncaught error terminates the script, surface it as the script's
296296result so the model can self-correct; the model is responsible for reporting any partial side
docs/draft/develop/connect-local-servers Changed · +4 / -4 lines
from line 204
204204
205205> **None of this is working. What do I do?**
206206>
207> Please refer to our [debugging guide](/docs/draft/tools/debugging.md) for better debugging tools and more detailed guidance.
207> Please refer to our [debugging guide](https://modelcontextprotocol.io/docs/draft/tools/debugging.md) for better debugging tools and more detailed guidance.
208208
209209> **ENOENT error and `$\{APPDATA\}` in paths on Windows**
210210>
from line 244
244244> Browse our collection of official and community-created MCP servers for
245245> additional capabilities
246246
247> **[Build your own server](/docs/draft/develop/build-server.md)**
247> **[Build your own server](https://modelcontextprotocol.io/docs/draft/develop/build-server.md)**
248248>
249249> Create custom MCP servers tailored to your specific workflows and
250250> integrations
251251
252> **[Connect to remote servers](/docs/draft/develop/connect-remote-servers.md)**
252> **[Connect to remote servers](https://modelcontextprotocol.io/docs/draft/develop/connect-remote-servers.md)**
253253>
254254> Learn how to connect Claude to remote MCP servers for cloud-based tools and
255255> services
256256
257> **[Understand the protocol](/docs/draft/learn/architecture.md)**
257> **[Understand the protocol](https://modelcontextprotocol.io/docs/draft/learn/architecture.md)**
258258>
259259> Dive deeper into how MCP works and its architecture
260260
docs/draft/develop/connect-remote-servers Changed · +4 / -4 lines
from line 19
1919With Custom Connectors, you can:
2020
2121* [Connect Claude to existing remote MCP servers](https://support.anthropic.com/en/articles/11175166-getting-started-with-custom-connectors-using-remote-mcp) provided by third-party developers
22* [Build your own remote MCP servers to connect with any tool](/docs/draft/develop/build-server.md)
22* [Build your own remote MCP servers to connect with any tool](https://modelcontextprotocol.io/docs/draft/develop/build-server.md)
2323
2424## Connecting to a Remote MCP Server
2525
from line 88
8888
8989Now that you've connected Claude to a remote MCP server, you can explore its capabilities in your conversations. Try using the connected tools to automate tasks, access external data, or integrate with your existing workflows.
9090
91> **[Build your own remote server](/docs/draft/develop/build-server.md)**
91> **[Build your own remote server](https://modelcontextprotocol.io/docs/draft/develop/build-server.md)**
9292>
9393> Create custom remote MCP servers to integrate with proprietary tools and
9494> services
from line 97
9797>
9898> Browse our collection of official and community-created MCP servers
9999
100> **[Connect local servers](/docs/draft/develop/connect-local-servers.md)**
100> **[Connect local servers](https://modelcontextprotocol.io/docs/draft/develop/connect-local-servers.md)**
101101>
102102> Learn how to connect Claude Desktop to local MCP servers for direct system
103103> access
104104
105> **[Understand the architecture](/docs/draft/learn/architecture.md)**
105> **[Understand the architecture](https://modelcontextprotocol.io/docs/draft/learn/architecture.md)**
106106>
107107> Dive deeper into how MCP works and its architecture
108108
docs/draft/getting-started/intro Changed · +6 / -6 lines
from line 29
2929
3030## Start Building
3131
32> **[Build servers](/docs/draft/develop/build-server.md)**
32> **[Build servers](https://modelcontextprotocol.io/docs/draft/develop/build-server.md)**
3333>
3434> Create MCP servers to expose your data and tools
3535
36> **[Build clients](/docs/draft/develop/build-client.md)**
36> **[Build clients](https://modelcontextprotocol.io/docs/draft/develop/build-client.md)**
3737>
3838> Develop applications that connect to MCP servers
3939
40> **[Build MCP Apps](/extensions/apps/overview.md)**
40> **[Build MCP Apps](https://modelcontextprotocol.io/extensions/apps/overview.md)**
4141>
4242> Build interactive apps that run inside AI clients
4343
4444## Learn more
4545
46> **[Architecture](/docs/draft/learn/architecture.md)**
46> **[Architecture](https://modelcontextprotocol.io/docs/draft/learn/architecture.md)**
4747>
4848> Learn the core concepts and architecture of MCP
4949
50> **[Security](/docs/draft/tutorials/security/security_best_practices.md)**
50> **[Security](https://modelcontextprotocol.io/docs/draft/tutorials/security/security_best_practices.md)**
5151>
5252> Understand the security considerations and best practices for MCP
5353
5454## Community
5555
56> **[Contributing](/community/contributing.md)**
56> **[Contributing](https://modelcontextprotocol.io/community/contributing.md)**
5757>
5858> Learn how to get involved and contribute to MCP
5959
docs/draft/learn/architecture Changed · +15 / -15 lines
from line 4
44
55Because MCP SDKs abstract away many concerns, most developers will likely find the [data layer protocol](#data-layer-protocol) section to be the most useful. It discusses how MCP servers can provide context to an AI application.
66
7For specific implementation details, please refer to the documentation for your [language-specific SDK](/docs/draft/sdk.md).
7For specific implementation details, please refer to the documentation for your [language-specific SDK](https://modelcontextprotocol.io/docs/draft/sdk.md).
88
99## Scope
1010
from line 11
1111The Model Context Protocol includes the following projects:
1212
1313* [MCP Specification](https://modelcontextprotocol.io/specification/latest.md): A specification of MCP that outlines the implementation requirements for clients and servers.
14* [MCP SDKs](/docs/draft/sdk.md): SDKs for different programming languages that implement MCP.
14* [MCP SDKs](https://modelcontextprotocol.io/docs/draft/sdk.md): SDKs for different programming languages that implement MCP.
1515* **MCP Development Tools**: Tools for developing MCP servers and clients, including the [MCP Inspector](https://github.com/modelcontextprotocol/inspector)
1616* [MCP Reference Server Implementations](https://github.com/modelcontextprotocol/servers): Reference implementations of MCP servers.
1717
from line 82
8282
8383* **Discovery**: Lets clients query a server's supported protocol versions, capabilities, and identity through the `server/discover` request
8484* **Server features**: Enables servers to provide core functionality including tools for AI actions, resources for context data, and prompts for interaction templates from and to the client
85* **Client features**: Enables servers to elicit input from the user. Sampling is [deprecated](/specification/draft/deprecated.md) as of protocol version `2026-07-28`.
85* **Client features**: Enables servers to elicit input from the user. Sampling is [deprecated](https://modelcontextprotocol.io/specification/draft/deprecated.md) as of protocol version `2026-07-28`.
8686* **Utility features**: Supports additional capabilities like notifications for real-time updates and progress tracking for long-running operations
8787
8888#### Transport layer
from line 104
104104
105105#### Statelessness and discovery
106106
107MCP is a stateless protocol (Every request contains all the information needed to process it, so servers infer nothing from previous requests). Every request carries the protocol version and the capabilities (Features and operations that a client or server supports, such as tools, resources, or prompts) relevant to that request in its `_meta` field, so the server can process each request on its own. Clients should also identify themselves in the same field unless configured not to. Servers advertise their supported versions and capabilities through the mandatory [`server/discover`](/specification/draft/server/discover) request, which clients may send before any other request. Detailed information can be found in the [specification](/specification/draft/basic/index.md#statelessness), and the [example](#example) showcases the per-request metadata and the discovery sequence.
107MCP is a stateless protocol (Every request contains all the information needed to process it, so servers infer nothing from previous requests). Every request carries the protocol version and the capabilities (Features and operations that a client or server supports, such as tools, resources, or prompts) relevant to that request in its `_meta` field, so the server can process each request on its own. Clients should also identify themselves in the same field unless configured not to. Servers advertise their supported versions and capabilities through the mandatory [`server/discover`](https://modelcontextprotocol.io/specification/draft/server/discover) request, which clients may send before any other request. Detailed information can be found in the [specification](https://modelcontextprotocol.io/specification/draft/basic/index.md#statelessness), and the [example](#example) showcases the per-request metadata and the discovery sequence.
108108
109109#### Primitives
110110
from line 121
121121
122122As a concrete example, consider an MCP server that provides context about a database. It can expose tools for querying the database, a resource that contains the schema of the database, and a prompt that includes few-shot examples for interacting with the tools.
123123
124For more details about server primitives see [server concepts](/docs/draft/learn/server-concepts.md).
124For more details about server primitives see [server concepts](https://modelcontextprotocol.io/docs/draft/learn/server-concepts.md).
125125
126126MCP also defines primitives that *clients* can expose. These primitives allow MCP server authors to build richer interactions.
127127
128128* **Elicitation**: Allows servers to request additional information from users. This is useful when server authors want to get more information from the user, or ask for confirmation of an action. Servers request user input with the `elicitation/create` method.
129129
130Elicitation requests are delivered through the [Multi Round-Trip Requests](/specification/draft/basic/patterns/mrtr.md) pattern, explained in the [elicitation overview](/docs/draft/learn/client-concepts.md#elicitation).
130Elicitation requests are delivered through the [Multi Round-Trip Requests](https://modelcontextprotocol.io/specification/draft/basic/patterns/mrtr.md) pattern, explained in the [elicitation overview](https://modelcontextprotocol.io/docs/draft/learn/client-concepts.md#elicitation).
131131
132132**Deprecated**: The following client primitives are deprecated as of protocol version `2026-07-28`.
133133
from line 134
134134* **Sampling**: Allows servers to request language model completions from the client's AI application. This is useful when server authors want access to a language model, but want to stay model-independent and not include a language model SDK in their MCP server. Servers request completions with the `sampling/createMessage` method, also delivered through the Multi Round-Trip Requests pattern. New implementations should integrate directly with LLM provider APIs.
135135* **Logging**: Enables servers to send log messages to clients for debugging and monitoring purposes. New implementations should log to `stderr` (stdio transport) or use OpenTelemetry.
136136
137For more details about client primitives see [client concepts](/docs/draft/learn/client-concepts.md).
137For more details about client primitives see [client concepts](https://modelcontextprotocol.io/docs/draft/learn/client-concepts.md).
138138
139Besides server and client primitives, the protocol supports optional [extensions](/extensions/overview.md) that build on the core protocol. For example, the [Tasks extension](/extensions/tasks/overview.md) lets servers return a durable handle for long-running requests, so clients can poll for status and retrieve the result later.
139Besides server and client primitives, the protocol supports optional [extensions](https://modelcontextprotocol.io/extensions/overview.md) that build on the core protocol. For example, the [Tasks extension](https://modelcontextprotocol.io/extensions/tasks/overview.md) lets servers return a durable handle for long-running requests, so clients can poll for status and retrieve the result later.
140140
141141#### Notifications
142142
143The protocol supports real-time notifications to enable dynamic updates between servers and clients. For example, when a server's available tools change (such as when new functionality becomes available or existing tools are modified), the server can send tool update notifications to inform connected clients about these changes. Notifications are sent as JSON-RPC 2.0 notification messages (without expecting a response). Change notifications are opt-in: the client opens a long-lived [`subscriptions/listen`](/specification/draft/basic/patterns/subscriptions) stream naming the notification types it wants to receive, and the server delivers matching notifications on that stream.
143The protocol supports real-time notifications to enable dynamic updates between servers and clients. For example, when a server's available tools change (such as when new functionality becomes available or existing tools are modified), the server can send tool update notifications to inform connected clients about these changes. Notifications are sent as JSON-RPC 2.0 notification messages (without expecting a response). Change notifications are opt-in: the client opens a long-lived [`subscriptions/listen`](https://modelcontextprotocol.io/specification/draft/basic/patterns/subscriptions) stream naming the notification types it wants to receive, and the server delivers matching notifications on that stream.
144144
145145## Example
146146
from line 215
215215
216216**Server Capabilities**:
217217
218* `"tools": {"listChanged": true}` - The server supports the tools primitive and can honor a `toolsListChanged` filter in [`subscriptions/listen`](/specification/draft/basic/patterns/subscriptions). Clients that request this filter receive `notifications/tools/list_changed` when the tool list changes.
218* `"tools": {"listChanged": true}` - The server supports the tools primitive and can honor a `toolsListChanged` filter in [`subscriptions/listen`](https://modelcontextprotocol.io/specification/draft/basic/patterns/subscriptions). Clients that request this filter receive `notifications/tools/list_changed` when the tool list changes.
219219* `"resources": {}` - The server also supports the resources primitive (can handle `resources/list` and `resources/read` methods)
220220
221221Calling `server/discover` is optional. Because every request carries the same `_meta` fields, a client is free to send any request directly and handle a version error if one comes back. Discovery is a convenient way to fetch the server's identity, capabilities, and supported versions in a single request.
from line 308
308308
309309#### Understanding the Tool Discovery Request
310310
311The `tools/list` request requires no parameters beyond the standard `_meta` fields that accompany every MCP request. It also accepts an optional `cursor` parameter for [pagination](/specification/draft/server/utilities/pagination.md), which the example above omits.
311The `tools/list` request requires no parameters beyond the standard `_meta` fields that accompany every MCP request. It also accepts an optional `cursor` parameter for [pagination](https://modelcontextprotocol.io/specification/draft/server/utilities/pagination.md), which the example above omits.
312312
313313#### Understanding the Tool Discovery Response
314314
from line 321
321321* **`description`**: Detailed explanation of what the tool does and when to use it
322322* **`inputSchema`**: A JSON Schema that defines the expected input parameters, enabling type validation and providing clear documentation about required and optional parameters
323323
324The result is marked `"resultType": "complete"` and carries two caching fields. `ttlMs` is a freshness hint in milliseconds, so this tool list can be cached for five minutes. `cacheScope` indicates who may reuse the response. The specification's [caching utility](/specification/draft/server/utilities/caching.md) defines the full rules.
324The result is marked `"resultType": "complete"` and carries two caching fields. `ttlMs` is a freshness hint in milliseconds, so this tool list can be cached for five minutes. `cacheScope` indicates who may reuse the response. The specification's [caching utility](https://modelcontextprotocol.io/specification/draft/server/utilities/caching.md) defines the full rules.
325325
326326#### How This Works in AI Applications
327327
from line 336
336336conversation.register_available_tools(available_tools)
337337```
338338
339Clients that federate many servers can use [progressive tool discovery](/docs/draft/develop/clients/client-best-practices.md#progressive-tool-discovery) rather than loading every tool upfront.
339Clients that federate many servers can use [progressive tool discovery](https://modelcontextprotocol.io/docs/draft/develop/clients/client-best-practices.md#progressive-tool-discovery) rather than loading every tool upfront.
340340
341341**3. Tool Execution (Primitives)**
342342
from line 431
431431
432432#### Subscribing to Changes
433433
434Change notifications are opt-in. To receive them, the client opens a long-lived notification stream by sending a [`subscriptions/listen`](/specification/draft/basic/patterns/subscriptions) request with a `notifications` filter naming the event types it wants. Here the client asks for tool list changes:
434Change notifications are opt-in. To receive them, the client opens a long-lived notification stream by sending a [`subscriptions/listen`](https://modelcontextprotocol.io/specification/draft/basic/patterns/subscriptions) request with a `notifications` filter naming the event types it wants. Here the client asks for tool list changes:
435435
436436```json Listen Request theme={null}
437437{
docs/draft/learn/client-concepts Changed · +7 / -7 lines
from line 11
1111| Feature | Explanation | Example |
1212| - | - | - |
1313| **Elicitation** | Elicitation enables servers to request specific information from users during interactions, providing a structured way for servers to gather information on demand. | A server booking travel may ask for the user's preferences on airplane seats, room type or their contact number to finalize a booking. |
14| **Roots** | Roots allow clients to specify which directories servers should focus on, communicating intended scope through a coordination mechanism. Roots are [deprecated](/specification/draft/deprecated.md) as of protocol version `2026-07-28`. | A server for booking travel may be given access to a specific directory, from which it can read a user's calendar. |
14| **Roots** | Roots allow clients to specify which directories servers should focus on, communicating intended scope through a coordination mechanism. Roots are [deprecated](https://modelcontextprotocol.io/specification/draft/deprecated.md) as of protocol version `2026-07-28`. | A server for booking travel may be given access to a specific directory, from which it can read a user's calendar. |
1515| **Sampling** | Sampling allows servers to request LLM completions through the client, enabling an agentic workflow. This approach puts the client in complete control of user permissions and security measures. Sampling is deprecated as of protocol version `2026-07-28`. | A server for booking travel may send a list of flights to an LLM and request that the LLM pick the best flight for the user. |
1616
1717### Elicitation
from line 27
2727* **Form mode**: The server asks the client to collect structured data from the user. The request includes a schema that the client uses to build an input form and validate the response.
2828* **URL mode**: The server provides a URL for the user to open. The interaction happens out of band and its data never passes through the client, which makes this mode suitable for sensitive flows such as credential entry or third-party OAuth authorization.
2929
30Elicitation follows the [Multi Round-Trip Requests](/specification/draft/basic/patterns/mrtr.md) (MRTR) pattern. When a server needs user input while processing a request such as `tools/call`, it responds with an `InputRequiredResult` whose `inputRequests` field carries one or more `elicitation/create` requests. The client gathers the input and retries the original request, attaching the collected `inputResponses` and echoing back any `requestState` the server included.
30Elicitation follows the [Multi Round-Trip Requests](https://modelcontextprotocol.io/specification/draft/basic/patterns/mrtr.md) (MRTR) pattern. When a server needs user input while processing a request such as `tools/call`, it responds with an `InputRequiredResult` whose `inputRequests` field carries one or more `elicitation/create` requests. The client gathers the input and retries the original request, attaching the collected `inputResponses` and echoing back any `requestState` the server included.
3131
3232**Elicitation flow:**
3333
from line 115
115115
116116> [!WARNING]
117117>
118> Roots are [deprecated](/specification/draft/deprecated.md) as of protocol version
118> Roots are [deprecated](https://modelcontextprotocol.io/specification/draft/deprecated.md) as of protocol version
119119> `2026-07-28` and scheduled for removal. New implementations should pass
120120> directories or files via tool parameters, resource URIs, or server
121121> configuration instead.
from line 171
171171
172172> [!WARNING]
173173>
174> Sampling is [deprecated](/specification/draft/deprecated.md) as of protocol
174> Sampling is [deprecated](https://modelcontextprotocol.io/specification/draft/deprecated.md) as of protocol
175175> version `2026-07-28` and scheduled for removal. New implementations should
176176> integrate directly with LLM provider APIs instead.
177177
from line 181
181181
182182Sampling enables servers to perform AI-dependent tasks without directly integrating with or paying for AI models. Instead, servers can request that the client—which already has AI model access—handle these tasks on their behalf. This approach puts the client in complete control of user permissions and security measures. Because sampling requests occur within the context of other operations—like a tool analyzing data—and are processed as separate model calls, they maintain clear boundaries between different contexts, allowing for more efficient use of the context window.
183183
184Sampling follows the same [Multi Round-Trip Requests](/specification/draft/basic/patterns/mrtr.md) flow described under [elicitation](#elicitation), with the `InputRequiredResult` carrying a `sampling/createMessage` request.
184Sampling follows the same [Multi Round-Trip Requests](https://modelcontextprotocol.io/specification/draft/basic/patterns/mrtr.md) flow described under [elicitation](#elicitation), with the `InputRequiredResult` carrying a `sampling/createMessage` request.
185185
186Servers can also request tool use during sampling by including a `tools` array and an optional `toolChoice` field in the request. The tool definitions are scoped to that sampling request and do not need to correspond to tools the server exposes. Clients declare support through the `sampling.tools` capability, and servers must not send tool-enabled sampling requests to clients that have not declared it. See [sampling](/specification/draft/client/sampling.md#tools-in-sampling) in the specification for details.
186Servers can also request tool use during sampling by including a `tools` array and an optional `toolChoice` field in the request. The tool definitions are scoped to that sampling request and do not need to correspond to tools the server exposes. Clients declare support through the `sampling.tools` capability, and servers must not send tool-enabled sampling requests to clients that have not declared it. See [sampling](https://modelcontextprotocol.io/specification/draft/client/sampling.md#tools-in-sampling) in the specification for details.
187187
188188**Sampling flow:**
189189
docs/draft/learn/versioning Changed · +9 / -9 lines
from line 18
1818 receive backwards compatible changes.
1919* **Final**: past, complete specifications that will not be changed.
2020
21The **current** protocol version is [**2026-07-28**](/specification/2026-07-28.md).
21The **current** protocol version is [**2026-07-28**](https://modelcontextprotocol.io/specification/2026-07-28.md).
2222
2323## Feature States
2424
2525Individual features of the specification may additionally be marked as
2626**Deprecated** under the
27[feature lifecycle and deprecation policy](/community/feature-lifecycle.md):
27[feature lifecycle and deprecation policy](https://modelcontextprotocol.io/community/feature-lifecycle.md):
2828the feature remains part of the specification, but is scheduled for removal.
2929Deprecated features document a migration path (or state that none is required)
3030and remain in the specification for at least twelve months, or at least
3131ninety days under the policy's
32[expedited-removal exception](/community/feature-lifecycle.md#expedited-removal),
32[expedited-removal exception](https://modelcontextprotocol.io/community/feature-lifecycle.md#expedited-removal),
3333before they become eligible for removal, after which they may be **Removed**
3434in a future revision.
3535
3636Features that are currently Deprecated are listed in the
37[deprecated features registry](/specification/draft/deprecated.md).
37[deprecated features registry](https://modelcontextprotocol.io/specification/draft/deprecated.md).
3838
3939## Negotiation
4040
4141Every request declares the protocol version it is using via the
4242`io.modelcontextprotocol/protocolVersion` key in its
43[`_meta`](/specification/draft/basic/index#meta) field, and the server accepts or
43[`_meta`](https://modelcontextprotocol.io/specification/draft/basic/index#meta) field, and the server accepts or
4444rejects each request independently. On Streamable HTTP, the same value is also carried
4545in the
46[`MCP-Protocol-Version` header](/specification/draft/basic/transports/streamable-http#protocol-version-header).
46[`MCP-Protocol-Version` header](https://modelcontextprotocol.io/specification/draft/basic/transports/streamable-http#protocol-version-header).
4747Clients and servers **MAY** support multiple protocol versions simultaneously.
4848
4949If the server does not support the requested version, it responds with an
50[`UnsupportedProtocolVersionError`](/specification/draft/basic/versioning#protocol-version-negotiation)
50[`UnsupportedProtocolVersionError`](https://modelcontextprotocol.io/specification/draft/basic/versioning#protocol-version-negotiation)
5151listing the versions it does support. The client can then retry the request with a
5252mutually supported version, or surface an error to the user if none exists.
5353
5454Clients that want to select a version up front can call
55[`server/discover`](/specification/draft/server/discover), a mandatory RPC that
55[`server/discover`](https://modelcontextprotocol.io/specification/draft/server/discover), a mandatory RPC that
5656returns the server's supported protocol versions, capabilities, and identity in a
5757single request. Calling it is optional: a client is free to send any request directly
5858and handle a version error if one comes back.
from line 59
5959
6060For interoperability with servers and clients that implement the
6161handshake-based protocol revisions (`2025-11-25` and earlier), see
62[Backward Compatibility](/specification/draft/basic/versioning.md#backward-compatibility-with-initialization-based-versions).
62[Backward Compatibility](https://modelcontextprotocol.io/specification/draft/basic/versioning.md#backward-compatibility-with-initialization-based-versions).
6363
docs/draft/sdk Changed · +4 / -4 lines
from line 2
22
33> Official SDKs for building with Model Context Protocol
44
5Build MCP servers and clients using our official SDKs. SDKs are classified into tiers based on feature completeness, protocol support, and maintenance commitment. Learn more about [SDK tiers](/community/sdk-tiers.md).
5Build MCP servers and clients using our official SDKs. SDKs are classified into tiers based on feature completeness, protocol support, and maintenance commitment. Learn more about [SDK tiers](https://modelcontextprotocol.io/community/sdk-tiers.md).
66
77## Available SDKs
88
from line 19
1919| [PHP](https://php.sdk.modelcontextprotocol.io) | [modelcontextprotocol/php-sdk](https://github.com/modelcontextprotocol/php-sdk) | Tier 3 |
2020| [Kotlin](https://kotlin.sdk.modelcontextprotocol.io) | [modelcontextprotocol/kotlin-sdk](https://github.com/modelcontextprotocol/kotlin-sdk) | Tier 3 |
2121
22See [SDK Tiering System](/community/sdk-tiers.md) for details on what each tier means.
22See [SDK Tiering System](https://modelcontextprotocol.io/community/sdk-tiers.md) for details on what each tier means.
2323
2424## Getting Started
2525
from line 36
3636
3737Ready to start building with MCP? Choose your path:
3838
39> **[Build a Server](/docs/draft/develop/build-server.md)**
39> **[Build a Server](https://modelcontextprotocol.io/docs/draft/develop/build-server.md)**
4040>
4141> Learn how to create your first MCP server
4242
43> **[Build a Client](/docs/draft/develop/build-client.md)**
43> **[Build a Client](https://modelcontextprotocol.io/docs/draft/develop/build-client.md)**
4444>
4545> Create applications that connect to MCP servers
4646
docs/draft/tools/debugging Changed · +24 / -24 lines
from line 10
1010
1111MCP provides several tools for debugging at different levels:
1212
131. **[MCP Inspector](/docs/draft/tools/inspector.md)**: interactive, transport-agnostic
131. **[MCP Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md)**: interactive, transport-agnostic
1414 testing UI. Connect to stdio or Streamable HTTP servers, invoke
15 [tools](/specification/latest/server/tools.md),
16 [prompts](/specification/latest/server/prompts.md), and
17 [resources](/specification/latest/server/resources.md), and watch the
15 [tools](https://modelcontextprotocol.io/specification/latest/server/tools.md),
16 [prompts](https://modelcontextprotocol.io/specification/latest/server/prompts.md), and
17 [resources](https://modelcontextprotocol.io/specification/latest/server/resources.md), and watch the
1818 notification stream. This should be your first stop.
19192. **Server logging**: structured logs to stderr (stdio transport) or via
2020 [OpenTelemetry](https://opentelemetry.io/) (all transports).
21 [Logging](/specification/draft/server/utilities/logging.md) over the protocol
21 [Logging](https://modelcontextprotocol.io/specification/draft/server/utilities/logging.md) over the protocol
2222 (`notifications/message`) is deprecated as of protocol version `2026-07-28`.
23233. **Client developer tools**: most MCP clients expose logs and connection
2424 state. See [Debugging in Claude Desktop](#debugging-in-claude-desktop)
from line 29
2929### Server-side logging
3030
3131When building a server that uses the local
32[stdio transport](/specification/draft/basic/transports/stdio.md), all messages
32[stdio transport](https://modelcontextprotocol.io/specification/draft/basic/transports/stdio.md), all messages
3333logged to stderr (standard error) will be captured by the host application
3434automatically.
3535
from line 39
3939> will interfere with protocol operation.
4040
4141For servers using the
42[Streamable HTTP transport](/specification/draft/basic/transports/streamable-http.md),
42[Streamable HTTP transport](https://modelcontextprotocol.io/specification/draft/basic/transports/streamable-http.md),
4343stderr is not captured by the client. Use your own server-side log aggregation
4444or [OpenTelemetry](https://opentelemetry.io/) for logs, and standard HTTP
4545tooling (curl, browser DevTools Network panel) to inspect requests and SSE
from line 50
5050> The `notifications/message` mechanism below is deprecated as of protocol
5151> version `2026-07-28`. It remains available during the deprecation window.
5252
53For all [transports](/specification/latest/basic/transports.md), record what the
53For all [transports](https://modelcontextprotocol.io/specification/latest/basic/transports.md), record what the
5454server is doing as it runs:
5555
5656```python Python theme={null}
from line 78
7878```
7979
8080MCP defines eight
81[RFC 5424 severity levels](/specification/latest/server/utilities/logging.md#log-levels)
81[RFC 5424 severity levels](https://modelcontextprotocol.io/specification/latest/server/utilities/logging.md#log-levels)
8282(`debug` through `emergency`). Clients opt in to log messages per request by
8383setting the
84[`io.modelcontextprotocol/logLevel`](/specification/draft/server/utilities/logging#per-request-log-level)
84[`io.modelcontextprotocol/logLevel`](https://modelcontextprotocol.io/specification/draft/server/utilities/logging#per-request-log-level)
8585field in the request's `_meta`. Servers must not send `notifications/message`
8686for requests that omit this field.
8787
from line 96
9696## Common issues
9797
9898The examples below use Claude Desktop's
99[`claude_desktop_config.json`](/docs/draft/develop/connect-local-servers); the same
99[`claude_desktop_config.json`](https://modelcontextprotocol.io/docs/draft/develop/connect-local-servers); the same
100100principles apply to any stdio-based MCP client.
101101
102102### Working directory
from line 177
177177
1781781. Check client logs
1791792. Verify server process is running
1803. Test standalone with [Inspector](/docs/draft/tools/inspector.md)
1803. Test standalone with [Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md)
1811814. Verify
182 [protocol compatibility](/docs/draft/learn/versioning.md#negotiation): call
183 [`server/discover`](/specification/draft/server/discover) to see which
182 [protocol compatibility](https://modelcontextprotocol.io/docs/draft/learn/versioning.md#negotiation): call
183 [`server/discover`](https://modelcontextprotocol.io/specification/draft/server/discover) to see which
184184 protocol versions the server supports. An
185185 `UnsupportedProtocolVersionError` (`-32022`) lists the server's supported
186186 versions in its `data` field
1871875. Check the
188 [per-request `_meta` fields](/specification/draft/basic/index#meta):
188 [per-request `_meta` fields](https://modelcontextprotocol.io/specification/draft/basic/index#meta):
189189 every request must carry `io.modelcontextprotocol/protocolVersion` and
190190 `io.modelcontextprotocol/clientCapabilities`, and clients should also
191191 include `io.modelcontextprotocol/clientInfo`. A request missing either
from line 192
192192 required field is rejected with error `-32602` (Invalid params), the same
193193 code returned for many other malformed inputs. If the server needs a
194194 capability the request's `clientCapabilities` did not declare, such as
195 [elicitation](/specification/draft/client/elicitation.md), it returns a
195 [elicitation](https://modelcontextprotocol.io/specification/draft/client/elicitation.md), it returns a
196196 `MissingRequiredClientCapabilityError` (`-32021`) naming the missing
197197 capabilities. Inspect the request's `_meta` and the
198 [`server/discover`](/specification/draft/server/discover) response to
198 [`server/discover`](https://modelcontextprotocol.io/specification/draft/server/discover) response to
199199 verify both sides declared what you expect
200200
201201## Debugging in Claude Desktop
from line 267
267267### Development cycle
268268
2692691. Initial Development
270 * Use [Inspector](/docs/draft/tools/inspector.md) for basic testing
270 * Use [Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md) for basic testing
271271 * Implement core functionality
272272 * Add logging points
273273
from line 283
283283* **Configuration changes**: Restart the MCP client
284284* **Server code changes**: Restart the client (for Claude Desktop, fully quit
285285 and reopen; closing the window is not enough)
286* **Quick iteration**: Use [Inspector](/docs/draft/tools/inspector.md) during
286* **Quick iteration**: Use [Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md) during
287287 development
288288
289289## Best practices
from line 323
323323 * Monitor access patterns
324324
325325For a full treatment of MCP attack vectors and mitigations, see
326[Security Best Practices](/docs/draft/tutorials/security/security_best_practices.md).
326[Security Best Practices](https://modelcontextprotocol.io/docs/draft/tutorials/security/security_best_practices.md).
327327
328328## Getting help
329329
from line 331
331331
3323321. **First Steps**
333333 * Check server logs
334 * Test with [Inspector](/docs/draft/tools/inspector.md)
334 * Test with [Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md)
335335 * Review configuration
336336 * Verify environment
337337
from line 347
347347
348348## Next steps
349349
350> **[MCP Inspector](/docs/draft/tools/inspector.md)**
350> **[MCP Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md)**
351351>
352352> Learn to use the MCP Inspector
353353
354> **[Build an MCP server](/docs/draft/develop/build-server.md)**
354> **[Build an MCP server](https://modelcontextprotocol.io/docs/draft/develop/build-server.md)**
355355>
356356> Walk through building a server from scratch
357357
358> **[Connect local servers](/docs/draft/develop/connect-local-servers.md)**
358> **[Connect local servers](https://modelcontextprotocol.io/docs/draft/develop/connect-local-servers.md)**
359359>
360360> Full claude\_desktop\_config.json reference and troubleshooting
361361
docs/draft/tools/inspector Changed · +18 / -18 lines
from line 2
22
33> Interactive developer tooling for testing and debugging MCP servers, in the browser, on the command line, and in the terminal
44
5The [MCP Inspector](https://github.com/modelcontextprotocol/inspector) is the reference developer tool for testing and debugging [MCP servers](/docs/draft/learn/server-concepts.md). It ships as a single package, `@modelcontextprotocol/inspector`, providing **three clients behind one binary**:
5The [MCP Inspector](https://github.com/modelcontextprotocol/inspector) is the reference developer tool for testing and debugging [MCP servers](https://modelcontextprotocol.io/docs/draft/learn/server-concepts.md). It ships as a single package, `@modelcontextprotocol/inspector`, providing **three clients behind one binary**:
66
77| Client | Invocation | What it's for |
88| - | - | - |
from line 10
1010| **CLI** | `npx @modelcontextprotocol/inspector --cli` | A scriptable, machine-readable client for CI, shell pipelines, and coding agents. |
1111| **TUI** | `npx @modelcontextprotocol/inspector --tui` | An interactive terminal UI, for when a browser isn't available or wanted. |
1212
13All three are built on the same shared core, so a connection behaves identically across them: the same transports, the same configuration files, the same OAuth state on disk, and the same [protocol-era](/docs/draft/tools/inspector/protocol-eras.md) negotiation (legacy vs. modern 2026-07-28).
13All three are built on the same shared core, so a connection behaves identically across them: the same transports, the same configuration files, the same OAuth state on disk, and the same [protocol-era](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md) negotiation (legacy vs. modern 2026-07-28).
1414
15The package also installs **`mcpdo`**, an experimental [connection client](/docs/draft/tools/inspector/mcpdo.md) that connects to a server once and keeps it open across many commands, on the same core.
15The package also installs **`mcpdo`**, an experimental [connection client](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md) that connects to a server once and keeps it open across many commands, on the same core.
1616
1717
1818
from line 32
3232npx @modelcontextprotocol/inspector
3333```
3434
35The command prints a URL carrying a per-launch API token and opens it in your browser (set `MCP_AUTO_OPEN_ENABLED=false` to stop it opening). See [Web client](/docs/draft/tools/inspector/web.md).
35The command prints a URL carrying a per-launch API token and opens it in your browser (set `MCP_AUTO_OPEN_ENABLED=false` to stop it opening). See [Web client](https://modelcontextprotocol.io/docs/draft/tools/inspector/web.md).
3636
3737**CLI**
3838
from line 45
4545 --method tools/call --tool-name get_weather --tool-arg city=Boston --format json | jq .result
4646```
4747
48See [CLI client](/docs/draft/tools/inspector/cli.md).
48See [CLI client](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md).
4949
5050**TUI**
5151
from line 53
5353npx @modelcontextprotocol/inspector --tui node path/to/server/index.js
5454```
5555
56See [TUI client](/docs/draft/tools/inspector/tui.md).
56See [TUI client](https://modelcontextprotocol.io/docs/draft/tools/inspector/tui.md).
5757
5858### Inspecting published servers
5959
from line 87
8787> sessions, Termux, and containers with a mounted volume) they are saved to
8888> `~/.mcp-inspector/secrets.json` instead, **unencrypted unless you supply a
8989> key**. See [Where secrets are
90> stored](/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored)
90> stored](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored)
9191> for how to get a keychain back, encrypt the file, or keep secrets in memory
9292> only.
9393
from line 98
98981. **The mode flag:** `--web` (default), `--cli`, or `--tui`. At most one; passing two errors with `Specify at most one of --web, --cli, or --tui.`
99992. **`-h` / `--help`.**
100100
101Everything else (`--catalog`, `--config`, `--server-url`, `--transport`, `--method`, the OAuth flags) is defined by the *client*, not the launcher, and the clients do not all define the same set. The [Configuration and flags](/docs/draft/tools/inspector/configuration.md) page is organized that way, by owner.
101Everything else (`--catalog`, `--config`, `--server-url`, `--transport`, `--method`, the OAuth flags) is defined by the *client*, not the launcher, and the clients do not all define the same set. The [Configuration and flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md) page is organized that way, by owner.
102102
103103> [!NOTE]
104104>
from line 117
117117
118118## Where to go next
119119
120> **[Web client](/docs/draft/tools/inspector/web.md)**
120> **[Web client](https://modelcontextprotocol.io/docs/draft/tools/inspector/web.md)**
121121>
122122> A tab-by-tab walkthrough of the graphical inspector.
123123
124> **[CLI client](/docs/draft/tools/inspector/cli.md)**
124> **[CLI client](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md)**
125125>
126126> Method reference, output formats, exit codes, and CI recipes.
127127
128> **[TUI client](/docs/draft/tools/inspector/tui.md)**
128> **[TUI client](https://modelcontextprotocol.io/docs/draft/tools/inspector/tui.md)**
129129>
130130> Terminal navigation and keyboard reference.
131131
132> **[Configuration and flags](/docs/draft/tools/inspector/configuration.md)**
132> **[Configuration and flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md)**
133133>
134134> Catalog vs. config files, the full per-client flag reference, and
135135> environment variables.
136136
137> **[Authorization](/docs/draft/tools/inspector/authorization.md)**
137> **[Authorization](https://modelcontextprotocol.io/docs/draft/tools/inspector/authorization.md)**
138138>
139139> The OAuth flow end to end, mid-session re-authorization, and loopback
140140> callbacks.
141141
142> **[Protocol eras](/docs/draft/tools/inspector/protocol-eras.md)**
142> **[Protocol eras](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md)**
143143>
144144> Legacy vs. modern (2026-07-28) operation, and how every tab changes between
145145> protocol eras.
146146
147> **[mcpdo connection client](/docs/draft/tools/inspector/mcpdo.md)**
147> **[mcpdo connection client](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md)**
148148>
149149> Connect once, then run many commands against a named connection.
150150
151> **[Security](/docs/draft/tools/inspector/security.md)**
151> **[Security](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md)**
152152>
153153> The threat model: the web backend's token, Docker, secret storage, stdio
154154> servers, and the mcpdo daemon.
155155
156> **[Recipes](/docs/draft/tools/inspector/recipes.md)**
156> **[Recipes](https://modelcontextprotocol.io/docs/draft/tools/inspector/recipes.md)**
157157>
158158> Importing client configs, reviewing MCP Apps, Docker, and network hosting.
159159
160> **[Debugging guide](/docs/draft/tools/debugging.md)**
160> **[Debugging guide](https://modelcontextprotocol.io/docs/draft/tools/debugging.md)**
161161>
162162> Broader debugging strategies beyond the Inspector.
163163
docs/draft/tools/inspector/authorization Changed · +10 / -10 lines
from line 2
22
33> How the MCP Inspector performs OAuth, re-authorizes mid-session, and shares tokens between its clients
44
5Remote MCP servers usually require authorization. The Inspector implements the full [authorization](/specification/latest/basic/authorization.md) flow in all three clients, sharing the resulting tokens on disk so a login done once is usable everywhere.
5Remote MCP servers usually require authorization. The Inspector implements the full [authorization](https://modelcontextprotocol.io/specification/latest/basic/authorization.md) flow in all three clients, sharing the resulting tokens on disk so a login done once is usable everywhere.
66
77## The flow, end to end
88
from line 17
1717
1818The Inspector fetches the server's [protected-resource and
1919authorization-server
20metadata](/specification/latest/basic/authorization/authorization-server-discovery.md)
20metadata](https://modelcontextprotocol.io/specification/latest/basic/authorization/authorization-server-discovery.md)
2121to learn the endpoints and the supported grants.
2222
2323**3. Register or identify the client**
from line 24
2424
2525The Inspector identifies itself to the authorization server through
2626whichever mechanism is configured: [dynamic client
27registration](/specification/latest/basic/authorization/client-registration.md#dynamic-client-registration),
27registration](https://modelcontextprotocol.io/specification/latest/basic/authorization/client-registration.md#dynamic-client-registration),
2828a pre-registered static client (`--client-id` / `--client-secret`), a
2929[Client ID Metadata
30Document](/specification/latest/basic/authorization/client-registration.md#client-id-metadata-documents)
30Document](https://modelcontextprotocol.io/specification/latest/basic/authorization/client-registration.md#client-id-metadata-documents)
3131(`--client-metadata-url`), or an [enterprise-managed
32IdP](/extensions/auth/enterprise-managed-authorization.md).
32IdP](https://modelcontextprotocol.io/extensions/auth/enterprise-managed-authorization.md).
3333
3434**4. Authorize in the browser**
3535
from line 87
8787| - | - |
8888| `~/.mcp-inspector/storage/oauth.json` | Non-secret OAuth state (discovery metadata, PKCE verifiers, granted scope, public client ids), keyed by canonicalized server URL. Written owner-only. |
8989| `~/.mcp-inspector/storage/client.json` | Install-level client settings (client metadata URL, enterprise IdP). The same file the web client's **Client Settings** dialog writes. |
90| The server's `oauth` block in the [catalog file](/docs/draft/tools/inspector/configuration.md#catalog-file-format) | Per-server client id/secret, scopes, the enterprise-managed flag, and the [step-up](#mid-session-re-authorization) policy. |
90| The server's `oauth` block in the [catalog file](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#catalog-file-format) | Per-server client id/secret, scopes, the enterprise-managed flag, and the [step-up](#mid-session-re-authorization) policy. |
9191
92The path to `oauth.json` is resolved in order: `MCP_INSPECTOR_OAUTH_STATE_PATH`, then `<MCP_STORAGE_DIR>/oauth.json` (see [Environment variables](/docs/draft/tools/inspector/configuration.md#environment-variables)), then the default above. All three clients resolve it the same way. Command-line `--client-id` / `--client-secret` / `--client-metadata-url` override `client.json`.
92The path to `oauth.json` is resolved in order: `MCP_INSPECTOR_OAUTH_STATE_PATH`, then `<MCP_STORAGE_DIR>/oauth.json` (see [Environment variables](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#environment-variables)), then the default above. All three clients resolve it the same way. Command-line `--client-id` / `--client-secret` / `--client-metadata-url` override `client.json`.
9393
94The secrets themselves (access and refresh tokens, client secrets, registration access tokens, and IdP session tokens) are not in `oauth.json`. They go to the [secret store](/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored), which is the OS keychain when one is reachable. `MCP_INSPECTOR_PERSIST_TOKENS` limits which acquired tokens are kept: `all` (default), `access` (no refresh tokens), or `none` (re-authorize every run). See [Secret store variables](/docs/draft/tools/inspector/configuration.md#secret-store-variables).
94The secrets themselves (access and refresh tokens, client secrets, registration access tokens, and IdP session tokens) are not in `oauth.json`. They go to the [secret store](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored), which is the OS keychain when one is reachable. `MCP_INSPECTOR_PERSIST_TOKENS` limits which acquired tokens are kept: `all` (default), `access` (no refresh tokens), or `none` (re-authorize every run). See [Secret store variables](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#secret-store-variables).
9595
9696## Mid-session re-authorization
9797
from line 110
110110
111111## Non-interactive and CI runs
112112
113Interactive OAuth requires a TTY on **stdin or stderr**, or [`MCP_AUTO_OPEN_ENABLED=true`](/docs/draft/tools/inspector/configuration#environment-variables). Redirecting stderr into a pipe, as in `2>&1 | tee`, still works because stdin stays a TTY. When neither is true, which is the normal CI shape, the CLI fails fast with `auth_required` rather than waiting up to fifteen minutes for a callback nobody will complete.
113Interactive OAuth requires a TTY on **stdin or stderr**, or [`MCP_AUTO_OPEN_ENABLED=true`](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration#environment-variables). Redirecting stderr into a pipe, as in `2>&1 | tee`, still works because stdin stays a TTY. When neither is true, which is the normal CI shape, the CLI fails fast with `auth_required` rather than waiting up to fifteen minutes for a callback nobody will complete.
114114
115115For CI, be explicit:
116116
from line 143
143143 --wait-for-auth 120 --method tools/list
144144```
145145
146The `deepLink` in the handoff block navigates a browser straight to a *connected* Inspector; see [Deep links](/docs/draft/tools/inspector/web.md#deep-links).
146The `deepLink` in the handoff block navigates a browser straight to a *connected* Inspector; see [Deep links](https://modelcontextprotocol.io/docs/draft/tools/inspector/web.md#deep-links).
147147
148148> [!NOTE]
149149>
docs/draft/tools/inspector/cli Changed · +7 / -7 lines
from line 12
1212>
1313> Running several commands against the same server, or a flow that spans one
1414> session (tasks, subscriptions, elicitation)? The [mcpdo connection
15> client](/docs/draft/tools/inspector/mcpdo.md) connects once and keeps the
15> client](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md) connects once and keeps the
1616> connection open between commands.
1717
1818The examples below use the installed `mcp-inspector` binary. Without a global install, prefix each command with `npx @modelcontextprotocol/inspector` instead, as above.
from line 32
3232mcp-inspector --cli --config ./mcp.json --server myserver --method tools/list
3333```
3434
35When the server comes from a file, its per-server settings (headers, timeouts, OAuth, [protocol era](/docs/draft/tools/inspector/protocol-eras.md), and roots) apply to the connection, resolved exactly as the TUI and web client resolve them. A `--header` flag overrides the file's headers for that run while leaving its timeouts and OAuth in place.
35When the server comes from a file, its per-server settings (headers, timeouts, OAuth, [protocol era](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md), and roots) apply to the connection, resolved exactly as the TUI and web client resolve them. A `--header` flag overrides the file's headers for that run while leaving its timeouts and OAuth in place.
3636
3737Later examples abbreviate whichever of these forms you use, along with its `--transport` or `--config`/`--server` flags, as `<server>`.
3838
from line 39
3939> [!NOTE]
4040>
4141> **The config file is the only durable way to give a run its
42> [roots](/specification/draft/client/roots.md):** there is no roots flag, and the
42> [roots](https://modelcontextprotocol.io/specification/draft/client/roots.md):** there is no roots flag, and the
4343> CLI has no `roots/set` method. Roots configured for a server are advertised at
4444> connect, so a server that calls `roots/list` (as
4545> `@modelcontextprotocol/server-filesystem` does, to learn its allowed
4646> directories) gets them.
4747
48See [Configuration and flags](/docs/draft/tools/inspector/configuration.md) for `--catalog` vs. `--config`, the `--` separator, and the shared server-selection flags.
48See [Configuration and flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md) for `--catalog` vs. `--config`, the `--` separator, and the shared server-selection flags.
4949
5050## Methods
5151
from line 97
9797
9898## Probing MCP Apps
9999
100`--app-info` reports whether a tool ships an [MCP App](/extensions/apps/overview.md) UI (its `ui://` resource, CSP, and permissions) **without calling the tool**, so a pipeline can decide whether it needs a browser before invoking anything:
100`--app-info` reports whether a tool ships an [MCP App](https://modelcontextprotocol.io/extensions/apps/overview.md) UI (its `ui://` resource, CSP, and permissions) **without calling the tool**, so a pipeline can decide whether it needs a browser before invoking anything:
101101
102102```bash theme={null}
103103# One tool -> one JSON line
from line 163
163163
164164Without either, and with no TTY on stdin or stderr, the CLI fails fast with `auth_required` rather than hanging for fifteen minutes on a callback nobody will complete.
165165
166See [Authorization](/docs/draft/tools/inspector/authorization.md) for the full flow, the web-to-CLI handoff, and `--print-handoff`.
166See [Authorization](https://modelcontextprotocol.io/docs/draft/tools/inspector/authorization.md) for the full flow, the web-to-CLI handoff, and `--print-handoff`.
167167
168168## Recipes
169169
from line 228
228228
229229### Editing the catalog
230230
231`servers/add`, `servers/edit`, and `servers/remove` write the catalog without connecting to anything. They go through the same code as the web client's server list, so `env` values and client secrets land in the [secret store](/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored) exactly as they would from the UI, and a running web client picks up the change.
231`servers/add`, `servers/edit`, and `servers/remove` write the catalog without connecting to anything. They go through the same code as the web client's server list, so `env` values and client secrets land in the [secret store](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored) exactly as they would from the UI, and a running web client picks up the change.
232232
233233```bash theme={null}
234234# Add: the positional target or --server-url describes the entry, not a server to connect to
docs/draft/tools/inspector/configuration Changed · +13 / -13 lines
from line 16
1616> [!NOTE]
1717>
1818> The package also installs a second, separate bin, `mcpdo`, the experimental
19> [connection client](/docs/draft/tools/inspector/mcpdo.md). It is not reached
19> [connection client](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md). It is not reached
2020> through the launcher and takes no mode flag.
2121
2222## Choosing servers
from line 93
9393| `--cwd <path>` | Working directory for a stdio server process. | None |
9494| `-e <KEY=VALUE>` | Environment variables for a stdio server. Repeatable. | None |
9595| `--header "Name: Value"` | HTTP headers for an HTTP/SSE server. Repeatable. | Requires an ad-hoc HTTP/SSE server on the web client. |
96| `--protocol-era <era>` | `legacy`, `auto`, or `modern`: the [protocol era](/docs/draft/tools/inspector/protocol-eras.md) to negotiate. | Requires an ad-hoc target on the web client. The CLI and TUI also let it override a file's `protocolEra`. |
96| `--protocol-era <era>` | `legacy`, `auto`, or `modern`: the [protocol era](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md) to negotiate. | Requires an ad-hoc target on the web client. The CLI and TUI also let it override a file's `protocolEra`. |
9797| `--skill-catalog-max-skills <n>` / `--skill-catalog-max-bytes <n>` | Budget for a skills verification run (most skills, most bytes read). | **CLI and TUI only.** Overrides the file's `skillCatalogMaxSkills` / `skillCatalogMaxBytes`. |
9898| `[target...]` | Positional command/URL for one ad-hoc server. | None |
9999
from line 133
133133
134134## CLI-only flags
135135
136The whole scripting surface belongs to the CLI. See [CLI client](/docs/draft/tools/inspector/cli.md) for usage.
136The whole scripting surface belongs to the CLI. See [CLI client](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md) for usage.
137137
138138| Group | Flags |
139139| - | - |
from line 149
149149
150150| Variable | Effect |
151151| - | - |
152| `MCP_DEBUG` | Append the error stack to a top-level `--web` or `--tui` failure (a `--cli` failure always prints its [JSON error envelope](/docs/draft/tools/inspector/cli.md#exit-codes-and-error-envelopes) instead). Only when set to a meaningful value: `0`, `false`, and empty read as off. |
152| `MCP_DEBUG` | Append the error stack to a top-level `--web` or `--tui` failure (a `--cli` failure always prints its [JSON error envelope](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md#exit-codes-and-error-envelopes) instead). Only when set to a meaningful value: `0`, `false`, and empty read as off. |
153153| `DEBUG` | Same, with the same meaningful-value rule, so a stray `DEBUG=0` doesn't turn stack traces on and `DEBUG` still works as the npm `debug` package's namespace filter. |
154154
155155### CLI and TUI
from line 169
169169
170170| Variable | Effect |
171171| - | - |
172| `MCP_INSPECTOR_API_TOKEN` | Pin the [session token](/docs/draft/tools/inspector/web.md#the-session-token) instead of generating a random one per launch. |
172| `MCP_INSPECTOR_API_TOKEN` | Pin the [session token](https://modelcontextprotocol.io/docs/draft/tools/inspector/web.md#the-session-token) instead of generating a random one per launch. |
173173| `DANGEROUSLY_OMIT_AUTH` | Disable the `/api/*` token check entirely. Only `true` or `1` turn it off. |
174174| `HOST` | Bind host. Defaults to `127.0.0.1`. |
175175| `CLIENT_PORT` | Web UI port. Defaults to `6274`. |
from line 192
192192> The web backend spawns processes and holds OAuth tokens, so anyone who can
193193> reach it can drive it.
194194
195What the token does and does not protect is laid out under [The web backend and its API token](/docs/draft/tools/inspector/security.md#the-web-backend-and-its-api-token).
195What the token does and does not protect is laid out under [The web backend and its API token](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#the-web-backend-and-its-api-token).
196196
197197### Secret store variables
198198
199Read by **every** client: web, CLI, TUI, and [mcpdo](/docs/draft/tools/inspector/mcpdo.md). How they combine is described under [Where secrets are stored](#where-secrets-are-stored).
199Read by **every** client: web, CLI, TUI, and [mcpdo](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md). How they combine is described under [Where secrets are stored](#where-secrets-are-stored).
200200
201201| Variable | Effect |
202202| - | - |
from line 245
245245> * **Encrypt the file:** supply a generated key with `MCP_INSPECTOR_SECRET_KEY_FILE` (preferred) or `MCP_INSPECTOR_SECRET_KEY`.
246246> * **Don't write secrets to disk at all:** `MCP_INSPECTOR_SECRET_STORE=memory`, and re-enter them each session.
247247>
248> Even encrypted, secrets on disk carry moderate risk. See [what the file store protects against](/docs/draft/tools/inspector/security.md#what-the-file-store-protects-against).
248> Even encrypted, secrets on disk carry moderate risk. See [what the file store protects against](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#what-the-file-store-protects-against).
249249
250[mcpdo](/docs/draft/tools/inspector/mcpdo.md) never falls back to `memory`: its commands and its daemon are separate processes, so it uses the file store instead.
250[mcpdo](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md) never falls back to `memory`: its commands and its daemon are separate processes, so it uses the file store instead.
251251
252252### The file store
253253
from line 292
292292}
293293```
294294
295Fields that equal their default are omitted when the Inspector writes the file back, keeping diffs minimal. `protocolEra` (see [Protocol eras](/docs/draft/tools/inspector/protocol-eras.md)) defaults to `legacy` and `modernLogLevel` to `debug`.
295Fields that equal their default are omitted when the Inspector writes the file back, keeping diffs minimal. `protocolEra` (see [Protocol eras](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md)) defaults to `legacy` and `modernLogLevel` to `debug`.
296296
297You do not have to hand-write these; the web client can [import an existing client config](/docs/draft/tools/inspector/recipes.md#importing-an-existing-client-config) from Claude Desktop, Cursor, Cline, or VS Code, or a registry `server.json`.
297You do not have to hand-write these; the web client can [import an existing client config](https://modelcontextprotocol.io/docs/draft/tools/inspector/recipes.md#importing-an-existing-client-config) from Claude Desktop, Cursor, Cline, or VS Code, or a registry `server.json`.
298298
docs/draft/tools/inspector/mcpdo Changed · +6 / -6 lines
from line 2
22
33> Connect to an MCP server once, then run many commands against that named connection
44
5`mcpdo` is an **experimental** command-line client that ships in the `@modelcontextprotocol/inspector` package alongside `mcp-inspector`. Where the [CLI client](/docs/draft/tools/inspector/cli.md) connects, runs one `--method` and disconnects, `mcpdo` **connects once** and keeps the connection open, so you can run many commands against it from any shell, the way `ssh-agent` keeps keys loaded.
5`mcpdo` is an **experimental** command-line client that ships in the `@modelcontextprotocol/inspector` package alongside `mcp-inspector`. Where the [CLI client](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md) connects, runs one `--method` and disconnects, `mcpdo` **connects once** and keeps the connection open, so you can run many commands against it from any shell, the way `ssh-agent` keeps keys loaded.
66
77| | `mcp-inspector --cli` | `mcpdo` |
88| - | - | - |
from line 10
1010| **State** | None between runs | Named connections held by a daemon |
1111| **Best for** | CI assertions, one JSON blob per run | Exploring a server, agent tool use, multi-step flows over one session (tasks, subscriptions, elicitation) |
1212
13Connections are held by a local background daemon, `mcpdod`, which `mcpdo` starts on demand and stops after its last connection closes. You never start it by hand. What it exposes, and how it is protected, is described under [The mcpdo connection daemon](/docs/draft/tools/inspector/security.md#the-mcpdo-connection-daemon).
13Connections are held by a local background daemon, `mcpdod`, which `mcpdo` starts on demand and stops after its last connection closes. You never start it by hand. What it exposes, and how it is protected, is described under [The mcpdo connection daemon](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#the-mcpdo-connection-daemon).
1414
1515Watch the [mcpdo tutorial video](https://www.youtube.com/watch?v=_a6eG0y156k).
1616
from line 51
5151mcpdo connect node build/index.js # ad-hoc stdio server
5252```
5353
54The catalog and `--config` behave exactly as for the other clients (see [Configuration and flags](/docs/draft/tools/inspector/configuration.md#choosing-servers)): the default catalog is `~/.mcp-inspector/mcp.json`, overridable with `--catalog` or `MCP_CATALOG_PATH`. `servers/list` and `servers/show <name>` read entries from disk. `connections/*` shows what the daemon currently holds. There are no commands to edit the catalog; edit the file directly.
54The catalog and `--config` behave exactly as for the other clients (see [Configuration and flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#choosing-servers)): the default catalog is `~/.mcp-inspector/mcp.json`, overridable with `--catalog` or `MCP_CATALOG_PATH`. `servers/list` and `servers/show <name>` read entries from disk. `connections/*` shows what the daemon currently holds. There are no commands to edit the catalog; edit the file directly.
5555
5656A stdio server runs with the working directory and command resolution of the shell that ran `connect`, not of the daemon, so relative paths and bare command names mean what you would expect.
5757
from line 111
111111
112112When a browser sign-in is needed and neither stdin nor stderr is a TTY (and `MCP_AUTO_OPEN_ENABLED` is not forced on), `connect` exits `0` immediately with `pendingAuth: true` and an `authUrl`. Relay that URL to whoever will sign in. The connection completes on its own once they do: the next real command against it finishes the connection, and `connections/list` reports `pendingAuthSignedIn` in the meantime. Don't reconnect to fix a pending sign-in.
113113
114On a host with no OS keychain, `mcpdo` stores tokens in the shared `secrets.json` file, never in memory, because its commands and the daemon are separate processes. That file is plaintext unless you supply a key; see [Where secrets are stored](/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored).
114On a host with no OS keychain, `mcpdo` stores tokens in the shared `secrets.json` file, never in memory, because its commands and the daemon are separate processes. That file is plaintext unless you supply a key; see [Where secrets are stored](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored).
115115
116116## Elicitation
117117
from line 131
131131
132132## Protocol eras
133133
134`mcpdo` negotiates the same [protocol eras](/docs/draft/tools/inspector/protocol-eras.md) as the other clients. `connect --era legacy|auto|modern` overrides a catalog entry's `protocolEra`, and is the only way to set it for an ad-hoc target. `connections/list` tags each connection `[legacy]` or `[modern]`, and `connections/show <name>` gives the negotiated version, server info, capabilities, and the supported-versions list when the server was probed.
134`mcpdo` negotiates the same [protocol eras](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md) as the other clients. `connect --era legacy|auto|modern` overrides a catalog entry's `protocolEra`, and is the only way to set it for an ad-hoc target. `connections/list` tags each connection `[legacy]` or `[modern]`, and `connections/show <name>` gives the negotiated version, server info, capabilities, and the supported-versions list when the server was probed.
135135
136136## The daemon
137137
from line 159
159159
160160## Environment variables
161161
162`mcpdo` reads the same catalog, storage and secret-store variables as the other clients (see [Environment variables](/docs/draft/tools/inspector/configuration.md#environment-variables)), plus these:
162`mcpdo` reads the same catalog, storage and secret-store variables as the other clients (see [Environment variables](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#environment-variables)), plus these:
163163
164164| Variable | Effect |
165165| - | - |
docs/draft/tools/inspector/protocol-eras Changed · +5 / -5 lines
from line 115
115115
116116**Modern**
117117
118Tasks are an **extension** (`io.modelcontextprotocol/tasks`, [SEP-2663](/seps/2663-tasks-extension.md)), so the tab is gated on the server *advertising that extension* rather than on `capabilities.tasks`.
118Tasks are an **extension** (`io.modelcontextprotocol/tasks`, [SEP-2663](https://modelcontextprotocol.io/seps/2663-tasks-extension.md)), so the tab is gated on the server *advertising that extension* rather than on `capabilities.tasks`.
119119
120120Run a tool as a task and `tools/call` returns a `CreateTaskResult` (`resultType: "task"`, visible in the Protocol and Network tabs). The Inspector polls **`tasks/get`** only; there is no `tasks/list`, so **Refresh** re-polls the handles the client already knows about. A completed task **inlines its result**, with no blocking `tasks/result` call.
121121
122A task that needs more information moves to `input_required` and surfaces an embedded [elicitation](/specification/draft/client/elicitation.md) in the pending-request modal (the dialog the web client opens whenever a request is waiting on you). Answering it sends **`tasks/update`** carrying the `inputResponses`, and the next poll completes.
122A task that needs more information moves to `input_required` and surfaces an embedded [elicitation](https://modelcontextprotocol.io/specification/draft/client/elicitation.md) in the pending-request modal (the dialog the web client opens whenever a request is waiting on you). Answering it sends **`tasks/update`** carrying the `inputResponses`, and the next poll completes.
123123
124124Reproduce with `test-servers/configs/tasks-modern-http.json` (tools `modern_task` and `modern_input_task`).
125125
from line 135
135135
136136## Multi-round tool results (MRTR)
137137
138On the modern era a tool can return `input_required` instead of a final result, embedding an [elicitation](/specification/draft/client/elicitation.md), a [sampling](/specification/draft/client/sampling.md) request, or a [`roots/list`](/specification/draft/client/roots) request. The client answers that embedded request and retries the `tools/call` under a fresh JSON-RPC id until the call reaches `complete`.
138On the modern era a tool can return `input_required` instead of a final result, embedding an [elicitation](https://modelcontextprotocol.io/specification/draft/client/elicitation.md), a [sampling](https://modelcontextprotocol.io/specification/draft/client/sampling.md) request, or a [`roots/list`](https://modelcontextprotocol.io/specification/draft/client/roots) request. The client answers that embedded request and retries the `tools/call` under a fresh JSON-RPC id until the call reaches `complete`.
139139
140140The Inspector drives MRTR **manually**, so each round pauses at the **pending-request modal**, tagged `input_required`, for you to answer. The Protocol view groups the whole exchange as one MRTR conversation rather than as unrelated calls.
141141
from line 170
170170
171171## Tools: mirrored headers and excluded tools
172172
173[SEP-2243](/seps/2243-http-standardization.md) lets a tool annotate an argument with `x-mcp-header`, asking a Streamable HTTP client to mirror that argument's value into an `Mcp-Param-*` request header.
173[SEP-2243](https://modelcontextprotocol.io/seps/2243-http-standardization.md) lets a tool annotate an argument with `x-mcp-header`, asking a Streamable HTTP client to mirror that argument's value into an `Mcp-Param-*` request header.
174174
175175The Inspector surfaces both halves of that contract in the **Tools** tab:
176176
from line 203
203203
204204## Network and Protocol: headers and the error taxonomy
205205
206The modern era standardizes a set of `Mcp-*` HTTP headers and introduces a richer JSON-RPC error taxonomy ([SEP-2243](/seps/2243-http-standardization.md) / [SEP-2575](/seps/2575-stateless-mcp.md)). The two monitoring tabs divide the work:
206The modern era standardizes a set of `Mcp-*` HTTP headers and introduces a richer JSON-RPC error taxonomy ([SEP-2243](https://modelcontextprotocol.io/seps/2243-http-standardization.md) / [SEP-2575](https://modelcontextprotocol.io/seps/2575-stateless-mcp.md)). The two monitoring tabs divide the work:
207207
208208* The **Network** tab is the HTTP view: mirrored `Mcp-*` headers are highlighted and sentinel values decoded.
209209* The **Protocol** tab is the JSON-RPC view: each spec error renders distinctly rather than as a generic failure.
docs/draft/tools/inspector/recipes Changed · +17 / -17 lines
from line 31
3131 --header "X-Tenant: acme"
3232```
3333
34`--transport` accepts `http` (Streamable HTTP) and `sse`. If the server is protected, see [Authorization](/docs/draft/tools/inspector/authorization.md): no setup is needed in advance, because when the server answers `401` the Inspector runs the OAuth flow described there and retries the connection.
34`--transport` accepts `http` (Streamable HTTP) and `sse`. If the server is protected, see [Authorization](https://modelcontextprotocol.io/docs/draft/tools/inspector/authorization.md): no setup is needed in advance, because when the server answers `401` the Inspector runs the OAuth flow described there and retries the connection.
3535
36For an HTTP server, also decide its [protocol era](/docs/draft/tools/inspector/protocol-eras.md). The default is `legacy`; set `modern` or `auto` in Server Settings (or `protocolEra` in the catalog file) to exercise the 2026-07-28 behavior. For an ad-hoc target, pass it at launch with `--protocol-era legacy|auto|modern`.
36For an HTTP server, also decide its [protocol era](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md). The default is `legacy`; set `modern` or `auto` in Server Settings (or `protocolEra` in the catalog file) to exercise the 2026-07-28 behavior. For an ad-hoc target, pass it at launch with `--protocol-era legacy|auto|modern`.
3737
3838## Importing an existing client config
3939
4040On the Servers screen, **Add Servers** can import MCP servers you have already configured
4141elsewhere instead of retyping them. It parses Claude Desktop, Cursor, Cline, and VS Code client
42configs directly, and it also reads a server's own [MCP Registry](/registry/about.md) `server.json`.
42configs directly, and it also reads a server's own [MCP Registry](https://modelcontextprotocol.io/registry/about.md) `server.json`.
4343
44Import merges into the active [catalog](/docs/draft/tools/inspector/configuration.md#choosing-servers)
44Import merges into the active [catalog](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#choosing-servers)
4545(the Inspector's writable server list). When an imported server's id is already taken, you
4646choose whether to overwrite, skip or rename it. If you'd rather
4747not touch your catalog at all, launch against the foreign file read-only instead:
from line 58
5858
5959## Reviewing an MCP App
6060
61[MCP Apps](/extensions/apps/overview.md) are tools that carry a UI widget. For an automated reviewer (CI or an agent), use the CLI for every check that returns JSON, and open a browser only to inspect the rendered widget.
61[MCP Apps](https://modelcontextprotocol.io/extensions/apps/overview.md) are tools that carry a UI widget. For an automated reviewer (CI or an agent), use the CLI for every check that returns JSON, and open a browser only to inspect the rendered widget.
6262
6363**1. Probe the security posture without calling the tool**
6464
from line 109
109109http://127.0.0.1:6274/?serverUrl=<encoded url>&transport=http&autoConnect=<TOKEN>&openApp=<tool>&appArgs=<base64url(JSON)>&autoOpen=<TOKEN>
110110```
111111
112`appArgs` is the tool's arguments as base64url-encoded JSON, and every deep-link parameter is described under [Deep links](/docs/draft/tools/inspector/web.md#deep-links). `autoConnect` and `autoOpen` must both equal the session token, since `autoOpen` fires a tool call straight from the URL and needs the same gate as `autoConnect`.
112`appArgs` is the tool's arguments as base64url-encoded JSON, and every deep-link parameter is described under [Deep links](https://modelcontextprotocol.io/docs/draft/tools/inspector/web.md#deep-links). `autoConnect` and `autoOpen` must both equal the session token, since `autoOpen` fires a tool call straight from the URL and needs the same gate as `autoConnect`.
113113
114114**5. Wait on a deterministic signal instead of sleeping**
115115
from line 129
129129docker run --rm -p 127.0.0.1:6274:6274 ghcr.io/modelcontextprotocol/inspector
130130```
131131
132Read the [session token](/docs/draft/tools/inspector/web.md#the-session-token) from the container logs, or pin it with `-e MCP_INSPECTOR_API_TOKEN=<value>`.
132Read the [session token](https://modelcontextprotocol.io/docs/draft/tools/inspector/web.md#the-session-token) from the container logs, or pin it with `-e MCP_INSPECTOR_API_TOKEN=<value>`.
133133
134134The image defaults to `--web`, bound to `0.0.0.0:6274` with browser auto-open off, and runs as the non-root `node` user (uid `1000`). It sets `DANGEROUSLY_BIND_ALL_INTERFACES=true` because a container must bind the wildcard address to be reachable through `-p`.
135135
from line 140
140140> processes, and the page that discloses its token, on your local network. The
141141> image's `DANGEROUSLY_BIND_ALL_INTERFACES` covers the container's interfaces,
142142> not the host's. See [Publish the port on loopback
143> only](/docs/draft/tools/inspector/security.md#publish-the-port-on-loopback-only).
143> only](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#publish-the-port-on-loopback-only).
144144
145145To use the **Apps** tab, also publish the MCP Apps sandbox port, `6275`, and `6278` for an app that declares `_meta.ui.domain`. Publish each on the same port number inside and out, since the browser is handed the in-container port:
146146
from line 179
179179> (umask 077 && openssl rand -base64 32 > ~/.config/mcp-inspector/secret-key)
180180> ```
181181>
182> Even encrypted, secrets on disk carry moderate risk. See [what the file store protects against](/docs/draft/tools/inspector/security.md#what-the-file-store-protects-against).
182> Even encrypted, secrets on disk carry moderate risk. See [what the file store protects against](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#what-the-file-store-protects-against).
183183
184184Hand the key to the container **as a file** with `MCP_INSPECTOR_SECRET_KEY_FILE`, not as an environment variable. A key passed with `-e MCP_INSPECTOR_SECRET_KEY=…` is readable by anyone who can run `docker inspect` or `docker exec`.
185185
from line 213
213213
214214Without Swarm, Compose secrets are bind mounts that keep the host file's owner and mode, so the `0600` key file must be owned by uid `1000`. On a Linux host where your uid is different, run `sudo chown 1000 ~/.config/mcp-inspector/secret-key` rather than loosening its mode. Supply the **same** key on every run.
215215
216If the key file is missing, unreadable or empty, or both key variables are set, the Inspector **refuses to read or write the secrets file** rather than falling back to plaintext, and says why in the log and in the settings dialogs' footer. Everything else about the store (selection order, location, permissions) is under [Where secrets are stored](/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored).
216If the key file is missing, unreadable or empty, or both key variables are set, the Inspector **refuses to read or write the secrets file** rather than falling back to plaintext, and says why in the log and in the settings dialogs' footer. Everything else about the store (selection order, location, permissions) is under [Where secrets are stored](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored).
217217
218218### Health checks and other modes
219219
220220The image's `HEALTHCHECK` probes the web UI at the address `HOST` binds. `--cli` and `--tui` have no web server, so the probe detects those modes from the container's arguments and reports healthy while they run. An external orchestrator (a Kubernetes probe, a Compose `healthcheck`) can call `GET /healthz` on the web port, which needs no token and returns only `{"status":"ok"}`.
221221
222`<target>` below is an [ad-hoc target](/docs/draft/tools/inspector/configuration.md#ad-hoc-targets): a positional stdio command, or `--server-url <url> --transport http`.
222`<target>` below is an [ad-hoc target](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#ad-hoc-targets): a positional stdio command, or `--server-url <url> --transport http`.
223223
224224```bash theme={null}
225225docker run --rm ghcr.io/modelcontextprotocol/inspector --cli <target> --method tools/list
from line 261
261261* **Behind TLS or a reverse proxy, give MCP Apps their public addresses.** By default the sandbox is advertised as `http://<bind host>:6275`, which an `https://` page blocks as mixed content. Set `MCP_SANDBOX_FULL_ADDRESS` (for example `https://inspector-sandbox.example.com/sandbox`) and, for apps that declare `_meta.ui.domain`, `MCP_APP_ORIGIN_FULL_ADDRESS` (for example `https://inspector-apps.example.com`). Each needs its own hostname or port; an address that shares the Inspector's origin is refused.
262262* **MCP Apps can't render at a bare IPv6 literal.** A bracketed IPv6 literal isn't a valid CSP host-source, so browse at a name or an IPv4 address.
263263
264Whatever the shape: keep authentication on. Do not set `DANGEROUSLY_OMIT_AUTH` on anything reachable by anyone but you. The reasoning is under [Security](/docs/draft/tools/inspector/security.md#the-web-backend-and-its-api-token).
264Whatever the shape: keep authentication on. Do not set `DANGEROUSLY_OMIT_AUTH` on anything reachable by anyone but you. The reasoning is under [Security](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#the-web-backend-and-its-api-token).
265265
266266## Keeping a connection open with mcpdo
267267
268When an exploration spans many calls (a multi-step flow over one session, a log you watch, an agent using a server's tools mid-session), reconnecting for every `--cli` invocation gets in the way. [mcpdo](/docs/draft/tools/inspector/mcpdo.md) holds the connection for you:
268When an exploration spans many calls (a multi-step flow over one session, a log you watch, an agent using a server's tools mid-session), reconnecting for every `--cli` invocation gets in the way. [mcpdo](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md) holds the connection for you:
269269
270270```bash theme={null}
271271mcpdo connect my-server
from line 277
277277
278278A connection runs one call at a time, so commands against the same connection from other shells wait their turn.
279279
280The daemon that holds the connection starts automatically and exits about a minute after the last connection closes. Read [The mcpdo connection daemon](/docs/draft/tools/inspector/security.md#the-mcpdo-connection-daemon) before using it on a shared machine.
280The daemon that holds the connection starts automatically and exits about a minute after the last connection closes. Read [The mcpdo connection daemon](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#the-mcpdo-connection-daemon) before using it on a shared machine.
281281
282282## Development workflow
283283
from line 305
305305Turn what you found into a CI assertion: pipe the CLI's `--format json`
306306output to `jq -e` with `--stored-auth-only`, so a missing token fails fast
307307instead of starting interactive OAuth. See [Verify a server in
308CI](/docs/draft/tools/inspector/cli.md#verify-a-server-in-ci) for the full
308CI](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md#verify-a-server-in-ci) for the full
309309command.
310310
docs/draft/tools/inspector/security Changed · +6 / -6 lines
from line 13
1313
1414## The web backend and its API token
1515
16The web client is a browser app backed by a Node server that owns the MCP connections. That server can start stdio processes on request, so every `/api/*` route requires a per-launch bearer token (`x-mcp-remote-auth: Bearer <token>`). How the browser obtains it is described under [The session token](/docs/draft/tools/inspector/web.md#the-session-token).
16The web client is a browser app backed by a Node server that owns the MCP connections. That server can start stdio processes on request, so every `/api/*` route requires a per-launch bearer token (`x-mcp-remote-auth: Bearer <token>`). How the browser obtains it is described under [The session token](https://modelcontextprotocol.io/docs/draft/tools/inspector/web.md#the-session-token).
1717
1818What the token does and does not protect:
1919
from line 24
2424
2525### Where the backend listens
2626
27The backend binds `127.0.0.1` by default. Binding every interface (`0.0.0.0`, `::` and equivalent spellings) is refused unless you set `DANGEROUSLY_BIND_ALL_INTERFACES=true`. Binding one specific address is allowed without that opt-in, because it is one deliberate exposure rather than all of them at once. See [Hosting on a network](/docs/draft/tools/inspector/recipes.md#hosting-on-a-network).
27The backend binds `127.0.0.1` by default. Binding every interface (`0.0.0.0`, `::` and equivalent spellings) is refused unless you set `DANGEROUSLY_BIND_ALL_INTERFACES=true`. Binding one specific address is allowed without that opt-in, because it is one deliberate exposure rather than all of them at once. See [Hosting on a network](https://modelcontextprotocol.io/docs/draft/tools/inspector/recipes.md#hosting-on-a-network).
2828
2929> [!WARNING]
3030>
from line 34
3434
3535## Docker
3636
37The [Docker image](/docs/draft/tools/inspector/recipes.md#docker) changes two things about the picture above.
37The [Docker image](https://modelcontextprotocol.io/docs/draft/tools/inspector/recipes.md#docker) changes two things about the picture above.
3838
3939### Publish the port on loopback only
4040
from line 57
5757
5858The Inspector keeps credentials out of `mcp.json`, `client.json` and `oauth.json` so that sharing, committing or syncing those files does not leak them. These are stored as secrets:
5959
60* acquired OAuth tokens (access, refresh and ID tokens), subject to [`MCP_INSPECTOR_PERSIST_TOKENS`](/docs/draft/tools/inspector/configuration#secret-store-variables), and IdP session tokens from enterprise-managed authorization;
60* acquired OAuth tokens (access, refresh and ID tokens), subject to [`MCP_INSPECTOR_PERSIST_TOKENS`](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration#secret-store-variables), and IdP session tokens from enterprise-managed authorization;
6161* each server's OAuth client secret, and the enterprise IdP client secret;
6262* dynamically registered client secrets and their registration access tokens;
6363* each stdio server's `env:` values.
from line 64
6464
6565**`headers` are not secrets.** They are saved in `mcp.json` exactly as written, so a header that carries a credential (an API key, a static `Authorization` value) stays in the file.
6666
67How the store is selected, and how to change it, is under [Where secrets are stored](/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored). This section covers the risks.
67How the store is selected, and how to change it, is under [Where secrets are stored](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored). This section covers the risks.
6868
6969### The automatic plaintext fallback
7070
from line 123
123123
124124## The mcpdo connection daemon
125125
126[mcpdo](/docs/draft/tools/inspector/mcpdo.md) keeps connections open between commands by handing them to a background daemon, `mcpdod`. It is started **automatically** the first time a command needs it (`mcpdo connect`, or any command against a connection). There is no separate "start the daemon" step to opt into. This section describes what that process exposes.
126[mcpdo](https://modelcontextprotocol.io/docs/draft/tools/inspector/mcpdo.md) keeps connections open between commands by handing them to a background daemon, `mcpdod`. It is started **automatically** the first time a command needs it (`mcpdo connect`, or any command against a connection). There is no separate "start the daemon" step to opt into. This section describes what that process exposes.
127127
128128### How clients reach it, and who else can
129129
docs/draft/tools/inspector/tui Changed · +6 / -6 lines
from line 21
2121mcp-inspector --tui --config mcp.json # read-only session, errors if absent
2222```
2323
24With neither `--catalog` nor `--config`, and no [ad-hoc target](/docs/draft/tools/inspector/configuration.md#ad-hoc-targets), it uses the default writable catalog `~/.mcp-inspector/mcp.json`. See [Configuration and flags](/docs/draft/tools/inspector/configuration.md).
24With neither `--catalog` nor `--config`, and no [ad-hoc target](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#ad-hoc-targets), it uses the default writable catalog `~/.mcp-inspector/mcp.json`. See [Configuration and flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md).
2525
26The TUI also takes the [shared server-selection flags](/docs/draft/tools/inspector/configuration.md#shared-server-selection-flags) (`--server-url`, `--transport`, `--header`, `-e`, `--cwd`) plus `--protocol-era` for an ad-hoc server, and the [OAuth client flags](/docs/draft/tools/inspector/configuration.md#cli-and-tui-oauth-client-flags) (`--client-id`, `--client-secret`, `--client-metadata-url`, `--client-config`, `--callback-url`).
26The TUI also takes the [shared server-selection flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#shared-server-selection-flags) (`--server-url`, `--transport`, `--header`, `-e`, `--cwd`) plus `--protocol-era` for an ad-hoc server, and the [OAuth client flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#cli-and-tui-oauth-client-flags) (`--client-id`, `--client-secret`, `--client-metadata-url`, `--client-config`, `--callback-url`).
2727
2828## Tabs
2929
from line 38
3838| **Tools** | `t` | View tools and execute them with form-like inputs. |
3939| **Tasks** | `s` | List tasks, fetch their results, cancel them, and clear finished ones (servers that support Tasks). |
4040| **Protocol** | `p` | JSON-RPC request/response/notification history. |
41| **Network** | `n` | HTTP traffic for SSE and [Streamable HTTP](/specification/latest/basic/transports.md) servers. |
41| **Network** | `n` | HTTP traffic for SSE and [Streamable HTTP](https://modelcontextprotocol.io/specification/latest/basic/transports.md) servers. |
4242| **Console** | `o` | `stderr` from a connected stdio server process. |
4343
4444The accelerators avoid collisions rather than always taking the first letter: **P**rotocol takes `p` so Pro**m**pts takes `m`, and **C**onsole takes `o` because `c` is the global Connect action. Ta**s**ks takes `s`, its only free letter, so Subscriptions takes `u` and Skills takes `k`.
from line 70
70703. When the browser redirect lands on the TUI's loopback listener, the connection finishes on its own, with no second **`c`**.
71714. Use the **Auth** tab to inspect the resulting OAuth state, or to clear it.
7272
73The TUI's callback listener defaults to `http://127.0.0.1:6276/oauth/callback`. The port is fixed on purpose: a pre-registered (static) OAuth client, a [Client ID Metadata Document (CIMD)](/specification/latest/basic/authorization/client-registration.md#client-id-metadata-documents), or an enterprise-managed IdP all need a redirect URI known in advance. Register that URI once and it works across sessions. On a remote host where your browser is on another machine, forward the callback port so the redirect reaches this listener; see [Callback URLs](/docs/draft/tools/inspector/authorization.md#callback-urls).
73The TUI's callback listener defaults to `http://127.0.0.1:6276/oauth/callback`. The port is fixed on purpose: a pre-registered (static) OAuth client, a [Client ID Metadata Document (CIMD)](https://modelcontextprotocol.io/specification/latest/basic/authorization/client-registration.md#client-id-metadata-documents), or an enterprise-managed IdP all need a redirect URI known in advance. Register that URI once and it works across sessions. On a remote host where your browser is on another machine, forward the callback port so the redirect reaches this listener; see [Callback URLs](https://modelcontextprotocol.io/docs/draft/tools/inspector/authorization.md#callback-urls).
7474
7575The trade-off is that only one TUI OAuth flow can hold the port at a time; a second concurrent flow fails with `EADDRINUSE`. To override it, pass `--callback-url` or set `MCP_OAUTH_CALLBACK_URL`: use a different fixed port per instance, or `http://127.0.0.1:0/oauth/callback` for an OS-assigned ephemeral port when your authorization server registers redirect URIs dynamically.
7676
from line 81
8181
8282Per-server OAuth fields in the catalog (static client id/secret, scopes, the enterprise-managed flag) are applied automatically. Install-wide settings (CIMD, enterprise IdP) come from `~/.mcp-inspector/storage/client.json`, the same file the web client's **Client Settings** dialog writes. Point at a different one with `--client-config` or `MCP_CLIENT_CONFIG_PATH`.
8383
84See [Authorization](/docs/draft/tools/inspector/authorization.md) for the full picture.
84See [Authorization](https://modelcontextprotocol.io/docs/draft/tools/inspector/authorization.md) for the full picture.
8585
8686
8787
from line 89
8989
9090## Requirements
9191
92The TUI needs a real TTY with raw-mode support. It will not run usefully in a headless CI job; use the [CLI](/docs/draft/tools/inspector/cli.md) there.
92The TUI needs a real TTY with raw-mode support. It will not run usefully in a headless CI job; use the [CLI](https://modelcontextprotocol.io/docs/draft/tools/inspector/cli.md) there.
9393
docs/draft/tools/inspector/web Changed · +15 / -15 lines
from line 20
20202. A `?MCP_INSPECTOR_API_TOKEN=...` query string, the form used in that printed URL.
21213. `sessionStorage`, as a backstop.
2222
23Set the `MCP_INSPECTOR_API_TOKEN` environment variable to pin a known token (useful for scripted launches), or set `DANGEROUSLY_OMIT_AUTH=true` to disable the check entirely, but only on a machine where nothing else can reach the port. Both are described under [Web backend environment variables](/docs/draft/tools/inspector/configuration.md#web-backend-environment-variables). What the token does and does not protect is described under [Security](/docs/draft/tools/inspector/security.md#the-web-backend-and-its-api-token).
23Set the `MCP_INSPECTOR_API_TOKEN` environment variable to pin a known token (useful for scripted launches), or set `DANGEROUSLY_OMIT_AUTH=true` to disable the check entirely, but only on a machine where nothing else can reach the port. Both are described under [Web backend environment variables](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#web-backend-environment-variables). What the token does and does not protect is described under [Security](https://modelcontextprotocol.io/docs/draft/tools/inspector/security.md#the-web-backend-and-its-api-token).
2424
2525## Dev mode
2626
from line 48
4848| **Network** | HTTP / SSE servers | The raw HTTP view: status, headers, bodies. |
4949| **Console** | stdio servers | The server process's `stderr`. |
5050
51**Network** and **Console** never appear together. Legacy and modern eras are described in [Protocol eras](/docs/draft/tools/inspector/protocol-eras.md).
51**Network** and **Console** never appear together. Legacy and modern eras are described in [Protocol eras](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md).
5252
5353
5454
from line 75
7575| `--config <path>` | That file, read-only (never written or seeded) | No |
7676| `--server-url <url>` or a positional command | One ad-hoc server, held in memory | No |
7777
78On a first launch the web client seeds the catalog with three sample servers: a filesystem server scoped to `/tmp`, the canonical "everything" reference server, and the MCP org's hosted example server (Streamable HTTP, with OAuth via dynamic client registration). See [Configuration and flags](/docs/draft/tools/inspector/configuration.md) for the full rules, including why the CLI and TUI seed an empty catalog instead.
78On a first launch the web client seeds the catalog with three sample servers: a filesystem server scoped to `/tmp`, the canonical "everything" reference server, and the MCP org's hosted example server (Streamable HTTP, with OAuth via dynamic client registration). See [Configuration and flags](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md) for the full rules, including why the CLI and TUI seed an empty catalog instead.
7979
8080### Server Settings
8181
82* **Protocol Era**: `legacy` / `auto` / `modern`. See [Protocol eras](/docs/draft/tools/inspector/protocol-eras.md).
83* **Log Level per Request**: the level a modern-era connection stamps on each outgoing request by default, or `off` to opt out (see [Logging](/docs/draft/tools/inspector/protocol-eras.md#logging)).
84* **Advertised Extensions**: which extensions the Inspector declares in `capabilities.extensions`. A debugging knob: a server may legitimately change what it registers based on what you advertise. Uncheck the Tasks extension and reconnect against the `test-servers/configs/advertised-extensions-http.json` fixture (setup in [Reproducing each era locally](/docs/draft/tools/inspector/protocol-eras.md#reproducing-each-era-locally)) to watch a tool disappear.
82* **Protocol Era**: `legacy` / `auto` / `modern`. See [Protocol eras](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md).
83* **Log Level per Request**: the level a modern-era connection stamps on each outgoing request by default, or `off` to opt out (see [Logging](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md#logging)).
84* **Advertised Extensions**: which extensions the Inspector declares in `capabilities.extensions`. A debugging knob: a server may legitimately change what it registers based on what you advertise. Uncheck the Tasks extension and reconnect against the `test-servers/configs/advertised-extensions-http.json` fixture (setup in [Reproducing each era locally](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md#reproducing-each-era-locally)) to watch a tool disappear.
8585* **Roots**: the roots advertised via the `roots` client capability. `@modelcontextprotocol/server-filesystem`, for instance, calls `roots/list` to learn its allowed directories.
86* **Headers**, **timeouts**, and **OAuth** fields. Headers are saved in the catalog as written; OAuth client secrets and stdio `env:` values go to the [secret store](/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored).
87* **OAuth Settings**: client ID and secret, a read-only **Redirect URI** to copy into a pre-registered client (it follows the origin you opened the Inspector at), **Scopes** (space-separated), **Request refresh token**, **Revoke tokens on clear**, additional authorization parameters, authorization and token URL overrides, and **Insufficient-scope response**, which decides whether a `403 insufficient_scope` triggers [step-up](/docs/draft/tools/inspector/authorization.md#mid-session-re-authorization) or surfaces the error.
86* **Headers**, **timeouts**, and **OAuth** fields. Headers are saved in the catalog as written; OAuth client secrets and stdio `env:` values go to the [secret store](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#where-secrets-are-stored).
87* **OAuth Settings**: client ID and secret, a read-only **Redirect URI** to copy into a pre-registered client (it follows the origin you opened the Inspector at), **Scopes** (space-separated), **Request refresh token**, **Revoke tokens on clear**, additional authorization parameters, authorization and token URL overrides, and **Insufficient-scope response**, which decides whether a `403 insufficient_scope` triggers [step-up](https://modelcontextprotocol.io/docs/draft/tools/inspector/authorization.md#mid-session-re-authorization) or surfaces the error.
8888* **Fetch Lists One Page at a Time**: when off, list results are auto-aggregated across pages on connect; when on, each list loads page 1 only with a **Load next page** control and an *N pages loaded* status. Reproduce with `test-servers/configs/pagination-http.json`, which paginates 12 tools, resources, and prompts into three pages each.
8989
9090A footer at the bottom of **Server Settings**, **Client Settings** and the **Add / Edit / Clone server** dialogs names the secret store in use, so you see it where you type a secret. It turns into a warning when secrets are memory-only (lost on restart), in an unencrypted file, in a file with loose permissions, or in a file that can't be read.
from line 97
9797
9898Select a tool to see its description, its input schema rendered as a form, and its annotations. Fill the form and call it; the result renders below with structured content, embedded resources, and images handled natively.
9999
100On modern-era servers this screen also shows mirrored `Mcp-Param-*` headers, excluded tools, and distinct `-32602` error panels, all covered in [Protocol eras](/docs/draft/tools/inspector/protocol-eras.md#tools-mirrored-headers-and-excluded-tools).
100On modern-era servers this screen also shows mirrored `Mcp-Param-*` headers, excluded tools, and distinct `-32602` error panels, all covered in [Protocol eras](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md#tools-mirrored-headers-and-excluded-tools).
101101
102102
103103
from line 105
105105
106106## Resources
107107
108Lists resources and resource templates with their MIME types and descriptions, reads content on selection, and offers **Subscribe** on servers that support subscriptions. The subscription mechanics differ by era; see [Resource subscriptions](/docs/draft/tools/inspector/protocol-eras.md#resource-subscriptions).
108Lists resources and resource templates with their MIME types and descriptions, reads content on selection, and offers **Subscribe** on servers that support subscriptions. The subscription mechanics differ by era; see [Resource subscriptions](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md#resource-subscriptions).
109109
110110
111111
from line 121
121121
122122## Apps
123123
124[MCP Apps](/extensions/apps/overview.md) are tools that carry UI. The Apps tab renders one in a sandboxed iframe served from a **separate port**, exercises the `ui/*` bridge, and shows the view's `ui/message` submissions and its `notifications/message` logs in panels below the frame.
124[MCP Apps](https://modelcontextprotocol.io/extensions/apps/overview.md) are tools that carry UI. The Apps tab renders one in a sandboxed iframe served from a **separate port**, exercises the `ui/*` bridge, and shows the view's `ui/message` submissions and its `notifications/message` logs in panels below the frame.
125125
126126* The sandbox listens on its own port, `6275` by default (set it with `MCP_SANDBOX_PORT`). An app whose UI resource declares `_meta.ui.domain` has its document served from a third listener, the app origin, on `6278` by default (`MCP_APP_ORIGIN_PORT`). Expose or forward both along with the web port.
127127* The sandbox is gated by a `frame-ancestors` CSP, and a bracketed IPv6 literal is not a valid CSP host-source, so browse the Inspector at `localhost`, `127.0.0.1`, a hostname, or a LAN IPv4, **not** at a bare `http://[::1]:...`.
128128* By default the sandbox URL is plain `http` on the bind address, so an `https://` Inspector page blocks the frame as mixed content. Behind a TLS reverse proxy, set `MCP_SANDBOX_FULL_ADDRESS` (and `MCP_APP_ORIGIN_FULL_ADDRESS`) to the public `https://` address the browser reaches each listener at. Neither may share an origin with the Inspector UI; a value that does is ignored with a warning.
129129
130See [Recipes](/docs/draft/tools/inspector/recipes.md#reviewing-an-mcp-app) for the CLI-first automated review flow.
130See [Recipes](https://modelcontextprotocol.io/docs/draft/tools/inspector/recipes.md#reviewing-an-mcp-app) for the CLI-first automated review flow.
131131
132132
133133
from line 137
137137
138138The three tabs show the same traffic at different levels of detail:
139139
140* **Protocol**: the JSON-RPC transcript. Requests paired with responses, notifications inline, [MRTR](/docs/draft/tools/inspector/protocol-eras.md#multi-round-tool-results-mrtr) rounds grouped as one conversation, and spec errors rendered by class.
140* **Protocol**: the JSON-RPC transcript. Requests paired with responses, notifications inline, [MRTR](https://modelcontextprotocol.io/docs/draft/tools/inspector/protocol-eras.md#multi-round-tool-results-mrtr) rounds grouped as one conversation, and spec errors rendered by class.
141141* **Network**: the HTTP layer, for SSE and Streamable HTTP servers. Status codes, request and response headers, and bodies. On modern connections the standardized `Mcp-*` headers are highlighted and sentinel values decoded.
142142* **Console**: the connected stdio server process's `stderr`, which is where most stdio servers put their own diagnostics.
143143
from line 149
149149
150150## Deep links
151151
152A driver (a script, a CI harness, or the CLI's [`--print-handoff`](/docs/draft/tools/inspector/authorization#handing-off-from-the-web-client-to-the-cli)) can reach a *connected* Inspector with a single navigation:
152A driver (a script, a CI harness, or the CLI's [`--print-handoff`](https://modelcontextprotocol.io/docs/draft/tools/inspector/authorization#handing-off-from-the-web-client-to-the-cli)) can reach a *connected* Inspector with a single navigation:
153153
154154```
155155http://127.0.0.1:6274/?serverUrl=<url>&transport=http|sse&autoConnect=<token>
from line 169
169169
170170Binding all interfaces (`HOST=0.0.0.0`) is **refused** unless you set `DANGEROUSLY_BIND_ALL_INTERFACES=true`. Binding a *specific* non-loopback address is allowed with no opt-in, since that's a single deliberate exposure rather than every interface at once.
171171
172See the [Hosting on a network](/docs/draft/tools/inspector/recipes.md#hosting-on-a-network) recipe for the full matrix, and [Configuration](/docs/draft/tools/inspector/configuration.md#web-backend-environment-variables) for the variables.
172See the [Hosting on a network](https://modelcontextprotocol.io/docs/draft/tools/inspector/recipes.md#hosting-on-a-network) recipe for the full matrix, and [Configuration](https://modelcontextprotocol.io/docs/draft/tools/inspector/configuration.md#web-backend-environment-variables) for the variables.
173173
docs/draft/tutorials/security/authorization Changed · +7 / -7 lines
from line 4
44
55Authorization in the Model Context Protocol (MCP) secures access to sensitive resources and operations exposed by MCP servers. If your MCP server handles user data or administrative actions, authorization ensures only permitted users can access its endpoints.
66
7MCP uses standardized authorization flows to build trust between MCP clients and MCP servers. Its design doesn't focus on one specific authorization or identity system, but rather follows the conventions outlined for [OAuth 2.1](https://datatracker.ietf.org/doc/html/draft-ietf-oauth-v2-1-13). For detailed information, see the [Authorization specification](/specification/latest/basic/authorization.md).
7MCP uses standardized authorization flows to build trust between MCP clients and MCP servers. Its design doesn't focus on one specific authorization or identity system, but rather follows the conventions outlined for [OAuth 2.1](https://datatracker.ietf.org/doc/html/draft-ietf-oauth-v2-1-13). For detailed information, see the [Authorization specification](https://modelcontextprotocol.io/specification/latest/basic/authorization.md).
88
99## When Should You Use Authorization?
1010
from line 20
2020>
2121> **Authorization for Local MCP Servers**
2222>
23> For MCP servers using the [STDIO transport](/specification/latest/basic/transports.md#stdio), you can use environment-based credentials or credentials provided by third-party libraries embedded directly in the MCP server instead. Because a STDIO-built MCP server runs locally, it has access to a range of flexible options when it comes to acquiring user credentials that may or may not rely on in-browser authentication and authorization flows.
23> For MCP servers using the [STDIO transport](https://modelcontextprotocol.io/specification/latest/basic/transports.md#stdio), you can use environment-based credentials or credentials provided by third-party libraries embedded directly in the MCP server instead. Because a STDIO-built MCP server runs locally, it has access to a range of flexible options when it comes to acquiring user credentials that may or may not rely on in-browser authentication and authorization flows.
2424>
2525> OAuth flows, in turn, are designed for HTTP-based transports where the MCP server is remotely-hosted and the client uses OAuth to establish that a user is authorized to access said remote server.
2626
from line 242
242242
243243### MCP Server Setup
244244
245We will now set up our MCP server to use the locally-running Keycloak authorization server. Depending on your programming language preference, you can use one of the supported [MCP SDKs](/docs/draft/sdk.md).
245We will now set up our MCP server to use the locally-running Keycloak authorization server. Depending on your programming language preference, you can use one of the supported [MCP SDKs](https://modelcontextprotocol.io/docs/draft/sdk.md).
246246
247247For our testing purposes, we will create an extremely simple MCP server that exposes two tools - one for addition and another for multiplication. The server will require authorization to access these.
248248
from line 1042
10421042
10431043## Common Pitfalls and How to Avoid Them
10441044
1045For comprehensive security guidance, including attack vectors, mitigation strategies, and implementation best practices, make sure to read through [Security Best Practices](/specification/draft/basic/security_best_practices.md). A few key issues are called out below.
1045For comprehensive security guidance, including attack vectors, mitigation strategies, and implementation best practices, make sure to read through [Security Best Practices](https://modelcontextprotocol.io/specification/draft/basic/security_best_practices.md). A few key issues are called out below.
10461046
10471047* **Do not implement token validation or authorization logic by yourself**. Use off-the-shelf, well-tested, and secure libraries for things like token validation or authorization decisions. Doing everything from scratch means that you're more likely to implement things incorrectly unless you are a security expert.
10481048* **Use short-lived access tokens**. Depending on the authorization server used, this setting might be customizable. We recommend to not use long-lived tokens - if a malicious actor steals them, they will be able to maintain their access for longer periods.
from line 1071
10711071
10721072For additional details, refer to:
10731073
1074* [Authorization Specification](/specification/draft/basic/authorization.md)
1075* [Security Best Practices](/specification/draft/basic/security_best_practices.md)
1076* [Available MCP SDKs](/docs/draft/sdk.md)
1074* [Authorization Specification](https://modelcontextprotocol.io/specification/draft/basic/authorization.md)
1075* [Security Best Practices](https://modelcontextprotocol.io/specification/draft/basic/security_best_practices.md)
1076* [Available MCP SDKs](https://modelcontextprotocol.io/docs/draft/sdk.md)
10771077
10781078Understanding these standards will help you implement authorization correctly and troubleshoot issues when they arise.
10791079
docs/draft/tutorials/security/local-server-security Changed · +9 / -9 lines
from line 4
44
55Most MCP security documentation covers the protocol threat model: OAuth flows,
66token handling, session hijacking, and confused deputy attacks. For those, see
7[Authorization](/docs/draft/tutorials/security/authorization.md) and
8[Security Best Practices](/docs/draft/tutorials/security/security_best_practices.md).
7[Authorization](https://modelcontextprotocol.io/docs/draft/tutorials/security/authorization.md) and
8[Security Best Practices](https://modelcontextprotocol.io/docs/draft/tutorials/security/security_best_practices.md).
99
1010This guide covers a different threat model: **your machine**. When you run an
1111MCP server locally, you download code from the internet and run it as a child
from line 46
4646
4747Clients that offer one-click installation are required to show you the exact
4848command before it runs
49([SEP-1024](/seps/1024-mcp-client-security-requirements-for-local-server-.md)),
49([SEP-1024](https://modelcontextprotocol.io/seps/1024-mcp-client-security-requirements-for-local-server-.md)),
5050but a consent dialog only helps if you know what to look for. That is what
5151the rest of this guide is about.
5252
from line 131
131131your laptop, while you take on everything else in this guide for no benefit.
132132
133133* **Prefer the remote version where one exists.** A server offered over
134 [Streamable HTTP](/specification/draft/basic/transports/streamable-http.md)
134 [Streamable HTTP](https://modelcontextprotocol.io/specification/draft/basic/transports/streamable-http.md)
135135 runs no code on your machine, uses the protocol's authorization flow
136136 instead of a token in a local config file, and is patched in one place.
137137 The protocol threat model (linked above) applies to it instead of this
from line 197
197197
198198* **Read the tool list before you rely on a server.** Most clients can show
199199 each tool's description, and the
200 [MCP Inspector](/docs/draft/tools/inspector.md) lists every tool a
200 [MCP Inspector](https://modelcontextprotocol.io/docs/draft/tools/inspector.md) lists every tool a
201201 server exposes without a model in the loop. If a description contains
202202 instructions that have nothing to do with the tool's job, remove the
203203 server.
from line 419
419419
420420## Next Steps
421421
422> **[Security Best Practices](/docs/draft/tutorials/security/security_best_practices.md)**
422> **[Security Best Practices](https://modelcontextprotocol.io/docs/draft/tutorials/security/security_best_practices.md)**
423423>
424424> The protocol threat model: confused deputy, token passthrough, and session
425425> hijacking
426426
427> **[Authorization](/docs/draft/tutorials/security/authorization.md)**
427> **[Authorization](https://modelcontextprotocol.io/docs/draft/tutorials/security/authorization.md)**
428428>
429429> How OAuth-based authorization works for remote MCP servers
430430
431> **[SEP-1024](/seps/1024-mcp-client-security-requirements-for-local-server-.md)**
431> **[SEP-1024](https://modelcontextprotocol.io/seps/1024-mcp-client-security-requirements-for-local-server-.md)**
432432>
433433> Client security requirements for local server installation consent
434434
435> **[Connect to local servers](/docs/draft/develop/connect-local-servers.md)**
435> **[Connect to local servers](https://modelcontextprotocol.io/docs/draft/develop/connect-local-servers.md)**
436436>
437437> Set up local servers in your client — the workflow this guide secures
438438
docs/draft/tutorials/security/security_best_practices Changed · +13 / -13 lines
from line 8
88
99This document provides security considerations for the Model Context
1010Protocol (MCP), complementing the
11[MCP Authorization](/specification/latest/basic/authorization.md)
11[MCP Authorization](https://modelcontextprotocol.io/specification/latest/basic/authorization.md)
1212specification. This document identifies security risks, attack vectors,
1313and best practices specific to MCP implementations.
1414
from line 148
148148 consent screen
1491496. The MCP authorization code is redirected to the attacker's server
150150 (specified in the malicious `redirect_uri` parameter during
151 [dynamic client registration](/specification/latest/basic/authorization.md#dynamic-client-registration))
151 [dynamic client registration](https://modelcontextprotocol.io/specification/latest/basic/authorization.md#dynamic-client-registration))
1521527. The attacker exchanges the stolen authorization code for access
153153 tokens for the MCP server without the user's explicit approval
1541548. The attacker now has access to the third-party API as the compromised
from line 303
303303#### Risks
304304
305305Token passthrough is explicitly forbidden in the
306[authorization specification](/specification/latest/basic/authorization.md)
306[authorization specification](https://modelcontextprotocol.io/specification/latest/basic/authorization.md)
307307as it introduces a number of security risks, that include:
308308
309309* **Security Control Circumvention**
from line 484
484484
485485SSRF risks are not limited to MCP clients. When an authorization
486486server supports
487[Client ID Metadata Documents](/specification/draft/basic/authorization/client-registration.md#client-id-metadata-documents),
487[Client ID Metadata Documents](https://modelcontextprotocol.io/specification/draft/basic/authorization/client-registration.md#client-id-metadata-documents),
488488the authorization server takes a URL as input from an unknown client
489489and fetches that URL. A malicious client could use this to trigger
490490the authorization server to make requests to arbitrary URLs, such as
from line 514
514514
515515### State Handle Hijacking
516516
517MCP is [stateless](/specification/draft/basic/index.md#statelessness) and
517MCP is [stateless](https://modelcontextprotocol.io/specification/draft/basic/index.md#statelessness) and
518518has no protocol-level sessions. Servers that need state spanning
519519multiple requests mint an explicit handle, such as a shopping cart ID
520520or a workflow ID, and receive it back as an ordinary tool argument on
from line 553
553553
554554For guidance on securing the server-assigned session IDs used by
555555protocol version `2025-11-25` and earlier, see
556[Session Hijacking in the 2025-11-25 version of this page](/docs/2025-11-25/tutorials/security/security_best_practices.md#session-hijacking).
556[Session Hijacking in the 2025-11-25 version of this page](https://modelcontextprotocol.io/docs/2025-11-25/tutorials/security/security_best_practices.md#session-hijacking).
557557
558558### Local MCP Server Compromise
559559
from line 806
806806
807807#### Mitigation
808808
809[Authorization Response Validation](/specification/draft/basic/authorization.md#authorization-response-validation)
809[Authorization Response Validation](https://modelcontextprotocol.io/specification/draft/basic/authorization.md#authorization-response-validation)
810810mitigates this by binding the response to the authorization server
811811the client recorded before redirecting, so the authorization code
812812cannot be redeemed at an unintended token endpoint. PKCE alone does
from line 821
821821
822822Native and locally-running MCP clients commonly use `localhost`
823823redirect URIs. When clients identify themselves with
824[Client ID Metadata Documents](/specification/draft/basic/authorization/client-registration.md#client-id-metadata-documents),
824[Client ID Metadata Documents](https://modelcontextprotocol.io/specification/draft/basic/authorization/client-registration.md#client-id-metadata-documents),
825825the metadata document proves control of a domain, but it cannot prove
826826which local process is listening on a `localhost` redirect URI.
827827
from line 842
842842#### Mitigation
843843
844844See
845[Localhost Redirect URI Risks](/specification/draft/basic/authorization/security-considerations.md#localhost-redirect-uri-risks)
845[Localhost Redirect URI Risks](https://modelcontextprotocol.io/specification/draft/basic/authorization/security-considerations.md#localhost-redirect-uri-risks)
846846in the authorization specification for the countermeasures expected
847847of authorization servers, including displaying additional warnings for
848848`localhost`-only redirect URIs and clearly displaying the redirect URI
from line 851
851851### CIMD Trust Policies
852852
853853Authorization servers that accept
854[Client ID Metadata Documents](/specification/draft/basic/authorization/client-registration.md#client-id-metadata-documents)
854[Client ID Metadata Documents](https://modelcontextprotocol.io/specification/draft/basic/authorization/client-registration.md#client-id-metadata-documents)
855855can apply domain-based trust policies to decide which URL-based
856856client IDs to accept:
857857
from line 863
863863 to prevent phishing
864864
865865Servers maintain full control over their access policies. See
866[Trust Policies](/specification/draft/basic/authorization/security-considerations.md#trust-policies)
866[Trust Policies](https://modelcontextprotocol.io/specification/draft/basic/authorization/security-considerations.md#trust-policies)
867867in the authorization specification, along with
868868[Section 6.4](https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html#section-6.4)
869869and
from line 936
936936
937937When the initial `WWW-Authenticate` challenge carries no `scope`
938938parameter, the
939[Scope Selection Strategy](/specification/draft/basic/authorization.md#scope-selection-strategy)
939[Scope Selection Strategy](https://modelcontextprotocol.io/specification/draft/basic/authorization.md#scope-selection-strategy)
940940directs clients to fall back to requesting all scopes listed in
941941`scopes_supported`. This approach accommodates the general-purpose
942942nature of MCP clients, which typically lack domain-specific knowledge
from line 952
952952> **SHOULD** compute the union of previously requested scopes and newly
953953> challenged scopes when initiating re-authorization, as described in [Step-Up
954954> Authorization
955> Flow](/specification/draft/basic/authorization.md#step-up-authorization-flow).
955> Flow](https://modelcontextprotocol.io/specification/draft/basic/authorization.md#step-up-authorization-flow).
956956> This allows servers to remain stateless with respect to client scope sets
957957> while ensuring clients do not lose previously granted permissions.
958958
extensions/apps/overview Changed · +3 / -3 lines
from line 167
167167
168168> [!NOTE]
169169>
170> MCP Apps is an extension to the [core MCP specification](/specification/latest.md). Host support varies by client.
170> MCP Apps is an extension to the [core MCP specification](https://modelcontextprotocol.io/specification/latest.md). Host support varies by client.
171171
172172MCP Apps are currently supported by [Claude](https://claude.ai),
173173[Claude Desktop](https://claude.ai/download),
174174[VS Code GitHub Copilot](https://code.visualstudio.com/), [Microsoft 365 Copilot](https://www.microsoft.com/microsoft-365-copilot), [Goose](https://block.github.io/goose/), [Postman](https://postman.com), [MCPJam](https://www.mcpjam.com/), and [Archestra.AI](https://www.archestra.ai/). See the
175[client matrix](/extensions/client-matrix.md) for the full list of extension support across clients.
175[client matrix](https://modelcontextprotocol.io/extensions/client-matrix.md) for the full list of extension support across clients.
176176
177177If you're building an MCP client and want to support MCP Apps, you have two options:
178178
from line 229
229229 [Solid](https://github.com/modelcontextprotocol/ext-apps/tree/main/examples/basic-server-solid),
230230 [vanilla JavaScript](https://github.com/modelcontextprotocol/ext-apps/tree/main/examples/basic-server-vanillajs)
231231
232To start building your own MCP App, see the [build guide](/extensions/apps/build.md).
232To start building your own MCP App, see the [build guide](https://modelcontextprotocol.io/extensions/apps/build.md).
233233