CloudflareSamuel MacleodAnnouncement
Introducing cf: the agentic CLI for the entire Cloudflare API
Summary
Cloudflare introduced cf, a new CLI that provides access to the entire Cloudflare API surface of over 3,000 operations, far exceeding Wrangler’s roughly 280 commands. Cf is designed primarily for AI coding agents, which account for nearly half of Wrangler usage, and defaults to JSON output with condensed formatting to minimize token consumption. The CLI includes a natural language search command, cf cli search, that helps agents discover the right operation without bloating context, and uses TypeScript-based configuration via cloudflare.config.ts for type safety. Cf is generated by Forge, Cloudflare’s internal pipeline that produces CLI commands from OpenAPI schema annotations, enabling consistent and comprehensive API coverage. The open beta is available globally via npm, and cf adopts Vite as its default local development server, with a migration path from Wrangler and maintenance support for 18 months after beta ends.
Context
In March 2026 agents were responsible for a quarter of Wrangler CLI usage, rising to 48% by the time of launch. Wrangler only covers about 280 of Cloudflare’s thousands of API operations and suffered from inconsistent command design and terminology across teams. Cloudflare needed a unified, agent-first CLI that could scale to their entire API surface.
Approach / What changed
Cloudflare built cf, a new CLI generated from their OpenAPI schema using a pipeline called Forge. The CLI defaults to JSON output, offers a natural language search command for agentic discovery, and adopts TypeScript configuration files. Vite replaces esbuild as the default local development server.
Takeaways
Cf covers over 3,000 API operations compared to Wrangler’s ~280, enabled by Forge’s schema-driven generation directly from OpenAPI annotations.
Cf defaults to JSON output and includes a natural language search command to help agents discover operations without context bloat.
Cf uses TypeScript configuration (cloudflare.config.ts) with LSP support, replacing TOML and JSONC; some configuration files have been condensed by 40%.
FAQ
How does cf help agents find the right command?
When an agent runs `--help` on cf, it is automatically told about the `cf cli search` command. This command accepts a natural language query and returns a list of matching commands from a small search index built from each API operation's description and parameters.
How does migration from Wrangler work?
The `cf migrate` command converts existing Wrangler projects to use the new TypeScript-based `cloudflare.config.ts` configuration. If the project relies on esbuild (Wrangler's default builder), cf continues to delegate builds to Wrangler during the open beta transition period.
Can humans still use cf directly?
Cf is designed for agents but remains usable by humans. JSON output is pretty-printed for human reading, and complex operations like domain purchase are presented as validated form inputs rather than long command chains, making manual interaction straightforward.
Source and freshness
- Source
- blog.cloudflare.com
- Published
- Added to Yomu
Summaries are generated from the original by a language model. Check the original before relying on it.
See the idea
Visual explainers
Keep reading
Related reading
The Good Stuff
Paid picks we use ourselves. Links carry a referral code — a subscription through one earns us a commission at no extra cost to you.
The best engineering reads, once a week
One useful email. Unsubscribe anytime.
