Skip to content

mozilla-ai/openresponses-python

Repository files navigation

OpenResponses Types

PyPI version Python versions License

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

About

Python SDK for OpenResponses Spec

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages