{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/amigo/main/json-schema/amigo-create-dashboard-request-schema.json",
  "title": "CreateDashboardRequest",
  "x-generated": "2026-10-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amigo-dashboards-api-openapi.yml#/components/schemas/CreateDashboardRequest",
  "properties": {
    "slug": {
      "type": "string",
      "maxLength": 128,
      "minLength": 2,
      "pattern": "^[a-z0-9][a-z0-9\\-]*$",
      "title": "Slug"
    },
    "title": {
      "$ref": "#/$defs/NameString"
    },
    "description": {
      "anyOf": [
        {
          "$ref": "#/$defs/DescriptionString"
        },
        {
          "type": "null"
        }
      ]
    },
    "page_context": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "home",
            "patients",
            "calls",
            "data",
            "analytics",
            "pipeline",
            "operators",
            "surfaces",
            "compliance",
            "custom"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Page Context"
    },
    "panels": {
      "items": {
        "additionalProperties": true,
        "type": "object"
      },
      "type": "array",
      "maxItems": 50,
      "title": "Panels"
    },
    "filters": {
      "items": {
        "additionalProperties": true,
        "type": "object"
      },
      "type": "array",
      "maxItems": 20,
      "title": "Filters"
    },
    "refresh_interval": {
      "type": "integer",
      "maximum": 86400.0,
      "minimum": 10.0,
      "title": "Refresh Interval",
      "default": 300
    }
  },
  "type": "object",
  "required": [
    "slug",
    "title"
  ],
  "$defs": {
    "DescriptionString": {
      "type": "string",
      "maxLength": 2000
    },
    "NameString": {
      "type": "string",
      "maxLength": 256,
      "minLength": 1
    }
  }
}