Hiding MCP methods behind Code Mode killed discovery; a routing skill layer fixed it

Kindly-Bag763 · reddit · 2026-11-13

The author describes a real trade-off with MCP tool exposure. Cloudflare estimates 2,500 API methods exposed as MCP tools would cost 1.17M tokens, so everything got hidden behind Code Mode: two tools, search() and execute(). Context was fixed — but discovery broke: the agent never realized a catalogue existed to search.

What worked: a routing layer in front.

Caveats: wrong-skill picks and bad JS still happen; not every sequence batches. Still better than hiding everything and hoping. Original writeup is a Russian blog post with the actual skill files.

Related event: Code Mode MCP in Practice: Replacing Thousands of Tools with Two Endpoints(3 posts)→

Original post →

More from coding & agent

coding & agent channel →