{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://www.sportsnip.com/schemas/v1/event.json",
  "title": "SportSnip event (v1)",
  "description": "A live event whose clipping a partner can follow.",
  "type": "object",
  "required": [
    "id",
    "name",
    "org_id",
    "starts_at",
    "ends_at",
    "rights_holder",
    "rights_confirmed_by",
    "status"
  ],
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "name": {
      "type": "string"
    },
    "org_id": {
      "type": "string",
      "format": "uuid"
    },
    "starts_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "ISO 8601, UTC"
    },
    "ends_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "ISO 8601, UTC"
    },
    "rights_holder": {
      "type": "string",
      "description": "Who holds the rights to the footage, e.g. \"Asia Rugby\". Never SportSnip or Rugby TTL."
    },
    "rights_confirmed_by": {
      "type": "string",
      "description": "Who gave permission, as recorded by SportSnip staff"
    },
    "status": {
      "enum": [
        "scheduled",
        "live",
        "ended"
      ]
    },
    "games": {
      "type": "array",
      "items": {
        "$ref": "https://www.sportsnip.com/schemas/v1/game.json"
      },
      "description": "Only in GET /events/{id}"
    },
    "resets": {
      "type": "array",
      "items": {
        "$ref": "https://www.sportsnip.com/schemas/v1/reset.json"
      },
      "description": "Only in GET /events/{id}"
    }
  }
}
