Handcrafting Codes← Index

AI

MCP Is Dead (For Agents That Can Code)

If an agent can write and run code, it doesn't need a menu of tools

Oct 08, 2026 / 7 min read / By the author

Everyone is talking about MCP

Everyone seems to be talking about MCP. New MCP servers come out every week. People share lists of the best ones to install, and companies announce MCP support to show that they are "AI first."

After watching this for a while, and after reading a lot about how agents are built today, I came to a different conclusion. If an agent runs in a good harness, MCP is almost useless.

An agent that writes code does not need a menu

A harnessed agent can write code and run it. When an agent can do that, it can use any API that has documentation and a credential. Nobody needs to wrap that API first as a list of tools with JSON schemas. The agent reads the documentation, writes a small client, calls the API, and filters the result before it reaches the model.

From what I have seen with coding agents, this already works well. When an agent needs a system it has never used, it can build the integration on the spot. It writes a short script for the REST API and uses the access the harness gives it. There is no server process to keep running. There is no registry. There is no schema that can get out of date.

MCP was built for a different situation. In late 2024, most models lived in a chat window with no place to run code. The only way they could take an action was to send a structured tool call and wait for the app to run it. MCP made that exchange standard. For that situation, it was a good idea.

The harness changed this. With a tool call, the model asks someone else to do the work. With code, the model does the work itself.

Even the people behind MCP are moving away from tool calls

The best evidence does not come from MCP critics. It comes from the companies that built MCP and promote it.

In September 2025, Cloudflare wrote a post that starts with "It turns out we've all been using MCP wrong." The authors found that agents could handle more tools, and more complex tools, when the tools became a TypeScript API and the model wrote code to call them (Cloudflare). Their reason was simple. Models have seen millions of real code projects. They have seen very few examples of tool calls, and most of those examples were created just for training.

About six weeks later, Anthropic, the company that created MCP, said the same thing (Anthropic). Its engineers described two problems with direct tool calls. First, every tool definition is loaded into the model's context at the start. Second, every result from every step goes back through the model. Their example is familiar to anyone who works with CRM: copy a meeting transcript from Google Drive into a Salesforce record. With direct tool calls, the full transcript passes through the model two times. When the agent wrote code instead, it loaded only the tools it needed, and token use for that task went down from 150,000 to 2,000. The post ends by suggesting that agents save working code as reusable skills.

In February 2026, Cloudflare went further (Cloudflare). Its API has more than 2,500 endpoints. If each endpoint were a normal MCP tool, the definitions alone would use about 1.17 million tokens. That is more than any top model can hold. The new Cloudflare MCP server has only two tools, search and execute, and both accept code. The full API fits in about 1,000 tokens.

After that, developers started to say it openly. In February, Eric Holmes wrote "MCP is dead. Long live the CLI", and it reached the top of Hacker News. His advice to companies was short: "Ship a good API, then ship a good CLI." In March, Perplexity's CTO, Denis Yarats, said at the Ask 2026 conference that Perplexity had moved its own agents away from MCP and back to APIs and CLIs. His reasons were the cost in context and difficult authentication (report). Perplexity still offers an MCP server for other people. It just stopped using MCP for its own agents.

All of these fixes have one thing in common. Each one makes MCP act less like MCP. When a server has only two tools and both accept code, what you really have is a place to run code.

Where MCP still makes sense

There are two cases where I agree MCP is useful.

The first case is a model with no harness. A simple chat session has no place to write and run code, so a protocol that gives it ready-made actions makes sense. This is why MCP still works well in consumer chat apps and desktop assistants, where a user clicks "connect" and expects it to work.

The second case is small models, around 7 to 15 billion parameters. Maybe. But most people who run models of that size on their own machines use them for coding. That puts them back in the group of agents that do not need MCP.

There is a third argument, and it is the one I hear most often: authentication and governance. Large companies want agents to access Salesforce or SAP with credentials that are limited, can be cancelled, and are logged. They do not want a long-lived token sitting inside a sandbox. The MCP team clearly understands this. The 2026-07-28 specification made the protocol stateless, put method and tool names in HTTP headers so gateways can route and control them, and made OAuth stronger. The release notes say that authorization is where developers spend most of their integration time. Security has also been a problem. In April, OX Security reported that the official SDKs would run any command written in an MCP configuration file, and Anthropic said this was expected behavior (Cloud Security Alliance).

I take governance seriously. Managing enterprise Salesforce orgs is my job. But look at what this argument really protects: a limited HTTP endpoint with OAuth in front of it. That is an API gateway. Cloudflare's own Code Mode post agrees. It says the lasting value of MCP is a standard way to connect and authorize, and that tool calling is the part to replace. So the useful part of MCP is the boring part. The part people get excited about, a list of tools for the model to choose from, is the part that is dying.

Download numbers do not prove much either. The MCP team reports close to half a billion SDK downloads per month. Downloads show how many products added MCP support. They do not show whether real working agents actually use it.

What I would build instead

If your agents run in a harness, start from the other side. Give them a sandbox to run code, a service that hands out short-lived, limited tokens, and good API documentation. Let the agents write the integrations. Keep the scripts that work and turn them into skills. Log every call at the gateway, the same way you log any service account.

If your company offers a platform, build a clean API and a good CLI first. An MCP server is a nice extra for chat apps. It should not be the only way in.

If you plan to spend months building and hosting many MCP servers for your internal agents, ask one question first: can those agents write code? If the answer is yes, you are building a menu for someone who can already cook.

I have been wrong before. Maybe in a year, better authentication will make MCP the standard way for enterprise agents to connect, and I will have to admit I was wrong. But even then, MCP will have won only as plumbing, something that runs in the background and nobody thinks about. That is not the future people were excited about.