{ "$schema": "https://json-schema.org/draft-04/schema", "type": "object", "description": "You can check a entity with `check-jsonschema --schemafile schema entity.json`.", "properties": { "person": { "type": "object", "properties": { "name": { "type": "string", "pattern": "^.{1,64}$", "description": "A name must be at least one character long and can be up to 64 characters long." }, "email": { "type": "string", "format": "email" }, "gpg": { "type": "string", "pattern": "^[\\dA-F]{40}$", "description": "GPG fingerprints are stored here without a spaces." } }, "minProperties": 1 }, "route": { "type": "object", "patternProperties": { "^(([0-9a-f]{1,4}:){7,7}[0-9a-f]{1,4}|([0-9a-f]{1,4}:){1,7}:|([0-9a-f]{1,4}:){1,6}:[0-9a-f]{1,4}|([0-9a-f]{1,4}:){1,5}(:[0-9a-f]{1,4}){1,2}|([0-9a-f]{1,4}:){1,4}(:[0-9a-f]{1,4}){1,3}|([0-9a-f]{1,4}:){1,3}(:[0-9a-f]{1,4}){1,4}|([0-9a-f]{1,4}:){1,2}(:[0-9a-f]{1,4}){1,5}|[0-9a-f]{1,4}:((:[0-9a-f]{1,4}){1,6})|:((:[0-9a-f]{1,4}){1,7}|:))\\/((4[4-9])|(5[1-9])|(6[1-4]))$": { "type": "object", "properties": { "description": { "type": "string", "pattern": "^.{1,2048}$" }, "dns": { "type": "object", "properties": { "nserver": { "type": "array", "items": { "type": "string", "format": "hostname" }, "minItems": 1, "uniqueItems": true }, "ds": { "type": "array", "items": { "type": "string", "pattern": "\\d{1,10} ([3-9]|1[0-6]) [1-4] [\\dA-F ]{40,384}" }, "minItems": 1, "uniqueItems": true } }, "required": [ "nserver" ], "additionalProperties": false }, "max-len": { "type": "string", "pattern": "((4[4-9])|(5[1-9])|(6[1-4]))" }, "device": { "type": "object", "patternProperties": { "^(([0-9a-f]{1,4}:){7,7}[0-9a-f]{1,4}|([0-9a-f]{1,4}:){1,7}:|([0-9a-f]{1,4}:){1,6}:[0-9a-f]{1,4}|([0-9a-f]{1,4}:){1,5}(:[0-9a-f]{1,4}){1,2}|([0-9a-f]{1,4}:){1,4}(:[0-9a-f]{1,4}){1,3}|([0-9a-f]{1,4}:){1,3}(:[0-9a-f]{1,4}){1,4}|([0-9a-f]{1,4}:){1,2}(:[0-9a-f]{1,4}){1,5}|[0-9a-f]{1,4}:((:[0-9a-f]{1,4}){1,6})|:((:[0-9a-f]{1,4}){1,7}|:))$": { "type": "object", "properties": { "type": { "type": "string", "pattern": "^(router|generic|server)$" }, "description": { "type": "string", "pattern": "^.{1,2048}$" }, "service": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string", "pattern": "^.{1,64}$" }, "description": { "type": "string", "pattern": "^.{1,2048}$" }, "endpoint": { "type": "array", "items": { "type": "object", "minProperties": 1 }, "minItems": 1, "uniqueItems": true }, "additionalProperties": false } }, "minItems": 1, "uniqueItems": true }, "additionalProperties": false } } }, "minProperties": 1, "additionalProperties": false } }, "required": [ "device" ], "additionalProperties": false } }, "minProperties": 1, "additionalProperties": false } }, "additionalProperties": true, "required": [ "route" ] }