Tool Deep DivesMCP

Model Context Protocol (MCP): a deep dive into the "USB-C port for AI" — architecture, primitives, and Sales Claw integration

MCP is the LLM-app extension protocol Anthropic launched in November 2024 that became an industry standard in 18 months. We walk through the Host / Client / Server tiers, JSON-RPC 2.0, six primitives, ecosystem adoption, and what 'Sales Claw as MCP server' looks like in practice — including safety risks and mitigations.

中澤 圭志

中澤 圭志

@keishi_nakazawa

Sales Claw maintainer

·18 min
Model Context Protocol (MCP): a deep dive into the "USB-C port for AI" — architecture, primitives, and Sales Claw integration
This English article is a concise version of the original. For the full Japanese deep-dive, see the Japanese original.

Key Facts

Spec version

2025-11-25 (current) / first announced 2024-11-25

Originator

Anthropic (D. Soria Parra + J. Spahr-Summers)

Role A (Host)

Claude / ChatGPT / VS Code / Cursor / Gemini CLI — the LLM side

Role B (Server)

Filesystem / Git / DB / API / Slack — the tools and data side

"You keep seeing 'MCP' everywhere — Claude, ChatGPT, Cursor, VS Code, Gemini CLI — but what actually is it, why did it become a de facto standard, and how would you build it into AI-driven sales automation?" This article answers that head-on. We work from the official MCP spec (2025-11-25 revision) and Anthropic / OpenAI / Google primary docs, walking through architecture, primitives, implementation, and operational risk from a Sales Claw maintainer's perspective.

Model Context Protocol (MCP) was announced by Anthropic on 2024-11-25. Eighteen months later (May 2026), every major AI development tool — Claude Code, ChatGPT (Apps), Codex, Gemini CLI, Cursor, VS Code, Zed, Replit — has adopted it. The official site frames MCP as "a USB-C port for AI applications." That framing is good marketing, but the real story underneath is a stateful JSON-RPC 2.0 protocol with a clean Host / Client / Server three-tier separation, deeply inspired by the Language Server Protocol (LSP).

Primary sources: the modelcontextprotocol.io official spec (2025-11-25), the modelcontextprotocol/specification GitHub repo, the modelcontextprotocol/servers GitHub repo, Anthropic Newsroom (2024-11-25 launch), Claude Code MCP Docs (code.claude.com), OpenAI MCP Docs (developers.openai.com/api/docs/mcp), and Gemini CLI MCP Docs (geminicli.com). If you've read the Claude agents × Codex remote-control orchestration piece or the Claude Code slash commands guide, read this article as "the common protocol layer underneath both." The Sales Claw Quick start is also worth reading alongside the implementation section.

1. What MCP is — beyond the "USB-C port for AI" metaphor

The formal MCP definition from modelcontextprotocol.io:

Decomposed: there's "(a) the AI-application side" and "(b) the external-system side," with "(c) an open standard protocol" inserted between them. The USB-C metaphor is accurate in the sense that hardware connectors went from "every vendor invents their own port" to "one USB-C cable handles everything," and MCP brings that same answer to the AI × tools problem.

But if you stop at the metaphor, you miss the real design decision. The spec (modelcontextprotocol.io/specification) is explicit that MCP was inspired by the Language Server Protocol (LSP).

Microsoft designed LSP in 2016 for VS Code. Before LSP, "editor × language" was an N × M problem — every editor had to integrate every language. LSP collapsed it into "editor ← LSP → language server" — a 1:N abstraction. MCP is best understood as the same trick, applied to "LLM app × data sources / tools".

Whiteboard-style hand-drawn diagram of MCP. At the center is a large USB-C connector labeled MCP. On the left: LLM apps (Claude / ChatGPT / Cursor / VS Code / Gemini CLI). On the right: external systems (Filesystem / Git / Slack / Postgres / API). A handwritten headline reads 'Industry-standard protocol — one cable instead of N × M.' Arrows converge both sides into MCP.
Figure: Figure 1: MCP collapses LLM-app × external-system fragmentation from N × M into a 1:N protocol

