{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/hummingdeck/json-schema/hummingdeck-room-label-list-schema.json",
  "title": "RoomLabelList",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/hummingdeck-room-labels-api-openapi.yml#/components/schemas/RoomLabelList",
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/RoomLabelWithUsage"
      }
    },
    "nextCursor": {
      "type": [
        "string",
        "null"
      ],
      "description": "Pass as cursor to get the next page. Null on the last page."
    }
  },
  "required": [
    "data",
    "nextCursor"
  ],
  "$defs": {
    "RoomLabel": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "name": {
          "type": "string",
          "maxLength": 40
        },
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "color": {
          "type": "string",
          "pattern": "^#[0-9A-Fa-f]{6}$"
        },
        "createdAt": {
          "type": "string",
          "format": "date-time"
        },
        "updatedAt": {
          "type": "string",
          "format": "date-time"
        }
      },
      "required": [
        "id",
        "name",
        "description",
        "color",
        "createdAt",
        "updatedAt"
      ]
    },
    "RoomLabelWithUsage": {
      "allOf": [
        {
          "$ref": "#/$defs/RoomLabel"
        },
        {
          "type": "object",
          "properties": {
            "roomCount": {
              "type": "integer"
            }
          },
          "required": [
            "roomCount"
          ]
        }
      ]
    }
  }
}