The OpenAPI Code Generation Guide: Clients, Servers, Types
Generate TypeScript clients and servers from the spec, or scan Express, FastAPI, and Django code to recover a spec without hallucinating.
Generate TypeScript clients and servers from the spec, or scan Express, FastAPI, and Django code to recover a spec without hallucinating.
The agent wrote interfaces on both ends, ran tsc, saw green, and marked it done. The UI rendered undefined because the producer nests its payload under a wrapper the declared type never mentioned. A green check proves the code agrees with itself, not that the outside world returned the shape.
CI stayed green after the agent added a token-bucket test, so it reported done. Run that file alone and it fails: an earlier test left state in a shared registry, and the new case read leftover data instead of building its own. Fixed sequential order hides this order pollution.
The suite stayed green after a package rename, CI was green, and the changelog promised formatBudget as a public export. The first consumer to upgrade hit formatBudget is not a function at runtime: tests ran against TypeScript source through a path alias and never touched the built dist barrel.
An agent refactored a sync helper to async to support a new IO call. Every caller got the await. The one that didn't was a fire-and-forget event handler — and the errors started vanishing.
When a type error blocks the build, the agent's fastest fix is usually to erase the type instead of understanding it. The build goes green. The real bug moves somewhere quieter.