Skip to content

Instantly share code, notes, and snippets.

@charanraj-golla
Last active July 28, 2019 12:15
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 charanraj-golla/1823c488895c177c4c449c4cbc11c407 to your computer and use it in GitHub Desktop.
Save charanraj-golla/1823c488895c177c4c449c4cbc11c407 to your computer and use it in GitHub Desktop.
{
"$id": "http://example.com/quiz",
"type": "object",
"$schema": "http://json-schema.org/draft-07/schema#",
"definitions": {
"sponsor": {
"properties": {
"id" : { "type": "integer" },
"description": { "type": [ "string", "null" ] },
"url" : { "type": [ "string", "null" ], "format": "uri" },
"media" : { "type": [ "array", "null" ],
"items": { "$ref": "http://example.com/common#/definitions/media" } }
},
"additionalProperties" : false,
"required" : [ "name", "description", "url", "media" ]
},
"campaign": {
"type": "object",
"properties": {
"id" : { "type": "integer" },
"campaignName" : { "type": "string" },
"sponsor" : { "type": [ "object", "null" ],
"default": null,
"$ref": "#/definitions/sponsor"
},
"media" : { "type": [ "array", "null" ],
"items": { "$ref": "http://example.com/common#/definitions/media" } }
},
"additionalProperties" : false,
"required" : [ "id", "campaignName", "endDate", "sponsor", "media"]
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment