{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/backworkhealth-com/json-schema/backworkhealth-com-health-schema.json",
  "title": "Health",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/backworkhealth-com-health-api-openapi.yml#/components/schemas/Health",
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "enum": [
        "healthy",
        "degraded",
        "unhealthy"
      ],
      "description": "`unhealthy` when the database is unreachable; `degraded` when a cache is"
    },
    "version": {
      "type": "string",
      "const": "v1"
    },
    "checks": {
      "type": "object",
      "propertyNames": {
        "type": "string"
      },
      "additionalProperties": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "enum": [
              "healthy",
              "degraded",
              "unhealthy"
            ]
          },
          "latency_ms": {
            "type": "integer"
          }
        },
        "required": [
          "status"
        ]
      }
    },
    "timestamp": {
      "type": "string",
      "format": "date-time"
    }
  },
  "required": [
    "status",
    "version",
    "checks",
    "timestamp"
  ]
}