openapi-generator-cli
CLI for openapi generator
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-cliuv
uv add openapi-generator-clipoetry
poetry add openapi-generator-cliInstalling 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
Tags
More Build Tools packages
Provides reusable utilities for Python…
permissive · top 100 on PyPI
tqdmWraps any iterable to display a real-time…
copyleft · top 100 on PyPI
pippip is the standard installer for Python…
permissive · top 100 on PyPI
hatchlingHatchling is a standards-compliant Python build…
permissive · top 100 on PyPI
grpcio-toolsGenerates Python gRPC service stubs and message…
permissive · top 1,000 on PyPI
pre-commitpre-commit is a framework for installing and…
permissive · top 1,000 on PyPI
openapi-python-clientGenerates type-annotated Python HTTP clients…
permissive · top 5,000 on PyPI
legit-api-clientA Python client library for interacting with an…
permissive · top 15,000 on PyPI
tapipyTapipy is a Python SDK that automatically…
permissive · top 15,000 on PyPI
gooddata-api-clientProvides a Python client for the GoodData API,…
permissive · top 15,000 on PyPI
trieve-py-clientProvides a Python client library for the Trieve…
unclear · top 15,000 on PyPI
openapi-spec-validatorValidates OpenAPI specifications (versions 2.0,…
permissive · top 1,000 on PyPI
qase-api-v2-clientA Python client library for the Qase TestOps…
unclear · top 15,000 on PyPI
openapi3Parses and validates OpenAPI 3 specifications,…
permissive · top 15,000 on PyPI
aiopenapi3Parses and validates OpenAPI 3 specifications…
permissive · top 15,000 on PyPI
mastercard-oauth1-signerGenerates OAuth 1.0a-compliant signatures for…
permissive · top 15,000 on PyPI