Holding the "LSP for AI" framing in mind makes the rest of the design click: capability negotiation and stateful sessions exist for reasons that LSP also encountered. Rather than each vendor inventing their own format (one for Claude, one for OpenAI, one for Google), Anthropic proposed: let's all speak the same protocol.

2. MCP's history and current spec (2024-11-25 → 2025-11-25)

The historical thread, from primary sources:

2024-11-25: Anthropic announces MCP

On 2024-11-25, Anthropic posted "Introducing the Model Context Protocol" on its Newsroom. Highlights:

  • Designers: led by David Soria Parra and Justin Spahr-Summers at Anthropic.
  • Motivation: AI models cut off from knowledge trapped behind information silos and legacy systems.
  • Initial supporters: Block and Apollo as early-adopter companies; Zed, Replit, Codeium, and Sourcegraph as developer-tool companies.
  • Released alongside: pre-built MCP servers for Google Drive, Slack, GitHub, PostgreSQL, and more.

2024-11 → 2025-11: a year of revisions

The modelcontextprotocol/specification repo's schema folder stacks TypeScript schemas by version. The lineage looks roughly like this (based on the repo's naming convention):

Spec versionWhenMain additions / changes
2024-11-05November 2024Launch version (Resources / Tools / Prompts / Sampling)
2025-03-26March 2025Streamable HTTP transport formalized, OAuth 2.0 authorization strengthened
2025-06-18June 2025Elicitation introduced (server-to-user requests for additional info)
2025-11-25November 2025 (1-year anniversary)Current. Schema cleanup, clearer capability negotiation, security principles elevated to the spec body.

As of May 2026, reference the 2025-11-25 spec. The official spec page (modelcontextprotocol.io/specification) is organized in five sections: Architecture / Base Protocol / Server / Client / Contributing.

Seven official reference servers and the ecosystem

The modelcontextprotocol/servers repo provides seven official reference implementations. They are the canonical examples of how MCP should behave — the best place to study before writing your own server.

Official serverRolePrimary primitives used
EverythingReference / test server exercising every primitiveResources / Tools / Prompts
FetchFetch web content and convert to MarkdownTools
FilesystemSafe file operations with access controlResources / Tools
GitRepository read / search / operateTools / Resources
MemoryKnowledge-graph-based persistent memoryTools / Resources
Sequential ThinkingStructured chain-of-thought assistanceTools
TimeTime / timezone conversionTools

The README links to well over 150 community implementations, and Anthropic Directory (claude.ai/directory) lists officially reviewed remote MCP servers. Slack, Notion, Linear, Figma, Google Drive, PostgreSQL, Sentry, Datadog, Statsig, Cloudflare — almost every major SaaS now has an official or semi-official MCP server.

MCP history timeline. Horizontal axis from November 2024 to May 2026. Markers at 2024-11-25 (Anthropic launch + early supporters Block/Apollo/Zed/Replit/Codeium/Sourcegraph), 2025-03-26 (Streamable HTTP + OAuth), 2025-06-18 (Elicitation), 2025-11-25 (current spec, capability negotiation clarified). Below: adoption timeline for Claude Code 2024-12, ChatGPT Apps 2025-04, Cursor 2025-03, VS Code 2025-06, Gemini CLI 2025-08, Codex 2025-10.
Figure: Figure 2: MCP timeline from launch to current spec — industry standard in 1.5 years

3. Architecture — Host / Client / Server three tiers, JSON-RPC 2.0

Summarizing the spec's architecture definition (modelcontextprotocol.io/specification/2025-11-25/architecture):

Host

  • Definition: the container/coordinator that owns the LLM application process.
  • Examples: Claude Desktop, Claude Code, ChatGPT, Cursor, VS Code, Zed, Gemini CLI.
  • Responsibilities: spawning and managing multiple Clients, obtaining user consent, enforcing security policy, coordinating LLM sampling, aggregating context from multiple Servers.

Client

  • Definition: a connector spawned by the Host that maintains a 1:1 session with a specific Server.
  • Responsibilities: establishing the stateful session, protocol negotiation, bidirectional message routing, subscription / notification management, maintaining security boundaries between Servers.

