Last active
June 27, 2018 16:36
-
-
Save nfreear/20ec56d19bae3e9a55d286c3493d1c13 to your computer and use it in GitHub Desktop.
Schema for the 'our-journey' JSON format. (Nick Freear, 27-June-2018)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"#": "https://spacetelescope.github.io/understanding-json-schema/basics.html#hello-world", | |
"$schema": "http://json-schema.org/schema#", | |
"id": "https://iet-ou.github.io/our-journey/#2018", | |
"title": "Our Journey", | |
"description": "Schema for the 'our-journey' JSON format. (Nick Freear, 27-June-2018)", | |
"type": "object", | |
"properties": { | |
"journey": { | |
"description": "An array with a fixed number of elements (35) ??", | |
"type": "array", | |
"minItems": 2, | |
"maxItems": 40, | |
"uniqueItems": true, | |
"items": { | |
"type": "object", | |
"properties": { | |
"eID": { | |
"description": "The lowercase element identifier, E.g. 'place0', 'place1' ... 'place34' ", | |
"type": "string", | |
"pattern": "^place[0-9]{1,2}$", | |
"minLength": 6, | |
"maxLength": 7, | |
"default": "place0" | |
}, | |
"description": { | |
"description": "A free-text description for this step in the journey, E.g. 'Register for 1st module' ", | |
"type": "string" | |
}, | |
"emoticon": { | |
"description": "(enum) A short lowercase string identifier for one of a fixed set of emojis or emoticons, E.g. 'happy', 'nervous' ... 'proud' ", | |
"type": "string", | |
"pattern": "^[a-z]+$", | |
"minLength": 4, | |
"maxLength": 8, | |
"default": "none" | |
}, | |
"icon": { | |
"description": "(enum) A short lowercase string identifier for one of a fixed set of icons, E.g. 'register', 'studymilestone' ... 'achievement' ", | |
"type": "string", | |
"pattern": "^[a-z]+$", | |
"minLength": 7, | |
"maxLength": 15, | |
"default": "none" | |
}, | |
"postit": { | |
"description": "An additional free-text note, E.g. 'Really nervous about the tutor' ", | |
"type": "string", | |
"default": "" | |
}, | |
}, | |
"additionalItems": false, | |
"required": [ | |
"icon" | |
] | |
} | |
}, | |
"summary": { | |
"description": "A free-text summary of the journey.", | |
"type": "string", | |
"default": "" | |
}, | |
"created": { | |
"description": "An ISO date-time, E.g. '2018-06-27T15:48:00+01:00' ", | |
"type": "string", | |
"format": "date-time" | |
}, | |
"generator": { | |
"description": "The software and version used to produce the JSON, E.g. 'our-journey@1.0.0' ", | |
"type": "string" | |
}, | |
"link": { | |
"description": "Is this just publicity?! E.g. 'https://iet-ou.github.io/our-journey/' ", | |
"type": "string", | |
"format": "uri", | |
"default": "https://iet-ou.github.io/our-journey/" | |
}, | |
"#": { | |
"description": "An automated warning comment, E.g. 'DO NOT EDIT!' ", | |
"type": "string", | |
"default": "Auto-generated file - DO NOT EDIT!" | |
} | |
}, | |
"additionalItems": true, | |
"required": [ | |
"journey" | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment