{ "info": { "author": "dorthu", "author_email": "", "bugtrack_url": null, "classifiers": [], "description": "openapi3\n========\n\nA Python `OpenAPI 3 Specification`_ client and validator for Python 3.\n\n.. image:: https://travis-ci.org/Dorthu/openapi3.svg?branch=master\n :target: https://travis-ci.org/Dorthu/openapi3\n\n\n.. image:: https://badge.fury.io/py/openapi3.svg\n :target: https://badge.fury.io/py/openapi3\n\n\nValidation Mode\n---------------\n\nThis module can be run against a spec file to validate it like so::\n\n python3 -m openapi3 /path/to/spec\n\nUsage as a Client\n-----------------\n\nThis library also functions as an interactive client for arbitrary OpenAPI 3\nspecs. For example, using `Linode's OpenAPI 3 Specification`_ for reference::\n\n from openapi3 import OpenAPI\n\n # load the spec file and read the yaml\n with open('openapi.yaml') as f:\n spec = yaml.safe_load(f.read())\n\n # parse the spec into python - this will raise if the spec is invalid\n api = OpenAPI(spec)\n\n # call operations and receive result models\n regions = api.call_getRegions()\n\n # authenticate using a securityScheme defined in the spec's components.securtiySchemes\n api.authenticate('personalAccessToken', my_token)\n\n # call an operation that requires authentication\n linodes = api.call_getLinodeInstances()\n\n # call an opertaion with parameters\n linode = api.call_getLinodeInstance(parameters={\"linodeId\": 123})\n\n # the models returns are all of the same (generated) type\n print(type(linode)) # openapi.schemas.Linode\n type(linode) == type(linodes.data[0]) # True\n\n # call an operation with a request body\n new_linode = api.call_createLinodeInstance(data={\"region\":\"us-east\",\"type\":\"g6-standard-2\"})\n\n # the returned models is still of the correct type\n type(new_linode) == type(linode) # True\n\nHTTP basic authentication and HTTP digest authentication works like this::\n\n # authenticate using a securityScheme defined in the spec's components.securtiySchemes\n # Tuple with (username, password) as second argument\n api.authenticate('basicAuth', ('username', 'password'))\n\nRoadmap\n-------\n\nThe following features are planned for the future:\n\n* Request body models, creation, and validation.\n* Parameters interface with validation and explicit typing.\n* Support for more authentication types.\n* Support for non-json request/response content.\n* Full support for all objects defined in the specification.\n\n.. _OpenAPI 3 Specification: https://openapis.org\n.. _Linode's OpenAPI 3 Specification: https://developers.linode.com/api/v4\n\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/dorthu/openapi3", "keywords": "", "license": "BSD 3-Clause License", "maintainer": "", "maintainer_email": "", "name": "openapi3", "package_url": "https://pypi.org/project/openapi3/", "platform": "", "project_url": "https://pypi.org/project/openapi3/", "project_urls": { "Homepage": "https://github.com/dorthu/openapi3" }, "release_url": "https://pypi.org/project/openapi3/1.0.0/", "requires_dist": [ "PyYaml", "requests" ], "requires_python": "", "summary": "Client and Validator of OpenAPI 3 Specifications", "version": "1.0.0" }, "last_serial": 5783153, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "36c06a680f2920c5b9d7c575f034e8a3", "sha256": "09bff310582915784ed389dd637c1045148814d4d57b3b19e7467d4020f0bef0" }, "downloads": -1, "filename": "openapi3-0.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "36c06a680f2920c5b9d7c575f034e8a3", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.4", "size": 19770, "upload_time": "2018-06-25T13:48:51", "url": "https://files.pythonhosted.org/packages/2b/1e/7ee0ee7b98e7d185744175cae4f7eac5561a097c0e966f3f28863836de32/openapi3-0.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c9536574915611a2c9ea327dd74a9906", "sha256": "f8632c5b6ba8e47f2f86c0708bfc253c5a9747d8e4d340ec750bf15b2a6f1c35" }, "downloads": -1, "filename": "openapi3-0.0.1.tar.gz", "has_sig": false, "md5_digest": "c9536574915611a2c9ea327dd74a9906", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.4", "size": 16182, "upload_time": "2018-06-25T13:48:52", "url": "https://files.pythonhosted.org/packages/15/14/2e9d5c4809a842e98d1b03a3f9ea648524d4923b051840f61f354dbb90db/openapi3-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "ef9346ea801a13150a958f9272a62b37", "sha256": "230c4cd3ed4b3ba4b0f19892a52e15c22306c674773c331be88a3c64245a5115" }, "downloads": -1, "filename": "openapi3-0.0.2-py3-none-any.whl", "has_sig": false, "md5_digest": "ef9346ea801a13150a958f9272a62b37", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 20825, "upload_time": "2019-06-21T17:39:37", "url": "https://files.pythonhosted.org/packages/4f/01/48878830c8a93f945073d20605feccaf5fbd9c981168b56ea813f81ad509/openapi3-0.0.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "4583e990d27f487b07aef937d0e4852a", "sha256": "4305b6c92d29510502b36e098a9154f75ac0dd4c254f82d46f0d1e517a7ff38e" }, "downloads": -1, "filename": "openapi3-0.0.2.tar.gz", "has_sig": false, "md5_digest": "4583e990d27f487b07aef937d0e4852a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 23147, "upload_time": "2019-06-21T17:39:39", "url": "https://files.pythonhosted.org/packages/73/60/03b6585326f526332be2a0d861150de4a0385bea3109680d3ec3bba33c4c/openapi3-0.0.2.tar.gz" } ], "1.0.0": [ { "comment_text": "", "digests": { "md5": "ae1be57c4189e31241eebda5a36dbb9f", "sha256": "2f7fd132fc62b3d6a1dea9d160c82849dd6eb3e4ee7b72f336bf666de473eaae" }, "downloads": -1, "filename": "openapi3-1.0.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "ae1be57c4189e31241eebda5a36dbb9f", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 21289, "upload_time": "2019-09-04T19:48:13", "url": "https://files.pythonhosted.org/packages/5a/fa/beec306d8ecfc146a8953122b77d7c5898c54e0c3f25bd82dac7f30a4c69/openapi3-1.0.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "d7cbba22a804b35b25089355fddf81ed", "sha256": "d0c84c942bc89c323069db6ea1e8c7aca470c2acda427d113dae3d92bdd086e6" }, "downloads": -1, "filename": "openapi3-1.0.0.tar.gz", "has_sig": false, "md5_digest": "d7cbba22a804b35b25089355fddf81ed", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 23240, "upload_time": "2019-09-04T19:48:15", "url": "https://files.pythonhosted.org/packages/35/9c/b984cccbd9f66316f9ed7ebf22523a73f196cac8786efdca30e37069d759/openapi3-1.0.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "ae1be57c4189e31241eebda5a36dbb9f", "sha256": "2f7fd132fc62b3d6a1dea9d160c82849dd6eb3e4ee7b72f336bf666de473eaae" }, "downloads": -1, "filename": "openapi3-1.0.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "ae1be57c4189e31241eebda5a36dbb9f", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 21289, "upload_time": "2019-09-04T19:48:13", "url": "https://files.pythonhosted.org/packages/5a/fa/beec306d8ecfc146a8953122b77d7c5898c54e0c3f25bd82dac7f30a4c69/openapi3-1.0.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "d7cbba22a804b35b25089355fddf81ed", "sha256": "d0c84c942bc89c323069db6ea1e8c7aca470c2acda427d113dae3d92bdd086e6" }, "downloads": -1, "filename": "openapi3-1.0.0.tar.gz", "has_sig": false, "md5_digest": "d7cbba22a804b35b25089355fddf81ed", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 23240, "upload_time": "2019-09-04T19:48:15", "url": "https://files.pythonhosted.org/packages/35/9c/b984cccbd9f66316f9ed7ebf22523a73f196cac8786efdca30e37069d759/openapi3-1.0.0.tar.gz" } ] }