belso.validator package

Submodules

belso.validator.validator module

class belso.validator.validator.SchemaValidator[source]

Bases: object

static validate(data, schema)[source]

Validate that the provided data conforms to the given schema.

Return type:

Dict[str, Any]

Args

param data:

the data to validate (either a dict or JSON string).

type data:

Any

param schema:

the schema to validate against.

type schema:

Type[Schema]

Returns:

  • Dict[str, Any]: the validated data.

Module contents

class belso.validator.SchemaValidator[source]

Bases: object

static validate(data, schema)[source]

Validate that the provided data conforms to the given schema.

Return type:

Dict[str, Any]

Args

param data:

the data to validate (either a dict or JSON string).

type data:

Any

param schema:

the schema to validate against.

type schema:

Type[Schema]

Returns:

  • Dict[str, Any]: the validated data.