The home of JSON Schema validation right in your browser 🚧 Alpha 🚧 draft-7 only
Valid JSON:
xxxxxxxxxx
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$comment": "persist attr is present and == true, require dbName",
"properties": {
"currentLegalLitigation": {
"type": "boolean",
"default": false
},
"litigationText": {
"type": "string"
},
"previouslyFined": {
"type": "boolean",
"default": false
}
},
"if": {
"not": {
"properties": {
"currentLegalLitigation": {
"enum": [
false
]
}
}
}
},
"then": {
"required": [
"litigationText"
]
}
}
Valid JSON:
xxxxxxxxxx
{
"currentLegalLitigation": true
}
should have required property 'litigationText'.
required at "#/then/required"
Instance location: ""
should match "then" schema.
if at "#/if"
Instance location: ""
jsonschema.dev@relequestual Thanks to Sponsors: