{ "info": { "author": "Steven Loria, Josh Carp", "author_email": "sloria1@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6" ], "description": "*************\nhapic-apispec\n*************\n\nFriendly fork of apispec waiting for merging `instance support `_\n\n.. image:: https://badge.fury.io/py/apispec.svg\n :target: http://badge.fury.io/py/apispec\n :alt: Latest version\n\n.. image:: https://travis-ci.org/marshmallow-code/apispec.svg?branch=dev\n :target: https://travis-ci.org/marshmallow-code/apispec\n\n.. image:: https://readthedocs.org/projects/apispec/badge/\n :target: https://apispec.readthedocs.io/\n :alt: Documentation\n\n.. image:: https://img.shields.io/badge/marshmallow-3-blue.svg\n :target: https://marshmallow.readthedocs.io/en/latest/upgrading.html\n :alt: marshmallow 3 compatible\n\nA pluggable API specification generator. Currently supports the `OpenAPI Specification `_ (f.k.a. the Swagger specification).\n\nFeatures\n========\n\n- Supports OpenAPI Specification version 2 (f.k.a. the Swagger specification) with limited support for version 3.\n- Framework-agnostic\n- Includes plugins for `marshmallow `_, `Flask `_, `Tornado `_, and `bottle `_.\n- Utilities for parsing docstrings\n\nExample Application\n===================\n\n.. code-block:: python\n\n from apispec import APISpec\n from flask import Flask, jsonify\n from marshmallow import Schema, fields\n\n # Create an APISpec\n spec = APISpec(\n title='Swagger Petstore',\n version='1.0.0',\n plugins=[\n 'apispec.ext.flask',\n 'apispec.ext.marshmallow',\n ],\n )\n\n # Optional marshmallow support\n class CategorySchema(Schema):\n id = fields.Int()\n name = fields.Str(required=True)\n\n class PetSchema(Schema):\n category = fields.Nested(CategorySchema, many=True)\n name = fields.Str()\n\n # Optional Flask support\n app = Flask(__name__)\n\n @app.route('/random')\n def random_pet():\n \"\"\"A cute furry animal endpoint.\n ---\n get:\n description: Get a random pet\n responses:\n 200:\n description: A pet to be returned\n schema: PetSchema\n \"\"\"\n pet = get_random_pet()\n return jsonify(PetSchema().dump(pet).data)\n\n # Register entities and paths\n spec.definition('Category', schema=CategorySchema)\n spec.definition('Pet', schema=PetSchema)\n with app.test_request_context():\n spec.add_path(view=random_pet)\n\n\nGenerated OpenAPI Spec\n----------------------\n\n.. code-block:: python\n\n spec.to_dict()\n # {\n # \"info\": {\n # \"title\": \"Swagger Petstore\",\n # \"version\": \"1.0.0\"\n # },\n # \"swagger\": \"2.0\",\n # \"paths\": {\n # \"/random\": {\n # \"get\": {\n # \"description\": \"A cute furry animal endpoint.\",\n # \"responses\": {\n # \"200\": {\n # \"schema\": {\n # \"$ref\": \"#/definitions/Pet\"\n # },\n # \"description\": \"A pet to be returned\"\n # }\n # },\n # }\n # }\n # },\n # \"definitions\": {\n # \"Pet\": {\n # \"properties\": {\n # \"category\": {\n # \"type\": \"array\",\n # \"items\": {\n # \"$ref\": \"#/definitions/Category\"\n # }\n # },\n # \"name\": {\n # \"type\": \"string\"\n # }\n # }\n # },\n # \"Category\": {\n # \"required\": [\n # \"name\"\n # ],\n # \"properties\": {\n # \"name\": {\n # \"type\": \"string\"\n # },\n # \"id\": {\n # \"type\": \"integer\",\n # \"format\": \"int32\"\n # }\n # }\n # }\n # },\n # }\n\n spec.to_yaml()\n # definitions:\n # Pet:\n # enum: [name, photoUrls]\n # properties:\n # id: {format: int64, type: integer}\n # name: {example: doggie, type: string}\n # info: {description: 'This is a sample Petstore server. You can find out more ', title: Swagger Petstore, version: 1.0.0}\n # parameters: {}\n # paths: {}\n # security:\n # - apiKey: []\n # swagger: '2.0'\n # tags: []\n\n\nDocumentation\n=============\n\nDocumentation is available at http://apispec.readthedocs.io/ .\n\nEcosystem\n=========\n\nA list of apispec-related libraries can be found at the GitHub wiki here:\n\nhttps://github.com/marshmallow-code/apispec/wiki/Ecosystem\n\nLicense\n=======\n\nMIT licensed. See the bundled `LICENSE `_ file for more details.\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/algoo/apispec", "keywords": "apispec swagger openapi specification documentation spec rest api", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "hapic_apispec", "package_url": "https://pypi.org/project/hapic_apispec/", "platform": "", "project_url": "https://pypi.org/project/hapic_apispec/", "project_urls": { "Homepage": "https://github.com/algoo/apispec" }, "release_url": "https://pypi.org/project/hapic_apispec/0.37.0/", "requires_dist": null, "requires_python": "", "summary": "A pluggable API specification generator. Currently supports the OpenAPI specification (f.k.a. the Swagger specification).", "version": "0.37.0" }, "last_serial": 3871391, "releases": { "0.35.0": [ { "comment_text": "", "digests": { "md5": "29ee26448ad35ef000fceb8dd23262c9", "sha256": "2efc48d44a565af277f6728a6bf452cfc5d559f123410d5ee24b39734225b445" }, "downloads": -1, "filename": "hapic_apispec-0.35.0.tar.gz", "has_sig": false, "md5_digest": "29ee26448ad35ef000fceb8dd23262c9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 50715, "upload_time": "2018-04-27T22:44:36", "url": "https://files.pythonhosted.org/packages/0c/da/62d67a888d65cc4751d2167ca6ce146fbfc767a2225463ac38b1858aa130/hapic_apispec-0.35.0.tar.gz" } ], "0.37.0": [ { "comment_text": "", "digests": { "md5": "8d97bf229daa0ef14dbf41d63400b138", "sha256": "cf8da2ea75586953b339c9439c9ca8a86c058f2adff657c0c8ed553d1b3a1ed3" }, "downloads": -1, "filename": "hapic_apispec-0.37.0.tar.gz", "has_sig": false, "md5_digest": "8d97bf229daa0ef14dbf41d63400b138", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 50763, "upload_time": "2018-05-17T08:18:16", "url": "https://files.pythonhosted.org/packages/92/f5/f1c55739a61220df57dfd0a194d2984d780c822e6a87036d129d3bba0ddf/hapic_apispec-0.37.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "8d97bf229daa0ef14dbf41d63400b138", "sha256": "cf8da2ea75586953b339c9439c9ca8a86c058f2adff657c0c8ed553d1b3a1ed3" }, "downloads": -1, "filename": "hapic_apispec-0.37.0.tar.gz", "has_sig": false, "md5_digest": "8d97bf229daa0ef14dbf41d63400b138", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 50763, "upload_time": "2018-05-17T08:18:16", "url": "https://files.pythonhosted.org/packages/92/f5/f1c55739a61220df57dfd0a194d2984d780c822e6a87036d129d3bba0ddf/hapic_apispec-0.37.0.tar.gz" } ] }