Python SDK for OpenResponses specification
Project Links
Meta
Author: mozilla.ai
Requires Python: >=3.11
Classifiers
Development Status
- 4 - Beta
Intended Audience
- Developers
License
- OSI Approved :: Apache Software License
Programming Language
- Python :: 3.11
- Python :: 3.12
- Python :: 3.13
Typing
- Typed
OpenResponses Types
Python SDK providing Pydantic models for the OpenResponses API specification.
Installation
pip install openresponses-types
Development
Setup
# Clone the repository
git clone https://github.com/mozilla-ai/openresponses-python.git
cd openresponses-python
# Create virtual environment and install dependencies
uv venv && source .venv/bin/activate
uv sync --group dev
Generate Types
The types are generated from the OpenResponses OpenAPI specification:
# Generate types (fetches spec if changed)
uv run python scripts/generate_types.py
# Force regeneration
uv run python scripts/generate_types.py --force
# Check if spec has changed
uv run python scripts/generate_types.py --check
# Show current spec hash
uv run python scripts/generate_types.py --version
Versioning
This package follows Semantic Versioning:
- Major: Breaking changes to helper types/API
- Minor: New types from spec updates, new helpers
- Patch: Bug fixes, documentation updates
The package includes a __spec_hash__ attribute to track which OpenAPI spec version was used to generate the types.
License
Apache 2.0 - see LICENSE for details.
Links
Wheel compatibility matrix
Files in release
Extras:
None
Dependencies:
pydantic
(<3.0,>=2.0)