OpenQuizz
Une application de gestion des contenus pédagogiques
|
Data Structures | |
class | Swagger |
Functions | |
def | ref (model) |
def | extract_path (path) |
def | extract_path_params (path) |
def | parse_docstring (obj) |
def | is_hidden (resource, route_doc=None) |
def | build_request_body_parameters_schema (body_params) |
Variables | |
dictionary | PATH_TYPES |
dictionary | PY_TYPES |
RE_URL = re.compile(r"<(?:[^:<>]+:)?([^<>]+)>") | |
string | DEFAULT_RESPONSE_DESCRIPTION = "Success" |
dictionary | DEFAULT_RESPONSE = {"description": DEFAULT_RESPONSE_DESCRIPTION} |
RE_RAISES | |
def flask_restx.swagger.build_request_body_parameters_schema | ( | body_params | ) |
:param body_params: List of JSON schema of body parameters. :type body_params: list of dict, generated from the json body parameters of a request parser :return dict: The Swagger schema representation of the request body :Example: { 'name': 'payload', 'required': True, 'in': 'body', 'schema': { 'type': 'object', 'properties': [ 'parameter1': { 'type': 'integer' }, 'parameter2': { 'type': 'string' } ] } }
def flask_restx.swagger.extract_path | ( | path | ) |
Transform a Flask/Werkzeug URL pattern in a Swagger one.
def flask_restx.swagger.extract_path_params | ( | path | ) |
Extract Flask-style parameters from an URL pattern as Swagger ones.
def flask_restx.swagger.is_hidden | ( | resource, | |
route_doc = None |
|||
) |
Determine whether a Resource has been hidden from Swagger documentation i.e. by using Api.doc(False) decorator
def flask_restx.swagger.parse_docstring | ( | obj | ) |
def flask_restx.swagger.ref | ( | model | ) |
Return a reference to model in definitions
dictionary DEFAULT_RESPONSE = {"description": DEFAULT_RESPONSE_DESCRIPTION} |
string DEFAULT_RESPONSE_DESCRIPTION = "Success" |
dictionary PATH_TYPES |
dictionary PY_TYPES |
RE_RAISES |
RE_URL = re.compile(r"<(?:[^:<>]+:)?([^<>]+)>") |