Originally published on Loop & Retry — field notes on building LLM agents that survive production.
If you've connected an agent to a ticketing system, a database, and a search index by hand, you've written the same 200 lines three times: a client for the API, a translation layer that turns its endpoints into something a model can call as a tool, and error handling that's subtly different for each because each API fails in its own way. MCP exists to kill that duplication. It doesn't exist to make the tools on the other end good — that part is still on you, and it's where most MCP servers actually break.
What MCP is
MCP — the Model Context Protocol — is a JSON-RPC-based protocol, released by Anthropic in late 2024, that standardizes how an LLM application talks to something that can give it tools and context. Before it, every agent host wrote a bespoke integration per data source: a Slack integration, a GitHub integration, a Postgres integration, each with its own auth, its own request shape, its own error handling. Wire up three hosts to three data sources by hand and you've written nine integrations. MCP turns that into three-plus-three: one server per data source, speaking one protocol, usable by any compliant host.
The vocabulary has two sides. A host is the application driving the model — Claude Desktop, Claude Code, Cursor, VS Code, or an agent runtime you built yourself. Inside the host, a client holds one connection to one server — a separate process, local or remote, that exposes capabilities over the protocol. A single host commonly holds many client connections open at once: a filesystem server, a database server, a Slack server, all in the same agent session.
A server exposes three kinds of capability. Tools are functions the model can call with arguments and get a result back — the direct analog of function calling in a normal LLM API. Resources are readable content the host can attach to context without a tool call — a file, a document, a database schema — closer to a GET than an RPC. Prompts are reusable prompt templates a user can select, parameterized by arguments, so a server can ship "the right way to ask about this data" alongside the data itself. Most of what breaks in practice is in the first category, because tools are the only one of the three that executes a side effect.
Discovery is the other piece that matters for what comes next. A host doesn't need documentation to know what a server offers — it calls tools/list and gets back every tool's name, description, and JSON Schema input shape, at runtime, in the same session. That's convenient. It's also exactly why the next section matters: nothing forces that schema to be good, and a model deciding what to call from a list it just discovered has no other source of truth to correct a bad one.
MCP vs. a plain API
Here's the question worth answering directly, because it's the one people actually type: is MCP just an API with extra ceremony? No — and the difference is about who's on the other end of the call, not the wire format.
A REST API is designed for a client written once by a human who read the docs, decided what each endpoint means, and hardcoded that decision into a codebase. If GET /tickets?filter=open is ambiguous — does filter take a string, a query language, a JSON blob? — the human engineer resolves the ambiguity once, writes the correct call, and it stays correct forever. The API's design quality mostly shows up in developer time: a confusing endpoint costs you an afternoon reading docs, once.
An MCP tool is designed for a client that reads the shape fresh, every call, and decides what to send based on a description and a schema with no human in that specific decision. There is no afternoon of doc-reading that happens once and then never again — the model re-derives "what does filter mean" from the same words every single invocation, and it does so under uncertainty, because natural-language descriptions don't fully constrain behavior the way a human's internalized understanding does. An ambiguous MCP tool doesn't cost you an afternoon. It costs you a wrong call in production, silently, on whichever invocation happened to land on the wrong interpretation.
This is the same shift this blog has been describing since designing tools an LLM won't misuse: a tool schema is a contract with a caller that guesses. MCP doesn't introduce that problem — Claude's own function-calling API has the same contract — but MCP is where the problem shows up at scale, because MCP servers get built once and then plugged into hosts and agents their authors never anticipated. A REST API written for one internal frontend can get away with a slightly-off filters string because the one client it has learned to work around it. An MCP server has no fixed client. It gets composed into sessions with tools it's never met, driven by a model reading its schema cold, and the badly-designed tool that "worked fine" for its original author breaks the moment a different agent, with a different task, calls it the way its schema actually implies.
The other structural difference is discoverability plus composition. A REST API is one service with one set of endpoints, and a client talks to it in isolation. An MCP session is usually several servers at once — filesystem, database, Slack, your internal ticketing system — all discovered and callable in the same context, by the same model, in the same turn. That composition is the point of MCP, and it's also where a mediocre tool on one server can be driven by tainted content that arrived through a completely different server. mcp vs api, as a question, comes down to this: an API is a fixed contract for a fixed client; MCP is a runtime-discovered contract for a probabilistic caller operating inside a room full of other tools it didn't choose.
Continue reading: the rest of this post — including the sections that follow — is on Loop & Retry: read the full article
Top comments (1)
The 'contract with a caller that guesses' framing is the clearest I've seen for this, and the get_tickets(filter: str) example is exactly the shape I keep meeting in the wild. What I haven't settled, reading it: where do you put the enum when the underlying API genuinely takes a free-text expression? Collapsing it to the three shapes callers actually use loses the long tail; keeping the string means every new host re-derives the dialect from the description, and some of them send JSON. Have you found a middle shape — an enum for the common cases plus one explicitly-labeled escape hatch — that hosts actually respect?