Skip to content

Instantly share code, notes, and snippets.

@KiryhaPikoff
Last active July 22, 2020 10:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KiryhaPikoff/15c66b5361251dce90111aa72e2a3067 to your computer and use it in GitHub Desktop.
Save KiryhaPikoff/15c66b5361251dce90111aa72e2a3067 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": [
{
"id": 1,
"nick": "DemoAccount",
"email": "demo@mail.ru",
"password": "$2a$10$I.K63YHBZwEFlJg12j/00eIPdd3lUtQ9iJyga2NW6r8RDjK5z5L9u"
}
],
"required": [
"id",
"nick",
"email",
"password"
],
"additionalProperties": true,
"properties": {
"id": {
"$id": "#/properties/id",
"type": "integer",
"title": "The id schema",
"description": "An explanation about the purpose of this instance.",
"default": 0,
"examples": [
1
],
"minimum": 0
},
"nick": {
"$id": "#/properties/nick",
"type": "string",
"title": "The nick schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"examples": [
"DemoAccount"
]
},
"email": {
"$id": "#/properties/email",
"type": "string",
"title": "The email schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"examples": [
"demo@mail.ru"
]
},
"password": {
"$id": "#/properties/password",
"type": "string",
"title": "The password schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"examples": [
"$2a$10$I.K63YHBZwEFlJg12j/00eIPdd3lUtQ9iJyga2NW6r8RDjK5z5L9u"
]
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment