{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/CloudHealthRule",
  "title": "CloudHealthRule",
  "type": "object",
  "description": "A health rule on the Cisco Observability Platform that defines performance thresholds for monitored cloud entities.",
  "properties": {
    "id": {
      "type": "string",
      "description": "The unique identifier of the health rule."
    },
    "name": {
      "type": "string",
      "description": "The name of the health rule."
    },
    "description": {
      "type": "string",
      "description": "A description of the health rule purpose."
    },
    "enabled": {
      "type": "boolean",
      "description": "Whether the health rule is currently enabled."
    },
    "entityType": {
      "type": "string",
      "description": "The type of entity this health rule monitors."
    },
    "entityFilter": {
      "type": "object",
      "description": "Filter criteria for selecting which entities are monitored."
    },
    "conditions": {
      "type": "array",
      "description": "The conditions that define violations for this health rule.",
      "items": {
        "type": "object",
        "properties": {
          "metric": {
            "type": "string",
            "description": "The metric to evaluate."
          },
          "operator": {
            "type": "string",
            "description": "The comparison operator."
          },
          "threshold": {
            "type": "number",
            "description": "The threshold value."
          },
          "severity": {
            "type": "string",
            "description": "The severity level for violations.",
            "enum": [
              "CRITICAL",
              "WARNING"
            ]
          }
        }
      }
    },
    "createdAt": {
      "type": "string",
      "format": "date-time",
      "description": "The timestamp when the health rule was created."
    },
    "updatedAt": {
      "type": "string",
      "format": "date-time",
      "description": "The timestamp when the health rule was last updated."
    }
  }
}