API Documentation¶
-
class
openapi_toolkit.OpenAPI(filename, spec)¶ OpenAPI Specification Manager
-
find_input_schema(path, method, content_type)¶ Searches for a request body schema by path, method, and content_type
-
find_path(path, method=None)¶ Searches for Path data (incomplete)
-
classmethod
load(filename, preprocessor=None, resolve=True, validate=True)¶ Loads an OpenAPI Specification from a file
-
save(filename)¶ Save the loaded OpenAPI specification to a file
-
-
class
openapi_toolkit.JsonSchema(formats=None, validators=None)¶ -
validate(schema, value)¶ Validates a value against a schema defintion
-
-
openapi_toolkit.schema_format()¶ Decorator to add custom JSONSchema format checkers
e.g.
@schema_format.checks('uuid', ValueError) def uuid_format(value): return uuid.UUID(value)