schema = {"type": "array",
"minItems": 1,
"properties": {
"id": {"type": "number"},
"name": {"type": "number"},
},
"required": ["id", "name"]
}
I found that the following JSON passes the validation
[{}] - it should fail because minItems and required properties are missing
[{"id": "test"}] - it should fails because required property "name" is missing and "id" is not a number.
Is there something I am missing?
Best regards,
Tiago
schema = {"type": "array",
"minItems": 1,
"items": {"type": "object",
"properties": {
"id": {"type": "number"},
"name": {"type": "string"}