About this project

Ultralytics OpenAPI is a tool that reads OpenAPI specifications (versions 3.0 through 3.2.0) and generates two outputs from a single contract: interactive API documentation and a typed Python SDK. It supports all standard HTTP operations (GET, POST, PUT, PATCH, DELETE, OPTIONS, HEAD, TRACE). Configuration is done through an `openapi.config.json` file, where you specify the source (local file or URL), the generated package name, API key environment variable, documentation base path, and various Python package metadata (authors, classifiers, version, license, etc.). The tool also supports optional CLI generation by including a consumer-owned Python source file. Key features include: - Synchronous and asynchronous Python clients - Typed resources and TypedDict responses - Multipart upload support - Automatic retries for temporary failures - Structured API errors - API key handling that stays in browser memory for docs - Deterministic static documentation builds - Customizable branding (logo, favicon, gradient tokens) - Optional auth provider module for custom credential discovery Generated SDKs default to AGPL-3.0 license but can be configured. The project is developed with Bun and uv, and includes commands for development, testing, and generation. Future SDKs for TypeScript, Go, and Java are planned.