api OpenAPI params match /docs display order, updated tour docs and docs test

This commit is contained in:
icleary
2019-02-21 18:35:19 -07:00
parent 9f2182949d
commit 0030993631
3 changed files with 53 additions and 21 deletions
+22 -1
View File
@@ -63,7 +63,28 @@ Responder comes with built-in support for OpenAPI / marshmallow::
import responder
from marshmallow import Schema, fields
api = responder.API(title="Web Service", version="1.0", openapi="3.0.0")
description = "This is a sample server for a pet store."
terms_of_service = "http://example.com/terms/"
contact = {
"name": "API Support",
"url": "http://www.example.com/support",
"email": "support@example.com",
}
license = {
"name": "Apache 2.0",
"url": "https://www.apache.org/licenses/LICENSE-2.0.html",
}
api = responder.API(
title="Web Service",
version="1.0",
openapi="3.0.2",
docs_route='/docs',
description=description,
terms_of_service=terms_of_service,
contact=contact,
license=license,
)
@api.schema("Pet")