Skip to content

Instantly share code, notes, and snippets.

@sn0wcat
Created November 9, 2020 21:56
Show Gist options
  • Save sn0wcat/b6e89ef434bd47aca2d211d37a76d6ce to your computer and use it in GitHub Desktop.
Save sn0wcat/b6e89ef434bd47aca2d211d37a76d6ce to your computer and use it in GitHub Desktop.
{
"$schema": "http://json-schema.org/draft-07/schema",
"$id": "http://example.com/example.json",
"type": "object",
"title": "The root schema",
"description": "The root schema comprises the entire JSON document.",
"default": {},
"examples": [
{
"blocked": false,
"vibration": true,
"servo1_temp": 21.67
}
],
"required": ["blocked", "vibration", "servo1_temp"],
"properties": {
"blocked": {
"$id": "#/properties/blocked",
"type": "boolean",
"title": "The blocked schema",
"description": "An explanation about the purpose of this instance.",
"default": false,
"examples": [false]
},
"vibration": {
"$id": "#/properties/vibration",
"type": "boolean",
"title": "The vibration schema",
"description": "An explanation about the purpose of this instance.",
"default": false,
"examples": [true]
},
"servo1_temp": {
"$id": "#/properties/servo1_temp",
"type": "number",
"title": "The servo1_temp schema",
"description": "An explanation about the purpose of this instance.",
"default": 0.0,
"examples": [21.67]
}
},
"additionalProperties": true
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment