{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/august-health/json-schema/august-health-com-august-api-integrations-models-bed-assignments-v1-list-bed-assignments-response-schema.json",
  "title": "com.august.api.integrations.models.bed_assignments.v1.ListBedAssignmentsResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/august-health-occupancy-v1-api-openapi.yml#/components/schemas/com.august.api.integrations.models.bed_assignments.v1.ListBedAssignmentsResponse",
  "properties": {
    "assignments": {
      "items": {
        "$ref": "#/$defs/com.august.api.integrations.models.bed_assignments.v1.BedAssignmentItem"
      },
      "type": "array"
    },
    "personId": {
      "type": "string"
    }
  },
  "required": [
    "personId",
    "assignments"
  ],
  "$defs": {
    "com.august.api.integrations.models.bed_assignments.v1.BedAssignmentItem": {
      "properties": {
        "bed": {
          "$ref": "#/$defs/com.august.api.integrations.models.bed_assignments.v1.BedInfo"
        },
        "createdAt": {
          "format": "date-time",
          "type": "string"
        },
        "endDate": {
          "format": "date",
          "type": "string"
        },
        "id": {
          "type": "string"
        },
        "isCurrentAssignment": {
          "type": "boolean"
        },
        "modifiedAt": {
          "format": "date-time",
          "type": "string"
        },
        "occupancyType": {
          "enum": [
            "PRIVATE",
            "SHARED",
            "SECOND_OCCUPANT"
          ],
          "type": "string"
        },
        "replacesAssignmentId": {
          "type": "string"
        },
        "room": {
          "$ref": "#/$defs/com.august.api.integrations.models.bed_assignments.v1.RoomInfo"
        },
        "startDate": {
          "format": "date",
          "type": "string"
        }
      },
      "required": [
        "id",
        "bed",
        "room",
        "occupancyType",
        "isCurrentAssignment",
        "createdAt",
        "modifiedAt"
      ]
    },
    "com.august.api.integrations.models.bed_assignments.v1.BedInfo": {
      "properties": {
        "externalId": {
          "description": "The bed's ID in the external system that manages the facility's rooms and beds.",
          "type": "string"
        },
        "id": {
          "type": "string"
        },
        "isPrimary": {
          "type": "boolean"
        },
        "name": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "isPrimary"
      ]
    },
    "com.august.api.integrations.models.bed_assignments.v1.RoomInfo": {
      "properties": {
        "externalId": {
          "description": "The room's ID in the external system that manages the facility's rooms.",
          "type": "string"
        },
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        }
      },
      "required": [
        "id",
        "name"
      ]
    }
  }
}