mirror of
https://github.com/correl/openapi-core.git
synced 2024-12-01 03:00:09 +00:00
13 lines
376 B
Python
13 lines
376 B
Python
"""OpenAPI core contrib flask responses module"""
|
|
from openapi_core.validation.response.datatypes import OpenAPIResponse
|
|
|
|
|
|
class FlaskOpenAPIResponseFactory(object):
|
|
|
|
@classmethod
|
|
def create(cls, response):
|
|
return OpenAPIResponse(
|
|
data=response.data,
|
|
status_code=response._status_code,
|
|
mimetype=response.mimetype,
|
|
)
|