Documentation ¶
Overview ¶
Package schemavalidate provides utilities for validating JSON schemas.
Index ¶
- func ApplyDefaults(schema *jsonschema.Schema, obj map[string]any)
- func CompileSchemaFromMap(schemaData map[string]any) (*jsonschema.Schema, error)
- func CompileSchemaFromPB(schemaData *structpb.Struct) (*jsonschema.Schema, error)
- func ValidateAgainstSchema(schema *jsonschema.Schema, obj map[string]any) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyDefaults ¶
ApplyDefaults recursively applies default values from the schema to the object.
func CompileSchemaFromMap ¶
CompileSchemaFromMap compiles a JSON schema from a map.
func CompileSchemaFromPB ¶
CompileSchemaFromPB compiles a JSON schema from a protobuf Struct.
func ValidateAgainstSchema ¶
ValidateAgainstSchema validates an object against a JSON schema.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.