skillfed

openapi-generator-cli

CLI for openapi generator

openapi-generator-cli v7.24.0 756.2K downloads/30d#5,139 on PyPI26,672
Permissive license APACHE 2.0 Active released

What it is and what it does

openapi-generator-cli is a Python package that wraps the OpenAPI Generator tool, making it available as a command-line interface. It automatically generates API client libraries (SDKs), server stubs, and API documentation from OpenAPI specifications in versions 2.0 and 3.0. The package syncs daily with the upstream Maven repository to stay current with the latest generator releases.

To use it, you install the package via pip and run openapi-generator-cli commands from your terminal. The tool requires Java (JDK 11 or later) to be installed and available on your system PATH, since the underlying generator is Java-based. Alternatively, you can install the optional jdk4py extra to avoid managing a separate Java installation. Once installed, you can invoke the CLI to parse OpenAPI specs and generate code in various target languages and frameworks.

Use it for:

  • Generate type-safe API client SDKs from OpenAPI specs to reduce manual coding and keep clients in sync with API changes
  • Produce server stub code and routing scaffolds from an OpenAPI contract to accelerate backend implementation
  • Auto-generate API documentation and interactive API explorer configurations from a single OpenAPI source
  • Integrate into CI/CD pipelines to regenerate client libraries whenever the OpenAPI spec is updated
  • Support multiple programming languages and frameworks from a single OpenAPI definition

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides a Python CLI wrapper for OpenAPI Generator, enabling automatic generation of API client libraries, server stubs, and documentation from OpenAPI specifications (2.0 and 3.0).

Yes. The package is actively maintained, has no Python dependencies (low friction), carries a permissive Apache 2.0 license, and addresses a real workflow need—code generation from API specs. The only prerequisite is Java on your PATH, which is documented. Install it if you work with OpenAPI specs and want to automate SDK or stub generation.

Install

openapi-generator-cli on PyPI

pip

pip install openapi-generator-cli

uv

uv add openapi-generator-cli

poetry

poetry add openapi-generator-cli

Installing openapi-generator-cli

Before you install

Low friction installation with no Python runtime dependencies. Actively maintained with recent releases; last commit 2026-08-14. Requires Java (JDK 11 minimum) on PATH or optional jdk4py package.

License in practice

Licensed under Apache 2.0 (permissive), allowing commercial and private use with minimal restrictions.

Quickstart

pip install openapi-generator-cli
openapi-generator-cli version

Java binary (JDK 11 or later) must be available on PATH, or install with jdk4py extra: pip install openapi-generator-cli[jdk4py]

Verify before relying

  • Specific OpenAPI generator features and output language support beyond the fact sheet
  • Performance characteristics for large or complex OpenAPI specifications
  • Integration patterns with CI/CD pipelines or build systems

Package facts

License APACHE 2.0 (permissive)
Python support supports the current Python release (<4,>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance actively maintained — 24 days since the last release
Last repo commit
First released
Downloads 756,151/month — #5,139 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: openapi_generator_cli-7.24.0-py3-none-any.whl

Keywords: cli, generator, openapi

License :: OSI Approved :: Apache Software LicenseProgramming Language :: PythonProgramming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPyTyping :: Typed

Tags

openapi code generationapi client generatoropenapi spec to codesdk generation from openapiopenapi cli toolapi documentation generatoropenapi 3.0 code gen
api-code-generationopenapicli-tool

More Build Tools packages