Introducing Forge: the open source pipeline for generating SDKs, CLIs, docs, and more
Source
blog.cloudflare.com
Date
Context
Forge lets developers connect code generators into a pipeline, so one generated output can become another generator's input. Cloudflare built this flexibility for tools such as its TypeScript command-line client, where generated API commands must coexist with handwritten local operations. The announcement says Forge already generates output used by cf and accepts OpenAPI descriptions. The broader plan is to run generation during automated change checks and provide preview clients and documentation before an API change ships. That would let teams inspect its effects on the tools customers use.
Key takeaways · AI-distilled
Cloudflare says its API has more than 3,500 operations served by hundreds of services written in Rust, Go, TypeScript and Python. Hosted SDK generators it tried did not solve the cross-team breakage problem, and some of those vendors have shut down.
Forge runs in CI on each team's API repo. It lints every API change and builds installable previews of the CLI, SDKs and docs with that change highlighted, so a change that would break generation shows up before merge instead of at release time.
Forge lets users chain generators so one output feeds another. Cloudflare needed this because its cf CLI is written in TypeScript and has handwritten commands such as cf dev and cf build that still have to appear in the generated docs.
Forge transformers can emit more than SDKs, including Cap'n Web RPC bindings, TanStack Query bindings, Zod or Valibot schemas and MCPThe Model Context Protocol — an open standard that lets any AI assistant plug into any tool or data source without custom integration code.Full definition → servers. Input is OpenAPI today, and Cloudflare names AsyncAPI, GraphQL and Protobuf as possible future formats.
Cloudflare's v4 API has been its only major version for 10 years despite many SemVer-breaking changes. The company says Forge prepares it to ship new major versions without breaking old clients, and plans extra care for Terraform. Forge is licensed Apache 2.0.
Terms in this piece · Glossary
MCP — The Model Context Protocol — an open standard that lets any AI assistant plug into any tool or data source without custom integration code.