Server

  • Definition: an independent process or remote service that provides specialized context or capability.
  • Examples: Filesystem server, Git server, Slack server, Postgres server, Sentry server — and eventually Sales Claw server.
  • Responsibilities: expose Resources / Tools / Prompts, request sampling via Client, follow security constraints.

JSON-RPC 2.0 and transports

The messaging layer is JSON-RPC 2.0 — bidirectional request / response / notification between Client and Server. Three standardized transports:

TransportUseTypical scenario
stdioLocal inter-process communication (stdin/stdout)Local Servers like Filesystem or Git
Streamable HTTPHTTP POST + SSE bidirectionalRemote SaaS Servers like Slack, Notion, Sentry
SSE (legacy)Server-Sent Events legacy remote transportCompat for older implementations (use Streamable HTTP for new)

Session lifecycle: initialize → negotiation → operate → close

An MCP session starts with an initialize request. The Client declares its own capabilities; the Server responds with its capabilities — this is capability negotiation. It fixes "does this Server support tools?" and "does this Client support sampling?" at session start.

// Client → Server: initialize
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "initialize",
  "params": {
    "protocolVersion": "2025-11-25",
    "capabilities": {
      "sampling": {},
      "roots": { "listChanged": true }
    },
    "clientInfo": { "name": "Claude Code", "version": "2.1.142" }
  }
}

// Server → Client: initialize result
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "protocolVersion": "2025-11-25",
    "capabilities": {
      "tools": { "listChanged": true },
      "resources": { "subscribe": true },
      "prompts": {}
    },
    "serverInfo": { "name": "salesclaw-mcp", "version": "0.1.0" }
  }
}

After that the Client issues tools/list, resources/list, prompts/list and so on. The LLM calls tools as needed via tools/call. Servers can also send requests back to the Client — typical examples: sampling/createMessage ("please continue this with the LLM") and roots/list("which directories may I operate in?").

JSON-RPC message sequence diagram for an MCP session. Three vertical lanes: Host / Client / Server. From top to bottom, seven messages: (1) Host → Client: initialize client; (2) Client → Server: initialize with capabilities; (3) Server → Client: initialize result with capabilities; (4) Client → Server: tools/list; (5) Server → Client: list of tools; (6) Host → Client: user intent → Client → Server: tools/call; (7) Server → Client: result. The capability negotiation region is marked with diagonal hatching.
Figure: Figure 3: MCP session JSON-RPC sequence (initialize → tools/call)

Sales Claw is built with MCP-server-ready, policy-controlled autonomous operation in mind.

無料・MIT ライセンス。インストールせずにライブデモも試せます。

4. Primitives — three server-side, three client-side

Every MCP capability decomposes into one of these six. The spec's server features table (modelcontextprotocol.io/specification/2025-11-25/server) splits them by who controls them:

Server features (three)

PrimitiveControlled byRoleMethods
ResourcesAppStructured data / context (files, Git history)resources/list, resources/read
PromptsUserTemplated workflows (slash commands, menu items)prompts/list, prompts/get
ToolsModelFunctions the LLM calls that have side effects (API POST, file write)tools/list, tools/call

The three are fundamentally different by who triggers them. Resources are "the Host app attaches them to context via UI." Prompts are "the user explicitly fires them via slash command or menu." Tools are "the LLM decides on its own." The same "Server-exposed capability" comes with very different safety layers. A "delete file" Tool fires at the LLM's discretion — explicit user consent is mandatory every time. A "file list" Resource only loads when the user picks it in the UI.

Whiteboard-style hand-drawn diagram. Central headline: 'The six MCP primitives.' Top row: three boxes labeled Resources / Prompts / Tools, with arrows labeled 'App-controlled' / 'User-controlled' / 'Model-controlled.' Bottom row: three boxes labeled Sampling / Roots / Elicitation, each with a one-line description. Annotation between Resources and Tools notes 'side-effect boundary,' with a red mark on Tools reading 'model-controlled = consent required.'
Figure: Figure 4: The six MCP primitives organized by who controls each

