mirror of
https://github.com/kennethreitz/responder.git
synced 2026-06-05 23:00:17 +00:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 8a46a87b3e |
+5
-4
@@ -44,12 +44,13 @@ class API:
|
|||||||
*,
|
*,
|
||||||
debug=False,
|
debug=False,
|
||||||
title=None,
|
title=None,
|
||||||
version=None,
|
version="1.0",
|
||||||
description=None,
|
description=None,
|
||||||
terms_of_service=None,
|
terms_of_service=None,
|
||||||
contact=None,
|
contact=None,
|
||||||
license=None,
|
license=None,
|
||||||
openapi=None,
|
openapi=None,
|
||||||
|
openapi_version="3.0.2",
|
||||||
openapi_route="/schema.yml",
|
openapi_route="/schema.yml",
|
||||||
static_dir="static",
|
static_dir="static",
|
||||||
static_route="/static",
|
static_route="/static",
|
||||||
@@ -117,9 +118,9 @@ class API:
|
|||||||
if openapi or docs_route:
|
if openapi or docs_route:
|
||||||
self.openapi = OpenAPISchema(
|
self.openapi = OpenAPISchema(
|
||||||
app=self,
|
app=self,
|
||||||
title="Web Service",
|
title=title,
|
||||||
version="1.0",
|
version=version,
|
||||||
openapi="3.0.2",
|
openapi=openapi_version,
|
||||||
docs_route=docs_route,
|
docs_route=docs_route,
|
||||||
description=description,
|
description=description,
|
||||||
terms_of_service=terms_of_service,
|
terms_of_service=terms_of_service,
|
||||||
|
|||||||
+1
-3
@@ -283,9 +283,7 @@ class Response:
|
|||||||
self.content = None #: A bytes representation of the response body.
|
self.content = None #: A bytes representation of the response body.
|
||||||
self.mimetype = None
|
self.mimetype = None
|
||||||
self.encoding = DEFAULT_ENCODING
|
self.encoding = DEFAULT_ENCODING
|
||||||
self.media = (
|
self.media = None #: A Python object that will be content-negotiated and sent back to the client. Typically, in JSON formatting.
|
||||||
None
|
|
||||||
) #: A Python object that will be content-negotiated and sent back to the client. Typically, in JSON formatting.
|
|
||||||
self._stream = None
|
self._stream = None
|
||||||
self.headers = (
|
self.headers = (
|
||||||
{}
|
{}
|
||||||
|
|||||||
Reference in New Issue
Block a user