{
  "asyncapi": "3.0.0",
  "channels": {
    "api_key.compromised": {
      "address": "com.clerktree.hive.api_key.compromised.v1",
      "description": "An API key was reported as leaked (IAM-KEYS-R-017).",
      "messages": {
        "api_key.compromised": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.api_key.compromised.v1",
          "payload": {
            "$ref": "#/components/schemas/api_key.compromised.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.api_key.compromised.v1"
        }
      }
    },
    "api_key.created": {
      "address": "com.clerktree.hive.api_key.created.v1",
      "description": "An API key was created (IAM-KEYS-R-020).",
      "messages": {
        "api_key.created": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.api_key.created.v1",
          "payload": {
            "$ref": "#/components/schemas/api_key.created.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.api_key.created.v1"
        }
      }
    },
    "api_key.expiring": {
      "address": "com.clerktree.hive.api_key.expiring.v1",
      "description": "An active API key expires within 30, 7 or 1 days (IAM-KEYS-R-016).",
      "messages": {
        "api_key.expiring": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.api_key.expiring.v1",
          "payload": {
            "$ref": "#/components/schemas/api_key.expiring.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.api_key.expiring.v1"
        }
      }
    },
    "api_key.revoked": {
      "address": "com.clerktree.hive.api_key.revoked.v1",
      "description": "An API key was revoked (IAM-KEYS-R-010).",
      "messages": {
        "api_key.revoked": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.api_key.revoked.v1",
          "payload": {
            "$ref": "#/components/schemas/api_key.revoked.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.api_key.revoked.v1"
        }
      }
    },
    "api_key.rotated": {
      "address": "com.clerktree.hive.api_key.rotated.v1",
      "description": "The secret of an API key was rotated (IAM-KEYS-R-009).",
      "messages": {
        "api_key.rotated": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.api_key.rotated.v1",
          "payload": {
            "$ref": "#/components/schemas/api_key.rotated.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.api_key.rotated.v1"
        }
      }
    },
    "api_version.deprecated": {
      "address": "com.clerktree.hive.api_version.deprecated.v1",
      "description": "An API version was announced as deprecated (API-VER-R-022).",
      "messages": {
        "api_version.deprecated": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.api_version.deprecated.v1",
          "payload": {
            "$ref": "#/components/schemas/api_version.deprecated.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.api_version.deprecated.v1"
        }
      }
    },
    "api_version.retired": {
      "address": "com.clerktree.hive.api_version.retired.v1",
      "description": "An API version was retired (API-VER-R-023).",
      "messages": {
        "api_version.retired": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.api_version.retired.v1",
          "payload": {
            "$ref": "#/components/schemas/api_version.retired.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.api_version.retired.v1"
        }
      }
    },
    "asset.created": {
      "address": "com.clerktree.hive.asset.created.v1",
      "description": "An asset was created (GRAPH-HIER-R-018). IAM-AUTHZ writes the parent tuple from parent_id.",
      "messages": {
        "asset.created": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.asset.created.v1",
          "payload": {
            "$ref": "#/components/schemas/asset.created.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.asset.created.v1"
        }
      }
    },
    "asset.deleted": {
      "address": "com.clerktree.hive.asset.deleted.v1",
      "description": "An asset was soft deleted (GRAPH-HIER-R-010).",
      "messages": {
        "asset.deleted": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.asset.deleted.v1",
          "payload": {
            "$ref": "#/components/schemas/asset.deleted.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.asset.deleted.v1"
        }
      }
    },
    "asset.lifecycle_changed": {
      "address": "com.clerktree.hive.asset.lifecycle_changed.v1",
      "description": "The lifecycle state of an asset changed; a decommission emits one event per asset of the subtree (GRAPH-HIER-R-009).",
      "messages": {
        "asset.lifecycle_changed": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.asset.lifecycle_changed.v1",
          "payload": {
            "$ref": "#/components/schemas/asset.lifecycle_changed.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.asset.lifecycle_changed.v1"
        }
      }
    },
    "asset.moved": {
      "address": "com.clerktree.hive.asset.moved.v1",
      "description": "An asset was moved with its subtree; previous holds the old parent and path (GRAPH-HIER-R-006, R-018).",
      "messages": {
        "asset.moved": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.asset.moved.v1",
          "payload": {
            "$ref": "#/components/schemas/asset.moved.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.asset.moved.v1"
        }
      }
    },
    "asset.restored": {
      "address": "com.clerktree.hive.asset.restored.v1",
      "description": "A deleted asset was restored (GRAPH-HIER-R-012).",
      "messages": {
        "asset.restored": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.asset.restored.v1",
          "payload": {
            "$ref": "#/components/schemas/asset.restored.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.asset.restored.v1"
        }
      }
    },
    "asset.updated": {
      "address": "com.clerktree.hive.asset.updated.v1",
      "description": "An asset changed, other than its place and lifecycle; previous holds the old values (GRAPH-HIER-R-018).",
      "messages": {
        "asset.updated": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.asset.updated.v1",
          "payload": {
            "$ref": "#/components/schemas/asset.updated.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.asset.updated.v1"
        }
      }
    },
    "clock_status.changed": {
      "address": "com.clerktree.hive.clock_status.changed.v1",
      "description": "The clock status of a gateway or a connection changed state (DATA-TIME-R-010).",
      "messages": {
        "clock_status.changed": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.clock_status.changed.v1",
          "payload": {
            "$ref": "#/components/schemas/clock_status.changed.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.clock_status.changed.v1"
        }
      }
    },
    "membership.created": {
      "address": "com.clerktree.hive.membership.created.v1",
      "description": "A user became a member of the tenant (TEN-MODEL).",
      "messages": {
        "membership.created": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.membership.created.v1",
          "payload": {
            "$ref": "#/components/schemas/membership.created.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.membership.created.v1"
        }
      }
    },
    "membership.removed": {
      "address": "com.clerktree.hive.membership.removed.v1",
      "description": "A membership ended (TEN-MODEL).",
      "messages": {
        "membership.removed": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.membership.removed.v1",
          "payload": {
            "$ref": "#/components/schemas/membership.removed.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.membership.removed.v1"
        }
      }
    },
    "membership.updated": {
      "address": "com.clerktree.hive.membership.updated.v1",
      "description": "The status of a membership changed (TEN-MODEL).",
      "messages": {
        "membership.updated": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.membership.updated.v1",
          "payload": {
            "$ref": "#/components/schemas/membership.updated.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.membership.updated.v1"
        }
      }
    },
    "service_account.created": {
      "address": "com.clerktree.hive.service_account.created.v1",
      "description": "A service account was created (IAM-KEYS).",
      "messages": {
        "service_account.created": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.service_account.created.v1",
          "payload": {
            "$ref": "#/components/schemas/service_account.created.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.service_account.created.v1"
        }
      }
    },
    "service_account.deleted": {
      "address": "com.clerktree.hive.service_account.deleted.v1",
      "description": "A service account was deleted (IAM-KEYS).",
      "messages": {
        "service_account.deleted": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.service_account.deleted.v1",
          "payload": {
            "$ref": "#/components/schemas/service_account.deleted.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.service_account.deleted.v1"
        }
      }
    },
    "service_account.disabled": {
      "address": "com.clerktree.hive.service_account.disabled.v1",
      "description": "A service account was disabled (IAM-KEYS).",
      "messages": {
        "service_account.disabled": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.service_account.disabled.v1",
          "payload": {
            "$ref": "#/components/schemas/service_account.disabled.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.service_account.disabled.v1"
        }
      }
    },
    "service_account.updated": {
      "address": "com.clerktree.hive.service_account.updated.v1",
      "description": "A service account was changed or enabled (IAM-KEYS).",
      "messages": {
        "service_account.updated": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.service_account.updated.v1",
          "payload": {
            "$ref": "#/components/schemas/service_account.updated.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.service_account.updated.v1"
        }
      }
    },
    "signal_window.revised": {
      "address": "com.clerktree.hive.signal_window.revised.v1",
      "description": "Samples older than the settle horizon were written for a signal; rollups, caches and gaps over the range must be recomputed (DATA-TIME-R-016).",
      "messages": {
        "signal_window.revised": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.signal_window.revised.v1",
          "payload": {
            "$ref": "#/components/schemas/signal_window.revised.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.signal_window.revised.v1"
        }
      }
    },
    "tenant.created": {
      "address": "com.clerktree.hive.tenant.created.v1",
      "description": "A tenant was created (TEN-MODEL).",
      "messages": {
        "tenant.created": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.tenant.created.v1",
          "payload": {
            "$ref": "#/components/schemas/tenant.created.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.tenant.created.v1"
        }
      }
    },
    "tenant.state_changed": {
      "address": "com.clerktree.hive.tenant.state_changed.v1",
      "description": "The lifecycle state of the tenant changed (TEN-LIFE).",
      "messages": {
        "tenant.state_changed": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.tenant.state_changed.v1",
          "payload": {
            "$ref": "#/components/schemas/tenant.state_changed.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.tenant.state_changed.v1"
        }
      }
    },
    "tenant.updated": {
      "address": "com.clerktree.hive.tenant.updated.v1",
      "description": "The display name or the default language of the tenant changed (TEN-MODEL-R-021).",
      "messages": {
        "tenant.updated": {
          "contentType": "application/json",
          "name": "com.clerktree.hive.tenant.updated.v1",
          "payload": {
            "$ref": "#/components/schemas/tenant.updated.v1"
          },
          "x-hive-event-type": "com.clerktree.hive.tenant.updated.v1"
        }
      }
    }
  },
  "components": {
    "schemas": {
      "api_key.compromised.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/api_key.compromised.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An API key was reported as leaked and marked compromised; the security admins are notified. The subject is the key ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "env": {
            "enum": [
              "live",
              "test"
            ]
          },
          "expires_at": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "pattern": "^key_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "api_key"
          },
          "service_account_id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "revoked",
              "compromised"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "service_account_id",
          "name",
          "env",
          "status",
          "expires_at",
          "version"
        ],
        "title": "com.clerktree.hive.api_key.compromised.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.api_key.compromised.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "api_key.created.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/api_key.created.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An API key was created. The data never holds the key or its secret. The subject is the key ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "env": {
            "enum": [
              "live",
              "test"
            ]
          },
          "expires_at": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "pattern": "^key_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "api_key"
          },
          "service_account_id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "revoked",
              "compromised"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "service_account_id",
          "name",
          "env",
          "status",
          "expires_at",
          "version"
        ],
        "title": "com.clerktree.hive.api_key.created.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.api_key.created.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "api_key.expiring.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/api_key.expiring.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An active API key expires within 30, 7 or 1 days. The data names the key ID and the users to tell (the creator and the security admins), never a secret. The subject is the key ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "days_left": {
            "enum": [
              30,
              7,
              1
            ]
          },
          "expires_at": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "pattern": "^key_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "object": {
            "const": "api_key"
          },
          "recipients": {
            "items": {
              "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
              "type": "string"
            },
            "minItems": 1,
            "type": "array"
          }
        },
        "required": [
          "object",
          "id",
          "days_left",
          "expires_at",
          "recipients"
        ],
        "title": "com.clerktree.hive.api_key.expiring.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.api_key.expiring.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "api_key.revoked.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/api_key.revoked.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An API key was revoked. The subject is the key ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "env": {
            "enum": [
              "live",
              "test"
            ]
          },
          "expires_at": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "pattern": "^key_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "api_key"
          },
          "service_account_id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "revoked",
              "compromised"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "service_account_id",
          "name",
          "env",
          "status",
          "expires_at",
          "version"
        ],
        "title": "com.clerktree.hive.api_key.revoked.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.api_key.revoked.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "api_key.rotated.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/api_key.rotated.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The secret of an API key was rotated. The data never holds a secret. The subject is the key ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "env": {
            "enum": [
              "live",
              "test"
            ]
          },
          "expires_at": {
            "format": "date-time",
            "type": "string"
          },
          "id": {
            "pattern": "^key_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "api_key"
          },
          "service_account_id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "revoked",
              "compromised"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "service_account_id",
          "name",
          "env",
          "status",
          "expires_at",
          "version"
        ],
        "title": "com.clerktree.hive.api_key.rotated.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.api_key.rotated.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "api_version.deprecated.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/api_version.deprecated.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: the api_version resource at the event's dated version (API-VER). pinned_by_tenant is true when the receiving tenant is pinned to the version. The event envelope is CloudEvents 1.0 (canon 5); subject is the version.",
        "properties": {
          "changelog_url": {
            "format": "uri",
            "type": "string"
          },
          "deprecated_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "object": {
            "const": "api_version"
          },
          "pinned_by_tenant": {
            "type": "boolean"
          },
          "released_on": {
            "format": "date",
            "type": "string"
          },
          "status": {
            "enum": [
              "current",
              "supported",
              "deprecated",
              "retired"
            ]
          },
          "sunset_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}$",
            "type": "string"
          }
        },
        "required": [
          "object",
          "version",
          "status",
          "released_on",
          "deprecated_on",
          "sunset_on",
          "changelog_url",
          "pinned_by_tenant"
        ],
        "title": "com.clerktree.hive.api_version.deprecated.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.api_version.deprecated.v1",
        "x-hive-owner": "API-VER"
      },
      "api_version.retired.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/api_version.retired.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: the api_version resource at the event's dated version (API-VER). pinned_by_tenant is true when the receiving tenant is pinned to the version. The event envelope is CloudEvents 1.0 (canon 5); subject is the version.",
        "properties": {
          "changelog_url": {
            "format": "uri",
            "type": "string"
          },
          "deprecated_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "object": {
            "const": "api_version"
          },
          "pinned_by_tenant": {
            "type": "boolean"
          },
          "released_on": {
            "format": "date",
            "type": "string"
          },
          "status": {
            "enum": [
              "current",
              "supported",
              "deprecated",
              "retired"
            ]
          },
          "sunset_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}$",
            "type": "string"
          }
        },
        "required": [
          "object",
          "version",
          "status",
          "released_on",
          "deprecated_on",
          "sunset_on",
          "changelog_url",
          "pinned_by_tenant"
        ],
        "title": "com.clerktree.hive.api_version.retired.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.api_version.retired.v1",
        "x-hive-owner": "API-VER"
      },
      "asset.created.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/asset.created.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An asset was created. data is the asset in its API representation without description_i18n and properties (GRAPH-HIER-R-031). The subject is the asset ID; parent_id lets IAM-AUTHZ write the parent tuple. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "asset_type_id": {
            "pattern": "^aty_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "asset_type_version": {
            "minimum": 1,
            "type": [
              "integer",
              "null"
            ]
          },
          "build_year": {
            "maximum": 2200,
            "minimum": 1900,
            "type": [
              "integer",
              "null"
            ]
          },
          "commissioned_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "deleted_at": {
            "format": "date-time",
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "key": {
            "maxLength": 64,
            "minLength": 1,
            "pattern": "^[A-Za-z0-9._/ -]+$",
            "type": [
              "string",
              "null"
            ]
          },
          "kind": {
            "enum": [
              "site",
              "area",
              "line",
              "work_unit",
              "machine",
              "component"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "lifecycle_changed_at": {
            "format": "date-time",
            "type": "string"
          },
          "lifecycle_state": {
            "enum": [
              "planned",
              "commissioning",
              "active",
              "standby",
              "decommissioned"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "manufacturer": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "model": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "object": {
            "const": "asset"
          },
          "parent_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "path_keys": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "serial_number": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "site_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "site_profile": {
            "additionalProperties": false,
            "properties": {
              "address": {
                "type": [
                  "object",
                  "null"
                ]
              },
              "country": {
                "pattern": "^[A-Z]{2}$",
                "type": "string"
              },
              "time_zone": {
                "type": "string"
              }
            },
            "required": [
              "time_zone",
              "country",
              "address"
            ],
            "type": [
              "object",
              "null"
            ]
          },
          "sort_order": {
            "maximum": 2147483647,
            "minimum": -2147483648,
            "type": "integer"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "variant": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "id",
          "object",
          "kind",
          "parent_id",
          "site_id",
          "key",
          "name",
          "asset_type_id",
          "asset_type_version",
          "lifecycle_state",
          "lifecycle_changed_at",
          "manufacturer",
          "model",
          "variant",
          "serial_number",
          "build_year",
          "commissioned_on",
          "sort_order",
          "path_keys",
          "site_profile",
          "version",
          "created_at",
          "updated_at",
          "deleted_at"
        ],
        "title": "com.clerktree.hive.asset.created.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.asset.created.v1",
        "x-hive-owner": "GRAPH-HIER"
      },
      "asset.deleted.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/asset.deleted.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An asset was soft deleted. A cascading delete emits one event per asset, grouped by the request ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "asset_type_id": {
            "pattern": "^aty_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "asset_type_version": {
            "minimum": 1,
            "type": [
              "integer",
              "null"
            ]
          },
          "build_year": {
            "maximum": 2200,
            "minimum": 1900,
            "type": [
              "integer",
              "null"
            ]
          },
          "commissioned_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "deleted_at": {
            "format": "date-time",
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "key": {
            "maxLength": 64,
            "minLength": 1,
            "pattern": "^[A-Za-z0-9._/ -]+$",
            "type": [
              "string",
              "null"
            ]
          },
          "kind": {
            "enum": [
              "site",
              "area",
              "line",
              "work_unit",
              "machine",
              "component"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "lifecycle_changed_at": {
            "format": "date-time",
            "type": "string"
          },
          "lifecycle_state": {
            "enum": [
              "planned",
              "commissioning",
              "active",
              "standby",
              "decommissioned"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "manufacturer": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "model": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "object": {
            "const": "asset"
          },
          "parent_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "path_keys": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "serial_number": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "site_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "site_profile": {
            "additionalProperties": false,
            "properties": {
              "address": {
                "type": [
                  "object",
                  "null"
                ]
              },
              "country": {
                "pattern": "^[A-Z]{2}$",
                "type": "string"
              },
              "time_zone": {
                "type": "string"
              }
            },
            "required": [
              "time_zone",
              "country",
              "address"
            ],
            "type": [
              "object",
              "null"
            ]
          },
          "sort_order": {
            "maximum": 2147483647,
            "minimum": -2147483648,
            "type": "integer"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "variant": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "id",
          "object",
          "kind",
          "parent_id",
          "site_id",
          "key",
          "name",
          "asset_type_id",
          "asset_type_version",
          "lifecycle_state",
          "lifecycle_changed_at",
          "manufacturer",
          "model",
          "variant",
          "serial_number",
          "build_year",
          "commissioned_on",
          "sort_order",
          "path_keys",
          "site_profile",
          "version",
          "created_at",
          "updated_at",
          "deleted_at"
        ],
        "title": "com.clerktree.hive.asset.deleted.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.asset.deleted.v1",
        "x-hive-owner": "GRAPH-HIER"
      },
      "asset.lifecycle_changed.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/asset.lifecycle_changed.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The lifecycle state of an asset changed. A decommission of a subtree emits one event per asset, grouped by the request ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "asset_type_id": {
            "pattern": "^aty_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "asset_type_version": {
            "minimum": 1,
            "type": [
              "integer",
              "null"
            ]
          },
          "build_year": {
            "maximum": 2200,
            "minimum": 1900,
            "type": [
              "integer",
              "null"
            ]
          },
          "commissioned_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "deleted_at": {
            "format": "date-time",
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "key": {
            "maxLength": 64,
            "minLength": 1,
            "pattern": "^[A-Za-z0-9._/ -]+$",
            "type": [
              "string",
              "null"
            ]
          },
          "kind": {
            "enum": [
              "site",
              "area",
              "line",
              "work_unit",
              "machine",
              "component"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "lifecycle_changed_at": {
            "format": "date-time",
            "type": "string"
          },
          "lifecycle_state": {
            "enum": [
              "planned",
              "commissioning",
              "active",
              "standby",
              "decommissioned"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "manufacturer": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "model": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "object": {
            "const": "asset"
          },
          "parent_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "path_keys": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "previous": {
            "additionalProperties": false,
            "description": "The old lifecycle_state.",
            "properties": {
              "lifecycle_state": {
                "enum": [
                  "planned",
                  "commissioning",
                  "active",
                  "standby",
                  "decommissioned"
                ]
              }
            },
            "required": [
              "lifecycle_state"
            ],
            "type": "object"
          },
          "serial_number": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "site_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "site_profile": {
            "additionalProperties": false,
            "properties": {
              "address": {
                "type": [
                  "object",
                  "null"
                ]
              },
              "country": {
                "pattern": "^[A-Z]{2}$",
                "type": "string"
              },
              "time_zone": {
                "type": "string"
              }
            },
            "required": [
              "time_zone",
              "country",
              "address"
            ],
            "type": [
              "object",
              "null"
            ]
          },
          "sort_order": {
            "maximum": 2147483647,
            "minimum": -2147483648,
            "type": "integer"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "variant": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "id",
          "object",
          "kind",
          "parent_id",
          "site_id",
          "key",
          "name",
          "asset_type_id",
          "asset_type_version",
          "lifecycle_state",
          "lifecycle_changed_at",
          "manufacturer",
          "model",
          "variant",
          "serial_number",
          "build_year",
          "commissioned_on",
          "sort_order",
          "path_keys",
          "site_profile",
          "version",
          "created_at",
          "updated_at",
          "deleted_at",
          "previous"
        ],
        "title": "com.clerktree.hive.asset.lifecycle_changed.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.asset.lifecycle_changed.v1",
        "x-hive-owner": "GRAPH-HIER"
      },
      "asset.moved.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/asset.moved.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An asset was moved with its subtree. data is the moved asset; previous holds the old parent_id and path_keys. No event is emitted for the descendants: consumers recompute from this event. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "asset_type_id": {
            "pattern": "^aty_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "asset_type_version": {
            "minimum": 1,
            "type": [
              "integer",
              "null"
            ]
          },
          "build_year": {
            "maximum": 2200,
            "minimum": 1900,
            "type": [
              "integer",
              "null"
            ]
          },
          "commissioned_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "deleted_at": {
            "format": "date-time",
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "key": {
            "maxLength": 64,
            "minLength": 1,
            "pattern": "^[A-Za-z0-9._/ -]+$",
            "type": [
              "string",
              "null"
            ]
          },
          "kind": {
            "enum": [
              "site",
              "area",
              "line",
              "work_unit",
              "machine",
              "component"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "lifecycle_changed_at": {
            "format": "date-time",
            "type": "string"
          },
          "lifecycle_state": {
            "enum": [
              "planned",
              "commissioning",
              "active",
              "standby",
              "decommissioned"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "manufacturer": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "model": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "object": {
            "const": "asset"
          },
          "parent_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "path_keys": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "previous": {
            "additionalProperties": false,
            "description": "The old parent_id and path_keys.",
            "properties": {
              "parent_id": {
                "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
                "type": [
                  "string",
                  "null"
                ]
              },
              "path_keys": {
                "items": {
                  "type": "string"
                },
                "type": "array"
              }
            },
            "required": [
              "parent_id",
              "path_keys"
            ],
            "type": "object"
          },
          "serial_number": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "site_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "site_profile": {
            "additionalProperties": false,
            "properties": {
              "address": {
                "type": [
                  "object",
                  "null"
                ]
              },
              "country": {
                "pattern": "^[A-Z]{2}$",
                "type": "string"
              },
              "time_zone": {
                "type": "string"
              }
            },
            "required": [
              "time_zone",
              "country",
              "address"
            ],
            "type": [
              "object",
              "null"
            ]
          },
          "sort_order": {
            "maximum": 2147483647,
            "minimum": -2147483648,
            "type": "integer"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "variant": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "id",
          "object",
          "kind",
          "parent_id",
          "site_id",
          "key",
          "name",
          "asset_type_id",
          "asset_type_version",
          "lifecycle_state",
          "lifecycle_changed_at",
          "manufacturer",
          "model",
          "variant",
          "serial_number",
          "build_year",
          "commissioned_on",
          "sort_order",
          "path_keys",
          "site_profile",
          "version",
          "created_at",
          "updated_at",
          "deleted_at",
          "previous"
        ],
        "title": "com.clerktree.hive.asset.moved.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.asset.moved.v1",
        "x-hive-owner": "GRAPH-HIER"
      },
      "asset.restored.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/asset.restored.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "A deleted asset was restored. A restore of a subtree emits one event per asset, grouped by the request ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "asset_type_id": {
            "pattern": "^aty_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "asset_type_version": {
            "minimum": 1,
            "type": [
              "integer",
              "null"
            ]
          },
          "build_year": {
            "maximum": 2200,
            "minimum": 1900,
            "type": [
              "integer",
              "null"
            ]
          },
          "commissioned_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "deleted_at": {
            "format": "date-time",
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "key": {
            "maxLength": 64,
            "minLength": 1,
            "pattern": "^[A-Za-z0-9._/ -]+$",
            "type": [
              "string",
              "null"
            ]
          },
          "kind": {
            "enum": [
              "site",
              "area",
              "line",
              "work_unit",
              "machine",
              "component"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "lifecycle_changed_at": {
            "format": "date-time",
            "type": "string"
          },
          "lifecycle_state": {
            "enum": [
              "planned",
              "commissioning",
              "active",
              "standby",
              "decommissioned"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "manufacturer": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "model": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "object": {
            "const": "asset"
          },
          "parent_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "path_keys": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "serial_number": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "site_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "site_profile": {
            "additionalProperties": false,
            "properties": {
              "address": {
                "type": [
                  "object",
                  "null"
                ]
              },
              "country": {
                "pattern": "^[A-Z]{2}$",
                "type": "string"
              },
              "time_zone": {
                "type": "string"
              }
            },
            "required": [
              "time_zone",
              "country",
              "address"
            ],
            "type": [
              "object",
              "null"
            ]
          },
          "sort_order": {
            "maximum": 2147483647,
            "minimum": -2147483648,
            "type": "integer"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "variant": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "id",
          "object",
          "kind",
          "parent_id",
          "site_id",
          "key",
          "name",
          "asset_type_id",
          "asset_type_version",
          "lifecycle_state",
          "lifecycle_changed_at",
          "manufacturer",
          "model",
          "variant",
          "serial_number",
          "build_year",
          "commissioned_on",
          "sort_order",
          "path_keys",
          "site_profile",
          "version",
          "created_at",
          "updated_at",
          "deleted_at"
        ],
        "title": "com.clerktree.hive.asset.restored.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.asset.restored.v1",
        "x-hive-owner": "GRAPH-HIER"
      },
      "asset.updated.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/asset.updated.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "An asset changed (not its place and not its lifecycle). data is the asset after the change; previous holds the old values of the changed fields. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "asset_type_id": {
            "pattern": "^aty_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "asset_type_version": {
            "minimum": 1,
            "type": [
              "integer",
              "null"
            ]
          },
          "build_year": {
            "maximum": 2200,
            "minimum": 1900,
            "type": [
              "integer",
              "null"
            ]
          },
          "commissioned_on": {
            "format": "date",
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "deleted_at": {
            "format": "date-time",
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "key": {
            "maxLength": 64,
            "minLength": 1,
            "pattern": "^[A-Za-z0-9._/ -]+$",
            "type": [
              "string",
              "null"
            ]
          },
          "kind": {
            "enum": [
              "site",
              "area",
              "line",
              "work_unit",
              "machine",
              "component"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "lifecycle_changed_at": {
            "format": "date-time",
            "type": "string"
          },
          "lifecycle_state": {
            "enum": [
              "planned",
              "commissioning",
              "active",
              "standby",
              "decommissioned"
            ],
            "type": "string",
            "x-hive-open": false
          },
          "manufacturer": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "model": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "object": {
            "const": "asset"
          },
          "parent_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": [
              "string",
              "null"
            ]
          },
          "path_keys": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "previous": {
            "additionalProperties": true,
            "description": "The old values of the fields that changed (name, key, serial_number and the other fields of a PATCH, or the time zone in site_profile). description_i18n and properties are never part of an event.",
            "type": "object",
            "x-hive-open": true
          },
          "serial_number": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "site_id": {
            "pattern": "^ast_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "site_profile": {
            "additionalProperties": false,
            "properties": {
              "address": {
                "type": [
                  "object",
                  "null"
                ]
              },
              "country": {
                "pattern": "^[A-Z]{2}$",
                "type": "string"
              },
              "time_zone": {
                "type": "string"
              }
            },
            "required": [
              "time_zone",
              "country",
              "address"
            ],
            "type": [
              "object",
              "null"
            ]
          },
          "sort_order": {
            "maximum": 2147483647,
            "minimum": -2147483648,
            "type": "integer"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "variant": {
            "maxLength": 200,
            "type": [
              "string",
              "null"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "id",
          "object",
          "kind",
          "parent_id",
          "site_id",
          "key",
          "name",
          "asset_type_id",
          "asset_type_version",
          "lifecycle_state",
          "lifecycle_changed_at",
          "manufacturer",
          "model",
          "variant",
          "serial_number",
          "build_year",
          "commissioned_on",
          "sort_order",
          "path_keys",
          "site_profile",
          "version",
          "created_at",
          "updated_at",
          "deleted_at",
          "previous"
        ],
        "title": "com.clerktree.hive.asset.updated.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.asset.updated.v1",
        "x-hive-owner": "GRAPH-HIER"
      },
      "clock_status.changed.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/clock_status.changed.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The clock status of a gateway or a connection changed state (DATA-TIME-R-010). Emitted once per transition. The subject is the gwy or cnx ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "gateway_id": {
            "pattern": "^gwy_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "id": {
            "pattern": "^(gwy|cnx)_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "object": {
            "const": "clock_status"
          },
          "offset_ms": {
            "type": [
              "integer",
              "null"
            ]
          },
          "previous": {
            "additionalProperties": false,
            "properties": {
              "state": {
                "enum": [
                  "ok",
                  "warn",
                  "skewed",
                  "unsynchronised",
                  "unknown"
                ]
              }
            },
            "required": [
              "state"
            ],
            "type": "object"
          },
          "source_kind": {
            "enum": [
              "gateway",
              "connection"
            ]
          },
          "state": {
            "enum": [
              "ok",
              "warn",
              "skewed",
              "unsynchronised",
              "unknown"
            ]
          },
          "state_since": {
            "format": "date-time",
            "type": "string"
          },
          "step": {
            "description": "The clock step in milliseconds that was detected since the last event (DATA-TIME-R-013), or null.",
            "type": [
              "integer",
              "null"
            ]
          }
        },
        "required": [
          "object",
          "source_kind",
          "id",
          "gateway_id",
          "previous",
          "state",
          "offset_ms",
          "step",
          "state_since"
        ],
        "title": "com.clerktree.hive.clock_status.changed.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.clock_status.changed.v1",
        "x-hive-owner": "DATA-TIME"
      },
      "membership.created.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/membership.created.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: a user became a member of the tenant (status invited or active). The subject is the user ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "object": {
            "const": "membership"
          },
          "source": {
            "enum": [
              "sso",
              "scim",
              "invite",
              "local"
            ]
          },
          "status": {
            "enum": [
              "invited",
              "active",
              "suspended",
              "removed"
            ]
          },
          "user_id": {
            "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "user_id",
          "status",
          "source",
          "created_at",
          "version"
        ],
        "title": "com.clerktree.hive.membership.created.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.membership.created.v1",
        "x-hive-owner": "TEN-MODEL"
      },
      "membership.removed.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/membership.removed.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: a membership ended. The subject is the user ID; a new invitation later creates a new membership version. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "object": {
            "const": "membership"
          },
          "previous": {
            "additionalProperties": false,
            "properties": {
              "status": {
                "enum": [
                  "invited",
                  "active",
                  "suspended"
                ]
              }
            },
            "required": [
              "status"
            ],
            "type": "object"
          },
          "status": {
            "const": "removed"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "user_id": {
            "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "user_id",
          "status",
          "updated_at",
          "version",
          "previous"
        ],
        "title": "com.clerktree.hive.membership.removed.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.membership.removed.v1",
        "x-hive-owner": "TEN-MODEL"
      },
      "membership.updated.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/membership.updated.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: the status of a membership changed, with the status before it. The subject is the user ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "object": {
            "const": "membership"
          },
          "previous": {
            "additionalProperties": false,
            "properties": {
              "status": {
                "enum": [
                  "invited",
                  "active",
                  "suspended",
                  "removed"
                ]
              }
            },
            "required": [
              "status"
            ],
            "type": "object"
          },
          "source": {
            "enum": [
              "sso",
              "scim",
              "invite",
              "local"
            ]
          },
          "status": {
            "enum": [
              "invited",
              "active",
              "suspended",
              "removed"
            ]
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "user_id": {
            "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "user_id",
          "status",
          "source",
          "updated_at",
          "version",
          "previous"
        ],
        "title": "com.clerktree.hive.membership.updated.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.membership.updated.v1",
        "x-hive-owner": "TEN-MODEL"
      },
      "service_account.created.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/service_account.created.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "A service account was created. The subject is the service account ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "service_account"
          },
          "owner_user_id": {
            "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "disabled",
              "deleted"
            ]
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "name",
          "status",
          "owner_user_id",
          "updated_at",
          "version"
        ],
        "title": "com.clerktree.hive.service_account.created.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.service_account.created.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "service_account.deleted.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/service_account.deleted.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "A service account was deleted and its keys revoked. The subject is the service account ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "service_account"
          },
          "owner_user_id": {
            "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "disabled",
              "deleted"
            ]
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "name",
          "status",
          "owner_user_id",
          "updated_at",
          "version"
        ],
        "title": "com.clerktree.hive.service_account.deleted.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.service_account.deleted.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "service_account.disabled.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/service_account.disabled.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "A service account was disabled; all its keys stopped working. The subject is the service account ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "service_account"
          },
          "owner_user_id": {
            "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "disabled",
              "deleted"
            ]
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "name",
          "status",
          "owner_user_id",
          "updated_at",
          "version"
        ],
        "title": "com.clerktree.hive.service_account.disabled.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.service_account.disabled.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "service_account.updated.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/service_account.updated.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "A service account was changed or enabled. The subject is the service account ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "id": {
            "pattern": "^sva_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "object": {
            "const": "service_account"
          },
          "owner_user_id": {
            "pattern": "^usr_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "disabled",
              "deleted"
            ]
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "name",
          "status",
          "owner_user_id",
          "updated_at",
          "version"
        ],
        "title": "com.clerktree.hive.service_account.updated.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.service_account.updated.v1",
        "x-hive-owner": "IAM-KEYS"
      },
      "signal_window.revised.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/signal_window.revised.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "Samples older than the settle horizon were written for a signal, so the rollups, caches and gaps over the range must be recomputed (DATA-TIME-R-016). Debounced: at most one event per signal per flush, with the merged range. The subject is the signal ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "from_t": {
            "description": "The start of the first minute that was revised, UTC, milliseconds.",
            "format": "date-time",
            "type": "string"
          },
          "object": {
            "const": "signal_window"
          },
          "reason": {
            "enum": [
              "late",
              "correction"
            ]
          },
          "signal_id": {
            "pattern": "^sig_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "to_t": {
            "description": "The last millisecond of the last minute that was revised, UTC.",
            "format": "date-time",
            "type": "string"
          }
        },
        "required": [
          "object",
          "signal_id",
          "from_t",
          "to_t",
          "reason"
        ],
        "title": "com.clerktree.hive.signal_window.revised.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.signal_window.revised.v1",
        "x-hive-owner": "DATA-TIME"
      },
      "tenant.created.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/tenant.created.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: the tenant as it was created. Delivered to the tenant's own subscribers only; the subject is the tenant ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "created_at": {
            "format": "date-time",
            "type": "string"
          },
          "default_language": {
            "enum": [
              "de",
              "en"
            ]
          },
          "display_name": {
            "type": "string"
          },
          "handle": {
            "pattern": "^[a-z0-9][a-z0-9-]{1,38}[a-z0-9]$",
            "type": "string"
          },
          "id": {
            "pattern": "^ten_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "object": {
            "const": "tenant"
          },
          "state": {
            "enum": [
              "provisioning",
              "active",
              "suspended",
              "offboarding",
              "deleting",
              "deleted",
              "failed"
            ]
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "handle",
          "display_name",
          "state",
          "default_language",
          "created_at",
          "version"
        ],
        "title": "com.clerktree.hive.tenant.created.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.tenant.created.v1",
        "x-hive-owner": "TEN-MODEL"
      },
      "tenant.state_changed.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/tenant.state_changed.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: the new lifecycle state of the tenant and the state before it. The subject is the tenant ID; the state is owned by TEN-LIFE. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "id": {
            "pattern": "^ten_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "object": {
            "const": "tenant"
          },
          "previous": {
            "additionalProperties": false,
            "properties": {
              "state": {
                "enum": [
                  "provisioning",
                  "active",
                  "suspended",
                  "offboarding",
                  "deleting",
                  "deleted",
                  "failed"
                ]
              }
            },
            "required": [
              "state"
            ],
            "type": "object"
          },
          "state": {
            "enum": [
              "provisioning",
              "active",
              "suspended",
              "offboarding",
              "deleting",
              "deleted",
              "failed"
            ]
          }
        },
        "required": [
          "object",
          "id",
          "state",
          "previous"
        ],
        "title": "com.clerktree.hive.tenant.state_changed.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.tenant.state_changed.v1",
        "x-hive-owner": "TEN-MODEL"
      },
      "tenant.updated.v1": {
        "$id": "https://hive.clerktree.com/schemas/events/tenant.updated.v1.json",
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "additionalProperties": false,
        "description": "The data of the event: the tenant after a change of its display name or default language, and the values before it (previous). The subject is the tenant ID. The event envelope is CloudEvents 1.0 (canon 5).",
        "properties": {
          "default_language": {
            "enum": [
              "de",
              "en"
            ]
          },
          "display_name": {
            "type": "string"
          },
          "id": {
            "pattern": "^ten_[0-9a-hjkmnp-tv-z]{26}$",
            "type": "string"
          },
          "object": {
            "const": "tenant"
          },
          "previous": {
            "additionalProperties": false,
            "properties": {
              "default_language": {
                "enum": [
                  "de",
                  "en"
                ]
              },
              "display_name": {
                "type": "string"
              },
              "version": {
                "minimum": 1,
                "type": "integer"
              }
            },
            "required": [
              "display_name",
              "default_language",
              "version"
            ],
            "type": "object"
          },
          "updated_at": {
            "format": "date-time",
            "type": "string"
          },
          "version": {
            "minimum": 1,
            "type": "integer"
          }
        },
        "required": [
          "object",
          "id",
          "display_name",
          "default_language",
          "updated_at",
          "version",
          "previous"
        ],
        "title": "com.clerktree.hive.tenant.updated.v1",
        "type": "object",
        "x-hive-event-type": "com.clerktree.hive.tenant.updated.v1",
        "x-hive-owner": "TEN-MODEL"
      }
    }
  },
  "info": {
    "description": "The public events of HIVE, in the CloudEvents 1.0 envelope (canon 5). Each message is the data schema of one event type under schemas/events. The delivery mechanics belong to API-WHK and API-RT; this document lists the events that exist. Published at GET /v1/asyncapi.json.",
    "title": "HIVE webhooks and streams",
    "version": "2026-11-01"
  },
  "operations": {
    "send_api_key_compromised": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/api_key.compromised"
      }
    },
    "send_api_key_created": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/api_key.created"
      }
    },
    "send_api_key_expiring": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/api_key.expiring"
      }
    },
    "send_api_key_revoked": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/api_key.revoked"
      }
    },
    "send_api_key_rotated": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/api_key.rotated"
      }
    },
    "send_api_version_deprecated": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/api_version.deprecated"
      }
    },
    "send_api_version_retired": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/api_version.retired"
      }
    },
    "send_asset_created": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/asset.created"
      }
    },
    "send_asset_deleted": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/asset.deleted"
      }
    },
    "send_asset_lifecycle_changed": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/asset.lifecycle_changed"
      }
    },
    "send_asset_moved": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/asset.moved"
      }
    },
    "send_asset_restored": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/asset.restored"
      }
    },
    "send_asset_updated": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/asset.updated"
      }
    },
    "send_membership_created": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/membership.created"
      }
    },
    "send_membership_removed": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/membership.removed"
      }
    },
    "send_membership_updated": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/membership.updated"
      }
    },
    "send_service_account_created": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/service_account.created"
      }
    },
    "send_service_account_deleted": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/service_account.deleted"
      }
    },
    "send_service_account_disabled": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/service_account.disabled"
      }
    },
    "send_service_account_updated": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/service_account.updated"
      }
    },
    "send_tenant_created": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/tenant.created"
      }
    },
    "send_tenant_state_changed": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/tenant.state_changed"
      }
    },
    "send_tenant_updated": {
      "action": "send",
      "channel": {
        "$ref": "#/channels/tenant.updated"
      }
    }
  }
}