Client features (three)

The reverse direction (Server → Client) has three primitives. These are callable from the Server only when the Client declares the matching capability.

PrimitiveRoleWhen to use
SamplingServer asks the Client "let the LLM continue this"Agentic MCP servers; recursive LLM-call patterns
RootsServer asks "which URIs / directories may I operate on?"Filesystem-class servers declaring scope to the user
ElicitationServer asks the user (via Client form) for additional inputInstead of guessing or erroring on missing parameters, request user input

Elicitation is a relatively new primitive added in the 2025-06-18 spec. Before that, the Server had no clean way to request user input — it had to guess or error. Cleanliness of design jumped significantly.

5. Major AI tool adoption + Sales Claw implementation sketch

Host adoption matrix

HostConfig locationTransportsNote
Claude Codeclaude mcp add / .mcp.jsonstdio / Streamable HTTPcode.claude.com/docs/en/mcp
Claude Desktopclaude_desktop_config.jsonstdio / Streamable HTTPRemote servers listed at claude.ai/directory
ChatGPTApps (formerly Connectors)Streamable HTTPRenamed from Connectors to Apps on 2025-12-17
OpenAI Codex~/.codex/config.tomlstdio / Streamable HTTPdevelopers.openai.com/codex
Gemini CLI~/.gemini/settings.jsonstdio / SSE / HTTP (OAuth 2.0)Project config overrides user config
VS Code.vscode/mcp.jsonstdio / Streamable HTTPManaged from Copilot Chat > MCP servers tab
Cursor.cursor/mcp.jsonstdio / Streamable HTTPcursor.com/docs/context/mcp

The key point: config formats differ, but the MCP server on the other end is the same binary. That's the value of MCP as an open protocol. An MCP server you wrote for Claude Code runs identically when called from Gemini CLI or Cursor.

Adding an MCP server to Claude Code

# Add a stdio (local process) server
claude mcp add salesclaw -- npx -y @salesclaw/mcp-server

# Add a Streamable HTTP (remote) server
claude mcp add --transport http salesclaw https://mcp.salesclaw.site

# Share via .mcp.json (one project config for the whole team)
cat > .mcp.json <<EOF
{
  "mcpServers": {
    "salesclaw": {
      "type": "stdio",
      "command": "npx",
      "args": ["-y", "@salesclaw/mcp-server"],
      "env": { "SALESCLAW_API_KEY": "${SALESCLAW_API_KEY}" }
    }
  }
}
EOF

Adding an MCP server to Gemini CLI

# Append to ~/.gemini/settings.json
cat >> ~/.gemini/settings.json <<EOF
{
  "mcpServers": {
    "salesclaw": {
      "command": "npx",
      "args": ["-y", "@salesclaw/mcp-server"],
      "env": {
        "SALESCLAW_API_KEY": "$SALESCLAW_API_KEY"
      }
    }
  }
}
EOF

Sales Claw as an MCP server — implementation sketch

Sales Claw is OSS designed to lower misfire and policy-violation risk through policy control, pre-send checks, do-not-contact detection, CAPTCHA-on-detect stop, rate limits, audit logging, and automatic stop conditions. Exposed as an MCP server, it becomes callable through the same interface from Claude / ChatGPT / Cursor / VS Code / Gemini CLI.

A draft of the primitives Sales Claw MCP would expose (design proposal — implementation staged):

TypeName (draft)Role
Resourcessalesclaw://leads/{id}Structured data for a single prospect / account
Resourcessalesclaw://action-logPast submission history and audit log (read-only)
Prompts/draft-outreachIndustry- and touchpoint-aware copy-drafting workflow
Toolspreflight_checkPre-send checks (do-not-contact / policy / CAPTCHA / compliance footer)
Toolssubmit_formSubmit the contact form (only if preflight_check passed)
Toolslist_recent_submissionsRecent submission counts and states

The design choice that matters: preflight_check and submit_form are intentionally split. Even if the LLM (Claude / ChatGPT) tries to call submit_form directly, the Sales Claw server enforces "only accept if preflight_check has passed." That gives you a second defense layer that runs independently of the Host's --permission-mode— the answer at the design level to the spec's "tools = arbitrary code execution" assumption.

