
Cloudflare Introduces Forge, an Open-Source Pipeline for Generating SDKs and CLIs
Cloudflare has released Forge, an open-source, pluggable pipeline that runs in CI and generates SDKs, CLIs, documentation and libraries directly from API definitions. It ships under the Apache 2.0 license.
Cloudflare has introduced Forge, an open-source, pluggable generation pipeline that turns API definitions into SDKs, CLIs, documentation and libraries. According to the company, anyone can deploy and run it for free.
The project is early in its life, but it already generates the output required for the cf CLI. Over the next few months it will power Cloudflare's API documentation and SDKs.

Why Cloudflare built Forge
Cloudflare's API has more than 3,500 operations, and the hundreds of services behind it are written in Rust, Go, TypeScript and Python. Building a single CLI for the entire API required a generation pipeline able to handle that scale across languages and teams.
Forge runs in CI, on each team's API repositories. It lints every change and produces preview builds of the CLI, docs and SDKs with only the new changes highlighted, so teams can catch mistakes before merging. The idea mirrors Workers Previews, applied to SDK generation.
Transformers and chained generation
Forge transformers can be chained, producing outputs from other outputs. The original OpenAPI definition is built into the TypeScript SDK, which is then used to generate the cf CLI and Cap'n Web specifications.

Forge supports OpenAPI as an input today, but is designed to allow AsyncAPI, GraphQL, Cap'n Proto, Protobuf and other formats later. Because transformers flow information from one output to another, they can also generate TanStack Query bindings, Zod or Valibot schemas, MCP servers, dashboards or full applications.
Versioning and open source
Forge also supports better API versioning. Cloudflare's v4 API has been the company's major version for ten years, and the company is working on an approach that would let it ship new major API versions without breaking older clients or SDKs.
New SDKs are planned for TypeScript, Rust, Python, Go, PHP and Terraform. Forge is released under the permissive Apache 2.0 license; users can run it for any purpose, with custom modifications, privately and for free.
SiTech — AI-powered web development
We build fast, modern websites and bring AI into real business workflows. Have a project or a question? We'd love to help.