{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://xcim.invalid/ietf/as01/schemas/event.schema.json",
  "title": "AS01-F01 event",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "proposal_version",
    "object_type",
    "issuer_id",
    "log_id",
    "sequence_number",
    "locator",
    "state_epoch",
    "previous_event_commitment",
    "previous_state_commitment",
    "new_state_core",
    "effective_at",
    "reason",
    "authorization_evidence_commitment"
  ],
  "properties": {
    "proposal_version": {
      "const": "as-01"
    },
    "object_type": {
      "const": "lifecycle_event"
    },
    "issuer_id": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/id"
    },
    "log_id": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/id"
    },
    "sequence_number": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/positive"
    },
    "locator": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/locator.schema.json"
    },
    "state_epoch": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/positive"
    },
    "previous_event_commitment": {
      "oneOf": [
        {
          "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/hash"
        },
        {
          "type": "null"
        }
      ]
    },
    "previous_state_commitment": {
      "oneOf": [
        {
          "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/hash"
        },
        {
          "type": "null"
        }
      ]
    },
    "new_state_core": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/state-core.schema.json"
    },
    "effective_at": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/nonnegative"
    },
    "reason": {
      "enum": [
        "registration",
        "rotation",
        "recipient_revocation",
        "owner_revocation",
        "compromise",
        "expiry",
        "suspension",
        "erasure"
      ]
    },
    "authorization_evidence_commitment": {
      "$ref": "https://xcim.invalid/ietf/as01/schemas/common.schema.json#/$defs/hash"
    }
  }
}