Internal validation at Sales Claw (around 300 contact-form submissions observed under autonomous looping + parallel batches + Hooks-driven event-loop monitoring) found that even when Sales Claw runs as an MCP server, these five conditions must all be enforced on the server side: (1) AND of goal / volume cap / elapsed-time cap as termination conditions; (2) awaiting_approval state preservation on CAPTCHA detection; (3) automatic compliance footer append; (4) per-subagent audit-log traceability; (5) immediate stop on do-not-contact detection. For enterprise deployment, per-tenant Resources isolation is also required.

# Local dev / debug with MCP Inspector
npx -y @modelcontextprotocol/inspector npx -y @salesclaw/mcp-server

# Call from Claude Code
claude mcp add salesclaw -- npx -y @salesclaw/mcp-server
# In Claude Code: "Run @salesclaw preflight_check, then @salesclaw submit_form."
Chalkboard-style diagram of Sales Claw exposed as an MCP server. Left side: five Hosts (Claude / ChatGPT / Cursor / VS Code / Gemini CLI) with arrows converging to a central MCP protocol (JSON-RPC 2.0) lane. From there an arrow into a Sales Claw MCP server box on the right. Inside the box: preflight_check (Tool), submit_form (Tool), leads (Resources), action-log (Resources), draft-outreach (Prompts). Arrow shows the enforced preflight_check → submit_form order. Below: handwritten note 'Whichever Host calls, Sales Claw checks always run.'
Figure: Figure 5: Once Sales Claw is an MCP server, every Host hits the same checked interface

Build-cost estimate for a custom MCP server

Bar chart estimating MCP server build effort across four scenarios. Horizontal axis: Hello World, Wrap existing REST API, Full new build, Multi-tenant production. Vertical axis: person-days. Each bar stacks four colors for implementation, testing, documentation, and security review. Totals roughly 1.5 / 5 / 12 / 22 person-days. A horizontal annotation notes 'Anthropic Quickstart gets you to Hello World in 1 day.'
Figure: Figure 6: Effort estimate across four MCP-server build scenarios (rough numbers — measure your own)
ScenarioEffort (estimate)What it includes
Hello World~1 dayOne tool built with the official SDK, callable from Claude Code
Wrap existing REST API~5 days3–5 internal APIs exposed as Tools, with tests and docs
Full new build (business logic)~12 daysFull Resources / Tools / Prompts coverage with auth
Multi-tenant production~22 daysStreamable HTTP + OAuth 2.0 + audit log + metering + security review

Expect ±30–50% variance. Security review and per-tool permission design swing 2–3× by organizational maturity.

6. Safety and risk in MCP — tool safety, sampling consent, data boundaries

MCP is a protocol where Hosts and Servers exchange "tools equivalent to arbitrary code execution." The security chapter of the spec is explicit that MCP cannot enforce these guarantees at the protocol level alone — it leaves responsibility with the implementers (both Host and Server). Whether you expose Sales Claw as an MCP server or just run it standalone, the risks below need to be reduced through automated checks.

Tool safety

  • Don't trust Tool descriptions: the spec says clearly "Tool description annotations should be considered untrusted." Calling a tool based on its name and description alone is unsafe.
  • Get user consent: Hosts must confirm with the user before tools with side effects (send, write, delete). Claude Code's --permission-mode default / ask exists for this.
  • Two-stage server-side check: "the Host approved it" isn't sufficient. Implement order enforcement (like preflight_check → submit_form) on the server too.
  • Prevent server-driven runaway: Sampling lets the Server ask the Client "please continue with the LLM." The spec mandates that "users must explicitly approve" these.
  • Control prompt visibility: "protocol intentionally limits server visibility into prompts" — the design keeps the Server from seeing the whole conversation.

Data boundaries and privacy

  • No undeclared transfer: the spec says "Hosts must not transmit resource data elsewhere without user consent."
  • Server-side silos: Clients hold 1:1 sessions with Servers, so Server A's context doesn't leak to Server B (unless the Host explicitly hands it over).
  • Audit log: expose submission history as Resources (as Sales Claw does), enabling after-the-fact audit.

