17.11 How today's tools realize it
- Approved by
- Panaversity ·
In everyday life. Every outlet in a country follows one standard, so any lamp works in any room, though some rooms add a dimmer or a timer.
What you will learn. How Claude Code, Codex and OpenCode each connect to an MCP server, where each adds to the specification or differs from it, and where the servers run.
Why it matters. The server stays the same, but the settings file, the way a key travels and who approves a call change with each product.
Concepts 17.1 to 17.10 taught the standard. This concept shows how each product connects to an MCP server, as of November 1, 2026, against revision 2026-07-28.1 The field guide that follows has the commands.
Which products does this page cover?
You know three from Chapter 12: Claude Code, Codex and OpenCode, coding agents that act as MCP hosts. Three more serve programs. The Messages API is how a program sends a conversation to Claude and gets a reply. Its MCP connector, Anthropic's name for this one feature, lets the request name a remote MCP server for Claude to call. The Responses API is OpenAI's equivalent, and can call MCP servers too. The Claude Agent SDK is a library for building your own agent around Claude Code's loop. The lab does not use them, but the same server serves them too.
How far to trust this page. Each statement below is what the product's own documentation said on November 1, 2026, cited to its source. Brightline's servers have been run against the MCP Inspector and the official MCP code libraries, and the TypeScript server against Claude Code. They have not yet been run against Codex or OpenCode, so note what you see in the lab.
How does each one connect, and where does it differ?
Pick the coding agent you use. Each tab also covers that vendor's programming interface, and each bullet says what the product adds to the MCP specification or how it sets up a connector.
- Connection and revision. Claude Code connects by web requests, as in 17.1, and uses revision 2026-07-28 with servers that support it. Project servers live in
.mcp.json. It can read${VAR}, or${VAR:-default}with a fallback, from the variables set where Claude Code started, inurlandheaders, so a key never sits in the file. A few variables that hold credentials, such as Anthropic's own API key, read as empty there, on purpose.2 - Tools and limits. Claude Code adds limits the specification leaves to hosts: a warning above 10,000 tokens of tool output and a default cap of 25,000 (
MAX_MCP_OUTPUT_TOKENS). Permission rules name toolsmcp__<server>__<tool>, ormcp__plugin_<plugin>_<server>__<tool>from a plugin.3 OAuth is built in (/mcp,claude mcp login). - The Messages API's MCP connector calls a remote server from Claude's platform:
mcp_serversentries (type: "url", anhttps://URL, an optionalauthorization_token), each referenced by anmcp_toolsetthat can turn each tool on or off, or load it only when needed. It uses only tool calls, none of MCP's other features. It is in beta on every model, and its data is retained under the standard policy.4 - Asking first. Claude Code asks before using a project's servers interactively. In runs with nobody at the keyboard (
claude -p) and in the Agent SDK, they load without asking, so run those only in repositories you trust.2 - Records of each call. Its OpenTelemetry records (17.10) name the server and tool.5
- Status and price. Claude Code needs a Claude plan or API billing.
- Where servers go. Servers go under
[mcp_servers.<name>]in~/.codex/config.toml, or in.codex/config.tomlin a project you have marked as trusted, shared by the desktop app, CLI and IDE extension. A remote server takes aurl, andbearer_token_env_varnames the variable holding its key.enabled_toolsanddisabled_toolschoose tools.codex mcp loginhandles OAuth, the sign-in of 17.8. Its page states no protocol revision.6 - Approval relaxes a specification warning.
default_tools_approval_modetakesauto,prompt,writesorapprove.writesprompts only for tools the server does not mark read-only, so it trusts the server's ownreadOnlyHint, which the specification calls untrusted unless the server is trusted. Use it only for servers you wrote or reviewed.6 - The Responses API offers function tools you define, hosted tools OpenAI runs such as web search and file search, remote MCP servers (
type: "mcp",server_label,server_url,require_approval), andtool_search, which loads tools only when the model needs them.7 - Records of each call. Codex exports OpenTelemetry logs for approvals and tool results, and a metric for MCP calls, under
[otel]in your user configuration.8 - Status and price.
tool_searchneedsgpt-5.4or later. For which plans include Codex, see 14.9.
- OpenCode version 2. Servers go under
mcp.serversinopencode.jsonc, not directly undermcp. A remote server is"type": "remote"with aurlandheaders, where{env:NAME}reads a key from the environment. OAuth is on by default, so a key in a header needs"oauth": false.9 - Which revision. The default
protocolsetting is not 2026-07-28, so set"protocol": "2026-07-28"on each server, or"auto"to ask the server which revisions it supports.9 - Tool names. Permission rules name tools
<server>_<tool>, such asapts_*. Resources are read through OpenCode's own tools. Its documentation notes that every server's tools cost context.9 - Security. OpenCode runs connectors with your rights. Its version 2 documentation describes no records of each call and no way to limit what a connector can touch.9
- Status and price. Free and open source. You pay for the model.
Where do the servers run?
Cloudflare Workers is the book's platform for stateless servers. A Worker is a small program Cloudflare runs at a web address, on the machine nearest each caller, in a light, short-lived sandbox: what 17.4 and 17.8 ask of a stateless server. Wrangler, Cloudflare's command-line tool, runs it locally (wrangler dev, no account needed) and uploads it (wrangler deploy). The code exports a fetch function that receives each request and an env object holding its bindings: its secrets and handles to platform resources, such as env.ASSETS for its files. Brightline's TypeScript server is a standard fetch function built with the official MCP SDK, so the platform stays a deployment choice. Never heard of Cloudflare? Field guide F1 starts with "Meet Cloudflare": what the company does, why it matters for AI, and what its free plan gives you, then explains each term from zero.
- Staging and production. One configuration file defines production and
staging, each a separate Worker with its own address and secrets. Bindings are not inherited, so each lists its own.10 - Each deploy can be undone. Every deploy is kept as a numbered Worker version. A rollback (
wrangler rollback) makes one of the 100 most recent live again.11 Version URLs give a version a public address before it goes live, and are off for Brightline's production Worker.12 - What gets logged. Workers Logs keep console output and errors, on by default for new Workers.13
wrangler tailshows live requests.14 - Python. Python Workers run on Pyodide, Python compiled to WebAssembly, a compact program format browsers can run.15 So only packages written purely in Python, or built for WebAssembly, run.16
- Security. The address is public. The Worker checks
Originand the key on every request, and never serves the data files directly. The CI deploy credential is limited to Workers and what they use, in one account.17 - Status and price. Generally available. The free plan gives 100,000 requests a day and 10 ms of processor time (CPU time) per request. The paid plan allows 30 seconds by default.18 The free plan keeps Workers Logs 3 days, until new log pricing starts on December 1, 2026.19 Cloudflare's own Containers are not on the free plan.20
The commands are in field guide F6. Another hosting service can run the same server, with only the configuration file and deploy commands changed.
The differences that change a decision
- The server never changes. Brightline's servers connected unchanged to the official SDK clients and the MCP Inspector, and the TypeScript server to Claude Code. Hosts write three facts in their own files and syntax: the address, the key, and which tools are allowed.
- The revision is set differently. Claude Code uses 2026-07-28 with servers that support it. OpenCode needs
"protocol": "2026-07-28". Codex's page states none: record what your run shows. - Read-only marks are trusted differently. Codex can skip approval for tools a server marks read-only: safe for a server you wrote, dangerous for a stranger's.
- A key travels differently:
${VAR}in Claude Code,bearer_token_env_varin Codex,{env:NAME}in OpenCode, never in the file. The Agent Plugins core, the plugin standard from Chapter 16, cannot carry a key at all, so a shared-key server is set per host, and OAuth lets one entry serve every host. - Records of each call are uneven. Claude Code and Codex export their own records. OpenCode's documentation describes none. Lab Task 16c records whether any sends its trace ID (
traceparent) to the server.21
What stays the same on every product?
- The server is written once, to the open protocol. Whichever host connects, it validates its inputs, checks every request's credential and
Origin, and returns only what the caller needs. - The host decides whether a call may run. A server's own description of itself never decides it alone.
- A span shows that a call ran. Only a test or an acceptance check shows it was right.
For the exam. CCDV-F and CCAR-F ask about Claude's behavior. Where Claude Code differs from the specification, such as its output limit or its tool naming in permission rules, the answer that scores is Claude Code's behavior.
Check yourself
Question 1 / 10
0 answered
In Claude Code, how is a plugin's connector tool named in a permission rule?
Sources
- Specification 2026-07-28, Model Context Protocol.↑
- Connect Claude Code to tools via MCP, Anthropic.↑↑2
- Configure permissions, Anthropic.↑
- MCP connector, Anthropic.↑
- Monitoring, Anthropic.↑
- Codex: MCP, OpenAI.↑↑2
- Using tools, OpenAI.↑
- Advanced configuration, Codex, OpenAI.↑
- MCP servers, OpenCode.↑↑2↑3↑4
- Environments, Cloudflare.↑
- Rollbacks, Cloudflare.↑
- Version URLs, Cloudflare.↑
- Workers Logs, Cloudflare.↑
- Real-time logs, Cloudflare.↑
- How Python Workers work, Cloudflare.↑
- Python packages, Cloudflare.↑
- GitHub Actions, Cloudflare.↑
- Workers limits, Cloudflare.↑
- Workers pricing, Cloudflare.↑
- Containers, Cloudflare.↑
- Semantic conventions for MCP, OpenTelemetry.↑
- Owner
- Panaversity