{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/comingup-today/json-schema/comingup-today-event-exceptions-body-schema.json",
  "title": "EventExceptionsBody",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/comingup-today-events-api-openapi.yml#/components/schemas/EventExceptionsBody",
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "exceptionStartAt": {
          "type": "string",
          "minLength": 1
        },
        "type": {
          "type": "string",
          "enum": [
            "cancel"
          ]
        }
      },
      "required": [
        "exceptionStartAt",
        "type"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "exceptionStartAt": {
          "type": "string",
          "minLength": 1
        },
        "type": {
          "type": "string",
          "enum": [
            "override"
          ]
        },
        "override": {
          "oneOf": [
            {
              "type": "object",
              "properties": {
                "title": {
                  "type": "string",
                  "minLength": 1
                },
                "description": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "location": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "isAllDay": {
                  "type": "boolean",
                  "enum": [
                    true
                  ]
                },
                "startDate": {
                  "type": "string",
                  "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                },
                "endDate": {
                  "type": "string",
                  "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                },
                "personIds": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "format": "uuid"
                  }
                },
                "contactIds": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "format": "uuid"
                  }
                }
              },
              "required": [
                "isAllDay"
              ],
              "additionalProperties": false
            },
            {
              "type": "object",
              "properties": {
                "title": {
                  "type": "string",
                  "minLength": 1
                },
                "description": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "location": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "isAllDay": {
                  "type": "boolean",
                  "enum": [
                    false
                  ]
                },
                "startAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "endAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "startDate": {
                  "type": "string",
                  "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                },
                "endDate": {
                  "type": "string",
                  "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
                },
                "personIds": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "format": "uuid"
                  }
                },
                "contactIds": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "format": "uuid"
                  }
                }
              },
              "required": [
                "isAllDay"
              ],
              "additionalProperties": false
            }
          ]
        }
      },
      "required": [
        "exceptionStartAt",
        "type",
        "override"
      ],
      "additionalProperties": false
    }
  ]
}