Validate JSON data with schemas, types, required fields, formats, composition, and API contracts.
Lessons
Describe array items, length, and uniqueness.
Validating Arrays is easiest to learn by reading the example, changing it, and observing the result.
{
"type": "object",
"properties": {
"tags": {
"type": "array",
"items": { "type": "string", "minLength": 1 }
}
}
}Practice the Validating Arrays example in a small scratch file, then explain what changed and why.