{ "$id": "scheduleDocument", "title": "scheduleDocument", "description": "A single schedule", "definitions": { "props": { "type": "object", "properties": { "_id": { "$ref": "common#/definitions/mongoObjectId" }, "name": { "$ref": "common#/definitions/standardName" }, "description": { "$ref": "common#/definitions/standardDescription" }, "daysOfWeek": { "type": "object", "properties": { "sunday": { "type": "boolean" }, "monday": { "type": "boolean" }, "tuesday": { "type": "boolean" }, "wednesday": { "type": "boolean" }, "thursday": { "type": "boolean" }, "friday": { "type": "boolean" }, "saturday": { "type": "boolean" } }, "required": [ "sunday", "monday", "tuesday", "wednesday", "thursday", "friday", "saturday" ] }, "timeOfDayStart": { "type": [ "object", "null" ], "properties": { "hour": { "type": "integer", "minimum": 0, "maximum": 23 }, "minute": { "type": "integer", "minimum": 0, "maximum": 59 } }, "required": [ "hour", "minute" ] }, "timeOfDayEnd": { "type": [ "object", "null" ], "properties": { "hour": { "type": "integer", "minimum": 0, "maximum": 23 }, "minute": { "type": "integer", "minimum": 0, "maximum": 59 } }, "required": [ "hour", "minute" ] }, "beginDate": { "type": [ "string", "null" ], "pattern": "\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}.\\d{3}\\d*Z" }, "endDate": { "type": [ "string", "null" ], "pattern": "\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}.\\d{3}\\d*Z" } }, "additionalProperties": true }, "createDetails": { "allOf": [ { "$ref": "#/definitions/props" }, { "required": [ "name" ] } ] }, "updateDetails": { "$ref": "#/definitions/props" }, "apiResponse": { "allOf": [ { "$ref": "#/definitions/props" }, { "type": "object", "properties": { "id": { "type": "string" }, "created": { "type": "string" }, "createdBy": { "type": "string" }, "lastUpdated": { "type": "string" }, "lastUpdatedBy": { "type": "string" } }, "required": [ "id", "name", "description", "daysOfWeek", "timeOfDayStart", "timeOfDayEnd", "beginDate", "endDate", "created", "createdBy", "lastUpdated", "lastUpdatedBy" ] } ] } }, "allOf": [ { "$ref": "#/definitions/props" }, { "required": [ "name", "description", "daysOfWeek", "timeOfDayStart", "timeOfDayEnd", "beginDate", "endDate" ] } ] }