Building a CLI for all of Cloudflare
Key point
Cloudflare has unveiled a new CLI and Local Explorer that span its entire API.
Details
Cloudflare is working to unify 100+ products and about 3,000 HTTP API operations into a single CLI.
The existing Wrangler didn't sufficiently cover all of Cloudflare, but the new technical preview, cf, is the first step toward expanding this. It currently supports only some products, but the goal is to grow it into a CLI that covers the entire Cloudflare API.
The core is a new TypeScript schema.
- OpenAPI alone makes it difficult to express CLI commands, local development, Workers bindings, Agent Skills, and documentation all at once.
- So they built a TypeScript-based schema that can define APIs, commands, arguments, and context all at once.
- This schema is used to generate the CLI, config, bindings, OpenAPI schema, and more together.
Cloudflare especially emphasizes agent-friendliness.
- The command structure strongly enforces consistency.
- Redundant expressions like
getandinfoare reduced, and options like--forceand--jsonare standardized. - Even in situations where local and remote resources are mixed, the output must be clear so agents don't get confused.
The also-released Local Explorer significantly changes the local development experience.
- It's an open beta available in Wrangler and the Cloudflare Vite plugin.
- You can directly explore simulated resources like KV, R2, D1, Durable Objects, Workflows locally.
- Previously, you had to dig through
.wrangler/statedirectly or use external tools, but now you can check bindings and stored data through a local UI. - The local API is served at
/cdn-cgi/explorer/api, and through an OpenAPI spec, agents can manipulate local resources.
Cloudflare's goal is to align the shape of remote and local APIs so that the same command works naturally even with a flag like --local attached. Currently, they've laid the groundwork, and they plan to more strongly integrate Wrangler with the new CLI going forward.
This summary was generated automatically by AI. Check the original for the author's claims and context. Copyright belongs to the original author.
Our guide explains how the AI works. Report summary errors, attribution issues, or removal requests via Contact.