Cloudflare put its entire API behind two MCP tools, search() and execute(): a ~1k-token fixed footprint versus ~1.17M tokens for a naive tool-per-endpoint listing. The agent writes JS against the OpenAPI and runs it in a Dynamic Worker isolate covering 2500+ endpoints with no OpenAPI dump in context (Code Mode MCP).

Key Takeaways

  • ✓Shape: the whole Cloudflare API is exposed as just search() and execute() MCP tools.
  • ✓Cost: ~1k fixed tokens vs ~1.17M for tool-per-endpoint listings.
  • ✓Runtime: agent writes JS and runs it in a Dynamic Worker isolate across 2500+ endpoints.
🧭

Turn your technical choice into a development budget

Compare 40 dev plans & simulate token costs vs $20/mo subscriptions

Action HubReady to adopt this in production?

Benchmark side-by-side against alternatives, or calculate monthly token cost vs subscription break-even.

Up NextCloudflare launches agentic CLI `cf`: 3000+ API ops from OpenAPI, JSON-default + cloudflare.config.ts
Read Now→