TypedDict typings for OpenAPI specification
Project description
OpenAPI typed
Python typings for OpenAPI using TypedDict.
Installation
Install package from PyPI.
pip install openapi-typed
Usage
from openapi_typed import OpenAPIObject, Info # Valid OpenAPIObject openapi_valid = OpenAPIObject( openapi="3.0.0", info=Info( title="My API", version="0.0.0") ) # Invalid OpenAPIObject openapi_invalid = OpenAPIObject( openap="3.0.0", # Type-check error, unknown attribute info=Info( title="My API" # Type-check error, missing attribute `version` ) )
Development
Install development dependencies:
pip install -e .[dev]
Run tests:
pytest # OR python setup.py test
Run type-checks with mypy
:
mypy openapi_typed
Build package:
python setup.py dist
Contributing
Thanks for wanting to contribute! We will soon have a contributing page detaling how to contribute. Meanwhile, feel free to star this repository, open issues and ask for more features and support.
Please note that this project is governed by the Meeshkan Community Code of Conduct. By participating in this project, you agree to abide by its terms.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size openapi_typed-0.1.0-py2.py3-none-any.whl (5.1 kB) | File type Wheel | Python version py2.py3 | Upload date | Hashes View |
Filename, size openapi_typed-0.1.0.tar.gz (6.7 kB) | File type Source | Python version None | Upload date | Hashes View |
Close
Hashes for openapi_typed-0.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a3d4674ff3229d6428acb07cd572ad2d51104943d73adfeee9238fd70cd73524 |
|
MD5 | 080a1f2925e9a9cd0885694589c4b942 |
|
BLAKE2-256 | 88c3dc2d1ad18676f158906a5753bd1a6c595c1e095096ee9fbff19470649282 |