{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "RoomBlockSignal simulated case export",
  "type": "object",
  "required": [
    "data_label",
    "case_id",
    "property",
    "event",
    "unit",
    "as_of",
    "cutoff",
    "sources",
    "proposed_finding",
    "unresolved_gap",
    "reviewer",
    "decision",
    "review_history",
    "export_status",
    "inventory_change_applied"
  ],
  "properties": {
    "data_label": {
      "const": "DEMO · SIMULATED DATA"
    },
    "case_id": {
      "type": "string"
    },
    "property": {
      "type": "string"
    },
    "event": {
      "type": "string"
    },
    "unit": {
      "const": "room-night"
    },
    "contracted_room_nights": {
      "type": [
        "integer",
        "null"
      ]
    },
    "as_of": {
      "type": "string"
    },
    "cutoff": {
      "type": [
        "string",
        "null"
      ]
    },
    "sources": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "id",
          "date",
          "name"
        ]
      }
    },
    "proposed_finding": {
      "type": "string"
    },
    "unresolved_gap": {
      "type": "string"
    },
    "reviewer": {
      "type": "object",
      "required": [
        "name",
        "role"
      ]
    },
    "decision": {
      "type": "object",
      "required": [
        "status",
        "scenario",
        "reason",
        "recorded_at"
      ],
      "properties": {
        "status": {
          "enum": [
            "reviewed",
            "open"
          ]
        },
        "scenario": {
          "enum": [
            "hold_20_friday",
            "release_20_friday",
            null
          ]
        },
        "reason": {
          "type": "string"
        },
        "recorded_at": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "review_history": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "action",
          "at"
        ]
      }
    },
    "export_status": {
      "const": "exported_example"
    },
    "inventory_change_applied": {
      "const": false
    }
  }
}
