# `generate-client` {% admonition type="warning" name="Experimental" %} `generate-client` is an experimental feature: its flags, generated output, configuration schema, and custom-generator API may change in any minor release until it's stable. We'd love your feedback while we stabilize it. {% /admonition %} ## Introduction The `generate-client` command generates a typed TypeScript client from an OpenAPI 3.x description. Swagger 2.0 descriptions are also accepted and normalized to the 3.x shape before generation. The description is validated first: unresolved `$ref`s or structural errors fail generation with the problems listed, independent of your lint configuration. The generated client has zero runtime dependencies by default — it uses only web-standard APIs (`fetch`, `AbortController`, `URLSearchParams`), so it runs in browsers, Node, Bun, Deno, and edge runtimes. By default it emits a single self-contained file with inline types and one async function per operation. The `` argument is a file path, a URL, or an [`apis:` alias](../configuration/index.md), resolved the same way as in other commands such as `bundle` and `lint`. An alias, or a path matching an api's `root`, uses that api's `client` block and `clientOutput`; an unmatched path or URL uses the top-level `client` defaults. With no argument, a client is generated for every api that declares a `client` block or a `clientOutput` (see [`client` configuration](../configuration/reference/client.md)). This page covers running the command; for the generated client's runtime API (auth, error handling, middleware, retries, and the add-on generators), see [Use the generated client](../guides/use-generated-client.md). ## Usage ```bash redocly generate-client redocly generate-client redocly generate-client [--output=] [--output-mode=] [--runtime=] redocly generate-client [--generator=] [--args-style=