Ravenports generated: 02 Jul 2018 06:37
[ravenports.git] / bucket_53 / python-flask-swagger
1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
2
3 NAMEBASE=               python-flask-swagger
4 VERSION=                0.2.13
5 KEYWORDS=               python devel
6 VARIANTS=               py27 py36 py37
7 SDESC[py36]=            Extract swagger specs from your flask proj (PY 36)
8 SDESC[py37]=            Extract swagger specs from your flask proj (PY 37)
9 SDESC[py27]=            Extract swagger specs from your flask proj (PY 27)
10 HOMEPAGE=               https://github.com/gangverk/flask-swagger
11 CONTACT=                Python_Automaton[python@ironwolf.systems]
12
13 DOWNLOAD_GROUPS=        main
14 SITES[main]=            PYPI/f/flask-swagger
15 DISTFILE[1]=            flask-swagger-0.2.13.tar.gz:main
16 DF_INDEX=               1
17 SPKGS[py36]=            single
18 SPKGS[py37]=            single
19 SPKGS[py27]=            single
20
21 OPTIONS_AVAILABLE=      PY27 PY36 PY37
22 OPTIONS_STANDARD=       none
23 VOPTS[py36]=            PY27=OFF PY36=ON PY37=OFF
24 VOPTS[py37]=            PY27=OFF PY36=OFF PY37=ON
25 VOPTS[py27]=            PY27=ON PY36=OFF PY37=OFF
26
27 DISTNAME=               flask-swagger-0.2.13
28
29 GENERATED=              yes
30
31 [PY36].BUILDRUN_DEPENDS_ON=             python-Flask:single:py36
32                                         python-PyYAML:single:py36
33 [PY36].USES_ON=                         python:py36
34
35 [PY37].BUILDRUN_DEPENDS_ON=             python-Flask:single:py37
36                                         python-PyYAML:single:py37
37 [PY37].USES_ON=                         python:py37
38
39 [PY27].BUILDRUN_DEPENDS_ON=             python-Flask:single:py27
40                                         python-PyYAML:single:py27
41 [PY27].USES_ON=                         python:py27
42
43 [FILE:3685:descriptions/desc.single]
44 flask-swagger
45 =============
46
47 A Swagger 2.0 spec extractor for Flask
48
49 Install:
50
51 ::
52
53     pip install flask-swagger
54
55 Flask-swagger provides a method (swagger) that inspects the Flask app
56 for endpoints that contain YAML docstrings with Swagger 2.0
57 `Operation
58 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#op
59 eration-object>`__
60 objects.
61
62 ::
63
64     class UserAPI(MethodView):
65
66         def post(self):
67             """
68             Create a new user
69             ---
70             tags:
71               - users
72             definitions:
73               - schema:
74                   id: Group
75                   properties:
76                     name:
77                      type: string
78                      description: the group's name
79             parameters:
80               - in: body
81                 name: body
82                 schema:
83                   id: User
84                   required:
85                     - email
86                     - name
87                   properties:
88                     email:
89                       type: string
90                       description: email for user
91                     name:
92                       type: string
93                       description: name for user
94                     address:
95                       description: address for user
96                       schema:
97                         id: Address
98                         properties:
99                           street:
100                             type: string
101                           state:
102                             type: string
103                           country:
104                             type: string
105                           postalcode:
106                             type: string
107                     groups:
108                       type: array
109                       description: list of groups
110                       items:
111                         $ref: "#/definitions/Group"
112             responses:
113               201:
114                 description: User created
115             """
116             return {}
117
118 Flask-swagger supports docstrings in methods of MethodView classes and
119 regular Flask view functions.
120
121 Following YAML conventions, flask-swagger searches for ``---``,
122 everything preceding is provided as ``summary`` (first line) and
123 ``description`` (following lines) for the endpoint while everything
124 after is parsed as a swagger
125 `Operation
126 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#op
127 eration-object>`__
128 object.
129
130 In order to support inline definition of
131 `Schema
132 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#sc
133 hemaObject>`__
134 objects in
135 `Parameter
136 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#pa
137 rameterObject>`__
138 and
139 `Response
140 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#re
141 sponsesObject>`__
142 objects, flask-swagger veers a little off from the standard. We require
143 an ``id`` field for the inline Schema which is then used to correctly
144 place the
145 `Schema
146 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#sc
147 hemaObject>`__
148 object in the
149 `Definitions
150 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#de
151 finitionsObject>`__
152 object.
153
154 `Schema
155 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#sc
156 hemaObject>`__
157 objects can be defined in a definitions section within the docstrings (see
158 group object above) or within responses or parameters (see user object
159 above). We alo support schema objects nested within the properties of other
160 `Schema
161 <https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#sc
162 hemaObject>`__
163 objects. An example is shown above with the address property of User.
164
165
166 [FILE:106:distinfo]
167 42420efbed1aad86f7ca6bb869df550e09591e1d540ebd3040c197906c0f0be6         8007 flask-swagger-0.2.13.tar.gz
168