Residual risks

Even with protocol design and server implementation done well, these remain structurally:

  • Malicious third-party MCP servers: Cursor / Claude Desktop let users add arbitrary servers — a "keylogger disguised as an image-generator MCP server" is technically feasible. Prefer reviewed directories like Anthropic Directory.
  • Tool-description prompt injection: Server-side tool descriptions crafted to manipulate the LLM. Mitigate by surfacing the description to the user in the Host UI.
  • Streamable HTTP authorization gaps: not implementing OAuth 2.0 and instead embedding API keys in URLs.
  • Sampling-driven cost explosion: Servers recursively triggering sampling can blow up API costs. Host-side rate limits are essential.

7. Pre-production checklist

Run through this before putting your own MCP server into production, or before adding a third-party MCP server to your Host.

Before going live with MCP

  • You trust the MCP server&apos;s origin (official Directory / your team / audited community)
  • Tool descriptions are visible in the Host UI for user confirmation
  • Side-effect tools (send / write / delete) have --permission-mode set to default or ask
  • The server also enforces order (e.g., preflight_check → submit_form)
  • Streamable HTTP servers authenticate with OAuth 2.0 (no API keys in URLs)
  • For sampling-using servers, host-side rate limits and a hard API budget are set
  • Audit log (Resources) makes past tool calls traceable
  • Send-class servers auto-append the compliance footer on the server side
  • Remote MCP servers stay on localhost / VPN, never on the open internet
  • Sampled 100+ records to measure preflight_check pass rate and false positives

8. Bottom line — MCP as foundation tech, and what to take from it

MCP gets sold as "a USB-C port for AI" for accessibility, but the real essence is LSP applied to AI — a protocol abstraction that re-organizes the LLM-app × external-system N × M problem into 1:N. Three tiers (Host / Client / Server), JSON-RPC 2.0, six primitives (Resources / Tools / Prompts / Sampling / Roots / Elicitation), and the strong premise that tools equal arbitrary code execution — all stable in the 2025-11-25 spec.

From a Sales Claw maintainer's perspective, MCP is significant because Sales Claw can be both called (Server) and caller (Client inside a Host). Designing "pre-send checks enforced at the protocol level" via MCP tool-order control means Sales Claw's safety design works identically no matter which Host (Claude, ChatGPT, Cursor) invokes it.

Next action: if you're building one MCP server, read the Everything server in modelcontextprotocol/servers first. It demonstrates the minimum implementation of Resources / Prompts / Tools, and teaches the SDK along the way. For Sales Claw operational integration, start with the Quick start and study the preflight_check logic.

MCP is foundation tech. You only internalize it by running it.

無料・MIT ライセンス。インストールせずにライブデモも試せます。

よくある質問

What is the Model Context Protocol (MCP)?
MCP is an open JSON-RPC 2.0 protocol that lets LLM applications access external data sources, tools, and workflows. Announced by Anthropic on 2024-11-25, it became the de facto industry standard within about 18 months — adopted by Claude Code, ChatGPT (Apps), Codex, Gemini CLI, VS Code, Cursor, Zed, Replit, and more. The official site calls it 'a USB-C port for AI apps,' but the design essence is closer to a re-application of the Language Server Protocol (LSP) — Host / Client / Server separation.
Why is it called "USB-C for AI"?
It's a metaphor for accessibility. Just as USB-C collapsed the N × M problem of proprietary connectors into one cable, MCP collapses LLM-app ↔ external-system fragmentation into a 1:N protocol. But architecturally, MCP is closer to Microsoft's Language Server Protocol (LSP) — the MCP spec itself notes it was 'inspired by LSP.' So: 'USB-C as a metaphor, LSP for AI as the design.'

この記事の著者

中澤 圭志

中澤 圭志

Sales Claw maintainer

Sales Claw の設計・開発を担当。BtoB 営業自動化と AI 活用の実践者として、現場目線で情報発信中。

Share this article