{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/getuptimely-com/json-schema/getuptimely-com-monitor-schema.json",
  "title": "Monitor",
  "description": "A monitor and its current status.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/getuptimely-com-openapi.json#/components/schemas/Monitor",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Stable opaque monitor id."
    },
    "name": {
      "type": "string",
      "description": "Monitor display name."
    },
    "description": {
      "description": "Optional human description.",
      "type": [
        "string",
        "null"
      ]
    },
    "monitor_type": {
      "type": "string",
      "description": "Monitor protocol type, e.g. \"Website\", \"API\", \"Ping\", \"Port\", \"SSL Certificate\"."
    },
    "status": {
      "$ref": "#/$defs/MonitorStatusRef"
    },
    "active_monitoring_disabled": {
      "type": "boolean",
      "description": "True when active probing is switched off for this monitor (manually or by maintenance)."
    },
    "failure_threshold": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "How many consecutive failed checks this monitor must record before it declares an incident or alert. 1 alerts on the first failed check. Honoured for monitor types an outbound probe checks and for Server monitors (each overdue or over-limit report is one failed check); a short blip below the threshold still appears on the timeline and status pages, it just does not page anyone."
    },
    "created_at": {
      "type": "string",
      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
      "format": "date-time",
      "description": "Creation time, ISO-8601 UTC."
    },
    "updated_at": {
      "type": "string",
      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
      "format": "date-time",
      "description": "Last update time, ISO-8601 UTC."
    }
  },
  "required": [
    "id",
    "name",
    "description",
    "monitor_type",
    "status",
    "active_monitoring_disabled",
    "failure_threshold",
    "created_at",
    "updated_at"
  ],
  "additionalProperties": false,
  "$defs": {
    "MonitorStatusRef": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "Current status name, e.g. \"Operational\" or \"Offline\"."
        },
        "color": {
          "description": "Display color of the status (hex), when configured.",
          "type": [
            "string",
            "null"
          ]
        }
      },
      "required": [
        "name",
        "color"
      ],
      "additionalProperties": false,
      "description": "The monitor's current status."
    }
  }
}