{
  "components": {
    "schemas": {
      "AcceptedRestoreBundle": {
        "description": "Accepted root-to-selected ancestry. Each member's original plan and exact-object receipt remain bound; presence is not restore execution evidence.",
        "oneOf": [
          {
            "additionalProperties": false,
            "properties": {
              "members": {
                "items": {
                  "additionalProperties": false,
                  "properties": {
                    "receipt": {
                      "$ref": "#/components/schemas/ProtocolKubeVirtStorageReceipt"
                    },
                    "request": {
                      "$ref": "#/components/schemas/ProtocolKubeVirtTransaction"
                    }
                  },
                  "required": [
                    "request",
                    "receipt"
                  ],
                  "type": "object"
                },
                "maxItems": 256,
                "minItems": 1,
                "type": "array"
              },
              "schema": {
                "const": "vnbui-kubevirt-restore/1"
              }
            },
            "required": [
              "schema",
              "members"
            ],
            "type": "object"
          },
          {
            "additionalProperties": false,
            "properties": {
              "members": {
                "items": {
                  "additionalProperties": false,
                  "properties": {
                    "push_result": {
                      "$ref": "#/components/schemas/ProtocolNativePushResult"
                    },
                    "receipt": {
                      "$ref": "#/components/schemas/ProtocolNativeStorageReceipt"
                    },
                    "request": {
                      "$ref": "#/components/schemas/ProtocolNativeTransaction"
                    }
                  },
                  "required": [
                    "request",
                    "receipt",
                    "push_result"
                  ],
                  "type": "object"
                },
                "maxItems": 256,
                "minItems": 1,
                "type": "array"
              },
              "schema": {
                "const": "vnbui-native-restore/1"
              }
            },
            "required": [
              "schema",
              "members"
            ],
            "type": "object"
          }
        ]
      },
      "AgentRegistrationKeyCreate": {
        "description": "Request model for creating agent registration key",
        "properties": {
          "agent_hostname": {
            "maxLength": 255,
            "minLength": 1,
            "title": "Agent Hostname",
            "type": "string"
          },
          "expires_at": {
            "anyOf": [
              {
                "format": "date-time",
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          },
          "max_uses": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Uses"
          },
          "name": {
            "title": "Name",
            "type": "string"
          }
        },
        "required": [
          "name",
          "agent_hostname"
        ],
        "title": "AgentRegistrationKeyCreate",
        "type": "object"
      },
      "AgentRegistrationKeyUpdate": {
        "description": "Request model for updating agent registration key",
        "properties": {
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          },
          "expires_at": {
            "anyOf": [
              {
                "format": "date-time",
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          },
          "max_uses": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Uses"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          }
        },
        "title": "AgentRegistrationKeyUpdate",
        "type": "object"
      },
      "AgentSettingsUpdate": {
        "additionalProperties": false,
        "properties": {
          "backup_storage_path": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Backup Storage Path"
          },
          "compression_level": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Compression Level"
          },
          "compression_type": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Compression Type"
          },
          "heartbeat_interval": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Heartbeat Interval"
          },
          "libvirt_uri": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Libvirt Uri"
          },
          "log_level": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Log Level"
          },
          "max_concurrent_backups": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Concurrent Backups"
          },
          "selected_source_namespaces": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Selected Source Namespaces"
          },
          "virtnbd_scratch_dir": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Virtnbd Scratch Dir"
          },
          "virtnbdbackup_path": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Virtnbdbackup Path"
          },
          "virtnbdrestore_path": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Virtnbdrestore Path"
          }
        },
        "title": "AgentSettingsUpdate",
        "type": "object"
      },
      "AgentUpdateRequest": {
        "description": "Request model for updating agent",
        "properties": {
          "display_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Display Name"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          }
        },
        "title": "AgentUpdateRequest",
        "type": "object"
      },
      "BackupCloseUnreservedRequest": {
        "additionalProperties": false,
        "description": "No caller-supplied proof, force flag or replacement identity is accepted.",
        "properties": {},
        "title": "BackupCloseUnreservedRequest",
        "type": "object"
      },
      "BackupCloseUnreservedResponse": {
        "properties": {
          "backup_id": {
            "title": "Backup Id",
            "type": "string"
          },
          "capacity_state": {
            "const": "unreserved",
            "title": "Capacity State",
            "type": "string"
          },
          "reason": {
            "const": "pre_dispatch_no_effect",
            "title": "Reason",
            "type": "string"
          },
          "request_id": {
            "title": "Request Id",
            "type": "string"
          },
          "status": {
            "const": "failed",
            "title": "Status",
            "type": "string"
          }
        },
        "required": [
          "backup_id",
          "status",
          "reason",
          "capacity_state",
          "request_id"
        ],
        "title": "BackupCloseUnreservedResponse",
        "type": "object"
      },
      "BackupCreate": {
        "description": "Request model for creating backup",
        "properties": {
          "backup_type": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": "full",
            "title": "Backup Type"
          },
          "exclude_disks": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "default": [],
            "title": "Exclude Disks"
          },
          "retention_days": {
            "anyOf": [
              {
                "maximum": 36500.0,
                "minimum": 1.0,
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "default": 30,
            "title": "Retention Days"
          },
          "tags": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "default": {},
            "title": "Tags"
          },
          "vm_id": {
            "title": "Vm Id",
            "type": "string"
          },
          "workers": {
            "description": "Per-backup worker overrides are unsupported",
            "title": "Workers",
            "type": "null"
          }
        },
        "required": [
          "vm_id"
        ],
        "title": "BackupCreate",
        "type": "object"
      },
      "BackupQueueCreate": {
        "description": "Request model for adding backup to queue",
        "properties": {
          "backup_type": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": "full",
            "title": "Backup Type"
          },
          "exclude_disks": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Exclude Disks"
          },
          "priority": {
            "anyOf": [
              {
                "maximum": 100.0,
                "minimum": 0.0,
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "default": 0,
            "title": "Priority"
          },
          "retention_days": {
            "default": 30,
            "maximum": 36500.0,
            "minimum": 1.0,
            "title": "Retention Days",
            "type": "integer"
          },
          "tags": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tags"
          },
          "vm_id": {
            "title": "Vm Id",
            "type": "string"
          },
          "workers": {
            "description": "Per-backup worker overrides are unsupported",
            "title": "Workers",
            "type": "null"
          }
        },
        "required": [
          "vm_id"
        ],
        "title": "BackupQueueCreate",
        "type": "object"
      },
      "BackupRequest": {
        "properties": {
          "backup_type": {
            "default": "full",
            "pattern": "^(full|incremental)$",
            "title": "Backup Type",
            "type": "string"
          },
          "scenario": {
            "default": "success",
            "pattern": "^(success|upload_failure)$",
            "title": "Scenario",
            "type": "string"
          },
          "vm_id": {
            "title": "Vm Id",
            "type": "string"
          }
        },
        "required": [
          "vm_id"
        ],
        "title": "BackupRequest",
        "type": "object"
      },
      "Body_confirm_export_custody_api_v1_encryption_keys_confirm_export_post": {
        "properties": {
          "file": {
            "contentMediaType": "application/octet-stream",
            "title": "File",
            "type": "string"
          },
          "location": {
            "title": "Location",
            "type": "string"
          },
          "password": {
            "title": "Password",
            "type": "string"
          }
        },
        "required": [
          "file",
          "password",
          "location"
        ],
        "title": "Body_confirm_export_custody_api_v1_encryption_keys_confirm_export_post",
        "type": "object"
      },
      "Body_import_keys_api_v1_encryption_keys_import_post": {
        "properties": {
          "file": {
            "contentMediaType": "application/octet-stream",
            "title": "File",
            "type": "string"
          },
          "password": {
            "default": "",
            "title": "Password",
            "type": "string"
          }
        },
        "required": [
          "file"
        ],
        "title": "Body_import_keys_api_v1_encryption_keys_import_post",
        "type": "object"
      },
      "Body_login_api_v1_auth_login_post": {
        "properties": {
          "client_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Client Id"
          },
          "client_secret": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "format": "password",
            "title": "Client Secret"
          },
          "grant_type": {
            "anyOf": [
              {
                "pattern": "^password$",
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Grant Type"
          },
          "org_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Org Id"
          },
          "password": {
            "format": "password",
            "title": "Password",
            "type": "string"
          },
          "scope": {
            "default": "",
            "title": "Scope",
            "type": "string"
          },
          "username": {
            "title": "Username",
            "type": "string"
          }
        },
        "required": [
          "username",
          "password"
        ],
        "title": "Body_login_api_v1_auth_login_post",
        "type": "object"
      },
      "Body_update_report_api_v1_reports__report_id__put": {
        "properties": {
          "filters": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Filters"
          },
          "recipients": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Recipients"
          }
        },
        "title": "Body_update_report_api_v1_reports__report_id__put",
        "type": "object"
      },
      "BulkBackupCreate": {
        "description": "Request model for bulk backup creation",
        "properties": {
          "filter": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Filter"
          },
          "retention_days": {
            "default": 30,
            "maximum": 36500.0,
            "minimum": 1.0,
            "title": "Retention Days",
            "type": "integer"
          },
          "tags": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "default": {},
            "title": "Tags"
          },
          "vm_ids": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vm Ids"
          },
          "workers": {
            "description": "Per-backup worker overrides are unsupported",
            "title": "Workers",
            "type": "null"
          }
        },
        "title": "BulkBackupCreate",
        "type": "object"
      },
      "BulkBackupDelete": {
        "description": "Request model for bulk backup deletion",
        "properties": {
          "backup_ids": {
            "items": {
              "type": "string"
            },
            "title": "Backup Ids",
            "type": "array"
          }
        },
        "required": [
          "backup_ids"
        ],
        "title": "BulkBackupDelete",
        "type": "object"
      },
      "BulkBackupTag": {
        "description": "Request model for bulk tagging",
        "properties": {
          "backup_ids": {
            "items": {
              "type": "string"
            },
            "title": "Backup Ids",
            "type": "array"
          },
          "overwrite": {
            "default": false,
            "title": "Overwrite",
            "type": "boolean"
          },
          "tags": {
            "additionalProperties": true,
            "title": "Tags",
            "type": "object"
          }
        },
        "required": [
          "backup_ids",
          "tags"
        ],
        "title": "BulkBackupTag",
        "type": "object"
      },
      "CreateKeyRequest": {
        "properties": {
          "algorithm": {
            "default": "aes-256-gcm",
            "title": "Algorithm",
            "type": "string"
          },
          "name": {
            "maxLength": 255,
            "minLength": 1,
            "title": "Name",
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "title": "CreateKeyRequest",
        "type": "object"
      },
      "CursorRealtimeEvent": {
        "additionalProperties": false,
        "properties": {
          "payload": {
            "additionalProperties": true,
            "description": "Event-specific invalidation data; fetch authoritative resource state after processing the event.",
            "title": "Payload",
            "type": "object",
            "x-open-schema-reason": "Realtime producers attach event-specific JSON metadata; this best-effort feed is not an execution or snapshot protocol."
          },
          "sequence": {
            "title": "Sequence",
            "type": "integer"
          },
          "timestamp": {
            "format": "date-time",
            "title": "Timestamp",
            "type": "string"
          },
          "type": {
            "title": "Type",
            "type": "string"
          }
        },
        "required": [
          "type",
          "payload",
          "timestamp",
          "sequence"
        ],
        "title": "CursorRealtimeEvent",
        "type": "object"
      },
      "EncryptionKeyMetadata": {
        "additionalProperties": false,
        "properties": {
          "algorithm": {
            "type": "string"
          },
          "backed_up": {
            "type": "boolean"
          },
          "backed_up_at": {
            "anyOf": [
              {
                "format": "date-time",
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "backed_up_locations": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "backup_count": {
            "type": "integer"
          },
          "created_at": {
            "anyOf": [
              {
                "format": "date-time",
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "created_by": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "id": {
            "type": "string"
          },
          "key_hash": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "provider": {
            "type": "string"
          },
          "replaced_by_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "rotated_at": {
            "anyOf": [
              {
                "format": "date-time",
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "status": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "algorithm",
          "key_hash",
          "status",
          "provider",
          "created_at",
          "created_by",
          "rotated_at",
          "replaced_by_id",
          "backed_up",
          "backed_up_at",
          "backed_up_locations",
          "backup_count"
        ],
        "type": "object"
      },
      "ExportKeysRequest": {
        "properties": {
          "key_ids": {
            "items": {
              "type": "string"
            },
            "title": "Key Ids",
            "type": "array"
          },
          "password": {
            "minLength": 8,
            "title": "Password",
            "type": "string"
          }
        },
        "required": [
          "key_ids",
          "password"
        ],
        "title": "ExportKeysRequest",
        "type": "object"
      },
      "GrantEnrollment": {
        "properties": {
          "enable": {
            "default": true,
            "title": "Enable",
            "type": "boolean"
          },
          "expected_revision": {
            "exclusiveMinimum": 0.0,
            "title": "Expected Revision",
            "type": "integer"
          },
          "replace_grant_id": {
            "anyOf": [
              {
                "format": "uuid",
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Replace Grant Id"
          },
          "request_id": {
            "format": "uuid",
            "title": "Request Id",
            "type": "string"
          },
          "scope_sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "title": "Scope Sha256",
            "type": "string"
          }
        },
        "required": [
          "request_id",
          "expected_revision",
          "scope_sha256"
        ],
        "title": "GrantEnrollment",
        "type": "object"
      },
      "GroupRequest": {
        "properties": {
          "name": {
            "maxLength": 80,
            "minLength": 1,
            "title": "Name",
            "type": "string"
          },
          "rules": {
            "items": {
              "$ref": "#/components/schemas/GroupRule"
            },
            "maxItems": 5,
            "minItems": 1,
            "title": "Rules",
            "type": "array"
          },
          "rules_match": {
            "default": "all",
            "pattern": "^(all|any)$",
            "title": "Rules Match",
            "type": "string"
          }
        },
        "required": [
          "name",
          "rules"
        ],
        "title": "GroupRequest",
        "type": "object"
      },
      "GroupRule": {
        "properties": {
          "field": {
            "pattern": "^(name|state|agent_id|metadata\\.environment)$",
            "title": "Field",
            "type": "string"
          },
          "op": {
            "pattern": "^(eq|neq|in)$",
            "title": "Op",
            "type": "string"
          },
          "value": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              }
            ],
            "title": "Value"
          }
        },
        "required": [
          "field",
          "op",
          "value"
        ],
        "title": "GroupRule",
        "type": "object"
      },
      "HTTPValidationError": {
        "properties": {
          "detail": {
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            },
            "title": "Detail",
            "type": "array"
          }
        },
        "title": "HTTPValidationError",
        "type": "object"
      },
      "ImportRequest": {
        "properties": {
          "chain_id": {
            "title": "Chain Id",
            "type": "string"
          }
        },
        "required": [
          "chain_id"
        ],
        "title": "ImportRequest",
        "type": "object"
      },
      "KubeVirtRestoreResult": {
        "additionalProperties": false,
        "properties": {
          "job_name": {
            "minLength": 1,
            "type": "string"
          },
          "job_uid": {
            "minLength": 1,
            "type": "string"
          },
          "namespace": {
            "minLength": 1,
            "type": "string"
          },
          "plan_sha256": {
            "minLength": 1,
            "type": "string"
          },
          "pvc_uids": {
            "additionalProperties": {
              "minLength": 1,
              "type": "string"
            },
            "minProperties": 1,
            "type": "object"
          },
          "run_strategy": {
            "const": "Halted"
          },
          "vm_name": {
            "minLength": 1,
            "type": "string"
          },
          "vm_uid": {
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "namespace",
          "vm_name",
          "vm_uid",
          "job_uid",
          "job_name",
          "plan_sha256",
          "run_strategy",
          "pvc_uids"
        ],
        "type": "object"
      },
      "KubeVirtRestoreTarget": {
        "additionalProperties": false,
        "description": "Fresh stopped target mapping for every protected source.volumes disk. Schema-2 known unprotected native participants are omitted from the new VM's volumes and disk devices after exact captured-identity validation. Unknown/duplicate/missing identities refuse work; schema 1 retains its unprotected-persistent-disk guard. Runtime checks fresh names against all native source PVCs, disk capacity and at most one pod network. Excluding boot/application dependencies does not promise guest or application recovery.",
        "properties": {
          "dependencies": {
            "additionalProperties": {
              "maxLength": 63,
              "minLength": 1,
              "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
              "type": "string"
            },
            "propertyNames": {
              "pattern": "^(secret|configMap)/[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?$"
            },
            "type": "object"
          },
          "disks": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "access_mode": {
                  "enum": [
                    "ReadWriteOnce",
                    "ReadWriteMany"
                  ]
                },
                "capacity_bytes": {
                  "minimum": 1,
                  "type": "integer"
                },
                "pvc_name": {
                  "maxLength": 63,
                  "minLength": 1,
                  "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                  "type": "string"
                },
                "storage_class": {
                  "maxLength": 63,
                  "minLength": 1,
                  "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                  "type": "string"
                },
                "volume_mode": {
                  "enum": [
                    "Filesystem",
                    "Block"
                  ]
                },
                "volume_name": {
                  "type": "string"
                }
              },
              "required": [
                "volume_name",
                "pvc_name",
                "storage_class",
                "access_mode",
                "volume_mode",
                "capacity_bytes"
              ],
              "type": "object"
            },
            "maxItems": 32,
            "minItems": 1,
            "type": "array"
          },
          "namespace": {
            "maxLength": 63,
            "minLength": 1,
            "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
            "type": "string"
          },
          "networks": {
            "items": {
              "oneOf": [
                {
                  "additionalProperties": false,
                  "properties": {
                    "name": {
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                      "type": "string"
                    },
                    "network_name": {
                      "const": ""
                    },
                    "type": {
                      "const": "pod"
                    }
                  },
                  "required": [
                    "name",
                    "type",
                    "network_name"
                  ],
                  "type": "object"
                },
                {
                  "additionalProperties": false,
                  "properties": {
                    "name": {
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                      "type": "string"
                    },
                    "network_name": {
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                      "type": "string"
                    },
                    "type": {
                      "const": "multus"
                    }
                  },
                  "required": [
                    "name",
                    "type",
                    "network_name"
                  ],
                  "type": "object"
                }
              ]
            },
            "maxItems": 32,
            "minItems": 0,
            "type": "array"
          },
          "vm_name": {
            "maxLength": 63,
            "minLength": 1,
            "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
            "type": "string"
          }
        },
        "required": [
          "namespace",
          "vm_name",
          "disks",
          "networks",
          "dependencies"
        ],
        "type": "object"
      },
      "LegacyRealtimeEvent": {
        "additionalProperties": false,
        "properties": {
          "payload": {
            "additionalProperties": true,
            "description": "Event-specific invalidation data; fetch authoritative resource state after processing the event.",
            "title": "Payload",
            "type": "object",
            "x-open-schema-reason": "Realtime producers attach event-specific JSON metadata; this best-effort feed is not an execution or snapshot protocol."
          },
          "timestamp": {
            "format": "date-time",
            "title": "Timestamp",
            "type": "string"
          },
          "type": {
            "title": "Type",
            "type": "string"
          }
        },
        "required": [
          "type",
          "payload",
          "timestamp"
        ],
        "title": "LegacyRealtimeEvent",
        "type": "object"
      },
      "NativeRestoreInput": {
        "additionalProperties": false,
        "description": "Fresh native target input. Runtime binds all protected and excluded disks to the accepted manifest and rejects source-name reuse and duplicate source MACs.",
        "properties": {
          "disks": {
            "items": {
              "type": "string"
            },
            "maxItems": 128,
            "minItems": 1,
            "type": "array"
          },
          "drop_excluded_disks": {
            "items": {
              "type": "string"
            },
            "maxItems": 128,
            "minItems": 0,
            "type": "array"
          },
          "networks": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "network": {
                  "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                  "type": "string"
                },
                "source_mac": {
                  "pattern": "^(?:[0-9a-f]{2}:){5}[0-9a-f]{2}$",
                  "type": "string"
                }
              },
              "required": [
                "source_mac",
                "network"
              ],
              "type": "object"
            },
            "maxItems": 128,
            "minItems": 0,
            "type": "array"
          },
          "vm_name": {
            "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
            "type": "string"
          }
        },
        "required": [
          "vm_name",
          "disks",
          "drop_excluded_disks",
          "networks"
        ],
        "type": "object"
      },
      "NativeRestoreResult": {
        "additionalProperties": false,
        "properties": {
          "disks": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "path": {
                  "pattern": "^/",
                  "type": "string"
                },
                "sha256": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "size_bytes": {
                  "minimum": 1,
                  "type": "integer"
                },
                "target": {
                  "type": "string"
                }
              },
              "required": [
                "target",
                "path",
                "size_bytes",
                "sha256"
              ],
              "type": "object"
            },
            "maxItems": 128,
            "minItems": 1,
            "type": "array"
          },
          "plan_sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "type": "string"
          },
          "state": {
            "const": "shutoff"
          },
          "vm_name": {
            "type": "string"
          },
          "vm_uuid": {
            "format": "uuid",
            "type": "string"
          }
        },
        "required": [
          "vm_name",
          "vm_uuid",
          "state",
          "plan_sha256",
          "disks"
        ],
        "type": "object"
      },
      "NativeRestoreTarget": {
        "additionalProperties": false,
        "description": "Accepted native target with its server-allocated fresh VM UUID.",
        "properties": {
          "disks": {
            "items": {
              "type": "string"
            },
            "maxItems": 128,
            "minItems": 1,
            "type": "array"
          },
          "drop_excluded_disks": {
            "items": {
              "type": "string"
            },
            "maxItems": 128,
            "minItems": 0,
            "type": "array"
          },
          "networks": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "network": {
                  "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                  "type": "string"
                },
                "source_mac": {
                  "pattern": "^(?:[0-9a-f]{2}:){5}[0-9a-f]{2}$",
                  "type": "string"
                }
              },
              "required": [
                "source_mac",
                "network"
              ],
              "type": "object"
            },
            "maxItems": 128,
            "minItems": 0,
            "type": "array"
          },
          "vm_name": {
            "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
            "type": "string"
          },
          "vm_uuid": {
            "format": "uuid",
            "type": "string"
          }
        },
        "required": [
          "vm_name",
          "disks",
          "drop_excluded_disks",
          "networks",
          "vm_uuid"
        ],
        "type": "object"
      },
      "OperatorAdmissionError": {
        "additionalProperties": false,
        "properties": {
          "detail": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "additionalProperties": true,
                "properties": {
                  "code": {
                    "type": "string"
                  },
                  "max_targets": {
                    "type": "integer"
                  },
                  "message": {
                    "type": "string"
                  },
                  "outcome": {
                    "type": "string"
                  },
                  "rotation_id": {
                    "type": "string"
                  }
                },
                "required": [
                  "code"
                ],
                "type": "object"
              },
              {
                "items": {
                  "additionalProperties": true,
                  "properties": {
                    "loc": {
                      "items": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "integer"
                          }
                        ]
                      },
                      "type": "array"
                    },
                    "msg": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "loc",
                    "msg",
                    "type"
                  ],
                  "type": "object"
                },
                "type": "array"
              }
            ]
          }
        },
        "required": [
          "detail"
        ],
        "type": "object"
      },
      "OrchestratorAPIKeyCreate": {
        "description": "Request model for creating orchestrator API key",
        "properties": {
          "expires_at": {
            "anyOf": [
              {
                "format": "date-time",
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          },
          "name": {
            "title": "Name",
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "title": "OrchestratorAPIKeyCreate",
        "type": "object"
      },
      "OrchestratorAPIKeyUpdate": {
        "description": "Request model for updating orchestrator API key",
        "properties": {
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          },
          "expires_at": {
            "anyOf": [
              {
                "format": "date-time",
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          }
        },
        "title": "OrchestratorAPIKeyUpdate",
        "type": "object"
      },
      "ProtocolAttemptBinding": {
        "additionalProperties": false,
        "properties": {
          "attempt_id": {
            "type": "string"
          },
          "key_ref": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "plan_sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "type": "string"
          },
          "reservation_id": {
            "type": "string"
          }
        },
        "required": [
          "reservation_id",
          "attempt_id",
          "plan_sha256",
          "key_ref"
        ],
        "type": "object"
      },
      "ProtocolCA": {
        "additionalProperties": false,
        "properties": {
          "fingerprint": {
            "type": "string"
          },
          "issuer": {
            "type": "string"
          },
          "not_after": {
            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
            "type": "string"
          },
          "not_before": {
            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
            "type": "string"
          },
          "serial": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          }
        },
        "required": [
          "subject",
          "issuer",
          "serial",
          "fingerprint",
          "not_before",
          "not_after"
        ],
        "type": "object"
      },
      "ProtocolFinalizeBinding": {
        "additionalProperties": false,
        "properties": {
          "acceptance_id": {
            "type": "string"
          },
          "attempt_id": {
            "type": "string"
          },
          "checkpoint": {
            "type": "string"
          },
          "guest_consistency": {
            "enum": [
              "quiesced",
              "failed",
              "crash-consistent",
              "unknown"
            ]
          },
          "guest_evidence_source": {
            "type": "string"
          },
          "namespace": {
            "type": "string"
          },
          "parent": {
            "anyOf": [
              {
                "additionalProperties": false,
                "properties": {
                  "backup_id": {
                    "title": "Backup Id",
                    "type": "string"
                  },
                  "checkpoint": {
                    "title": "Checkpoint",
                    "type": "string"
                  },
                  "generation_id": {
                    "title": "Generation Id",
                    "type": "string"
                  },
                  "receipt_sha256": {
                    "title": "Receipt Sha256",
                    "type": "string"
                  },
                  "root_backup_id": {
                    "title": "Root Backup Id",
                    "type": "string"
                  },
                  "tracker_uid": {
                    "title": "Tracker Uid",
                    "type": "string"
                  }
                },
                "required": [
                  "backup_id",
                  "root_backup_id",
                  "receipt_sha256",
                  "generation_id",
                  "tracker_uid",
                  "checkpoint"
                ],
                "title": "Parent",
                "type": "object"
              },
              {
                "type": "null"
              }
            ]
          },
          "plan_sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "type": "string"
          },
          "protocol": {
            "type": "string"
          },
          "receipt_sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "type": "string"
          },
          "reservation_id": {
            "type": "string"
          },
          "started_at": {
            "type": "string"
          },
          "tracker_name": {
            "type": "string"
          },
          "tracker_uid": {
            "type": "string"
          },
          "vm_uid": {
            "type": "string"
          },
          "vmb_name": {
            "type": "string"
          },
          "vmb_uid": {
            "type": "string"
          },
          "vmi_uid": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "volumes": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "capacity_bytes": {
                  "exclusiveMinimum": 0,
                  "maximum": 9223372036854775807,
                  "title": "Capacity Bytes",
                  "type": "integer"
                },
                "mapping": {
                  "$ref": "#/components/schemas/ProtocolWireDiskMapping"
                },
                "name": {
                  "title": "Name",
                  "type": "string"
                },
                "pvc_name": {
                  "title": "Pvc Name",
                  "type": "string"
                },
                "pvc_resource_version": {
                  "title": "Pvc Resource Version",
                  "type": "string"
                },
                "pvc_uid": {
                  "title": "Pvc Uid",
                  "type": "string"
                }
              },
              "required": [
                "name",
                "pvc_name",
                "pvc_uid",
                "pvc_resource_version",
                "capacity_bytes",
                "mapping"
              ],
              "title": "Volume",
              "type": "object"
            },
            "type": "array"
          }
        },
        "required": [
          "protocol",
          "reservation_id",
          "attempt_id",
          "acceptance_id",
          "namespace",
          "vm_uid",
          "tracker_name",
          "tracker_uid",
          "vmb_name",
          "vmb_uid",
          "checkpoint",
          "started_at",
          "guest_evidence_source",
          "plan_sha256",
          "receipt_sha256",
          "vmi_uid",
          "parent",
          "volumes",
          "guest_consistency"
        ],
        "type": "object"
      },
      "ProtocolInstalledProfile": {
        "additionalProperties": false,
        "properties": {
          "auth_mode": {
            "enum": [
              "single_organization",
              "multi_organization"
            ]
          },
          "edition": {
            "enum": [
              "community",
              "commercial"
            ]
          },
          "enabled_modules": {
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "edition",
          "auth_mode",
          "enabled_modules"
        ],
        "type": "object"
      },
      "ProtocolKubeVirtStorageReceipt": {
        "additionalProperties": false,
        "properties": {
          "backup_id": {
            "type": "string"
          },
          "bucket": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "objects": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "ciphertext_bytes": {
                  "minimum": 0,
                  "type": "integer"
                },
                "ciphertext_sha256": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "etag": {
                  "type": "string"
                },
                "key": {
                  "type": "string"
                },
                "plaintext_bytes": {
                  "minimum": 0,
                  "type": "integer"
                },
                "plaintext_sha256": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "role": {
                  "type": "string"
                },
                "version_id": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "volume_id": {
                  "type": "string"
                }
              },
              "required": [
                "key",
                "etag",
                "volume_id",
                "role",
                "version_id",
                "plaintext_bytes",
                "ciphertext_bytes",
                "plaintext_sha256",
                "ciphertext_sha256"
              ],
              "type": "object"
            },
            "maxItems": 4096,
            "minItems": 1,
            "type": "array"
          },
          "protocol": {
            "const": "vnbui-storage-transaction/1",
            "type": "string"
          },
          "reservation_id": {
            "type": "string"
          },
          "schema": {
            "const": 2,
            "type": "integer"
          }
        },
        "required": [
          "protocol",
          "schema",
          "reservation_id",
          "backup_id",
          "endpoint",
          "bucket",
          "objects"
        ],
        "type": "object"
      },
      "ProtocolKubeVirtTransaction": {
        "additionalProperties": false,
        "properties": {
          "agent_id": {
            "title": "Agent Id",
            "type": "string"
          },
          "backup_id": {
            "title": "Backup Id",
            "type": "string"
          },
          "org_id": {
            "title": "Org Id",
            "type": "string"
          },
          "plan": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireTransferQualifiedPlanV2"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireTransferQualifiedPlan"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireTransferPlan"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireQualifiedPlanV2"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireQualifiedPlan"
              },
              {
                "$ref": "#/components/schemas/ProtocolWirePlan"
              }
            ],
            "title": "Plan"
          },
          "plan_sha256": {
            "title": "Plan Sha256",
            "type": "string"
          },
          "protocol": {
            "const": "vnbui-storage-transaction/1",
            "title": "Protocol",
            "type": "string"
          },
          "reservation_id": {
            "title": "Reservation Id",
            "type": "string"
          }
        },
        "required": [
          "protocol",
          "org_id",
          "agent_id",
          "backup_id",
          "reservation_id",
          "plan_sha256",
          "plan"
        ],
        "title": "TransactionRequest",
        "type": "object"
      },
      "ProtocolLegacyStorageReceipt": {
        "additionalProperties": false,
        "properties": {
          "backup_id": {
            "type": "string"
          },
          "bucket": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "objects": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "ciphertext_bytes": {
                  "minimum": 0,
                  "type": "integer"
                },
                "ciphertext_sha256": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "etag": {
                  "type": "string"
                },
                "key": {
                  "type": "string"
                },
                "plaintext_bytes": {
                  "minimum": 0,
                  "type": "integer"
                },
                "plaintext_sha256": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "role": {
                  "type": "string"
                },
                "version_id": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "volume_id": {
                  "type": "string"
                }
              },
              "required": [
                "key",
                "etag",
                "volume_id",
                "role",
                "version_id",
                "plaintext_bytes",
                "ciphertext_bytes",
                "plaintext_sha256",
                "ciphertext_sha256"
              ],
              "type": "object"
            },
            "maxItems": 4096,
            "minItems": 1,
            "type": "array"
          },
          "reservation_id": {
            "type": "string"
          },
          "schema": {
            "const": 1,
            "type": "integer"
          }
        },
        "required": [
          "schema",
          "reservation_id",
          "backup_id",
          "endpoint",
          "bucket",
          "objects"
        ],
        "type": "object"
      },
      "ProtocolNativeInventory": {
        "additionalProperties": false,
        "properties": {
          "attempt_id": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
            "type": "string"
          },
          "backup_id": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
            "type": "string"
          },
          "checkpoint": {
            "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
            "type": "string"
          },
          "disks": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "bus": {
                  "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                  "type": "string"
                },
                "id": {
                  "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                  "type": "string"
                },
                "serial": {
                  "description": "At most 256 UTF-8 bytes.",
                  "type": "string"
                },
                "target": {
                  "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                  "type": "string"
                }
              },
              "required": [
                "bus",
                "id",
                "target",
                "serial"
              ],
              "type": "object"
            },
            "maxItems": 128,
            "minItems": 1,
            "type": "array"
          },
          "domain_uuid": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
            "type": "string"
          },
          "files": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "artifact_id": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "ctime_ns": {
                  "maximum": 9223372036854775807,
                  "minimum": -9223372036854775808,
                  "type": "integer"
                },
                "device": {
                  "maximum": 18446744073709551615,
                  "minimum": 0,
                  "type": "integer"
                },
                "disk_id": {
                  "anyOf": [
                    {
                      "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                      "type": "string"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "inode": {
                  "maximum": 18446744073709551615,
                  "minimum": 1,
                  "type": "integer"
                },
                "member_backup_id": {
                  "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
                  "type": "string"
                },
                "member_checkpoint": {
                  "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                  "type": "string"
                },
                "mtime_ns": {
                  "maximum": 9223372036854775807,
                  "minimum": -9223372036854775808,
                  "type": "integer"
                },
                "path": {
                  "description": "Relative path with at most 16 safe components; case collisions are refused.",
                  "maxLength": 1024,
                  "minLength": 1,
                  "type": "string"
                },
                "role": {
                  "enum": [
                    "disk_payload",
                    "disk_checksum",
                    "disk_metadata",
                    "domain_config",
                    "checkpoint",
                    "autostart",
                    "backup_metadata"
                  ]
                },
                "size": {
                  "maximum": 1125899906842624,
                  "minimum": 0,
                  "type": "integer"
                }
              },
              "required": [
                "artifact_id",
                "path",
                "member_backup_id",
                "member_checkpoint",
                "role",
                "disk_id",
                "ctime_ns",
                "mtime_ns",
                "device",
                "inode",
                "size"
              ],
              "type": "object"
            },
            "maxItems": 4096,
            "minItems": 1,
            "type": "array"
          },
          "format": {
            "const": "libvirt-native-fileset/1",
            "type": "string"
          },
          "job_id": {
            "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
            "type": "string"
          }
        },
        "required": [
          "attempt_id",
          "backup_id",
          "domain_uuid",
          "checkpoint",
          "job_id",
          "format",
          "disks",
          "files"
        ],
        "type": "object"
      },
      "ProtocolNativePushResult": {
        "additionalProperties": false,
        "properties": {
          "manifest": {
            "additionalProperties": false,
            "properties": {
              "attempt_id": {
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
                "type": "string"
              },
              "backup_id": {
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
                "type": "string"
              },
              "checkpoint": {
                "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                "type": "string"
              },
              "checkpoint_sha256": {
                "pattern": "^[0-9a-f]{64}$",
                "type": "string"
              },
              "disks": {
                "items": {
                  "additionalProperties": false,
                  "properties": {
                    "file": {
                      "type": "string"
                    },
                    "sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "size_bytes": {
                      "maximum": 9223372036854775807,
                      "minimum": 1,
                      "type": "integer"
                    },
                    "target": {
                      "type": "string"
                    },
                    "virtual_size": {
                      "maximum": 9223372036854775807,
                      "minimum": 1,
                      "type": "integer"
                    }
                  },
                  "required": [
                    "target",
                    "file",
                    "size_bytes",
                    "virtual_size",
                    "sha256"
                  ],
                  "type": "object"
                },
                "maxItems": 128,
                "minItems": 1,
                "type": "array"
              },
              "domain_uuid": {
                "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
                "type": "string"
              },
              "domain_xml_sha256": {
                "pattern": "^[0-9a-f]{64}$",
                "type": "string"
              },
              "exclusions": {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "parent_backup_id": {
                "anyOf": [
                  {
                    "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
                    "type": "string"
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "parent_manifest_sha256": {
                "anyOf": [
                  {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "schema": {
                "const": "libvirt-push-qcow2/1",
                "type": "string"
              },
              "source": {
                "items": {
                  "additionalProperties": false,
                  "properties": {
                    "bus": {
                      "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                      "type": "string"
                    },
                    "format": {
                      "enum": [
                        "qcow2",
                        "raw"
                      ]
                    },
                    "source": {
                      "maxLength": 4096,
                      "minLength": 1,
                      "pattern": "^/",
                      "type": "string"
                    },
                    "target": {
                      "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "target",
                    "bus",
                    "source",
                    "format"
                  ],
                  "type": "object"
                },
                "maxItems": 128,
                "minItems": 1,
                "type": "array"
              }
            },
            "required": [
              "schema",
              "backup_id",
              "attempt_id",
              "domain_uuid",
              "checkpoint",
              "checkpoint_sha256",
              "domain_xml_sha256",
              "parent_backup_id",
              "parent_manifest_sha256",
              "source",
              "exclusions",
              "disks"
            ],
            "type": "object"
          },
          "manifest_sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "type": "string"
          }
        },
        "required": [
          "manifest",
          "manifest_sha256"
        ],
        "type": "object"
      },
      "ProtocolNativeStorageReceipt": {
        "additionalProperties": false,
        "properties": {
          "backup_id": {
            "type": "string"
          },
          "bucket": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "objects": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "artifact_id": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "ciphertext_bytes": {
                  "minimum": 0,
                  "type": "integer"
                },
                "ciphertext_sha256": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "disk_id": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "etag": {
                  "type": "string"
                },
                "key": {
                  "type": "string"
                },
                "plaintext_bytes": {
                  "minimum": 0,
                  "type": "integer"
                },
                "plaintext_sha256": {
                  "pattern": "^[0-9a-f]{64}$",
                  "type": "string"
                },
                "role": {
                  "type": "string"
                },
                "version_id": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "null"
                    }
                  ]
                }
              },
              "required": [
                "key",
                "etag",
                "role",
                "version_id",
                "plaintext_bytes",
                "ciphertext_bytes",
                "plaintext_sha256",
                "ciphertext_sha256",
                "artifact_id",
                "disk_id"
              ],
              "type": "object"
            },
            "maxItems": 4096,
            "minItems": 1,
            "type": "array"
          },
          "protocol": {
            "const": "vnbui-storage-transaction/1",
            "type": "string"
          },
          "representation": {
            "const": "libvirt-native-fileset/1",
            "type": "string"
          },
          "reservation_id": {
            "type": "string"
          },
          "schema": {
            "const": 2,
            "type": "integer"
          }
        },
        "required": [
          "protocol",
          "schema",
          "representation",
          "reservation_id",
          "backup_id",
          "endpoint",
          "bucket",
          "objects"
        ],
        "type": "object"
      },
      "ProtocolNativeTransaction": {
        "additionalProperties": false,
        "properties": {
          "agent_id": {
            "title": "Agent Id",
            "type": "string"
          },
          "backup_id": {
            "title": "Backup Id",
            "type": "string"
          },
          "org_id": {
            "title": "Org Id",
            "type": "string"
          },
          "plan": {
            "$ref": "#/components/schemas/ProtocolWireNativePlan"
          },
          "plan_sha256": {
            "title": "Plan Sha256",
            "type": "string"
          },
          "protocol": {
            "const": "vnbui-storage-transaction/1",
            "title": "Protocol",
            "type": "string"
          },
          "reservation_id": {
            "title": "Reservation Id",
            "type": "string"
          }
        },
        "required": [
          "protocol",
          "org_id",
          "agent_id",
          "backup_id",
          "reservation_id",
          "plan_sha256",
          "plan"
        ],
        "title": "NativeTransactionRequest",
        "type": "object"
      },
      "ProtocolStorageReceipt": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/ProtocolLegacyStorageReceipt"
          },
          {
            "$ref": "#/components/schemas/ProtocolKubeVirtStorageReceipt"
          },
          {
            "$ref": "#/components/schemas/ProtocolNativeStorageReceipt"
          }
        ]
      },
      "ProtocolStorageTransaction": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/ProtocolKubeVirtTransaction"
          },
          {
            "$ref": "#/components/schemas/ProtocolNativeTransaction"
          }
        ]
      },
      "ProtocolTransactionReceipt": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/ProtocolKubeVirtStorageReceipt"
          },
          {
            "$ref": "#/components/schemas/ProtocolNativeStorageReceipt"
          }
        ]
      },
      "ProtocolWireArtifact": {
        "additionalProperties": false,
        "properties": {
          "ciphertext_max": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Ciphertext Max",
            "type": "integer"
          },
          "ciphertext_min": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Ciphertext Min",
            "type": "integer"
          },
          "key": {
            "maxLength": 1024,
            "minLength": 1,
            "title": "Key",
            "type": "string"
          },
          "plaintext_max": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Plaintext Max",
            "type": "integer"
          },
          "plaintext_min": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Plaintext Min",
            "type": "integer"
          },
          "role": {
            "title": "Role",
            "type": "string"
          },
          "volume_id": {
            "title": "Volume Id",
            "type": "string"
          }
        },
        "required": [
          "volume_id",
          "role",
          "key",
          "plaintext_min",
          "plaintext_max",
          "ciphertext_min",
          "ciphertext_max"
        ],
        "title": "Artifact",
        "type": "object"
      },
      "ProtocolWireCapabilityEvidenceRef": {
        "additionalProperties": false,
        "properties": {
          "adapter": {
            "const": "vnbui-callback-provider/1",
            "title": "Adapter",
            "type": "string"
          },
          "id": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
            "title": "Id",
            "type": "string"
          },
          "revision": {
            "exclusiveMinimum": 0,
            "maximum": 9223372036854775807,
            "title": "Revision",
            "type": "integer"
          },
          "sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "title": "Sha256",
            "type": "string"
          },
          "wire": {
            "const": "vnbui-storage-transaction/1",
            "title": "Wire",
            "type": "string"
          }
        },
        "required": [
          "id",
          "revision",
          "sha256",
          "adapter",
          "wire"
        ],
        "title": "CapabilityEvidenceRef",
        "type": "object"
      },
      "ProtocolWireCapabilityEvidenceRefV2": {
        "additionalProperties": false,
        "properties": {
          "adapter": {
            "const": "vnbui-callback-provider/1",
            "title": "Adapter",
            "type": "string"
          },
          "id": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
            "title": "Id",
            "type": "string"
          },
          "revision": {
            "exclusiveMinimum": 0,
            "maximum": 9223372036854775807,
            "title": "Revision",
            "type": "integer"
          },
          "schema": {
            "maximum": 2,
            "minimum": 2,
            "title": "Schema",
            "type": "integer"
          },
          "sha256": {
            "pattern": "^[0-9a-f]{64}$",
            "title": "Sha256",
            "type": "string"
          },
          "wire": {
            "const": "vnbui-storage-transaction/1",
            "title": "Wire",
            "type": "string"
          }
        },
        "required": [
          "id",
          "revision",
          "sha256",
          "adapter",
          "wire",
          "schema"
        ],
        "title": "CapabilityEvidenceRefV2",
        "type": "object"
      },
      "ProtocolWireDiskMapping": {
        "additionalProperties": false,
        "properties": {
          "bus": {
            "title": "Bus",
            "type": "string"
          },
          "device": {
            "title": "Device",
            "type": "string"
          },
          "disk_name": {
            "title": "Disk Name",
            "type": "string"
          },
          "serial": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Serial"
          }
        },
        "required": [
          "disk_name",
          "device",
          "bus",
          "serial"
        ],
        "title": "DiskMapping",
        "type": "object"
      },
      "ProtocolWireEncryption": {
        "additionalProperties": false,
        "properties": {
          "format": {
            "title": "Format",
            "type": "string"
          },
          "key_ref": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Key Ref"
          }
        },
        "required": [
          "format",
          "key_ref"
        ],
        "title": "Encryption",
        "type": "object"
      },
      "ProtocolWireNativeArtifact": {
        "additionalProperties": false,
        "properties": {
          "artifact_id": {
            "title": "Artifact Id",
            "type": "string"
          },
          "ciphertext_max": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Ciphertext Max",
            "type": "integer"
          },
          "ciphertext_min": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Ciphertext Min",
            "type": "integer"
          },
          "disk_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Disk Id"
          },
          "key": {
            "maxLength": 1024,
            "minLength": 1,
            "title": "Key",
            "type": "string"
          },
          "plaintext_max": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Plaintext Max",
            "type": "integer"
          },
          "plaintext_min": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "title": "Plaintext Min",
            "type": "integer"
          },
          "role": {
            "title": "Role",
            "type": "string"
          }
        },
        "required": [
          "artifact_id",
          "disk_id",
          "role",
          "key",
          "plaintext_min",
          "plaintext_max",
          "ciphertext_min",
          "ciphertext_max"
        ],
        "title": "NativeArtifact",
        "type": "object"
      },
      "ProtocolWireNativeDiskSource": {
        "additionalProperties": false,
        "properties": {
          "agent_id": {
            "title": "Agent Id",
            "type": "string"
          },
          "namespace": {
            "title": "Namespace",
            "type": "string"
          },
          "native_volumes": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireVolume"
            },
            "maxItems": 256,
            "minItems": 1,
            "title": "Native Volumes",
            "type": "array"
          },
          "schema": {
            "const": 2,
            "title": "Schema",
            "type": "integer"
          },
          "vm_id": {
            "title": "Vm Id",
            "type": "string"
          },
          "vm_uid": {
            "title": "Vm Uid",
            "type": "string"
          },
          "vmi_uid": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vmi Uid"
          },
          "volumes": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireVolume"
            },
            "maxItems": 256,
            "minItems": 1,
            "title": "Volumes",
            "type": "array"
          }
        },
        "required": [
          "schema",
          "agent_id",
          "vm_id",
          "vm_uid",
          "vmi_uid",
          "namespace",
          "volumes",
          "native_volumes"
        ],
        "title": "NativeDiskSource",
        "type": "object"
      },
      "ProtocolWireNativePlan": {
        "additionalProperties": false,
        "properties": {
          "artifacts": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireNativeArtifact"
            },
            "maxItems": 4096,
            "minItems": 1,
            "title": "Artifacts",
            "type": "array"
          },
          "attempt_id": {
            "title": "Attempt Id",
            "type": "string"
          },
          "backup_type": {
            "enum": [
              "full",
              "incremental"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "capability_profile": {
            "enum": [
              "checksum-enforced/1",
              "consumer-verified/1",
              "db-rooted-consumer-verified/1"
            ],
            "title": "Capability Profile",
            "type": "string"
          },
          "checksum_policy": {
            "const": "sha256-parts-receipt-v2",
            "title": "Checksum Policy",
            "type": "string"
          },
          "credential_ref": {
            "const": "installation/storage.s3",
            "title": "Credential Ref",
            "type": "string"
          },
          "encryption": {
            "$ref": "#/components/schemas/ProtocolWireEncryption"
          },
          "exclusions": {
            "items": {
              "type": "string"
            },
            "maxItems": 128,
            "title": "Exclusions",
            "type": "array"
          },
          "parent": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireParent"
              },
              {
                "type": "null"
              }
            ]
          },
          "provider": {
            "const": "libvirt",
            "title": "Provider",
            "type": "string"
          },
          "source": {
            "additionalProperties": false,
            "properties": {
              "agent_id": {
                "type": "string"
              },
              "inventory": {
                "$ref": "#/components/schemas/ProtocolNativeInventory"
              },
              "inventory_sha256": {
                "pattern": "^[0-9a-f]{64}$",
                "type": "string"
              },
              "representation": {
                "const": "libvirt-native-fileset/1",
                "type": "string"
              },
              "vm_id": {
                "type": "string"
              }
            },
            "required": [
              "representation",
              "agent_id",
              "vm_id",
              "inventory_sha256",
              "inventory"
            ],
            "type": "object"
          },
          "target": {
            "$ref": "#/components/schemas/ProtocolWireTarget"
          }
        },
        "required": [
          "attempt_id",
          "capability_profile",
          "provider",
          "source",
          "backup_type",
          "parent",
          "exclusions",
          "target",
          "credential_ref",
          "encryption",
          "artifacts",
          "checksum_policy"
        ],
        "title": "NativePlan",
        "type": "object"
      },
      "ProtocolWireParent": {
        "additionalProperties": false,
        "properties": {
          "backup_id": {
            "title": "Backup Id",
            "type": "string"
          },
          "checkpoint": {
            "title": "Checkpoint",
            "type": "string"
          },
          "generation_id": {
            "title": "Generation Id",
            "type": "string"
          },
          "receipt_sha256": {
            "title": "Receipt Sha256",
            "type": "string"
          },
          "root_backup_id": {
            "title": "Root Backup Id",
            "type": "string"
          },
          "tracker_uid": {
            "title": "Tracker Uid",
            "type": "string"
          }
        },
        "required": [
          "backup_id",
          "root_backup_id",
          "receipt_sha256",
          "generation_id",
          "tracker_uid",
          "checkpoint"
        ],
        "title": "Parent",
        "type": "object"
      },
      "ProtocolWirePlan": {
        "additionalProperties": false,
        "properties": {
          "artifacts": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireArtifact"
            },
            "maxItems": 4096,
            "minItems": 1,
            "title": "Artifacts",
            "type": "array"
          },
          "attempt_id": {
            "title": "Attempt Id",
            "type": "string"
          },
          "backup_type": {
            "enum": [
              "full",
              "incremental"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "capability_profile": {
            "enum": [
              "checksum-enforced/1",
              "consumer-verified/1",
              "db-rooted-consumer-verified/1"
            ],
            "title": "Capability Profile",
            "type": "string"
          },
          "checksum_policy": {
            "const": "sha256-parts-receipt-v2",
            "title": "Checksum Policy",
            "type": "string"
          },
          "credential_ref": {
            "title": "Credential Ref",
            "type": "string"
          },
          "encryption": {
            "$ref": "#/components/schemas/ProtocolWireEncryption"
          },
          "exclusions": {
            "items": {
              "type": "string"
            },
            "maxItems": 256,
            "title": "Exclusions",
            "type": "array"
          },
          "parent": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireParent"
              },
              {
                "type": "null"
              }
            ]
          },
          "provider": {
            "const": "kubevirt",
            "title": "Provider",
            "type": "string"
          },
          "source": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireNativeDiskSource"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireSource"
              }
            ],
            "title": "Source"
          },
          "target": {
            "$ref": "#/components/schemas/ProtocolWireTarget"
          },
          "vm_name": {
            "title": "Vm Name",
            "type": "string"
          }
        },
        "required": [
          "attempt_id",
          "capability_profile",
          "source",
          "provider",
          "vm_name",
          "backup_type",
          "exclusions",
          "parent",
          "target",
          "credential_ref",
          "encryption",
          "artifacts",
          "checksum_policy"
        ],
        "title": "Plan",
        "type": "object"
      },
      "ProtocolWireQualifiedPlan": {
        "additionalProperties": false,
        "properties": {
          "artifacts": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireArtifact"
            },
            "maxItems": 4096,
            "minItems": 1,
            "title": "Artifacts",
            "type": "array"
          },
          "attempt_id": {
            "title": "Attempt Id",
            "type": "string"
          },
          "backup_type": {
            "enum": [
              "full",
              "incremental"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "capability_evidence": {
            "$ref": "#/components/schemas/ProtocolWireCapabilityEvidenceRef"
          },
          "capability_profile": {
            "enum": [
              "checksum-enforced/1",
              "consumer-verified/1",
              "db-rooted-consumer-verified/1"
            ],
            "title": "Capability Profile",
            "type": "string"
          },
          "checksum_policy": {
            "const": "sha256-parts-receipt-v2",
            "title": "Checksum Policy",
            "type": "string"
          },
          "credential_ref": {
            "title": "Credential Ref",
            "type": "string"
          },
          "encryption": {
            "$ref": "#/components/schemas/ProtocolWireEncryption"
          },
          "evidence_schema": {
            "maximum": 1,
            "minimum": 1,
            "title": "Evidence Schema",
            "type": "integer"
          },
          "exclusions": {
            "items": {
              "type": "string"
            },
            "maxItems": 256,
            "title": "Exclusions",
            "type": "array"
          },
          "parent": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireParent"
              },
              {
                "type": "null"
              }
            ]
          },
          "provider": {
            "const": "kubevirt",
            "title": "Provider",
            "type": "string"
          },
          "source": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireNativeDiskSource"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireSource"
              }
            ],
            "title": "Source"
          },
          "target": {
            "$ref": "#/components/schemas/ProtocolWireTarget"
          },
          "vm_name": {
            "title": "Vm Name",
            "type": "string"
          }
        },
        "required": [
          "attempt_id",
          "capability_profile",
          "source",
          "provider",
          "vm_name",
          "backup_type",
          "exclusions",
          "parent",
          "target",
          "credential_ref",
          "encryption",
          "artifacts",
          "checksum_policy",
          "evidence_schema",
          "capability_evidence"
        ],
        "title": "QualifiedPlan",
        "type": "object"
      },
      "ProtocolWireQualifiedPlanV2": {
        "additionalProperties": false,
        "properties": {
          "artifacts": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireArtifact"
            },
            "maxItems": 4096,
            "minItems": 1,
            "title": "Artifacts",
            "type": "array"
          },
          "attempt_id": {
            "title": "Attempt Id",
            "type": "string"
          },
          "backup_type": {
            "enum": [
              "full",
              "incremental"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "capability_evidence": {
            "$ref": "#/components/schemas/ProtocolWireCapabilityEvidenceRefV2"
          },
          "capability_profile": {
            "enum": [
              "checksum-enforced/1",
              "consumer-verified/1",
              "db-rooted-consumer-verified/1"
            ],
            "title": "Capability Profile",
            "type": "string"
          },
          "checksum_policy": {
            "const": "sha256-parts-receipt-v2",
            "title": "Checksum Policy",
            "type": "string"
          },
          "credential_ref": {
            "title": "Credential Ref",
            "type": "string"
          },
          "encryption": {
            "$ref": "#/components/schemas/ProtocolWireEncryption"
          },
          "evidence_schema": {
            "maximum": 2,
            "minimum": 2,
            "title": "Evidence Schema",
            "type": "integer"
          },
          "exclusions": {
            "items": {
              "type": "string"
            },
            "maxItems": 256,
            "title": "Exclusions",
            "type": "array"
          },
          "parent": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireParent"
              },
              {
                "type": "null"
              }
            ]
          },
          "provider": {
            "const": "kubevirt",
            "title": "Provider",
            "type": "string"
          },
          "source": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireNativeDiskSource"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireSource"
              }
            ],
            "title": "Source"
          },
          "target": {
            "$ref": "#/components/schemas/ProtocolWireTarget"
          },
          "vm_name": {
            "title": "Vm Name",
            "type": "string"
          }
        },
        "required": [
          "attempt_id",
          "capability_profile",
          "source",
          "provider",
          "vm_name",
          "backup_type",
          "exclusions",
          "parent",
          "target",
          "credential_ref",
          "encryption",
          "artifacts",
          "checksum_policy",
          "evidence_schema",
          "capability_evidence"
        ],
        "title": "QualifiedPlanV2",
        "type": "object"
      },
      "ProtocolWireSource": {
        "additionalProperties": false,
        "properties": {
          "agent_id": {
            "title": "Agent Id",
            "type": "string"
          },
          "namespace": {
            "title": "Namespace",
            "type": "string"
          },
          "schema": {
            "const": 1,
            "type": "integer"
          },
          "vm_id": {
            "title": "Vm Id",
            "type": "string"
          },
          "vm_uid": {
            "title": "Vm Uid",
            "type": "string"
          },
          "vmi_uid": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vmi Uid"
          },
          "volumes": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireVolume"
            },
            "maxItems": 256,
            "minItems": 1,
            "title": "Volumes",
            "type": "array"
          }
        },
        "required": [
          "schema",
          "agent_id",
          "vm_id",
          "vm_uid",
          "vmi_uid",
          "namespace",
          "volumes"
        ],
        "title": "Source",
        "type": "object"
      },
      "ProtocolWireTarget": {
        "additionalProperties": false,
        "properties": {
          "bucket": {
            "title": "Bucket",
            "type": "string"
          },
          "configuration_prefix": {
            "title": "Configuration Prefix",
            "type": "string"
          },
          "endpoint": {
            "title": "Endpoint",
            "type": "string"
          },
          "region": {
            "title": "Region",
            "type": "string"
          }
        },
        "required": [
          "endpoint",
          "bucket",
          "region",
          "configuration_prefix"
        ],
        "title": "Target",
        "type": "object"
      },
      "ProtocolWireTransferPlan": {
        "additionalProperties": false,
        "properties": {
          "artifacts": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireArtifact"
            },
            "maxItems": 4096,
            "minItems": 1,
            "title": "Artifacts",
            "type": "array"
          },
          "attempt_id": {
            "title": "Attempt Id",
            "type": "string"
          },
          "backup_type": {
            "enum": [
              "full",
              "incremental"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "capability_profile": {
            "enum": [
              "checksum-enforced/1",
              "consumer-verified/1",
              "db-rooted-consumer-verified/1"
            ],
            "title": "Capability Profile",
            "type": "string"
          },
          "checksum_policy": {
            "const": "sha256-parts-receipt-v2",
            "title": "Checksum Policy",
            "type": "string"
          },
          "credential_ref": {
            "title": "Credential Ref",
            "type": "string"
          },
          "encryption": {
            "$ref": "#/components/schemas/ProtocolWireEncryption"
          },
          "exclusions": {
            "items": {
              "type": "string"
            },
            "maxItems": 256,
            "title": "Exclusions",
            "type": "array"
          },
          "parent": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireParent"
              },
              {
                "type": "null"
              }
            ]
          },
          "provider": {
            "const": "kubevirt",
            "title": "Provider",
            "type": "string"
          },
          "source": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireNativeDiskSource"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireSource"
              }
            ],
            "title": "Source"
          },
          "target": {
            "$ref": "#/components/schemas/ProtocolWireTarget"
          },
          "transfer_profile": {
            "const": "kubevirt-32m/1",
            "title": "Transfer Profile",
            "type": "string"
          },
          "vm_name": {
            "title": "Vm Name",
            "type": "string"
          }
        },
        "required": [
          "attempt_id",
          "capability_profile",
          "source",
          "provider",
          "vm_name",
          "backup_type",
          "exclusions",
          "parent",
          "target",
          "credential_ref",
          "encryption",
          "artifacts",
          "checksum_policy",
          "transfer_profile"
        ],
        "title": "TransferPlan",
        "type": "object"
      },
      "ProtocolWireTransferQualifiedPlan": {
        "additionalProperties": false,
        "properties": {
          "artifacts": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireArtifact"
            },
            "maxItems": 4096,
            "minItems": 1,
            "title": "Artifacts",
            "type": "array"
          },
          "attempt_id": {
            "title": "Attempt Id",
            "type": "string"
          },
          "backup_type": {
            "enum": [
              "full",
              "incremental"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "capability_evidence": {
            "$ref": "#/components/schemas/ProtocolWireCapabilityEvidenceRef"
          },
          "capability_profile": {
            "enum": [
              "checksum-enforced/1",
              "consumer-verified/1",
              "db-rooted-consumer-verified/1"
            ],
            "title": "Capability Profile",
            "type": "string"
          },
          "checksum_policy": {
            "const": "sha256-parts-receipt-v2",
            "title": "Checksum Policy",
            "type": "string"
          },
          "credential_ref": {
            "title": "Credential Ref",
            "type": "string"
          },
          "encryption": {
            "$ref": "#/components/schemas/ProtocolWireEncryption"
          },
          "evidence_schema": {
            "maximum": 1,
            "minimum": 1,
            "title": "Evidence Schema",
            "type": "integer"
          },
          "exclusions": {
            "items": {
              "type": "string"
            },
            "maxItems": 256,
            "title": "Exclusions",
            "type": "array"
          },
          "parent": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireParent"
              },
              {
                "type": "null"
              }
            ]
          },
          "provider": {
            "const": "kubevirt",
            "title": "Provider",
            "type": "string"
          },
          "source": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireNativeDiskSource"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireSource"
              }
            ],
            "title": "Source"
          },
          "target": {
            "$ref": "#/components/schemas/ProtocolWireTarget"
          },
          "transfer_profile": {
            "const": "kubevirt-32m/1",
            "title": "Transfer Profile",
            "type": "string"
          },
          "vm_name": {
            "title": "Vm Name",
            "type": "string"
          }
        },
        "required": [
          "attempt_id",
          "capability_profile",
          "source",
          "provider",
          "vm_name",
          "backup_type",
          "exclusions",
          "parent",
          "target",
          "credential_ref",
          "encryption",
          "artifacts",
          "checksum_policy",
          "transfer_profile",
          "evidence_schema",
          "capability_evidence"
        ],
        "title": "TransferQualifiedPlan",
        "type": "object"
      },
      "ProtocolWireTransferQualifiedPlanV2": {
        "additionalProperties": false,
        "properties": {
          "artifacts": {
            "items": {
              "$ref": "#/components/schemas/ProtocolWireArtifact"
            },
            "maxItems": 4096,
            "minItems": 1,
            "title": "Artifacts",
            "type": "array"
          },
          "attempt_id": {
            "title": "Attempt Id",
            "type": "string"
          },
          "backup_type": {
            "enum": [
              "full",
              "incremental"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "capability_evidence": {
            "$ref": "#/components/schemas/ProtocolWireCapabilityEvidenceRefV2"
          },
          "capability_profile": {
            "enum": [
              "checksum-enforced/1",
              "consumer-verified/1",
              "db-rooted-consumer-verified/1"
            ],
            "title": "Capability Profile",
            "type": "string"
          },
          "checksum_policy": {
            "const": "sha256-parts-receipt-v2",
            "title": "Checksum Policy",
            "type": "string"
          },
          "credential_ref": {
            "title": "Credential Ref",
            "type": "string"
          },
          "encryption": {
            "$ref": "#/components/schemas/ProtocolWireEncryption"
          },
          "evidence_schema": {
            "maximum": 2,
            "minimum": 2,
            "title": "Evidence Schema",
            "type": "integer"
          },
          "exclusions": {
            "items": {
              "type": "string"
            },
            "maxItems": 256,
            "title": "Exclusions",
            "type": "array"
          },
          "parent": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireParent"
              },
              {
                "type": "null"
              }
            ]
          },
          "provider": {
            "const": "kubevirt",
            "title": "Provider",
            "type": "string"
          },
          "source": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProtocolWireNativeDiskSource"
              },
              {
                "$ref": "#/components/schemas/ProtocolWireSource"
              }
            ],
            "title": "Source"
          },
          "target": {
            "$ref": "#/components/schemas/ProtocolWireTarget"
          },
          "transfer_profile": {
            "const": "kubevirt-32m/1",
            "title": "Transfer Profile",
            "type": "string"
          },
          "vm_name": {
            "title": "Vm Name",
            "type": "string"
          }
        },
        "required": [
          "attempt_id",
          "capability_profile",
          "source",
          "provider",
          "vm_name",
          "backup_type",
          "exclusions",
          "parent",
          "target",
          "credential_ref",
          "encryption",
          "artifacts",
          "checksum_policy",
          "transfer_profile",
          "evidence_schema",
          "capability_evidence"
        ],
        "title": "TransferQualifiedPlanV2",
        "type": "object"
      },
      "ProtocolWireVolume": {
        "additionalProperties": false,
        "properties": {
          "capacity_bytes": {
            "exclusiveMinimum": 0,
            "maximum": 9223372036854775807,
            "title": "Capacity Bytes",
            "type": "integer"
          },
          "mapping": {
            "$ref": "#/components/schemas/ProtocolWireDiskMapping"
          },
          "name": {
            "title": "Name",
            "type": "string"
          },
          "pvc_name": {
            "title": "Pvc Name",
            "type": "string"
          },
          "pvc_resource_version": {
            "title": "Pvc Resource Version",
            "type": "string"
          },
          "pvc_uid": {
            "title": "Pvc Uid",
            "type": "string"
          }
        },
        "required": [
          "name",
          "pvc_name",
          "pvc_uid",
          "pvc_resource_version",
          "capacity_bytes",
          "mapping"
        ],
        "title": "Volume",
        "type": "object"
      },
      "RealtimeErrorDetail": {
        "properties": {
          "code": {
            "enum": [
              "realtime_contract_unsupported",
              "realtime_parameters_conflict",
              "realtime_cursor_invalid",
              "realtime_cursor_contract_required",
              "realtime_timestamp_invalid"
            ],
            "title": "Code",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          }
        },
        "required": [
          "code",
          "message"
        ],
        "title": "RealtimeErrorDetail",
        "type": "object"
      },
      "RealtimeErrorResponse": {
        "properties": {
          "detail": {
            "$ref": "#/components/schemas/RealtimeErrorDetail"
          }
        },
        "required": [
          "detail"
        ],
        "title": "RealtimeErrorResponse",
        "type": "object"
      },
      "RealtimePage": {
        "additionalProperties": false,
        "properties": {
          "delivery": {
            "const": "best_effort",
            "title": "Delivery",
            "type": "string"
          },
          "has_more": {
            "title": "Has More",
            "type": "boolean"
          },
          "items": {
            "items": {
              "$ref": "#/components/schemas/CursorRealtimeEvent"
            },
            "title": "Items",
            "type": "array"
          },
          "next_cursor": {
            "title": "Next Cursor",
            "type": "string"
          },
          "reset_reason": {
            "anyOf": [
              {
                "enum": [
                  "initial",
                  "process_changed",
                  "scope_changed",
                  "cursor_expired",
                  "history_lost"
                ],
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reset Reason"
          },
          "reset_required": {
            "title": "Reset Required",
            "type": "boolean"
          },
          "retention_seconds": {
            "const": 300,
            "title": "Retention Seconds",
            "type": "integer"
          }
        },
        "required": [
          "items",
          "next_cursor",
          "has_more",
          "reset_required",
          "reset_reason",
          "retention_seconds",
          "delivery"
        ],
        "title": "RealtimePage",
        "type": "object"
      },
      "ReportCreate": {
        "description": "Request model for creating report",
        "properties": {
          "enabled": {
            "default": true,
            "title": "Enabled",
            "type": "boolean"
          },
          "filters": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Filters"
          },
          "format": {
            "default": "pdf",
            "title": "Format",
            "type": "string"
          },
          "name": {
            "title": "Name",
            "type": "string"
          },
          "recipients": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Recipients"
          },
          "report_type": {
            "title": "Report Type",
            "type": "string"
          },
          "schedule": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Schedule"
          }
        },
        "required": [
          "name",
          "report_type"
        ],
        "title": "ReportCreate",
        "type": "object"
      },
      "RestoreCreateRequest": {
        "additionalProperties": false,
        "description": "Normalize defaults before identity matching; refuse ignored intent.",
        "properties": {
          "adjust_config": {
            "default": false,
            "title": "Adjust Config",
            "type": "boolean"
          },
          "auto_define": {
            "default": false,
            "title": "Auto Define",
            "type": "boolean"
          },
          "backup_id": {
            "minLength": 1,
            "title": "Backup Id",
            "type": "string"
          },
          "kubevirt_target": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/KubeVirtRestoreTarget"
              },
              {
                "type": "null"
              }
            ]
          },
          "native_target": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/NativeRestoreInput"
              },
              {
                "type": "null"
              }
            ]
          },
          "restore_to_original": {
            "default": true,
            "title": "Restore To Original",
            "type": "boolean"
          },
          "selected_disks": {
            "items": {
              "type": "string"
            },
            "title": "Selected Disks",
            "type": "array"
          },
          "target_vm_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Target Vm Name"
          },
          "until_checkpoint": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Until Checkpoint"
          }
        },
        "required": [
          "backup_id"
        ],
        "title": "RestoreCreateRequest",
        "type": "object"
      },
      "RestoreRequest": {
        "properties": {
          "backup_id": {
            "title": "Backup Id",
            "type": "string"
          }
        },
        "required": [
          "backup_id"
        ],
        "title": "RestoreRequest",
        "type": "object"
      },
      "RotateKeyRequest": {
        "properties": {
          "new_name": {
            "maxLength": 255,
            "minLength": 1,
            "title": "New Name",
            "type": "string"
          }
        },
        "required": [
          "new_name"
        ],
        "title": "RotateKeyRequest",
        "type": "object"
      },
      "ScheduleCreate": {
        "description": "Request model for creating schedule",
        "properties": {
          "backup_policy": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Backup Policy"
          },
          "backup_type": {
            "default": "full",
            "enum": [
              "full",
              "incremental",
              "automatic"
            ],
            "title": "Backup Type",
            "type": "string"
          },
          "cron_expression": {
            "title": "Cron Expression",
            "type": "string"
          },
          "enabled": {
            "default": false,
            "title": "Enabled",
            "type": "boolean"
          },
          "exclude_disks": {
            "items": {
              "type": "string"
            },
            "maxItems": 256,
            "title": "Exclude Disks",
            "type": "array"
          },
          "name": {
            "title": "Name",
            "type": "string"
          },
          "retention_days": {
            "default": 30,
            "maximum": 36500.0,
            "minimum": 1.0,
            "title": "Retention Days",
            "type": "integer"
          },
          "tags": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "default": {},
            "title": "Tags"
          },
          "vm_group_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vm Group Id"
          },
          "vm_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vm Id"
          },
          "workers": {
            "description": "Per-backup worker overrides are unsupported",
            "title": "Workers",
            "type": "null"
          }
        },
        "required": [
          "name",
          "cron_expression"
        ],
        "title": "ScheduleCreate",
        "type": "object"
      },
      "ScheduleRequest": {
        "properties": {
          "backup_type": {
            "default": "full",
            "pattern": "^(full|incremental)$",
            "title": "Backup Type",
            "type": "string"
          },
          "cron_expression": {
            "maxLength": 80,
            "minLength": 5,
            "title": "Cron Expression",
            "type": "string"
          },
          "enabled": {
            "default": true,
            "title": "Enabled",
            "type": "boolean"
          },
          "name": {
            "maxLength": 80,
            "minLength": 1,
            "title": "Name",
            "type": "string"
          },
          "retention_days": {
            "default": 30,
            "maximum": 90.0,
            "minimum": 1.0,
            "title": "Retention Days",
            "type": "integer"
          },
          "vm_group_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vm Group Id"
          },
          "vm_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vm Id"
          }
        },
        "required": [
          "name",
          "cron_expression"
        ],
        "title": "ScheduleRequest",
        "type": "object"
      },
      "ScheduleUpdate": {
        "description": "Request model for updating schedule",
        "properties": {
          "backup_policy": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Backup Policy"
          },
          "backup_type": {
            "anyOf": [
              {
                "enum": [
                  "full",
                  "incremental",
                  "automatic"
                ],
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Backup Type"
          },
          "cron_expression": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cron Expression"
          },
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          },
          "exclude_disks": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "maxItems": 256,
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Exclude Disks"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "retention_days": {
            "anyOf": [
              {
                "maximum": 36500.0,
                "minimum": 1.0,
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Retention Days"
          },
          "tags": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tags"
          },
          "workers": {
            "description": "Per-backup worker overrides are unsupported",
            "title": "Workers",
            "type": "null"
          }
        },
        "title": "ScheduleUpdate",
        "type": "object"
      },
      "StorageSafetyDiagnostic": {
        "additionalProperties": false,
        "description": "Bounded retained safety observation. Missing optional counts/timestamps mean unobserved; zero counts are explicit observations. No credentials, URLs or provider bodies. This does not grant replay, deletion, capacity release or successful completion authority.",
        "properties": {
          "acknowledged_bytes": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "deadline": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "disposition": {
            "enum": [
              "refused",
              "transient",
              "uncertain"
            ],
            "type": "string"
          },
          "estimated_bytes": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "estimated_bytes_per_second": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "expected_native_volumes": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "first_ack_at": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "first_byte_at": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "http_status": {
            "maximum": 599,
            "minimum": 100,
            "type": "integer"
          },
          "last_map_offset": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "last_map_page": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "last_map_raw_ranges": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "last_map_stored_ranges": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "last_map_volume": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "last_progress_at": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "last_trustworthy_observation_at": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "native_stop_http_status": {
            "maximum": 599,
            "minimum": 100,
            "type": "integer"
          },
          "native_stop_phase": {
            "pattern": "^[a-z][a-z_]{0,79}$",
            "type": "string"
          },
          "no_progress_budget_seconds": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "no_progress_seconds": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "observation_deadline": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "observation_reason": {
            "pattern": "^[a-z][a-z_]{0,79}$",
            "type": "string"
          },
          "observation_uncertain_since": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "observed_export_links": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "observed_native_volumes": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "offset": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "page": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "producer_deadline": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "raw_ranges": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "read_observation_deadline": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "read_observation_reason": {
            "pattern": "^[a-z][a-z_]{0,79}$",
            "type": "string"
          },
          "read_observation_uncertain_since": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "reason": {
            "pattern": "^[a-z][a-z_]{0,79}$",
            "type": "string"
          },
          "run_budget_seconds": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "scratch_available_bytes": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "scratch_peak_growth_bytes_per_second": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "scratch_required_bytes": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "scratch_sample_at": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "scratch_time_to_full_seconds": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "stage": {
            "pattern": "^[a-z][a-z_]{0,79}$",
            "type": "string"
          },
          "started_at": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "stop_at": {
            "format": "date-time",
            "pattern": "Z$",
            "type": "string"
          },
          "stored_ranges": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          },
          "volume": {
            "maximum": 9223372036854775807,
            "minimum": 0,
            "type": "integer"
          }
        },
        "required": [
          "stage",
          "reason",
          "disposition"
        ],
        "type": "object"
      },
      "UserCreate": {
        "additionalProperties": false,
        "description": "Request model for creating user",
        "properties": {
          "email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Email"
          },
          "full_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Full Name"
          },
          "is_active": {
            "default": true,
            "title": "Is Active",
            "type": "boolean"
          },
          "password": {
            "minLength": 1,
            "title": "Password",
            "type": "string"
          },
          "role": {
            "default": "viewer",
            "enum": [
              "admin",
              "operator",
              "viewer"
            ],
            "title": "Role",
            "type": "string"
          },
          "username": {
            "maxLength": 255,
            "minLength": 1,
            "title": "Username",
            "type": "string"
          }
        },
        "required": [
          "username",
          "password"
        ],
        "title": "UserCreate",
        "type": "object"
      },
      "UserUpdate": {
        "additionalProperties": false,
        "description": "Request model for updating user",
        "properties": {
          "email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Email"
          },
          "full_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Full Name"
          },
          "is_active": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Is Active"
          },
          "password": {
            "anyOf": [
              {
                "minLength": 1,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Password"
          },
          "role": {
            "anyOf": [
              {
                "enum": [
                  "admin",
                  "operator",
                  "viewer"
                ],
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Role"
          },
          "role_source": {
            "anyOf": [
              {
                "enum": [
                  "local",
                  "oidc"
                ],
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Role Source"
          },
          "username": {
            "anyOf": [
              {
                "maxLength": 255,
                "minLength": 1,
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Username"
          }
        },
        "title": "UserUpdate",
        "type": "object"
      },
      "VMGroupAddVMs": {
        "description": "Request model for adding VMs to group",
        "properties": {
          "vm_ids": {
            "items": {
              "type": "string"
            },
            "title": "Vm Ids",
            "type": "array"
          }
        },
        "required": [
          "vm_ids"
        ],
        "title": "VMGroupAddVMs",
        "type": "object"
      },
      "VMGroupCreate": {
        "description": "Request model for creating VM group",
        "properties": {
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "group_type": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": "static",
            "title": "Group Type"
          },
          "name": {
            "title": "Name",
            "type": "string"
          },
          "rules": {
            "anyOf": [
              {
                "items": {
                  "additionalProperties": true,
                  "type": "object"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Rules"
          },
          "rules_match": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "default": "all",
            "title": "Rules Match"
          },
          "tags": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "default": [],
            "title": "Tags"
          }
        },
        "required": [
          "name"
        ],
        "title": "VMGroupCreate",
        "type": "object"
      },
      "VMGroupUpdate": {
        "description": "Request model for updating VM group",
        "properties": {
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "group_type": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Group Type"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "rules": {
            "anyOf": [
              {
                "items": {
                  "additionalProperties": true,
                  "type": "object"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Rules"
          },
          "rules_match": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Rules Match"
          },
          "tags": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tags"
          }
        },
        "title": "VMGroupUpdate",
        "type": "object"
      },
      "ValidationError": {
        "properties": {
          "ctx": {
            "title": "Context",
            "type": "object"
          },
          "input": {
            "title": "Input"
          },
          "loc": {
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "title": "Location",
            "type": "array"
          },
          "msg": {
            "title": "Message",
            "type": "string"
          },
          "type": {
            "title": "Error Type",
            "type": "string"
          }
        },
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError",
        "type": "object"
      },
      "VerificationCommand": {
        "additionalProperties": false,
        "properties": {
          "action": {
            "default": "start",
            "enum": [
              "start",
              "resume",
              "cancel"
            ],
            "title": "Action",
            "type": "string"
          },
          "verification_id": {
            "title": "Verification Id",
            "type": "string"
          }
        },
        "required": [
          "verification_id"
        ],
        "title": "VerificationCommand",
        "type": "object"
      },
      "VerificationResult": {
        "additionalProperties": false,
        "properties": {
          "agent_id": {
            "type": "string"
          },
          "members": {
            "items": {
              "additionalProperties": false,
              "properties": {
                "backup_id": {
                  "type": "string"
                },
                "objects": {
                  "type": "integer"
                },
                "plan_sha256": {
                  "type": "string"
                },
                "receipt_sha256": {
                  "type": "string"
                },
                "reservation_id": {
                  "type": "string"
                }
              },
              "required": [
                "backup_id",
                "reservation_id",
                "plan_sha256",
                "receipt_sha256",
                "objects"
              ],
              "type": "object"
            },
            "type": "array"
          },
          "org_id": {
            "type": "string"
          },
          "provider": {
            "type": "string"
          },
          "schema": {
            "const": "vnbui-chain-verification/1"
          },
          "vm_id": {
            "type": "string"
          }
        },
        "required": [
          "schema",
          "provider",
          "org_id",
          "agent_id",
          "vm_id",
          "members"
        ],
        "type": "object"
      }
    },
    "securitySchemes": {
      "AgentCandidate": {
        "description": "Pending candidate proof authorizes only its exact activation route.",
        "in": "header",
        "name": "X-Agent-Key",
        "type": "apiKey"
      },
      "AgentKey": {
        "in": "header",
        "name": "X-Agent-Key",
        "type": "apiKey"
      },
      "AgentMTLS": {
        "description": "Transport-verified client certificate; never a caller-supplied fingerprint header.",
        "type": "mutualTLS"
      },
      "DemoSession": {
        "in": "cookie",
        "name": "vnbui_demo_session",
        "type": "apiKey"
      },
      "OAuth2PasswordBearer": {
        "flows": {
          "password": {
            "scopes": {},
            "tokenUrl": "/api/v1/auth/login"
          }
        },
        "type": "oauth2"
      },
      "OIDCPKCE": {
        "in": "cookie",
        "name": "oidc_pkce",
        "type": "apiKey"
      },
      "OIDCState": {
        "in": "cookie",
        "name": "oidc_state",
        "type": "apiKey"
      },
      "RegistrationKey": {
        "in": "header",
        "name": "X-API-Key",
        "type": "apiKey"
      }
    }
  },
  "info": {
    "description": "KVM Backup Orchestration Platform",
    "title": "Vesta API",
    "version": "6.0.81"
  },
  "openapi": "3.1.0",
  "paths": {
    "/api/v1/activity": {
      "get": {
        "description": "Unified activity feed combining user actions and system events.\n\nMerges ActivityLog (user actions) and SystemEvent (agent/system events)\ninto a single chronological feed.\n\nArgs:\n    skip: Number of records to skip\n    limit: Max records to return (max 100)\n    source: Filter by source - \"user\" for ActivityLog, \"system\" for SystemEvent, None for both\n    action: Filter by action type (e.g., \"backup_created\") - applies to user events only\n    resource_type: Filter by resource type (e.g., \"backup\", \"vm_group\")\n\nReturns:\n    Combined activity list sorted by timestamp",
        "operationId": "get_activity_api_v1_activity_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "description": "Clamped to 100 per page",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "description": "Clamped to 100 per page",
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "source",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Source"
            }
          },
          {
            "in": "query",
            "name": "action",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Action"
            }
          },
          {
            "in": "query",
            "name": "resource_type",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Resource Type"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "activities": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "attribution": {
                            "type": "string"
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "details": {
                            "additionalProperties": true,
                            "description": "Extensible domain metadata; keys are not a closed schema.",
                            "type": "object",
                            "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                          },
                          "event_type": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "org_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "resource_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "resource_type": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "source": {
                            "enum": [
                              "user",
                              "system"
                            ],
                            "type": "string"
                          },
                          "source_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "source",
                          "source_name",
                          "event_type",
                          "resource_type",
                          "resource_id",
                          "details",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "has_more": {
                      "type": "boolean"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "activities",
                    "total",
                    "skip",
                    "limit",
                    "has_more"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Activity",
        "tags": [
          "activity"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending, source descending, id descending",
          "pagination": "offset",
          "snapshot": false
        }
      }
    },
    "/api/v1/activity/unified": {
      "get": {
        "description": "DEPRECATED: Use /api/v1/activity instead. This endpoint will be removed in v4.0.",
        "operationId": "get_unified_activity_deprecated_api_v1_activity_unified_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "description": "Clamped to 100 per page",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "description": "Clamped to 100 per page",
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "source",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Source"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "activities": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "attribution": {
                            "type": "string"
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "details": {
                            "additionalProperties": true,
                            "description": "Extensible domain metadata; keys are not a closed schema.",
                            "type": "object",
                            "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                          },
                          "event_type": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "org_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "resource_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "resource_type": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "source": {
                            "enum": [
                              "user",
                              "system"
                            ],
                            "type": "string"
                          },
                          "source_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "source",
                          "source_name",
                          "event_type",
                          "resource_type",
                          "resource_id",
                          "details",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "has_more": {
                      "type": "boolean"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "activities",
                    "total",
                    "skip",
                    "limit",
                    "has_more"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Unified Activity Deprecated",
        "tags": [
          "activity"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending, source descending, id descending",
          "pagination": "offset",
          "snapshot": false
        }
      }
    },
    "/api/v1/agents": {
      "get": {
        "description": "List all agents (protected)",
        "operationId": "list_agents_api_v1_agents_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "items": {
                    "additionalProperties": false,
                    "properties": {
                      "display_name": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "hostname": {
                        "type": "string"
                      },
                      "id": {
                        "type": "string"
                      },
                      "ip_address": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "last_heartbeat": {
                        "anyOf": [
                          {
                            "format": "date-time",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "metrics": {
                        "additionalProperties": true,
                        "description": "Extensible domain metadata; keys are not a closed schema.",
                        "type": "object",
                        "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                      },
                      "port": {
                        "anyOf": [
                          {
                            "type": "integer"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "status": {
                        "type": "string"
                      },
                      "version": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "vm_count": {
                        "type": "integer"
                      }
                    },
                    "required": [
                      "id",
                      "hostname",
                      "display_name",
                      "status",
                      "ip_address",
                      "port",
                      "version",
                      "last_heartbeat",
                      "vm_count",
                      "metrics"
                    ],
                    "type": "object"
                  },
                  "type": "array"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Agents",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "unspecified",
          "pagination": "unpaginated",
          "snapshot": false
        }
      }
    },
    "/api/v1/agents/backups/{backup_id}/checkpoint-proof": {
      "post": {
        "operationId": "transaction_checkpoint_proof_api_v1_agents_backups__backup_id__checkpoint_proof_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "checkpoint": {
                    "type": "string"
                  },
                  "checkpoint_creation_time": {
                    "type": "string"
                  },
                  "guest_consistency": {
                    "type": "string"
                  },
                  "intent_id": {
                    "type": "string"
                  },
                  "terminal_resource_version": {
                    "type": "string"
                  },
                  "tracker_resource_version": {
                    "type": "string"
                  },
                  "vmb_absent": {
                    "const": true,
                    "type": "boolean"
                  }
                },
                "required": [
                  "intent_id",
                  "checkpoint",
                  "tracker_resource_version",
                  "terminal_resource_version",
                  "checkpoint_creation_time",
                  "guest_consistency",
                  "vmb_absent"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "completed": {
                          "const": false,
                          "type": "boolean"
                        },
                        "intent_id": {
                          "type": "string"
                        },
                        "status": {
                          "const": "awaiting_manifest",
                          "type": "string"
                        }
                      },
                      "required": [
                        "intent_id",
                        "status",
                        "completed"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "completed": {
                          "const": true,
                          "type": "boolean"
                        },
                        "intent_id": {
                          "type": "string"
                        },
                        "status": {
                          "const": "completed",
                          "type": "string"
                        }
                      },
                      "required": [
                        "intent_id",
                        "status",
                        "completed"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Checkpoint evidence durably accepted; publication may still await manifest. Completed replay also returns 202."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Transaction Checkpoint Proof",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/finalize-intent": {
      "post": {
        "operationId": "transaction_finalize_intent_api_v1_agents_backups__backup_id__finalize_intent_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProtocolFinalizeBinding"
              }
            }
          },
          "description": "Exact accepted receipt and immutable source binding; started_at must include timezone. No publication authority is granted by intent acceptance.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "binding": {
                      "$ref": "#/components/schemas/ProtocolFinalizeBinding"
                    },
                    "intent_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "intent_id",
                    "binding"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Transaction Finalize Intent",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/native-admission": {
      "post": {
        "operationId": "native_admission_api_v1_agents_backups__backup_id__native_admission_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "attempt_id": {
                    "type": "string"
                  },
                  "intent_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "producer_request_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  }
                },
                "required": [
                  "attempt_id",
                  "intent_sha256",
                  "producer_request_sha256"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "admitted": {
                      "const": true,
                      "type": "boolean"
                    },
                    "attempt_id": {
                      "type": "string"
                    },
                    "intent_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "producer_request_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "attempt_id",
                    "intent_sha256",
                    "producer_request_sha256",
                    "admitted"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Native Admission",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/native-closed-failure": {
      "post": {
        "operationId": "native_closed_failure_api_v1_agents_backups__backup_id__native_closed_failure_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "closure_canonical": {
                    "type": "string"
                  },
                  "closure_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "intent_canonical": {
                    "type": "string"
                  },
                  "intent_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  }
                },
                "required": [
                  "intent_canonical",
                  "closure_canonical",
                  "intent_sha256",
                  "closure_sha256"
                ],
                "type": "object"
              }
            }
          },
          "description": "Canonical JSON strings and SHA256 digests must match the original admitted intent and exact versioned evidence certificate. Equality, producer identity, and database custody gates are enforced separately.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "attempt_id": {
                      "type": "string"
                    },
                    "capacity_id": {
                      "type": "string"
                    },
                    "closure_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "intent_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "settled": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "settled",
                    "attempt_id",
                    "capacity_id",
                    "intent_sha256",
                    "closure_sha256"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Native Closed Failure",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/native-fenced-failure": {
      "post": {
        "operationId": "native_fenced_failure_api_v1_agents_backups__backup_id__native_fenced_failure_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "fence_canonical": {
                    "type": "string"
                  },
                  "fence_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "intent_canonical": {
                    "type": "string"
                  },
                  "intent_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  }
                },
                "required": [
                  "intent_canonical",
                  "fence_canonical",
                  "intent_sha256",
                  "fence_sha256"
                ],
                "type": "object"
              }
            }
          },
          "description": "Canonical JSON strings and SHA256 digests must match the original admitted intent and exact versioned evidence certificate. Equality, producer identity, and database custody gates are enforced separately.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "attempt_id": {
                      "type": "string"
                    },
                    "capacity_id": {
                      "type": "string"
                    },
                    "fence_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "intent_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "settled": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "settled",
                    "attempt_id",
                    "capacity_id",
                    "intent_sha256",
                    "fence_sha256"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Native Fenced Failure",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/native-inventory": {
      "post": {
        "operationId": "native_inventory_api_v1_agents_backups__backup_id__native_inventory_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "closed_job": {
                    "additionalProperties": false,
                    "properties": {
                      "attempt_id": {
                        "type": "string"
                      },
                      "exit_code": {
                        "const": 0,
                        "type": "integer"
                      },
                      "invocation_id": {
                        "pattern": "^[0-9a-f]{32}$",
                        "type": "string"
                      },
                      "job_id": {
                        "type": "string"
                      },
                      "state": {
                        "enum": [
                          "exited",
                          "sealed"
                        ]
                      }
                    },
                    "required": [
                      "job_id",
                      "attempt_id",
                      "invocation_id",
                      "exit_code",
                      "state"
                    ],
                    "type": "object"
                  },
                  "intent_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "inventory": {
                    "$ref": "#/components/schemas/ProtocolNativeInventory"
                  },
                  "push_result": {
                    "$ref": "#/components/schemas/ProtocolNativePushResult"
                  }
                },
                "required": [
                  "intent_sha256",
                  "inventory",
                  "closed_job",
                  "push_result"
                ],
                "type": "object"
              }
            }
          },
          "description": "Inventory, producer manifest and closed job must bind exactly to the admitted intent, domain and selected disks. Canonical digest and cross-field checks remain runtime requirements.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "accepted": {
                      "const": true,
                      "type": "boolean"
                    },
                    "attempt_id": {
                      "type": "string"
                    },
                    "completed": {
                      "const": false,
                      "type": "boolean"
                    },
                    "inventory_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "accepted",
                    "inventory_sha256",
                    "attempt_id",
                    "completed"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Native Inventory",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/native-no-effect": {
      "post": {
        "operationId": "native_no_effect_api_v1_agents_backups__backup_id__native_no_effect_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "intent_canonical": {
                    "type": "string"
                  },
                  "intent_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "refusal_canonical": {
                    "type": "string"
                  },
                  "refusal_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  }
                },
                "required": [
                  "intent_canonical",
                  "refusal_canonical",
                  "intent_sha256",
                  "refusal_sha256"
                ],
                "type": "object"
              }
            }
          },
          "description": "Canonical JSON strings and SHA256 digests must match the original admitted intent and exact versioned evidence certificate. Equality, producer identity, and database custody gates are enforced separately.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "attempt_id": {
                      "type": "string"
                    },
                    "capacity_id": {
                      "type": "string"
                    },
                    "intent_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "refusal_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "settled": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "settled",
                    "attempt_id",
                    "capacity_id",
                    "intent_sha256",
                    "refusal_sha256"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Native No Effect",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/native-publication": {
      "post": {
        "operationId": "native_publication_api_v1_agents_backups__backup_id__native_publication_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "acceptance_id": {
                    "type": "string"
                  },
                  "receipt_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "reservation_id": {
                    "type": "string"
                  }
                },
                "required": [
                  "reservation_id",
                  "acceptance_id",
                  "receipt_sha256"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "completed": {
                      "const": true,
                      "type": "boolean"
                    },
                    "reservation_id": {
                      "type": "string"
                    },
                    "status": {
                      "const": "completed",
                      "type": "string"
                    }
                  },
                  "required": [
                    "reservation_id",
                    "status",
                    "completed"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Native Publication",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/native-transaction": {
      "post": {
        "operationId": "native_transaction_api_v1_agents_backups__backup_id__native_transaction_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "attempt_id": {
                    "type": "string"
                  },
                  "inventory_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  }
                },
                "required": [
                  "attempt_id",
                  "inventory_sha256"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProtocolNativeTransaction"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:192"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:178"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:183"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:196"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Native Transaction",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/prepared-receipt": {
      "post": {
        "description": "A durable acceptance permits finalize, never completion or visibility.\n\nThe agent must retain its prepared journal until this response is received.\nAuthentication installs persisted tenant identity before any reservation read.",
        "operationId": "prepared_receipt_api_v1_agents_backups__backup_id__prepared_receipt_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProtocolStorageReceipt"
              }
            }
          },
          "description": "Receipt must match all committed artifacts and target; canonical ordering, byte counts and digest bindings are verified. Acceptance does not imply backup visibility or completion.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "accepted": {
                          "const": true,
                          "type": "boolean"
                        },
                        "reservation_id": {
                          "type": "string"
                        },
                        "verification": {
                          "additionalProperties": false,
                          "properties": {
                            "receipt": {
                              "$ref": "#/components/schemas/ProtocolLegacyStorageReceipt"
                            },
                            "scrub_required": {
                              "type": "boolean"
                            },
                            "verification": {
                              "items": {
                                "additionalProperties": false,
                                "properties": {
                                  "assurance": {
                                    "enum": [
                                      "provider_checksum_verified",
                                      "identity_metadata_only"
                                    ]
                                  },
                                  "checksum_sha256": {
                                    "anyOf": [
                                      {
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "checksum_type": {
                                    "anyOf": [
                                      {
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "key": {
                                    "type": "string"
                                  },
                                  "reason": {
                                    "anyOf": [
                                      {
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "version_id": {
                                    "anyOf": [
                                      {
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "required": [
                                  "key",
                                  "version_id",
                                  "assurance",
                                  "reason",
                                  "checksum_type",
                                  "checksum_sha256"
                                ],
                                "type": "object"
                              },
                              "type": "array"
                            }
                          },
                          "required": [
                            "receipt",
                            "verification",
                            "scrub_required"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "reservation_id",
                        "accepted",
                        "verification"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "acceptance_id": {
                          "type": "string"
                        },
                        "accepted": {
                          "const": true,
                          "type": "boolean"
                        },
                        "protocol": {
                          "const": "vnbui-storage-transaction/1",
                          "type": "string"
                        },
                        "receipt_sha256": {
                          "pattern": "^[0-9a-f]{64}$",
                          "type": "string"
                        },
                        "reservation_id": {
                          "type": "string"
                        },
                        "scrub_required": {
                          "type": "boolean"
                        },
                        "verification": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "assurance": {
                                "enum": [
                                  "provider_checksum_verified",
                                  "identity_metadata_only"
                                ]
                              },
                              "key": {
                                "type": "string"
                              },
                              "reason": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "version_id": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "key",
                              "version_id",
                              "assurance",
                              "reason"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "protocol",
                        "reservation_id",
                        "receipt_sha256",
                        "accepted",
                        "acceptance_id",
                        "verification",
                        "scrub_required"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:357"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:340"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:345"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:361"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Prepared Receipt",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/storage-control": {
      "post": {
        "description": "Finite, authenticated control; signed authority never enters durable state.",
        "operationId": "storage_control_api_v1_agents_backups__backup_id__storage_control_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "additionalProperties": false,
                    "properties": {
                      "args": {
                        "additionalProperties": false,
                        "properties": {},
                        "required": [],
                        "type": "object"
                      },
                      "artifact_key": {
                        "type": "string"
                      },
                      "binding": {
                        "$ref": "#/components/schemas/ProtocolAttemptBinding"
                      },
                      "operation": {
                        "const": "create",
                        "type": "string"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "binding",
                      "artifact_key",
                      "operation",
                      "args"
                    ],
                    "type": "object"
                  },
                  {
                    "additionalProperties": false,
                    "properties": {
                      "args": {
                        "additionalProperties": false,
                        "properties": {
                          "bytes": {
                            "minimum": 0,
                            "type": "integer"
                          },
                          "number": {
                            "maximum": 10000,
                            "minimum": 1,
                            "type": "integer"
                          },
                          "sha256": {
                            "pattern": "^[0-9a-f]{64}$",
                            "type": "string"
                          },
                          "upload_id": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "upload_id",
                          "number",
                          "bytes",
                          "sha256"
                        ],
                        "type": "object"
                      },
                      "artifact_key": {
                        "type": "string"
                      },
                      "binding": {
                        "$ref": "#/components/schemas/ProtocolAttemptBinding"
                      },
                      "operation": {
                        "const": "part",
                        "type": "string"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "binding",
                      "artifact_key",
                      "operation",
                      "args"
                    ],
                    "type": "object"
                  },
                  {
                    "additionalProperties": false,
                    "properties": {
                      "args": {
                        "additionalProperties": false,
                        "properties": {
                          "bytes": {
                            "minimum": 0,
                            "type": "integer"
                          },
                          "etag": {
                            "type": "string"
                          },
                          "number": {
                            "maximum": 10000,
                            "minimum": 1,
                            "type": "integer"
                          },
                          "sha256": {
                            "pattern": "^[0-9a-f]{64}$",
                            "type": "string"
                          },
                          "upload_id": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "upload_id",
                          "number",
                          "bytes",
                          "sha256",
                          "etag"
                        ],
                        "type": "object"
                      },
                      "artifact_key": {
                        "type": "string"
                      },
                      "binding": {
                        "$ref": "#/components/schemas/ProtocolAttemptBinding"
                      },
                      "operation": {
                        "const": "part_ack",
                        "type": "string"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "binding",
                      "artifact_key",
                      "operation",
                      "args"
                    ],
                    "type": "object"
                  },
                  {
                    "additionalProperties": false,
                    "properties": {
                      "args": {
                        "additionalProperties": false,
                        "properties": {
                          "parts": {
                            "items": {
                              "additionalProperties": false,
                              "properties": {
                                "bytes": {
                                  "minimum": 0,
                                  "type": "integer"
                                },
                                "etag": {
                                  "type": "string"
                                },
                                "number": {
                                  "maximum": 10000,
                                  "minimum": 1,
                                  "type": "integer"
                                },
                                "sha256": {
                                  "pattern": "^[0-9a-f]{64}$",
                                  "type": "string"
                                }
                              },
                              "required": [
                                "number",
                                "bytes",
                                "sha256",
                                "etag"
                              ],
                              "type": "object"
                            },
                            "type": "array"
                          },
                          "upload_id": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "upload_id",
                          "parts"
                        ],
                        "type": "object"
                      },
                      "artifact_key": {
                        "type": "string"
                      },
                      "binding": {
                        "$ref": "#/components/schemas/ProtocolAttemptBinding"
                      },
                      "operation": {
                        "const": "complete",
                        "type": "string"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "binding",
                      "artifact_key",
                      "operation",
                      "args"
                    ],
                    "type": "object"
                  },
                  {
                    "additionalProperties": false,
                    "properties": {
                      "args": {
                        "additionalProperties": false,
                        "properties": {
                          "etag": {
                            "type": "string"
                          },
                          "version_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "etag",
                          "version_id"
                        ],
                        "type": "object"
                      },
                      "artifact_key": {
                        "type": "string"
                      },
                      "binding": {
                        "$ref": "#/components/schemas/ProtocolAttemptBinding"
                      },
                      "operation": {
                        "const": "head",
                        "type": "string"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "binding",
                      "artifact_key",
                      "operation",
                      "args"
                    ],
                    "type": "object"
                  },
                  {
                    "additionalProperties": false,
                    "properties": {
                      "args": {
                        "additionalProperties": false,
                        "properties": {
                          "abort_id": {
                            "type": "string"
                          },
                          "acceptance_id": {
                            "type": "string"
                          },
                          "reason": {
                            "const": "original_native_identity_lost",
                            "type": "string"
                          },
                          "receipt_sha256": {
                            "pattern": "^[0-9a-f]{64}$",
                            "type": "string"
                          }
                        },
                        "required": [
                          "abort_id",
                          "acceptance_id",
                          "receipt_sha256",
                          "reason"
                        ],
                        "type": "object"
                      },
                      "artifact_key": {
                        "const": "",
                        "type": "string"
                      },
                      "binding": {
                        "$ref": "#/components/schemas/ProtocolAttemptBinding"
                      },
                      "operation": {
                        "const": "compensate_pre_finalize",
                        "type": "string"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "binding",
                      "artifact_key",
                      "operation",
                      "args"
                    ],
                    "type": "object"
                  }
                ]
              }
            }
          },
          "description": "Exact attempt binding required; part sizes and sequence, object identities, signed authority lifetime and compensation custody are checked against the committed plan.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "schema": {
                          "const": 1,
                          "type": "integer"
                        },
                        "upload_id": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "schema",
                        "upload_id"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "acknowledged": {
                          "const": true,
                          "type": "boolean"
                        },
                        "schema": {
                          "const": 1,
                          "type": "integer"
                        }
                      },
                      "required": [
                        "schema",
                        "acknowledged"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "authority": {
                          "additionalProperties": false,
                          "properties": {
                            "expires_at": {
                              "type": "integer"
                            },
                            "headers": {
                              "additionalProperties": {
                                "type": "string"
                              },
                              "description": "Dynamic HTTP header names, each with a string value.",
                              "type": "object",
                              "x-open-schema-reason": "Dynamic HTTP header names, each with a string value."
                            },
                            "method": {
                              "const": "PUT",
                              "type": "string"
                            },
                            "url": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "method",
                            "url",
                            "headers",
                            "expires_at"
                          ],
                          "type": "object"
                        },
                        "schema": {
                          "const": 1,
                          "type": "integer"
                        }
                      },
                      "required": [
                        "schema",
                        "authority"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "object": {
                          "additionalProperties": false,
                          "properties": {
                            "bytes": {
                              "type": "integer"
                            },
                            "checksum_type": {
                              "enum": [
                                "",
                                "FULL_OBJECT",
                                "COMPOSITE"
                              ]
                            },
                            "etag": {
                              "type": "string"
                            },
                            "metadata": {
                              "oneOf": [
                                {
                                  "additionalProperties": false,
                                  "properties": {},
                                  "required": [],
                                  "type": "object"
                                },
                                {
                                  "additionalProperties": false,
                                  "properties": {
                                    "vnbui-artifact-id": {
                                      "type": "string"
                                    },
                                    "vnbui-backup-id": {
                                      "type": "string"
                                    },
                                    "vnbui-org-id": {
                                      "type": "string"
                                    },
                                    "vnbui-plan-sha256": {
                                      "type": "string"
                                    },
                                    "vnbui-protocol": {
                                      "type": "string"
                                    },
                                    "vnbui-reservation-id": {
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "vnbui-protocol",
                                    "vnbui-org-id",
                                    "vnbui-backup-id",
                                    "vnbui-reservation-id",
                                    "vnbui-plan-sha256",
                                    "vnbui-artifact-id"
                                  ],
                                  "type": "object"
                                }
                              ]
                            },
                            "sha256": {
                              "type": "string"
                            },
                            "version_id": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "required": [
                            "etag",
                            "version_id",
                            "bytes",
                            "sha256",
                            "checksum_type",
                            "metadata"
                          ],
                          "type": "object"
                        },
                        "schema": {
                          "const": 1,
                          "type": "integer"
                        }
                      },
                      "required": [
                        "schema",
                        "object"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "capacity_state": {
                          "const": "reserved",
                          "type": "string"
                        },
                        "cleanup_required": {
                          "const": true,
                          "type": "boolean"
                        },
                        "intent_id": {
                          "type": "string"
                        },
                        "s3_absent": {
                          "type": "boolean"
                        },
                        "schema": {
                          "const": 1,
                          "type": "integer"
                        }
                      },
                      "required": [
                        "schema",
                        "intent_id",
                        "s3_absent",
                        "cleanup_required",
                        "capacity_state"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:159"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:143"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:150"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Storage Control",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/storage-retirement": {
      "post": {
        "description": "Reveal only the exact reviewed release to its original agent.",
        "operationId": "storage_retirement_api_v1_agents_backups__backup_id__storage_retirement_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "attempt_id": {
                    "type": "string"
                  },
                  "journal_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "plan_sha256": {
                    "pattern": "^[0-9a-f]{64}$",
                    "type": "string"
                  },
                  "reservation_id": {
                    "type": "string"
                  }
                },
                "required": [
                  "reservation_id",
                  "attempt_id",
                  "plan_sha256",
                  "journal_sha256"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "attempt_id": {
                      "type": "string"
                    },
                    "backup_id": {
                      "type": "string"
                    },
                    "capacity_id": {
                      "type": "string"
                    },
                    "journal_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "operation_id": {
                      "type": "string"
                    },
                    "org_id": {
                      "type": "string"
                    },
                    "plan_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "release_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    },
                    "reservation_id": {
                      "type": "string"
                    },
                    "schema": {
                      "const": 1,
                      "type": "integer"
                    }
                  },
                  "required": [
                    "schema",
                    "org_id",
                    "backup_id",
                    "reservation_id",
                    "attempt_id",
                    "operation_id",
                    "capacity_id",
                    "plan_sha256",
                    "journal_sha256",
                    "release_sha256"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:91"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:79"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:84"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Storage Retirement",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/backups/{backup_id}/transaction-key": {
      "post": {
        "description": "Authenticated, no-store, memory-only key delivery for exact live custody.",
        "operationId": "transaction_key_api_v1_agents_backups__backup_id__transaction_key_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProtocolAttemptBinding"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "attempt_id": {
                          "type": "string"
                        },
                        "dek": {
                          "type": "null"
                        },
                        "format": {
                          "const": "none",
                          "type": "string"
                        },
                        "key_ref": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "plan_sha256": {
                          "pattern": "^[0-9a-f]{64}$",
                          "type": "string"
                        },
                        "reservation_id": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "reservation_id",
                        "attempt_id",
                        "plan_sha256",
                        "key_ref",
                        "format",
                        "dek"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "attempt_id": {
                          "type": "string"
                        },
                        "dek": {
                          "description": "Base64 encoded 32 byte attempt data key; memory-only, no-store delivery.",
                          "type": "string"
                        },
                        "format": {
                          "const": "vnbu1-aes256gcm-chunk5242880",
                          "type": "string"
                        },
                        "key_ref": {
                          "type": "string"
                        },
                        "plan_sha256": {
                          "pattern": "^[0-9a-f]{64}$",
                          "type": "string"
                        },
                        "reservation_id": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "reservation_id",
                        "attempt_id",
                        "key_ref",
                        "plan_sha256",
                        "format",
                        "dek"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:125"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/health.py:109"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/health.py:116"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Transaction Key",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/register": {
      "post": {
        "description": "Agent self-registration endpoint with secure key generation.\n\nRequires valid registration key from AgentRegistrationKey table.\nValidates key expiration, max uses, and enabled status.",
        "operationId": "register_agent_api_v1_agents_register_post",
        "parameters": [
          {
            "in": "header",
            "name": "X-API-Key",
            "required": false,
            "schema": {
              "title": "X-Api-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "capabilities": {
                    "additionalProperties": true,
                    "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                    "type": "object",
                    "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                  },
                  "display_name": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "hostname": {
                    "type": "string"
                  },
                  "ip_address": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "libvirt_uri": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "port": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "version": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "hostname"
                ],
                "type": "object"
              }
            }
          },
          "description": "Registration key must authorize hostname. Capabilities are provider metadata. Unknown fields are ignored; type validation is performed by existing handler/database behavior, not this document.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agent_id": {
                      "type": "string"
                    },
                    "api_key": {
                      "type": "string"
                    },
                    "env_snippet": {
                      "type": "string"
                    },
                    "heartbeat_interval": {
                      "type": "integer"
                    },
                    "hostname": {
                      "type": "string"
                    },
                    "key_prefix": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "orchestrator_api_key_required": {
                      "type": "boolean"
                    },
                    "orchestrator_url": {
                      "type": "string"
                    },
                    "tls": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "agent_cert": {
                              "type": "string"
                            },
                            "agent_key": {
                              "type": "string"
                            },
                            "ca_cert": {
                              "type": "string"
                            },
                            "expires_at": {
                              "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                              "type": "string"
                            },
                            "fingerprint": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "ca_cert",
                            "agent_cert",
                            "agent_key",
                            "fingerprint",
                            "expires_at"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "agent_id",
                    "hostname",
                    "api_key",
                    "key_prefix",
                    "orchestrator_url",
                    "env_snippet",
                    "message",
                    "orchestrator_api_key_required",
                    "heartbeat_interval",
                    "tls"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:92"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/agents.py:60",
              "backend/routers/agents.py:74",
              "backend/routers/agents.py:86",
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/agents.py:94",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:102",
              "backend/routers/agents.py:207"
            ]
          }
        },
        "security": [
          {
            "RegistrationKey": []
          }
        ],
        "summary": "Register Agent",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "agent-registration"
      }
    },
    "/api/v1/agents/{agent_id}": {
      "delete": {
        "description": "Delete agent (admin only).\n\nArgs:\n    agent_id: Agent ID to delete\n    cascade: If True, delete VMs only when they have no backup custody",
        "operationId": "delete_agent_api_v1_agents__agent_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "cascade",
            "required": false,
            "schema": {
              "default": false,
              "title": "Cascade",
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "deleted": {
                      "additionalProperties": false,
                      "properties": {
                        "backups": {
                          "type": "integer"
                        },
                        "certificates": {
                          "type": "integer"
                        },
                        "vms": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "vms",
                        "backups",
                        "certificates"
                      ],
                      "type": "object"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "deleted"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:698"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:691"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:709"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Agent",
        "tags": [
          "agents"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      },
      "get": {
        "description": "Get agent details by ID",
        "operationId": "get_agent_details_api_v1_agents__agent_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "api_key": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "enabled": {
                              "type": "boolean"
                            },
                            "expires_at": {
                              "anyOf": [
                                {
                                  "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "is_valid": {
                              "type": "boolean"
                            },
                            "key_prefix": {
                              "type": "string"
                            },
                            "last_used_at": {
                              "anyOf": [
                                {
                                  "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "required": [
                            "key_prefix",
                            "expires_at",
                            "enabled",
                            "is_valid",
                            "last_used_at"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "capabilities": {
                      "additionalProperties": true,
                      "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                      "type": "object",
                      "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                    },
                    "config": {
                      "additionalProperties": true,
                      "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                      "type": "object",
                      "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "display_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "hostname": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "ip_address": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "last_heartbeat": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "metrics": {
                      "additionalProperties": true,
                      "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                      "type": "object",
                      "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                    },
                    "platform": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "port": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "version": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_count": {
                      "type": "integer"
                    },
                    "vms": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "absent_since": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "disks": {
                            "items": {
                              "additionalProperties": true,
                              "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                              "type": "object",
                              "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                            },
                            "type": "array"
                          },
                          "id": {
                            "type": "string"
                          },
                          "inventory_present": {
                            "type": "boolean"
                          },
                          "last_observed_at": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "memory_kb": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "metadata": {
                            "additionalProperties": true,
                            "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                            "type": "object",
                            "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                          },
                          "name": {
                            "type": "string"
                          },
                          "namespace": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "provider": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "replaces_vm_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "state": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "uuid": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vcpu_count": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_uid": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vmi_uid": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "state",
                          "uuid",
                          "memory_kb",
                          "vcpu_count",
                          "disks",
                          "metadata",
                          "provider",
                          "namespace",
                          "vm_uid",
                          "vmi_uid",
                          "replaces_vm_id",
                          "inventory_present",
                          "last_observed_at",
                          "absent_since"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "id",
                    "hostname",
                    "status",
                    "display_name",
                    "ip_address",
                    "version",
                    "platform",
                    "port",
                    "last_heartbeat",
                    "created_at",
                    "vm_count",
                    "vms",
                    "capabilities",
                    "metrics",
                    "config",
                    "api_key"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:511"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Agent Details",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "user-session"
      },
      "patch": {
        "description": "Update agent settings (admin only)",
        "operationId": "update_agent_api_v1_agents__agent_id__patch",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AgentUpdateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "display_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "hostname": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "hostname",
                    "status",
                    "message",
                    "display_name"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:568"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Agent",
        "tags": [
          "agents"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/agents/{agent_id}/key-rotations": {
      "get": {
        "operationId": "list_agent_key_rotations_api_v1_agents__agent_id__key_rotations_get",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "activated_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "agent_id": {
                            "type": "string"
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "expires_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "key_prefix": {
                            "type": "string"
                          },
                          "rotation_id": {
                            "type": "string"
                          },
                          "state": {
                            "enum": [
                              "pending",
                              "activated",
                              "cancelled",
                              "expired"
                            ],
                            "type": "string"
                          }
                        },
                        "required": [
                          "rotation_id",
                          "agent_id",
                          "state",
                          "key_prefix",
                          "created_at",
                          "expires_at",
                          "activated_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:419",
              "backend/core/agent_key_rotation.py:426"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key."
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Agent Key Rotations",
        "tags": [
          "agents"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/agents/{agent_id}/key-rotations/{rotation_id}": {
      "delete": {
        "operationId": "cancel_agent_key_rotation_api_v1_agents__agent_id__key_rotations__rotation_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "rotation_id",
            "required": true,
            "schema": {
              "title": "Rotation Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "activated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "agent_id": {
                      "type": "string"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "key_prefix": {
                      "type": "string"
                    },
                    "rotation_id": {
                      "type": "string"
                    },
                    "state": {
                      "enum": [
                        "pending",
                        "activated",
                        "cancelled",
                        "expired"
                      ],
                      "type": "string"
                    }
                  },
                  "required": [
                    "rotation_id",
                    "agent_id",
                    "state",
                    "key_prefix",
                    "created_at",
                    "expires_at",
                    "activated_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_authority_revoked",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:89",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:270",
              "backend/core/agent_key_rotation.py:281"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_not_pending",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:446"
            ]
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Cancel Agent Key Rotation",
        "tags": [
          "agents"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      },
      "get": {
        "operationId": "get_agent_key_rotation_api_v1_agents__agent_id__key_rotations__rotation_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "rotation_id",
            "required": true,
            "schema": {
              "title": "Rotation Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "activated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "agent_id": {
                      "type": "string"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "key_prefix": {
                      "type": "string"
                    },
                    "rotation_id": {
                      "type": "string"
                    },
                    "state": {
                      "enum": [
                        "pending",
                        "activated",
                        "cancelled",
                        "expired"
                      ],
                      "type": "string"
                    }
                  },
                  "required": [
                    "rotation_id",
                    "agent_id",
                    "state",
                    "key_prefix",
                    "created_at",
                    "expires_at",
                    "activated_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:419",
              "backend/core/agent_key_rotation.py:426"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key."
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Agent Key Rotation",
        "tags": [
          "agents"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/agents/{agent_id}/key-rotations/{rotation_id}/activate": {
      "post": {
        "description": "Candidate proof is limited to this exact rotation; no user Bearer substitute.",
        "operationId": "activate_agent_key_api_v1_agents__agent_id__key_rotations__rotation_id__activate_post",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "rotation_id",
            "required": true,
            "schema": {
              "title": "Rotation Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "X-Agent-Key"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "activated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "agent_id": {
                      "type": "string"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "key_prefix": {
                      "type": "string"
                    },
                    "rotation_id": {
                      "type": "string"
                    },
                    "state": {
                      "enum": [
                        "pending",
                        "activated",
                        "cancelled",
                        "expired"
                      ],
                      "type": "string"
                    }
                  },
                  "required": [
                    "rotation_id",
                    "agent_id",
                    "state",
                    "key_prefix",
                    "created_at",
                    "expires_at",
                    "activated_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_candidate_invalid",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "verified_certificate_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_candidate_certificate_invalid",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:188",
              "backend/core/agent_key_rotation.py:215",
              "backend/core/agent_key_rotation.py:312",
              "backend/core/agent_key_rotation.py:197",
              "backend/core/agent_key_rotation.py:322",
              "backend/core/agent_key_rotation.py:244",
              "backend/core/agent_key_rotation.py:338",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_candidate_superseded",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_authority_revoked",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:230",
              "backend/core/agent_key_rotation.py:89",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_not_found",
                              "type": "string"
                            }
                          },
                          "required": [
                            "code"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:304",
              "backend/core/agent_key_rotation.py:270",
              "backend/core/agent_key_rotation.py:281"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_not_pending",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_predecessor_changed",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_candidate_superseded",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:357",
              "backend/core/agent_key_rotation.py:375",
              "backend/core/agent_key_rotation.py:348"
            ]
          },
          "410": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_candidate_expired",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:367"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Candidate or current administrator authority, lifecycle state or validated input unavailable. A refused candidate does not replace the active key.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "AgentCandidate": [],
            "AgentMTLS": []
          }
        ],
        "summary": "Activate Agent Key",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "agent-candidate-activation-only",
        "x-transport-policy": "Candidate proof is bound to this agent and rotation; it grants no ordinary agent authority. When mTLS is required, a current certificate for the same agent is required in addition to the candidate."
      }
    },
    "/api/v1/agents/{agent_id}/pending-jobs": {
      "get": {
        "description": "Get backup jobs orchestrator believes are running on this agent.\n\nUsed by agent on startup to reconcile state - determine which backups\nthe orchestrator thinks are running so agent can verify reality.\n\nReturns:\n    dict: backups list with id, vm_name, storage_path, started_at",
        "operationId": "get_agent_pending_jobs_api_v1_agents__agent_id__pending_jobs_get",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backups": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "started_at": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "storage_path": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "vm_name",
                          "storage_path",
                          "started_at",
                          "status"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "backups"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/health.py:1065",
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Get Agent Pending Jobs",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/agents/{agent_id}/rotate-key": {
      "post": {
        "description": "Stage a one-time candidate; the current agent key remains active until proof.",
        "operationId": "rotate_agent_key_api_v1_agents__agent_id__rotate_key_post",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          },
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "discriminator": {
                    "propertyName": "secret_delivery"
                  },
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "activated_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "agent_id": {
                          "type": "string"
                        },
                        "api_key": {
                          "description": "First response only. Permanently absent from replay and outcome lookup.",
                          "type": "string",
                          "writeOnly": true
                        },
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "expires_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "key_prefix": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "rotation_id": {
                          "type": "string"
                        },
                        "secret_delivery": {
                          "const": "one_time",
                          "type": "string"
                        },
                        "state": {
                          "enum": [
                            "pending",
                            "activated",
                            "cancelled",
                            "expired"
                          ],
                          "type": "string"
                        }
                      },
                      "required": [
                        "rotation_id",
                        "agent_id",
                        "state",
                        "key_prefix",
                        "created_at",
                        "expires_at",
                        "activated_at",
                        "request_id",
                        "secret_delivery",
                        "api_key"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "activated_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "agent_id": {
                          "type": "string"
                        },
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "expires_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "key_prefix": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "rotation_id": {
                          "type": "string"
                        },
                        "secret_delivery": {
                          "const": "unavailable",
                          "type": "string"
                        },
                        "state": {
                          "enum": [
                            "pending",
                            "activated",
                            "cancelled",
                            "expired"
                          ],
                          "type": "string"
                        }
                      },
                      "required": [
                        "rotation_id",
                        "agent_id",
                        "state",
                        "key_prefix",
                        "created_at",
                        "expires_at",
                        "activated_at",
                        "request_id",
                        "secret_delivery"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Invalid domain request."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_authority_revoked",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:89",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_not_found",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authorized resource unavailable.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:113"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_predecessor_missing",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_pending",
                              "type": "string"
                            },
                            "rotation_id": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "rotation_id"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract.",
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:117",
              "backend/core/agent_key_rotation.py:133"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit."
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "agent_rotation_configuration",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "backend/core/agent_key_rotation.py:38",
              "backend/core/agent_key_rotation.py:30",
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Rotate Agent Key",
        "tags": [
          "agents"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-operator-action": "credential.agent.rotate"
      }
    },
    "/api/v1/agents/{agent_id}/settings": {
      "patch": {
        "description": "Update agent runtime settings (admin only).\n\nSettings are delivered to agent via heartbeat response and applied\nunless overridden by local agent.env configuration.\n\nPre-condition: No active backups on agent (returns 409 if busy).",
        "operationId": "update_agent_settings_api_v1_agents__agent_id__settings_patch",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AgentSettingsUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "config": {
                      "additionalProperties": true,
                      "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                      "type": "object",
                      "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                    },
                    "hostname": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "hostname",
                    "message",
                    "config"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:615"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:635"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "core/vm_inventory.py:49 sync_inventory; core/agent_scope.py:21 namespace_list/validate_settings"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Agent Settings",
        "tags": [
          "agents"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/agents/{hostname}/vms": {
      "post": {
        "description": "Sync VMs from agent - requires agent API key authentication.",
        "operationId": "sync_agent_vms_api_v1_agents__hostname__vms_post",
        "parameters": [
          {
            "in": "path",
            "name": "hostname",
            "required": true,
            "schema": {
              "title": "Hostname",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "complete": {
                    "default": false,
                    "type": "boolean"
                  },
                  "source_namespaces": {
                    "items": {
                      "type": "string"
                    },
                    "type": "array"
                  },
                  "vms": {
                    "items": {
                      "additionalProperties": true,
                      "properties": {
                        "disks": {
                          "items": {
                            "additionalProperties": true,
                            "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                            "type": "object",
                            "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                          },
                          "type": "array"
                        },
                        "memory_kb": {
                          "anyOf": [
                            {
                              "type": "integer"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "metadata": {
                          "additionalProperties": true,
                          "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                          "type": "object",
                          "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                        },
                        "name": {
                          "type": "string"
                        },
                        "namespace": {
                          "type": "string"
                        },
                        "provider": {
                          "type": "string"
                        },
                        "state": {
                          "type": "string"
                        },
                        "uuid": {
                          "type": "string"
                        },
                        "vcpu_count": {
                          "anyOf": [
                            {
                              "type": "integer"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "vm_uid": {
                          "type": "string"
                        },
                        "vmi_uid": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object"
                    },
                    "type": "array"
                  }
                },
                "required": [
                  "vms"
                ],
                "type": "object"
              }
            }
          },
          "description": "Stable vm_uid (or libvirt uuid) required directly on each entry. Provider and namespace may fall back to entry metadata. KubeVirt requires namespace. Scope ceilings and complete inventory semantics are checked by sync_inventory.",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agent_hostname": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "synced": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "synced",
                    "agent_hostname",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/agents.py:260",
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "core/vm_inventory.py:49 sync_inventory; core/agent_scope.py:21 namespace_list/validate_settings"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Sync Agent Vms",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/auth/login": {
      "post": {
        "description": "Login endpoint - returns JWT token",
        "operationId": "login_api_v1_auth_login_post",
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "$ref": "#/components/schemas/Body_login_api_v1_auth_login_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "access_token": {
                      "type": "string"
                    },
                    "token_type": {
                      "const": "bearer",
                      "type": "string"
                    },
                    "user": {
                      "additionalProperties": false,
                      "properties": {
                        "org_id": {
                          "type": "string"
                        },
                        "role": {
                          "type": "string"
                        },
                        "username": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "username",
                        "role",
                        "org_id"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "access_token",
                    "token_type",
                    "user"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/auth.py:101",
              "backend/routers/auth.py:99",
              "backend/routers/auth.py:120",
              "backend/routers/auth.py:128",
              "backend/routers/auth.py:117",
              "backend/core/tenant_context.py:184 tenant_middleware",
              "backend/routers/auth.py:AuthRoute.get_route_handler"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Login",
        "tags": [
          "auth"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/auth/logout": {
      "post": {
        "description": "Logout endpoint. JWT is stateless so this is a no-op server-side;\nthe client clears its token.",
        "operationId": "logout_api_v1_auth_logout_post",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Logout",
        "tags": [
          "auth"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/auth/me": {
      "get": {
        "description": "Persisted profile only. Optional display fields are explicit JSON nulls.",
        "operationId": "get_current_user_info_api_v1_auth_me_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "auth_source": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "can_manage_installation": {
                      "type": "boolean"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "email": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "full_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "is_active": {
                      "type": "boolean"
                    },
                    "is_platform_admin": {
                      "type": "boolean"
                    },
                    "last_login": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "oidc_issuer": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "org_id": {
                      "type": "string"
                    },
                    "role": {
                      "type": "string"
                    },
                    "role_source": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "username": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "username",
                    "role",
                    "org_id",
                    "auth_source",
                    "role_source",
                    "full_name",
                    "email",
                    "oidc_issuer",
                    "is_platform_admin",
                    "can_manage_installation",
                    "is_active",
                    "last_login",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Current User Info",
        "tags": [
          "auth"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/auth/oidc/callback": {
      "get": {
        "description": "Handle OIDC callback after authentication.\n\nExchanges code for tokens, creates/updates user, returns JWT.\nRedirects to frontend with token in URL fragment.",
        "operationId": "oidc_callback_api_v1_auth_oidc_callback_get",
        "parameters": [
          {
            "in": "query",
            "name": "code",
            "required": false,
            "schema": {
              "title": "Code",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "state",
            "required": false,
            "schema": {
              "title": "State",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "error",
            "required": false,
            "schema": {
              "title": "Error",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "error_description",
            "required": false,
            "schema": {
              "title": "Error Description",
              "type": "string"
            }
          }
        ],
        "responses": {
          "302": {
            "description": "Redirect to frontend with access token in URL fragment",
            "headers": {
              "Location": {
                "schema": {
                  "type": "string"
                }
              },
              "Set-Cookie": {
                "description": "Login sets oidc_state and oidc_pkce cookies; callback deletes both cookies on success and failure.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-no-response-body": true
          },
          "400": {
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "description": "Provider rejection, exchange failure, invalid local state/code/PKCE and request validation failure use HTML; browser custody cookies are deleted.",
            "headers": {
              "Set-Cookie": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-sources": [
              "backend/routers/auth.py:250",
              "backend/routers/auth.py:278",
              "backend/routers/auth.py:517",
              "backend/routers/auth.py:523",
              "backend/routers/auth.py:529",
              "backend/routers/auth.py:535",
              "backend/routers/auth.py:AuthRoute.get_route_handler"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Callback or user provisioning transaction failed; browser custody cookies are deleted",
            "headers": {
              "Set-Cookie": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)",
              "backend/routers/auth.py:AuthRoute.get_route_handler"
            ]
          },
          "503": {
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "description": "OIDC organization binding unavailable; browser custody cookies are deleted",
            "headers": {
              "Set-Cookie": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-sources": [
              "backend/routers/auth.py:271",
              "backend/routers/auth.py:262",
              "backend/routers/auth.py:AuthRoute.get_route_handler"
            ]
          }
        },
        "security": [
          {
            "OIDCPKCE": [],
            "OIDCState": []
          }
        ],
        "summary": "Oidc Callback",
        "tags": [
          "auth"
        ],
        "x-credential-domain": "browser-oidc-callback",
        "x-transport-policy": "State query and browser state cookie must match; PKCE cookie and provider response are verified. This is not user Bearer authentication."
      }
    },
    "/api/v1/auth/oidc/login": {
      "get": {
        "description": "Initiate OIDC login flow.\n\nRedirects user to OIDC provider. Frontend should redirect to this URL\nor fetch it and redirect client-side.\n\nReturns:\n    302 redirect to OIDC provider, or 400 if OIDC not configured",
        "operationId": "oidc_login_api_v1_auth_oidc_login_get",
        "responses": {
          "302": {
            "description": "Redirect to issuer authorization URL",
            "headers": {
              "Location": {
                "schema": {
                  "type": "string"
                }
              },
              "Set-Cookie": {
                "description": "Login sets oidc_state and oidc_pkce cookies; callback deletes both cookies on success and failure.",
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-no-response-body": true
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/auth.py:250",
              "backend/routers/auth.py:278",
              "backend/routers/auth.py:429"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "backend/routers/auth.py:462",
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/auth.py:271",
              "backend/routers/auth.py:262"
            ]
          }
        },
        "summary": "Oidc Login",
        "tags": [
          "auth"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/auth/oidc/status": {
      "get": {
        "description": "Check if OIDC is enabled and configured.\n\nPublic endpoint - no auth required.\nFrontend uses this to show/hide SSO login button.",
        "operationId": "get_oidc_status_api_v1_auth_oidc_status_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "enabled": {
                      "type": "boolean"
                    },
                    "issuer": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "enabled",
                    "issuer"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/auth.py:250",
              "backend/routers/auth.py:278"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/auth.py:271",
              "backend/routers/auth.py:262"
            ]
          }
        },
        "summary": "Get Oidc Status",
        "tags": [
          "auth"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/auth/oidc/test": {
      "post": {
        "description": "Test OIDC configuration by fetching discovery document.\n\nRequires persisted installation authority. Tests that the issuer URL is accessible\nand returns valid OIDC discovery metadata.",
        "operationId": "test_oidc_configuration_api_v1_auth_oidc_test_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "client_id": {
                    "default": "",
                    "type": "string"
                  },
                  "issuer": {
                    "type": "string"
                  }
                },
                "required": [
                  "issuer"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "authorization_endpoint": {
                      "type": "string"
                    },
                    "check": {
                      "const": "discovery_only",
                      "type": "string"
                    },
                    "credentials_verified": {
                      "const": false,
                      "type": "boolean"
                    },
                    "issuer": {
                      "type": "string"
                    },
                    "jwks_uri": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "const": "ok",
                      "type": "string"
                    },
                    "token_endpoint": {
                      "type": "string"
                    },
                    "userinfo_endpoint": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "status",
                    "check",
                    "credentials_verified",
                    "issuer",
                    "authorization_endpoint",
                    "token_endpoint",
                    "userinfo_endpoint",
                    "jwks_uri"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/auth.py:331",
              "backend/routers/auth.py:358",
              "backend/routers/auth.py:375",
              "backend/routers/auth.py:382",
              "backend/routers/auth.py:405",
              "backend/routers/auth.py:407",
              "backend/routers/auth.py:327",
              "backend/routers/auth.py:335",
              "backend/routers/auth.py:366",
              "backend/routers/auth.py:389"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "backend/routers/auth.py:412",
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Test Oidc Configuration",
        "tags": [
          "auth"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/auth/refresh": {
      "post": {
        "description": "Refresh access token. Issues a new JWT for the current user.",
        "operationId": "refresh_token_api_v1_auth_refresh_post",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "access_token": {
                      "type": "string"
                    },
                    "token_type": {
                      "const": "bearer",
                      "type": "string"
                    }
                  },
                  "required": [
                    "access_token",
                    "token_type"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Refresh Token",
        "tags": [
          "auth"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/backups": {
      "get": {
        "description": "List backups with pagination and optional filters.\n\n- skip: Number of records to skip (default: 0)\n- limit: Maximum number of records to return (default: 50, max: 100)\n- vm_id: Filter by specific VM\n- status: Filter by status (pending, running, completed, failed)\n- search: Search by VM name (partial match, case-insensitive)\n- date_from: Filter backups created after this date (ISO format: 2025-01-01)\n- date_to: Filter backups created before this date (ISO format: 2025-12-31)\n- tag_key: Filter by tag key (requires tag_value)\n- tag_value: Filter by tag value (requires tag_key)",
        "operationId": "list_backups_api_v1_backups_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "description": "Clamped to 100 per page",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "description": "Clamped to 100 per page",
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "vm_id",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vm Id"
            }
          },
          {
            "in": "query",
            "name": "status",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Status"
            }
          },
          {
            "in": "query",
            "name": "search",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Search"
            }
          },
          {
            "in": "query",
            "name": "date_from",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Date From"
            }
          },
          {
            "in": "query",
            "name": "date_to",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Date To"
            }
          },
          {
            "in": "query",
            "name": "tag_key",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Tag Key"
            }
          },
          {
            "in": "query",
            "name": "tag_value",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Tag Value"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "has_more": {
                      "type": "boolean"
                    },
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "backup_type": {
                            "type": "string"
                          },
                          "capacity_state": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "completed_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "operator_dispatch": {
                            "anyOf": [
                              {
                                "additionalProperties": false,
                                "properties": {
                                  "reason": {
                                    "anyOf": [
                                      {
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "request_id": {
                                    "format": "uuid",
                                    "type": "string"
                                  },
                                  "state": {
                                    "enum": [
                                      "pending",
                                      "dispatching",
                                      "delivered",
                                      "held"
                                    ],
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "state",
                                  "reason",
                                  "request_id"
                                ],
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "progress": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "retention_days": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "safety_diagnostic": {
                            "anyOf": [
                              {
                                "$ref": "#/components/schemas/StorageSafetyDiagnostic"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "size_bytes": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "storage_path": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "storage_progress": {
                            "anyOf": [
                              {
                                "additionalProperties": false,
                                "properties": {
                                  "bytes_transferred": {
                                    "maximum": 9223372036854775807,
                                    "minimum": 0,
                                    "type": "integer"
                                  },
                                  "phase": {
                                    "enum": [
                                      "pending",
                                      "preparing",
                                      "uploading",
                                      "finalizing"
                                    ],
                                    "type": "string"
                                  },
                                  "plan_sha256": {
                                    "type": "string"
                                  },
                                  "reservation_id": {
                                    "type": "string"
                                  },
                                  "schema": {
                                    "const": 1,
                                    "type": "integer"
                                  },
                                  "total_bytes": {
                                    "maximum": 9223372036854775807,
                                    "minimum": 0,
                                    "type": "integer"
                                  },
                                  "updated_at": {
                                    "format": "date-time",
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "schema",
                                  "reservation_id",
                                  "plan_sha256",
                                  "phase",
                                  "bytes_transferred",
                                  "total_bytes",
                                  "updated_at"
                                ],
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "tags": {
                            "additionalProperties": true,
                            "description": "Extensible domain metadata; keys are not a closed schema.",
                            "type": "object",
                            "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                          },
                          "vm_id": {
                            "type": "string"
                          },
                          "vm_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "vm_id",
                          "vm_name",
                          "status",
                          "progress",
                          "safety_diagnostic",
                          "storage_progress",
                          "size_bytes",
                          "retention_days",
                          "backup_type",
                          "capacity_state",
                          "storage_path",
                          "tags",
                          "created_at",
                          "completed_at",
                          "operator_dispatch"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit",
                    "has_more"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/backups.py:329",
              "backend/routers/backups.py:307",
              "backend/routers/backups.py:319"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Backups",
        "tags": [
          "backups"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending, id descending",
          "pagination": "offset",
          "snapshot": false
        }
      },
      "post": {
        "description": "Create a new backup job for a VM (operator or admin only).\nTriggers async backup execution.",
        "operationId": "create_backup_api_v1_backups_post",
        "parameters": [
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BackupCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "discriminator": {
                    "propertyName": "status"
                  },
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "executor": {
                          "enum": [
                            "real",
                            "mock"
                          ],
                          "type": "string"
                        },
                        "id": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "status": {
                          "const": "pending",
                          "type": "string"
                        },
                        "vm_id": {
                          "type": "string"
                        },
                        "vm_name": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "vm_id",
                        "vm_name",
                        "status",
                        "message",
                        "executor",
                        "request_id"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "message": {
                          "type": "string"
                        },
                        "queue_id": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "status": {
                          "const": "queued",
                          "type": "string"
                        },
                        "vm_id": {
                          "type": "string"
                        },
                        "vm_name": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "status",
                        "queue_id",
                        "vm_id",
                        "vm_name",
                        "message",
                        "request_id"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Invalid domain request."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authorized resource unavailable.",
            "x-error-sources": [
              "core/backup_service.py:115 can_start_backup -> BackupCreateResult.error_code -> routers/backups.py:163"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract.",
            "x-error-sources": [
              "core/backup_service.py:115 can_start_backup -> BackupCreateResult.error_code -> routers/backups.py:163"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit.",
            "x-error-sources": [
              "core/backup_service.py:115 can_start_backup -> BackupCreateResult.error_code -> routers/backups.py:163"
            ]
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Admission dependency unavailable.",
            "x-error-sources": [
              "core/backup_service.py:115 can_start_backup -> BackupCreateResult.error_code -> routers/backups.py:163"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Backup",
        "tags": [
          "backups"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-operator-action": "backup.create"
      }
    },
    "/api/v1/backups/bulk-create": {
      "post": {
        "description": "Atomically freeze targets, per-target outcomes and original dispatches.",
        "operationId": "bulk_create_backups_api_v1_backups_bulk_create_post",
        "parameters": [
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkBackupCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "details": {
                      "additionalProperties": false,
                      "properties": {
                        "created": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_id": {
                                "type": "string"
                              },
                              "vm_id": {
                                "type": "string"
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "backup_id",
                              "vm_id",
                              "vm_name"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "failed": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "reason": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "vm_id": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "vm_id",
                              "reason"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "skipped": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "reason": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "vm_id": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "vm_id",
                              "reason"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "created",
                        "skipped",
                        "failed"
                      ],
                      "type": "object"
                    },
                    "request_id": {
                      "format": "uuid",
                      "type": "string"
                    },
                    "summary": {
                      "additionalProperties": false,
                      "properties": {
                        "created": {
                          "minimum": 0,
                          "type": "integer"
                        },
                        "failed": {
                          "minimum": 0,
                          "type": "integer"
                        },
                        "skipped": {
                          "minimum": 0,
                          "type": "integer"
                        },
                        "total": {
                          "minimum": 0,
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "created",
                        "skipped",
                        "failed"
                      ],
                      "type": "object"
                    },
                    "targets": {
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 200,
                      "minItems": 1,
                      "type": "array",
                      "uniqueItems": true
                    }
                  },
                  "required": [
                    "targets",
                    "summary",
                    "details",
                    "request_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Invalid domain request.",
            "x-error-sources": [
              "backend/routers/bulk.py:78"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Authorized resource unavailable."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract."
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "bulk_admission_limit",
                              "type": "string"
                            },
                            "max_targets": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "code",
                            "max_targets"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit.",
            "x-error-sources": [
              "backend/routers/bulk.py:80"
            ]
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Bulk Create Backups",
        "tags": [
          "bulk"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-operator-action": "backup.bulk_create"
      }
    },
    "/api/v1/backups/bulk-delete": {
      "post": {
        "description": "Delete multiple backups at once (operator or admin only)",
        "operationId": "bulk_delete_backups_api_v1_backups_bulk_delete_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkBackupDelete"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "details": {
                      "additionalProperties": false,
                      "properties": {
                        "deleted": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_id": {
                                "type": "string"
                              },
                              "deleted_bytes": {
                                "type": "integer"
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "backup_id",
                              "vm_name",
                              "deleted_bytes"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "failed": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_id": {
                                "type": "string"
                              },
                              "reason": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "backup_id",
                              "reason"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "skipped": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_id": {
                                "type": "string"
                              },
                              "reason": {
                                "type": "string"
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "backup_id",
                              "vm_name",
                              "reason"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "deleted",
                        "skipped",
                        "failed"
                      ],
                      "type": "object"
                    },
                    "summary": {
                      "additionalProperties": false,
                      "properties": {
                        "deleted": {
                          "type": "integer"
                        },
                        "failed": {
                          "type": "integer"
                        },
                        "skipped": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "deleted",
                        "skipped",
                        "failed"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "summary",
                    "details"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/bulk.py:145"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Bulk Delete Backups",
        "tags": [
          "bulk"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/bulk.py:bulk_delete_backups"
      }
    },
    "/api/v1/backups/bulk-tag": {
      "post": {
        "description": "Add or update tags on multiple backups at once (operator or admin only)",
        "operationId": "bulk_tag_backups_api_v1_backups_bulk_tag_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkBackupTag"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "details": {
                      "additionalProperties": false,
                      "properties": {
                        "failed": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_id": {
                                "type": "string"
                              },
                              "reason": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "backup_id",
                              "reason"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "updated": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_id": {
                                "type": "string"
                              },
                              "new_tags": {
                                "additionalProperties": true,
                                "description": "Extensible domain metadata; keys are not a closed schema.",
                                "type": "object",
                                "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                              },
                              "old_tags": {
                                "additionalProperties": true,
                                "description": "Extensible domain metadata; keys are not a closed schema.",
                                "type": "object",
                                "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "backup_id",
                              "vm_name",
                              "old_tags",
                              "new_tags"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "updated",
                        "failed"
                      ],
                      "type": "object"
                    },
                    "summary": {
                      "additionalProperties": false,
                      "properties": {
                        "failed": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "integer"
                        },
                        "updated": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "updated",
                        "failed"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "summary",
                    "details"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/bulk.py:241",
              "backend/routers/bulk.py:247"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Bulk Tag Backups",
        "tags": [
          "bulk"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/bulk.py:bulk_tag_backups"
      }
    },
    "/api/v1/backups/cleanup": {
      "post": {
        "description": "Clean up expired backups based on retention policies (admin only).\n\n- dry_run: If True, return what would be deleted without actually deleting\n\nUses RetentionPolicyEnforcer which:\n- Deletes from storage (S3 or filesystem)\n- Retains accepted-generation catalog tombstones and original custody\n- Logs all deletions",
        "operationId": "cleanup_expired_backups_api_v1_backups_cleanup_post",
        "parameters": [
          {
            "in": "query",
            "name": "dry_run",
            "required": false,
            "schema": {
              "default": false,
              "title": "Dry Run",
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "deleted_bytes": {
                      "type": "integer"
                    },
                    "deleted_count": {
                      "type": "integer"
                    },
                    "deleted_gb": {
                      "type": "number"
                    },
                    "dry_run": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "deleted_count",
                    "deleted_bytes",
                    "deleted_gb",
                    "dry_run"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Cleanup Expired Backups",
        "tags": [
          "backups"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/backups.py:cleanup_expired_backups"
      }
    },
    "/api/v1/backups/queue": {
      "get": {
        "description": "Get the current backup queue status.",
        "operationId": "get_backup_queue_api_v1_backups_queue_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "available_slots": {
                      "type": "integer"
                    },
                    "max_concurrent": {
                      "type": "integer"
                    },
                    "processing": {
                      "type": "integer"
                    },
                    "queue": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "hold_reason": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "position": {
                            "type": "integer"
                          },
                          "priority": {
                            "type": "integer"
                          },
                          "queued_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "schedule_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "started_backup_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "vm_id": {
                            "type": "string"
                          },
                          "vm_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "vm_id",
                          "vm_name",
                          "priority",
                          "position",
                          "queued_at",
                          "schedule_id",
                          "created_by",
                          "status",
                          "hold_reason",
                          "started_backup_id"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "running_backups": {
                      "type": "integer"
                    },
                    "total_queued": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "queue",
                    "total_queued",
                    "processing",
                    "running_backups",
                    "max_concurrent",
                    "available_slots"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Backup Queue",
        "tags": [
          "queue"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "priority descending, queued_at ascending, id ascending",
          "pagination": "unpaginated queued state only",
          "snapshot": false
        }
      },
      "post": {
        "description": "Add a backup to the queue instead of starting immediately.",
        "operationId": "add_backup_to_queue_api_v1_backups_queue_post",
        "parameters": [
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BackupQueueCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "hold_reason": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "position": {
                      "type": "integer"
                    },
                    "priority": {
                      "type": "integer"
                    },
                    "queued_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "request_id": {
                      "format": "uuid",
                      "type": "string"
                    },
                    "started_backup_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "vm_id": {
                      "type": "string"
                    },
                    "vm_name": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "vm_id",
                    "vm_name",
                    "position",
                    "priority",
                    "queued_at",
                    "status",
                    "hold_reason",
                    "started_backup_id",
                    "message",
                    "request_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Invalid domain request."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authorized resource unavailable.",
            "x-error-sources": [
              "backend/routers/queue.py:94"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract.",
            "x-error-sources": [
              "backend/routers/queue.py:105",
              "backend/routers/queue.py:117"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit."
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Add Backup To Queue",
        "tags": [
          "queue"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-operator-action": "queue.create"
      }
    },
    "/api/v1/backups/queue/{queue_id}": {
      "delete": {
        "description": "Cancel a queued backup.",
        "operationId": "cancel_queued_backup_api_v1_backups_queue__queue_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "queue_id",
            "required": true,
            "schema": {
              "title": "Queue Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/queue.py:209"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/queue.py:204"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Cancel Queued Backup",
        "tags": [
          "queue"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/queue.py:cancel_queued_backup"
      },
      "get": {
        "description": "A durable queue identity remains readable after it leaves the active list.",
        "operationId": "get_backup_queue_item_api_v1_backups_queue__queue_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "queue_id",
            "required": true,
            "schema": {
              "title": "Queue Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_status": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "hold_reason": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "position": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "priority": {
                      "type": "integer"
                    },
                    "queued_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "started_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "started_backup_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "vm_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "vm_id",
                    "status",
                    "hold_reason",
                    "started_backup_id",
                    "backup_status",
                    "position",
                    "priority",
                    "queued_at",
                    "started_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Authorized current state; the immutable receipt remains separate from current dispatch/resource state."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "x-error-sources": [
              "backend/routers/queue.py:176"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Backup Queue Item",
        "tags": [
          "queue"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/backups/{backup_id}": {
      "delete": {
        "description": "Delete exact owned payload, retaining its attributable tombstone.",
        "operationId": "delete_backup_api_v1_backups__backup_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "force",
            "required": false,
            "schema": {
              "default": false,
              "title": "Force",
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "deleted_bytes": {
                      "type": "integer"
                    },
                    "deleted_id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "deleted_id",
                    "deleted_bytes"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/backups.py:437"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/backups.py:441",
              "backend/routers/backups.py:446",
              "backend/routers/backups.py:462"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "502": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/backups.py:464"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Backup",
        "tags": [
          "backups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/backups.py:delete_backup"
      },
      "get": {
        "description": "Get backup status and details.",
        "operationId": "get_backup_api_v1_backups__backup_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_type": {
                      "type": "string"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "operator_dispatch": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "reason": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "state": {
                              "enum": [
                                "pending",
                                "dispatching",
                                "delivered",
                                "held"
                              ],
                              "type": "string"
                            }
                          },
                          "required": [
                            "state",
                            "reason",
                            "request_id"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "progress": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "retention_days": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "safety_diagnostic": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/StorageSafetyDiagnostic"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "scheduler_decision": {
                      "anyOf": [
                        {
                          "description": "Saved nine-field automatic-policy decision. Runtime also validates calendar chronology and recomputes the type/reason against the sealed policy; reading it grants no execution authority.",
                          "oneOf": [
                            {
                              "additionalProperties": false,
                              "properties": {
                                "backup_type": {
                                  "const": "full"
                                },
                                "generation_id": {
                                  "type": "null"
                                },
                                "incremental_count": {
                                  "type": "null"
                                },
                                "observed_date": {
                                  "format": "date",
                                  "type": "string"
                                },
                                "policy": {
                                  "additionalProperties": false,
                                  "properties": {
                                    "full_every_days": {
                                      "maximum": 36500,
                                      "minimum": 1,
                                      "type": "integer"
                                    },
                                    "max_incrementals": {
                                      "maximum": 255,
                                      "minimum": 1,
                                      "type": "integer"
                                    },
                                    "schema": {
                                      "const": 1,
                                      "type": "integer"
                                    }
                                  },
                                  "required": [
                                    "schema",
                                    "full_every_days",
                                    "max_incrementals"
                                  ],
                                  "type": "object"
                                },
                                "reason": {
                                  "enum": [
                                    "parent_unavailable",
                                    "new_grant",
                                    "source_changed",
                                    "root_time_unavailable",
                                    "previous_failure"
                                  ]
                                },
                                "root_backup_id": {
                                  "type": "null"
                                },
                                "root_date": {
                                  "type": "null"
                                },
                                "schema": {
                                  "const": 1,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "schema",
                                "policy",
                                "observed_date",
                                "generation_id",
                                "root_backup_id",
                                "root_date",
                                "incremental_count",
                                "backup_type",
                                "reason"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "backup_type": {
                                  "const": "full"
                                },
                                "generation_id": {
                                  "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",
                                  "type": "string"
                                },
                                "incremental_count": {
                                  "minimum": 0,
                                  "type": "integer"
                                },
                                "observed_date": {
                                  "format": "date",
                                  "type": "string"
                                },
                                "policy": {
                                  "additionalProperties": false,
                                  "properties": {
                                    "full_every_days": {
                                      "maximum": 36500,
                                      "minimum": 1,
                                      "type": "integer"
                                    },
                                    "max_incrementals": {
                                      "maximum": 255,
                                      "minimum": 1,
                                      "type": "integer"
                                    },
                                    "schema": {
                                      "const": 1,
                                      "type": "integer"
                                    }
                                  },
                                  "required": [
                                    "schema",
                                    "full_every_days",
                                    "max_incrementals"
                                  ],
                                  "type": "object"
                                },
                                "reason": {
                                  "enum": [
                                    "max_incrementals",
                                    "full_interval"
                                  ]
                                },
                                "root_backup_id": {
                                  "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",
                                  "type": "string"
                                },
                                "root_date": {
                                  "format": "date",
                                  "type": "string"
                                },
                                "schema": {
                                  "const": 1,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "schema",
                                "policy",
                                "observed_date",
                                "generation_id",
                                "root_backup_id",
                                "root_date",
                                "incremental_count",
                                "backup_type",
                                "reason"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "backup_type": {
                                  "const": "incremental"
                                },
                                "generation_id": {
                                  "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",
                                  "type": "string"
                                },
                                "incremental_count": {
                                  "minimum": 0,
                                  "type": "integer"
                                },
                                "observed_date": {
                                  "format": "date",
                                  "type": "string"
                                },
                                "policy": {
                                  "additionalProperties": false,
                                  "properties": {
                                    "full_every_days": {
                                      "maximum": 36500,
                                      "minimum": 1,
                                      "type": "integer"
                                    },
                                    "max_incrementals": {
                                      "maximum": 255,
                                      "minimum": 1,
                                      "type": "integer"
                                    },
                                    "schema": {
                                      "const": 1,
                                      "type": "integer"
                                    }
                                  },
                                  "required": [
                                    "schema",
                                    "full_every_days",
                                    "max_incrementals"
                                  ],
                                  "type": "object"
                                },
                                "reason": {
                                  "const": "within_policy"
                                },
                                "root_backup_id": {
                                  "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",
                                  "type": "string"
                                },
                                "root_date": {
                                  "format": "date",
                                  "type": "string"
                                },
                                "schema": {
                                  "const": 1,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "schema",
                                "policy",
                                "observed_date",
                                "generation_id",
                                "root_backup_id",
                                "root_date",
                                "incremental_count",
                                "backup_type",
                                "reason"
                              ],
                              "type": "object"
                            }
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "size_bytes": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "storage_path": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "storage_progress": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "bytes_transferred": {
                              "maximum": 9223372036854775807,
                              "minimum": 0,
                              "type": "integer"
                            },
                            "phase": {
                              "enum": [
                                "pending",
                                "preparing",
                                "uploading",
                                "finalizing"
                              ],
                              "type": "string"
                            },
                            "plan_sha256": {
                              "type": "string"
                            },
                            "reservation_id": {
                              "type": "string"
                            },
                            "schema": {
                              "const": 1,
                              "type": "integer"
                            },
                            "total_bytes": {
                              "maximum": 9223372036854775807,
                              "minimum": 0,
                              "type": "integer"
                            },
                            "updated_at": {
                              "format": "date-time",
                              "type": "string"
                            }
                          },
                          "required": [
                            "schema",
                            "reservation_id",
                            "plan_sha256",
                            "phase",
                            "bytes_transferred",
                            "total_bytes",
                            "updated_at"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "tags": {
                      "additionalProperties": true,
                      "description": "Extensible domain metadata; keys are not a closed schema.",
                      "type": "object",
                      "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                    },
                    "vm_id": {
                      "type": "string"
                    },
                    "vm_name": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "vm_id",
                    "vm_name",
                    "status",
                    "progress",
                    "safety_diagnostic",
                    "storage_progress",
                    "size_bytes",
                    "retention_days",
                    "backup_type",
                    "storage_path",
                    "tags",
                    "created_at",
                    "completed_at",
                    "operator_dispatch",
                    "scheduler_decision"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/backups.py:224"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Backup",
        "tags": [
          "backups"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/backups/{backup_id}/close-unreserved": {
      "post": {
        "description": "Close a pristine pending human request; preserve its original receipts.\n\nNo provider effects, deletion, capacity release or replacement attempt occurs.\nSupply a new Idempotency-Key for this separately audited closeout action.",
        "operationId": "close_unreserved_attempt_api_v1_backups__backup_id__close_unreserved_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BackupCloseUnreservedRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_id": {
                      "type": "string"
                    },
                    "capacity_state": {
                      "const": "unreserved",
                      "type": "string"
                    },
                    "reason": {
                      "const": "pre_dispatch_no_effect",
                      "type": "string"
                    },
                    "request_id": {
                      "format": "uuid",
                      "type": "string"
                    },
                    "status": {
                      "const": "failed",
                      "type": "string"
                    }
                  },
                  "required": [
                    "backup_id",
                    "status",
                    "reason",
                    "capacity_state",
                    "request_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Invalid domain request."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authorized resource unavailable.",
            "x-error-sources": [
              "backend/routers/backups.py:close_unreserved_attempt"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract.",
            "x-error-sources": [
              "backend/routers/backups.py:close_unreserved_attempt"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit."
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Close Unreserved Attempt",
        "tags": [
          "backups"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-operator-action": "backup.close_unreserved"
      }
    },
    "/api/v1/backups/{backup_id}/restore-bundle": {
      "get": {
        "description": "Export accepted chain metadata for vnbui-restore; no keys or credentials.",
        "operationId": "get_restore_bundle_api_v1_backups__backup_id__restore_bundle_get",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AcceptedRestoreBundle"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/backups.py:208"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Restore Bundle",
        "tags": [
          "backups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-response-source": "core/storage_restore.py:build_restore_bundle;core/native_restore_bundle.py:build_native_bundle"
      }
    },
    "/api/v1/backups/{backup_id}/resume": {
      "post": {
        "description": "Redeliver only this backup's original durable attempt; never replace it.",
        "operationId": "resume_attempt_api_v1_backups__backup_id__resume_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_id": {
                      "type": "string"
                    },
                    "resumed": {
                      "const": false
                    },
                    "status": {
                      "const": "completed"
                    }
                  },
                  "required": [
                    "status",
                    "backup_id",
                    "resumed"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "202": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "attempt_id": {
                      "type": "string"
                    },
                    "backup_id": {
                      "type": "string"
                    },
                    "resumed": {
                      "const": true
                    },
                    "status": {
                      "const": "accepted"
                    }
                  },
                  "required": [
                    "status",
                    "backup_id",
                    "resumed",
                    "attempt_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "backup_id": {
                              "type": "string"
                            },
                            "capacity_retained": {
                              "const": true
                            },
                            "reason": {
                              "type": "string"
                            },
                            "status": {
                              "const": "held"
                            }
                          },
                          "required": [
                            "status",
                            "backup_id",
                            "reason",
                            "capacity_retained"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "backup_id": {
                              "type": "string"
                            },
                            "capacity_retained": {
                              "const": true,
                              "type": "boolean"
                            },
                            "reason": {
                              "type": "string"
                            },
                            "status": {
                              "const": "held",
                              "type": "string"
                            }
                          },
                          "required": [
                            "status",
                            "backup_id",
                            "reason",
                            "capacity_retained"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Original attempt remains held; this response does not authorize replacement or release.",
            "x-error-sources": [
              "backend/routers/backups.py:412"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Resume Attempt",
        "tags": [
          "backups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-response-source": "core/backup_recovery.py:_resume_backup_attempt_worker"
      }
    },
    "/api/v1/backups/{backup_id}/retry-upload": {
      "post": {
        "description": "Attribute manual retry without converting uncertainty to send authority.",
        "operationId": "retry_upload_api_v1_backups__backup_id__retry_upload_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "core/upload_retry.py:90 record_retry_hold",
              "backend/core/upload_retry.py:110",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "core/upload_retry.py:90 record_retry_hold",
              "backend/core/upload_retry.py:113"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "core/upload_retry.py:90 record_retry_hold",
              "backend/core/upload_retry.py:120",
              "backend/core/upload_retry.py:129"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "reason": {
                              "type": "string"
                            },
                            "status": {
                              "const": "held"
                            }
                          },
                          "required": [
                            "status",
                            "reason"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "reason": {
                              "type": "string"
                            },
                            "status": {
                              "const": "held",
                              "type": "string"
                            }
                          },
                          "required": [
                            "status",
                            "reason"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Original custody retained; no upload is dispatched.",
            "x-error-sources": [
              "backend/routers/backups.py:389"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Retry Upload",
        "tags": [
          "backups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-no-success-response": "Always returns a hold/refusal; never grants upload dispatch authority.",
        "x-response-source": "routers/backups.py:retry_upload"
      }
    },
    "/api/v1/backups/{backup_id}/verifications": {
      "get": {
        "description": "List verification history for a backup",
        "operationId": "list_backup_verifications_api_v1_backups__backup_id__verifications_get",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "items": {
                    "additionalProperties": false,
                    "properties": {
                      "cancel_requested": {
                        "type": "boolean"
                      },
                      "completed_at": {
                        "anyOf": [
                          {
                            "format": "date-time",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "created_at": {
                        "anyOf": [
                          {
                            "format": "date-time",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "created_by": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "id": {
                        "type": "string"
                      },
                      "read_attempts": {
                        "anyOf": [
                          {
                            "type": "integer"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "read_limit": {
                        "anyOf": [
                          {
                            "type": "integer"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "recorded_status": {
                        "type": "string"
                      },
                      "result_message": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "started_at": {
                        "anyOf": [
                          {
                            "format": "date-time",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "status": {
                        "type": "string"
                      },
                      "verification_type": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "id",
                      "status",
                      "recorded_status",
                      "created_by",
                      "read_attempts",
                      "read_limit",
                      "cancel_requested",
                      "result_message",
                      "verification_type",
                      "started_at",
                      "completed_at",
                      "created_at"
                    ],
                    "type": "object"
                  },
                  "type": "array"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/verification.py:188"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Backup Verifications",
        "tags": [
          "verification"
        ],
        "x-credential-domain": "user-session",
        "x-response-source": "routers/verification.py:list_backup_verifications"
      }
    },
    "/api/v1/backups/{backup_id}/verify": {
      "post": {
        "description": "Admit original-ID read-only work; an acknowledgement is never proof.",
        "operationId": "verify_backup_api_v1_backups__backup_id__verify_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VerificationCommand"
              }
            }
          },
          "required": true
        },
        "responses": {
          "202": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_id": {
                      "type": "string"
                    },
                    "cancel_requested": {
                      "type": "boolean"
                    },
                    "created_by": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "read_attempts": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "read_limit": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "recorded_status": {
                      "type": "string"
                    },
                    "result_message": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "verification_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "backup_id",
                    "status",
                    "recorded_status",
                    "created_by",
                    "read_attempts",
                    "read_limit",
                    "cancel_requested",
                    "result_message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/verification.py:119"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/verification.py:116",
              "backend/routers/verification.py:142"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/verification.py:168"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Verify Backup",
        "tags": [
          "verification"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/verification.py:verify_backup"
      }
    },
    "/api/v1/bootstrap": {
      "get": {
        "description": "Minimal prelogin installation data without license or customer details.",
        "operationId": "get_bootstrap_api_v1_bootstrap_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "auth_mode": {
                      "enum": [
                        "single_organization",
                        "multi_organization"
                      ]
                    },
                    "edition": {
                      "enum": [
                        "community",
                        "commercial"
                      ]
                    },
                    "login_methods": {
                      "additionalProperties": false,
                      "properties": {
                        "oidc": {
                          "type": "boolean"
                        },
                        "password": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "password",
                        "oidc"
                      ],
                      "type": "object"
                    },
                    "schema_version": {
                      "const": 1,
                      "type": "integer"
                    }
                  },
                  "required": [
                    "schema_version",
                    "edition",
                    "auth_mode",
                    "login_methods"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Get Bootstrap",
        "tags": [
          "public"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/compatibility": {
      "get": {
        "description": "Check API/frontend and online agents owned by the persisted user's organization.\n\nReturns overall system compatibility status and per-component details.\nFrontend can pass its version via X-Frontend-Version header.",
        "operationId": "get_compatibility_api_v1_compatibility_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agents": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "compatible": {
                            "type": "boolean"
                          },
                          "hostname": {
                            "type": "string"
                          },
                          "reason": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "enum": [
                              "aligned",
                              "degraded",
                              "incompatible"
                            ]
                          },
                          "version": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "hostname",
                          "version",
                          "compatible",
                          "status",
                          "reason"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "api": {
                      "additionalProperties": false,
                      "properties": {
                        "major": {
                          "type": "integer"
                        },
                        "minor": {
                          "type": "integer"
                        },
                        "patch": {
                          "type": "integer"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "version",
                        "major",
                        "minor",
                        "patch"
                      ],
                      "type": "object"
                    },
                    "contract_version": {
                      "const": 6,
                      "type": "integer"
                    },
                    "degraded_mode": {
                      "type": "boolean"
                    },
                    "expected_version": {
                      "type": "string"
                    },
                    "frontend": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "compatible": {
                              "type": "boolean"
                            },
                            "reason": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "status": {
                              "enum": [
                                "aligned",
                                "degraded",
                                "incompatible"
                              ]
                            },
                            "version": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "compatible",
                            "status",
                            "reason",
                            "version"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "organization_id": {
                      "type": "string"
                    },
                    "scope": {
                      "const": "organization-online-agents",
                      "type": "string"
                    },
                    "status": {
                      "enum": [
                        "aligned",
                        "degraded",
                        "incompatible"
                      ]
                    },
                    "warnings": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "contract_version",
                    "scope",
                    "organization_id",
                    "status",
                    "api",
                    "frontend",
                    "agents",
                    "expected_version",
                    "warnings",
                    "degraded_mode"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/public.py:158"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Compatibility",
        "tags": [
          "public"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/config/realtime": {
      "get": {
        "description": "Get real-time configuration for the client.",
        "operationId": "get_realtime_config_api_v1_config_realtime_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "enablePolling": {
                      "type": "boolean"
                    },
                    "enableWebSocket": {
                      "type": "boolean"
                    },
                    "pollingInterval": {
                      "type": "integer"
                    },
                    "wsMaxReconnectAttempts": {
                      "type": "integer"
                    },
                    "wsReconnectDelay": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "enableWebSocket",
                    "enablePolling",
                    "pollingInterval",
                    "wsReconnectDelay",
                    "wsMaxReconnectAttempts"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Realtime Config",
        "tags": [
          "realtime"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/dashboard/backup-trends": {
      "get": {
        "description": "Get backup trends over time",
        "operationId": "get_backup_trends_api_v1_dashboard_backup_trends_get",
        "parameters": [
          {
            "in": "query",
            "name": "days",
            "required": false,
            "schema": {
              "default": 7,
              "title": "Days",
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "data": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "completed": {
                            "type": "integer"
                          },
                          "date": {
                            "format": "date",
                            "type": "string"
                          },
                          "failed": {
                            "type": "integer"
                          },
                          "total": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "date",
                          "completed",
                          "failed",
                          "total"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "period_days": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "period_days",
                    "data"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Backup Trends",
        "tags": [
          "dashboard"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/dashboard/storage-usage": {
      "get": {
        "description": "Get storage usage breakdown by agent",
        "operationId": "get_storage_usage_api_v1_dashboard_storage_usage_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "by_agent": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_id": {
                            "type": "string"
                          },
                          "backup_count": {
                            "type": "integer"
                          },
                          "hostname": {
                            "type": "string"
                          },
                          "size_bytes": {
                            "type": "integer"
                          },
                          "size_gb": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "agent_id",
                          "hostname",
                          "size_bytes",
                          "size_gb",
                          "backup_count"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "by_agent"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Storage Usage",
        "tags": [
          "dashboard"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/dashboard/summary": {
      "get": {
        "description": "Get dashboard summary statistics",
        "operationId": "get_dashboard_summary_api_v1_dashboard_summary_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agents": {
                      "additionalProperties": false,
                      "properties": {
                        "offline": {
                          "type": "integer"
                        },
                        "online": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "online",
                        "offline"
                      ],
                      "type": "object"
                    },
                    "attention": {
                      "additionalProperties": false,
                      "properties": {
                        "failed_backups": {
                          "type": "integer"
                        },
                        "held_backups": {
                          "type": "integer"
                        },
                        "held_jobs": {
                          "type": "integer"
                        },
                        "offline_agents": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "offline_agents",
                        "failed_backups",
                        "held_jobs",
                        "held_backups"
                      ],
                      "type": "object"
                    },
                    "backups": {
                      "additionalProperties": false,
                      "properties": {
                        "by_status": {
                          "additionalProperties": false,
                          "properties": {
                            "completed": {
                              "type": "integer"
                            },
                            "failed": {
                              "type": "integer"
                            },
                            "held": {
                              "type": "integer"
                            },
                            "other": {
                              "type": "integer"
                            },
                            "queued": {
                              "type": "integer"
                            },
                            "running": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "completed",
                            "running",
                            "queued",
                            "failed",
                            "held",
                            "other"
                          ],
                          "type": "object"
                        },
                        "completed_24h": {
                          "type": "integer"
                        },
                        "failed_24h": {
                          "type": "integer"
                        },
                        "last_24h": {
                          "type": "integer"
                        },
                        "period_end": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "period_start": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "running_count": {
                          "type": "integer"
                        },
                        "success_rate_24h": {
                          "anyOf": [
                            {
                              "type": "number"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "total": {
                          "type": "integer"
                        },
                        "uploads_pending": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "last_24h",
                        "completed_24h",
                        "failed_24h",
                        "uploads_pending",
                        "running_count",
                        "success_rate_24h",
                        "period_start",
                        "period_end",
                        "by_status"
                      ],
                      "type": "object"
                    },
                    "generated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "recent_backups": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "backup_type": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "progress": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "size_bytes": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "vm_id": {
                            "type": "string"
                          },
                          "vm_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "vm_id",
                          "vm_name",
                          "status",
                          "backup_type",
                          "size_bytes",
                          "progress",
                          "created_at",
                          "agent_name"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "running_backups": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "backup_type": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "progress": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "size_bytes": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "vm_id": {
                            "type": "string"
                          },
                          "vm_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "vm_id",
                          "vm_name",
                          "status",
                          "backup_type",
                          "size_bytes",
                          "progress",
                          "created_at",
                          "agent_name"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "schedules": {
                      "additionalProperties": false,
                      "properties": {
                        "active": {
                          "type": "integer"
                        },
                        "upcoming": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "active",
                        "upcoming"
                      ],
                      "type": "object"
                    },
                    "storage": {
                      "additionalProperties": false,
                      "properties": {
                        "total_bytes": {
                          "type": "integer"
                        },
                        "total_gb": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "total_bytes",
                        "total_gb"
                      ],
                      "type": "object"
                    },
                    "vms": {
                      "additionalProperties": false,
                      "properties": {
                        "by_agent": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "agent_id": {
                                "type": "string"
                              },
                              "count": {
                                "type": "integer"
                              },
                              "name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "agent_id",
                              "name",
                              "count"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "by_status": {
                          "additionalProperties": {
                            "type": "integer"
                          },
                          "description": "Current VM state strings mapped to counts; null state normalizes to unknown.",
                          "type": "object",
                          "x-open-schema-reason": "Current VM state strings mapped to counts; null state normalizes to unknown."
                        },
                        "running": {
                          "type": "integer"
                        },
                        "stopped": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "running",
                        "stopped",
                        "by_status",
                        "by_agent"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "vms",
                    "agents",
                    "backups",
                    "storage",
                    "schedules",
                    "attention",
                    "recent_backups",
                    "running_backups",
                    "generated_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Dashboard Summary",
        "tags": [
          "dashboard"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/demo/backups": {
      "post": {
        "operationId": "create_backup_api_v1_demo_backups_post",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BackupRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_type": {
                      "type": "string"
                    },
                    "chain_id": {
                      "type": "string"
                    },
                    "chain_position": {
                      "type": "integer"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "error_message": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "events": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "environment": {
                            "const": "demo",
                            "type": "string"
                          },
                          "message": {
                            "type": "string"
                          },
                          "progress": {
                            "type": "integer"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "stage": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "status",
                          "progress",
                          "stage",
                          "message",
                          "simulated",
                          "environment"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "parent_backup_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "progress": {
                      "type": "integer"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "status": {
                      "type": "string"
                    },
                    "vm_id": {
                      "type": "string"
                    },
                    "vm_name": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "vm_id",
                    "vm_name",
                    "backup_type",
                    "status",
                    "progress",
                    "parent_backup_id",
                    "chain_id",
                    "chain_position",
                    "created_at",
                    "completed_at",
                    "error_message",
                    "simulated",
                    "events"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Create Backup",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/backups/{backup_id}/retry": {
      "post": {
        "operationId": "retry_backup_api_v1_demo_backups__backup_id__retry_post",
        "parameters": [
          {
            "in": "path",
            "name": "backup_id",
            "required": true,
            "schema": {
              "title": "Backup Id",
              "type": "string"
            }
          },
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_type": {
                      "type": "string"
                    },
                    "chain_id": {
                      "type": "string"
                    },
                    "chain_position": {
                      "type": "integer"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "error_message": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "events": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "environment": {
                            "const": "demo",
                            "type": "string"
                          },
                          "message": {
                            "type": "string"
                          },
                          "progress": {
                            "type": "integer"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "stage": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "status",
                          "progress",
                          "stage",
                          "message",
                          "simulated",
                          "environment"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "parent_backup_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "progress": {
                      "type": "integer"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "size_bytes": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "storage_path": {
                      "type": "string"
                    },
                    "vm_id": {
                      "type": "string"
                    },
                    "vm_name": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "vm_id",
                    "vm_name",
                    "backup_type",
                    "status",
                    "progress",
                    "parent_backup_id",
                    "chain_id",
                    "chain_position",
                    "created_at",
                    "completed_at",
                    "error_message",
                    "simulated",
                    "events"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Retry Backup",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/groups": {
      "post": {
        "operationId": "create_group_api_v1_demo_groups_post",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GroupRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "group_type": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "member_count": {
                      "type": "integer"
                    },
                    "name": {
                      "type": "string"
                    },
                    "rules": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "field": {
                            "type": "string"
                          },
                          "op": {
                            "type": "string"
                          },
                          "value": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              }
                            ]
                          }
                        },
                        "required": [
                          "field",
                          "op",
                          "value"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "rules_match": {
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "group_type",
                    "rules",
                    "rules_match",
                    "member_count",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Create Group",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/groups/preview": {
      "post": {
        "operationId": "preview_group_api_v1_demo_groups_preview_post",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GroupRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_id": {
                            "type": "string"
                          },
                          "disks": {
                            "items": {
                              "additionalProperties": false,
                              "properties": {
                                "format": {
                                  "type": "string"
                                },
                                "size_bytes": {
                                  "type": "integer"
                                },
                                "source": {
                                  "type": "string"
                                },
                                "target": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "target",
                                "format",
                                "size_bytes",
                                "source"
                              ],
                              "type": "object"
                            },
                            "type": "array"
                          },
                          "id": {
                            "type": "string"
                          },
                          "memory_kb": {
                            "type": "integer"
                          },
                          "metadata": {
                            "additionalProperties": false,
                            "properties": {
                              "environment": {
                                "type": "string"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "supports_incremental": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "environment",
                              "supports_incremental",
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "name": {
                            "type": "string"
                          },
                          "state": {
                            "type": "string"
                          },
                          "uuid": {
                            "type": "string"
                          },
                          "vcpu_count": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "id",
                          "uuid",
                          "name",
                          "agent_id",
                          "state",
                          "memory_kb",
                          "vcpu_count",
                          "disks",
                          "metadata"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Preview Group",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/groups/{group_id}": {
      "put": {
        "operationId": "update_group_api_v1_demo_groups__group_id__put",
        "parameters": [
          {
            "in": "path",
            "name": "group_id",
            "required": true,
            "schema": {
              "title": "Group Id",
              "type": "string"
            }
          },
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GroupRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "group_type": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "member_count": {
                      "type": "integer"
                    },
                    "name": {
                      "type": "string"
                    },
                    "rules": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "field": {
                            "type": "string"
                          },
                          "op": {
                            "type": "string"
                          },
                          "value": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              }
                            ]
                          }
                        },
                        "required": [
                          "field",
                          "op",
                          "value"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "rules_match": {
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "group_type",
                    "rules",
                    "rules_match",
                    "member_count",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Update Group",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/reset": {
      "post": {
        "operationId": "reset_session_api_v1_demo_reset_post",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "absolute_expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "fixture_version": {
                      "type": "string"
                    },
                    "session_id": {
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "state": {
                      "additionalProperties": false,
                      "properties": {
                        "activity": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "action": {
                                "type": "string"
                              },
                              "created_at": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "details": {
                                "additionalProperties": false,
                                "properties": {
                                  "name": {
                                    "type": "string"
                                  },
                                  "simulated": {
                                    "const": true,
                                    "type": "boolean"
                                  },
                                  "vm_name": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "simulated"
                                ],
                                "type": "object"
                              },
                              "id": {
                                "type": "string"
                              },
                              "resource_id": {
                                "type": "string"
                              },
                              "resource_type": {
                                "type": "string"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "id",
                              "action",
                              "resource_type",
                              "resource_id",
                              "created_at",
                              "details"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "agents": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "capabilities": {
                                "additionalProperties": false,
                                "properties": {
                                  "backup_method": {
                                    "type": "string"
                                  },
                                  "checkpoints": {
                                    "type": "boolean"
                                  },
                                  "incremental": {
                                    "type": "boolean"
                                  },
                                  "snapshots": {
                                    "type": "boolean"
                                  }
                                },
                                "required": [
                                  "incremental",
                                  "backup_method"
                                ],
                                "type": "object"
                              },
                              "display_name": {
                                "type": "string"
                              },
                              "health_reasons": {
                                "additionalProperties": false,
                                "properties": {
                                  "libvirt_unavailable": {
                                    "type": "integer"
                                  },
                                  "load_high": {
                                    "type": "integer"
                                  },
                                  "storage_low": {
                                    "type": "integer"
                                  }
                                },
                                "required": [
                                  "storage_low",
                                  "load_high",
                                  "libvirt_unavailable"
                                ],
                                "type": "object"
                              },
                              "hostname": {
                                "type": "string"
                              },
                              "id": {
                                "type": "string"
                              },
                              "last_heartbeat": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "provider": {
                                "type": "string"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "status": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "hostname",
                              "display_name",
                              "status",
                              "provider",
                              "last_heartbeat",
                              "capabilities",
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "backups": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_type": {
                                "type": "string"
                              },
                              "chain_id": {
                                "type": "string"
                              },
                              "chain_position": {
                                "type": "integer"
                              },
                              "completed_at": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "created_at": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "error_message": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "events": {
                                "items": {
                                  "additionalProperties": false,
                                  "properties": {
                                    "environment": {
                                      "const": "demo",
                                      "type": "string"
                                    },
                                    "message": {
                                      "type": "string"
                                    },
                                    "progress": {
                                      "type": "integer"
                                    },
                                    "simulated": {
                                      "const": true,
                                      "type": "boolean"
                                    },
                                    "stage": {
                                      "type": "string"
                                    },
                                    "status": {
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "status",
                                    "progress",
                                    "stage",
                                    "message",
                                    "simulated",
                                    "environment"
                                  ],
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              "id": {
                                "type": "string"
                              },
                              "parent_backup_id": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "progress": {
                                "type": "integer"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "size_bytes": {
                                "anyOf": [
                                  {
                                    "type": "integer"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "status": {
                                "type": "string"
                              },
                              "storage_path": {
                                "type": "string"
                              },
                              "vm_id": {
                                "type": "string"
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "vm_id",
                              "vm_name",
                              "backup_type",
                              "status",
                              "progress",
                              "parent_backup_id",
                              "chain_id",
                              "chain_position",
                              "created_at",
                              "completed_at",
                              "error_message",
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "fixture_version": {
                          "type": "string"
                        },
                        "generated_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "groups": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "group_type": {
                                "type": "string"
                              },
                              "id": {
                                "type": "string"
                              },
                              "member_count": {
                                "type": "integer"
                              },
                              "name": {
                                "type": "string"
                              },
                              "rules": {
                                "items": {
                                  "additionalProperties": false,
                                  "properties": {
                                    "field": {
                                      "type": "string"
                                    },
                                    "op": {
                                      "type": "string"
                                    },
                                    "value": {
                                      "anyOf": [
                                        {
                                          "type": "string"
                                        },
                                        {
                                          "items": {
                                            "type": "string"
                                          },
                                          "type": "array"
                                        }
                                      ]
                                    }
                                  },
                                  "required": [
                                    "field",
                                    "op",
                                    "value"
                                  ],
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              "rules_match": {
                                "type": "string"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "vm_ids": {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "group_type",
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "persona": {
                          "additionalProperties": false,
                          "properties": {
                            "hands_on": {
                              "type": "string"
                            },
                            "msp_context": {
                              "type": "string"
                            },
                            "msp_message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "hands_on",
                            "msp_context",
                            "msp_message"
                          ],
                          "type": "object"
                        },
                        "restores": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_id": {
                                "type": "string"
                              },
                              "completed_at": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "created_at": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "events": {
                                "items": {
                                  "additionalProperties": false,
                                  "properties": {
                                    "environment": {
                                      "const": "demo",
                                      "type": "string"
                                    },
                                    "message": {
                                      "type": "string"
                                    },
                                    "progress": {
                                      "type": "integer"
                                    },
                                    "simulated": {
                                      "const": true,
                                      "type": "boolean"
                                    },
                                    "stage": {
                                      "type": "string"
                                    },
                                    "status": {
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "status",
                                    "progress",
                                    "stage",
                                    "message",
                                    "simulated",
                                    "environment"
                                  ],
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              "id": {
                                "type": "string"
                              },
                              "message": {
                                "type": "string"
                              },
                              "progress": {
                                "type": "integer"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "status": {
                                "type": "string"
                              },
                              "target_vm_id": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "backup_id",
                              "target_vm_id",
                              "status",
                              "progress",
                              "created_at",
                              "completed_at",
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "schedules": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_type": {
                                "type": "string"
                              },
                              "cron_expression": {
                                "type": "string"
                              },
                              "enabled": {
                                "type": "boolean"
                              },
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "retention_days": {
                                "type": "integer"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "vm_group_id": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "vm_id": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "cron_expression",
                              "retention_days",
                              "backup_type",
                              "enabled",
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        },
                        "vms": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "agent_id": {
                                "type": "string"
                              },
                              "disks": {
                                "items": {
                                  "additionalProperties": false,
                                  "properties": {
                                    "format": {
                                      "type": "string"
                                    },
                                    "size_bytes": {
                                      "type": "integer"
                                    },
                                    "source": {
                                      "type": "string"
                                    },
                                    "target": {
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "target",
                                    "format",
                                    "size_bytes",
                                    "source"
                                  ],
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              "id": {
                                "type": "string"
                              },
                              "memory_kb": {
                                "type": "integer"
                              },
                              "metadata": {
                                "additionalProperties": false,
                                "properties": {
                                  "environment": {
                                    "type": "string"
                                  },
                                  "simulated": {
                                    "const": true,
                                    "type": "boolean"
                                  },
                                  "supports_incremental": {
                                    "type": "boolean"
                                  }
                                },
                                "required": [
                                  "environment",
                                  "supports_incremental",
                                  "simulated"
                                ],
                                "type": "object"
                              },
                              "name": {
                                "type": "string"
                              },
                              "state": {
                                "type": "string"
                              },
                              "uuid": {
                                "type": "string"
                              },
                              "vcpu_count": {
                                "type": "integer"
                              }
                            },
                            "required": [
                              "id",
                              "uuid",
                              "name",
                              "agent_id",
                              "state",
                              "memory_kb",
                              "vcpu_count",
                              "disks",
                              "metadata"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "fixture_version",
                        "generated_at",
                        "environment",
                        "simulated",
                        "persona",
                        "agents",
                        "vms",
                        "groups",
                        "schedules",
                        "backups",
                        "restores",
                        "activity"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "session_id",
                    "fixture_version",
                    "expires_at",
                    "absolute_expires_at",
                    "environment",
                    "simulated",
                    "state"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:267",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Reset Session",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/restores": {
      "post": {
        "operationId": "create_restore_api_v1_demo_restores_post",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RestoreRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_id": {
                      "type": "string"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "events": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "environment": {
                            "const": "demo",
                            "type": "string"
                          },
                          "message": {
                            "type": "string"
                          },
                          "progress": {
                            "type": "integer"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "stage": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "status",
                          "progress",
                          "stage",
                          "message",
                          "simulated",
                          "environment"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "progress": {
                      "type": "integer"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "status": {
                      "type": "string"
                    },
                    "target_vm_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "backup_id",
                    "target_vm_id",
                    "status",
                    "progress",
                    "created_at",
                    "completed_at",
                    "events",
                    "message",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Create Restore",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/schedules": {
      "post": {
        "operationId": "create_schedule_api_v1_demo_schedules_post",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduleRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_type": {
                      "type": "string"
                    },
                    "cron_expression": {
                      "type": "string"
                    },
                    "enabled": {
                      "type": "boolean"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "retention_days": {
                      "type": "integer"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "vm_group_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "cron_expression",
                    "retention_days",
                    "backup_type",
                    "enabled",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Create Schedule",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/schedules/{schedule_id}/run": {
      "post": {
        "operationId": "run_schedule_api_v1_demo_schedules__schedule_id__run_post",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          },
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup_type": {
                      "type": "string"
                    },
                    "chain_id": {
                      "type": "string"
                    },
                    "chain_position": {
                      "type": "integer"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "error_message": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "events": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "environment": {
                            "const": "demo",
                            "type": "string"
                          },
                          "message": {
                            "type": "string"
                          },
                          "progress": {
                            "type": "integer"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "stage": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "status",
                          "progress",
                          "stage",
                          "message",
                          "simulated",
                          "environment"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "parent_backup_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "progress": {
                      "type": "integer"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "status": {
                      "type": "string"
                    },
                    "vm_id": {
                      "type": "string"
                    },
                    "vm_name": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "vm_id",
                    "vm_name",
                    "backup_type",
                    "status",
                    "progress",
                    "parent_backup_id",
                    "chain_id",
                    "chain_position",
                    "created_at",
                    "completed_at",
                    "error_message",
                    "simulated",
                    "events"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/demo.py:91"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Run Schedule",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/sessions": {
      "post": {
        "operationId": "create_session_api_v1_demo_sessions_post",
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "absolute_expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "fixture_version": {
                      "type": "string"
                    },
                    "session_id": {
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "session_id",
                    "fixture_version",
                    "expires_at",
                    "absolute_expires_at",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:114"
            ]
          }
        },
        "security": [],
        "summary": "Create Session",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "public-demo-bootstrap"
      }
    },
    "/api/v1/demo/sessions/current": {
      "delete": {
        "operationId": "destroy_session_api_v1_demo_sessions_current_delete",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Destroy Session",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      },
      "get": {
        "operationId": "current_session_api_v1_demo_sessions_current_get",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "absolute_expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "fixture_version": {
                      "type": "string"
                    },
                    "session_id": {
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "session_id",
                    "fixture_version",
                    "expires_at",
                    "absolute_expires_at",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Current Session",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/demo/state": {
      "get": {
        "operationId": "get_state_api_v1_demo_state_get",
        "parameters": [
          {
            "in": "cookie",
            "name": "vnbui_demo_session",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Vnbui Demo Session"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "activity": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "action": {
                            "type": "string"
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "details": {
                            "additionalProperties": false,
                            "properties": {
                              "name": {
                                "type": "string"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "id": {
                            "type": "string"
                          },
                          "resource_id": {
                            "type": "string"
                          },
                          "resource_type": {
                            "type": "string"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "id",
                          "action",
                          "resource_type",
                          "resource_id",
                          "created_at",
                          "details"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "agents": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "capabilities": {
                            "additionalProperties": false,
                            "properties": {
                              "backup_method": {
                                "type": "string"
                              },
                              "checkpoints": {
                                "type": "boolean"
                              },
                              "incremental": {
                                "type": "boolean"
                              },
                              "snapshots": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "incremental",
                              "backup_method"
                            ],
                            "type": "object"
                          },
                          "display_name": {
                            "type": "string"
                          },
                          "health_reasons": {
                            "additionalProperties": false,
                            "properties": {
                              "libvirt_unavailable": {
                                "type": "integer"
                              },
                              "load_high": {
                                "type": "integer"
                              },
                              "storage_low": {
                                "type": "integer"
                              }
                            },
                            "required": [
                              "storage_low",
                              "load_high",
                              "libvirt_unavailable"
                            ],
                            "type": "object"
                          },
                          "hostname": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "last_heartbeat": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "provider": {
                            "type": "string"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "hostname",
                          "display_name",
                          "status",
                          "provider",
                          "last_heartbeat",
                          "capabilities",
                          "simulated"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "backups": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "backup_type": {
                            "type": "string"
                          },
                          "chain_id": {
                            "type": "string"
                          },
                          "chain_position": {
                            "type": "integer"
                          },
                          "completed_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "error_message": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "events": {
                            "items": {
                              "additionalProperties": false,
                              "properties": {
                                "environment": {
                                  "const": "demo",
                                  "type": "string"
                                },
                                "message": {
                                  "type": "string"
                                },
                                "progress": {
                                  "type": "integer"
                                },
                                "simulated": {
                                  "const": true,
                                  "type": "boolean"
                                },
                                "stage": {
                                  "type": "string"
                                },
                                "status": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "status",
                                "progress",
                                "stage",
                                "message",
                                "simulated",
                                "environment"
                              ],
                              "type": "object"
                            },
                            "type": "array"
                          },
                          "id": {
                            "type": "string"
                          },
                          "parent_backup_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "progress": {
                            "type": "integer"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "size_bytes": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "storage_path": {
                            "type": "string"
                          },
                          "vm_id": {
                            "type": "string"
                          },
                          "vm_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "vm_id",
                          "vm_name",
                          "backup_type",
                          "status",
                          "progress",
                          "parent_backup_id",
                          "chain_id",
                          "chain_position",
                          "created_at",
                          "completed_at",
                          "error_message",
                          "simulated"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "fixture_version": {
                      "type": "string"
                    },
                    "generated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "groups": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "group_type": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "member_count": {
                            "type": "integer"
                          },
                          "name": {
                            "type": "string"
                          },
                          "rules": {
                            "items": {
                              "additionalProperties": false,
                              "properties": {
                                "field": {
                                  "type": "string"
                                },
                                "op": {
                                  "type": "string"
                                },
                                "value": {
                                  "anyOf": [
                                    {
                                      "type": "string"
                                    },
                                    {
                                      "items": {
                                        "type": "string"
                                      },
                                      "type": "array"
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "field",
                                "op",
                                "value"
                              ],
                              "type": "object"
                            },
                            "type": "array"
                          },
                          "rules_match": {
                            "type": "string"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "vm_ids": {
                            "items": {
                              "type": "string"
                            },
                            "type": "array"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "group_type",
                          "simulated"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "persona": {
                      "additionalProperties": false,
                      "properties": {
                        "hands_on": {
                          "type": "string"
                        },
                        "msp_context": {
                          "type": "string"
                        },
                        "msp_message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "hands_on",
                        "msp_context",
                        "msp_message"
                      ],
                      "type": "object"
                    },
                    "restores": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "backup_id": {
                            "type": "string"
                          },
                          "completed_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "events": {
                            "items": {
                              "additionalProperties": false,
                              "properties": {
                                "environment": {
                                  "const": "demo",
                                  "type": "string"
                                },
                                "message": {
                                  "type": "string"
                                },
                                "progress": {
                                  "type": "integer"
                                },
                                "simulated": {
                                  "const": true,
                                  "type": "boolean"
                                },
                                "stage": {
                                  "type": "string"
                                },
                                "status": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "status",
                                "progress",
                                "stage",
                                "message",
                                "simulated",
                                "environment"
                              ],
                              "type": "object"
                            },
                            "type": "array"
                          },
                          "id": {
                            "type": "string"
                          },
                          "message": {
                            "type": "string"
                          },
                          "progress": {
                            "type": "integer"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "status": {
                            "type": "string"
                          },
                          "target_vm_id": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "backup_id",
                          "target_vm_id",
                          "status",
                          "progress",
                          "created_at",
                          "completed_at",
                          "simulated"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "schedules": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "backup_type": {
                            "type": "string"
                          },
                          "cron_expression": {
                            "type": "string"
                          },
                          "enabled": {
                            "type": "boolean"
                          },
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "retention_days": {
                            "type": "integer"
                          },
                          "simulated": {
                            "const": true,
                            "type": "boolean"
                          },
                          "vm_group_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "cron_expression",
                          "retention_days",
                          "backup_type",
                          "enabled",
                          "simulated"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    },
                    "vms": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_id": {
                            "type": "string"
                          },
                          "disks": {
                            "items": {
                              "additionalProperties": false,
                              "properties": {
                                "format": {
                                  "type": "string"
                                },
                                "size_bytes": {
                                  "type": "integer"
                                },
                                "source": {
                                  "type": "string"
                                },
                                "target": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "target",
                                "format",
                                "size_bytes",
                                "source"
                              ],
                              "type": "object"
                            },
                            "type": "array"
                          },
                          "id": {
                            "type": "string"
                          },
                          "memory_kb": {
                            "type": "integer"
                          },
                          "metadata": {
                            "additionalProperties": false,
                            "properties": {
                              "environment": {
                                "type": "string"
                              },
                              "simulated": {
                                "const": true,
                                "type": "boolean"
                              },
                              "supports_incremental": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "environment",
                              "supports_incremental",
                              "simulated"
                            ],
                            "type": "object"
                          },
                          "name": {
                            "type": "string"
                          },
                          "state": {
                            "type": "string"
                          },
                          "uuid": {
                            "type": "string"
                          },
                          "vcpu_count": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "id",
                          "uuid",
                          "name",
                          "agent_id",
                          "state",
                          "memory_kb",
                          "vcpu_count",
                          "disks",
                          "metadata"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "fixture_version",
                    "generated_at",
                    "environment",
                    "simulated",
                    "persona",
                    "agents",
                    "vms",
                    "groups",
                    "schedules",
                    "backups",
                    "restores",
                    "activity"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/demo.py:77",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/demo.py:55"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "429": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_RATE_LIMITED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: per-source/session window limit reached",
            "headers": {
              "Retry-After": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: per-source/session window limit reached"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware._demo_rate_limits; demo/limits.py:DemoRateLimiter.check"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "DemoSession": []
          }
        ],
        "summary": "Get State",
        "tags": [
          "demo"
        ],
        "x-credential-domain": "synthetic-demo-session"
      }
    },
    "/api/v1/encryption/keys": {
      "get": {
        "description": "List all encryption keys (metadata only, never key material)",
        "operationId": "list_keys_api_v1_encryption_keys_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "algorithm": {
                            "type": "string"
                          },
                          "backed_up": {
                            "type": "boolean"
                          },
                          "backed_up_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "backed_up_locations": {
                            "items": {
                              "type": "string"
                            },
                            "type": "array"
                          },
                          "backup_count": {
                            "type": "integer"
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "key_hash": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "provider": {
                            "type": "string"
                          },
                          "replaced_by_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "rotated_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "algorithm",
                          "key_hash",
                          "status",
                          "provider",
                          "created_at",
                          "created_by",
                          "rotated_at",
                          "replaced_by_id",
                          "backed_up",
                          "backed_up_at",
                          "backed_up_locations",
                          "backup_count"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:130 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Keys",
        "tags": [
          "encryption"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "provider-defined; local created_at descending",
          "pagination": "unpaginated",
          "snapshot": false
        },
        "x-required-roles": [
          "admin"
        ]
      },
      "post": {
        "description": "Create a local KEK and its nonsecret admission receipt atomically.",
        "operationId": "create_key_api_v1_encryption_keys_post",
        "parameters": [
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateKeyRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "algorithm": {
                      "type": "string"
                    },
                    "backed_up": {
                      "type": "boolean"
                    },
                    "backed_up_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "backed_up_locations": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "backup_count": {
                      "type": "integer"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_by": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "key_hash": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "provider": {
                      "type": "string"
                    },
                    "replaced_by_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "request_id": {
                      "format": "uuid",
                      "type": "string"
                    },
                    "rotated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "algorithm",
                    "key_hash",
                    "status",
                    "provider",
                    "created_at",
                    "created_by",
                    "rotated_at",
                    "replaced_by_id",
                    "backed_up",
                    "backed_up_at",
                    "backed_up_locations",
                    "backup_count",
                    "request_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Invalid domain request.",
            "x-error-sources": [
              "backend/routers/encryption.py:111"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:99 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Authorized resource unavailable."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "provider_admission_contract_unavailable",
                              "type": "string"
                            }
                          },
                          "required": [
                            "code"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract.",
            "x-error-sources": [
              "backend/routers/encryption.py:102"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit."
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Key",
        "tags": [
          "encryption"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-credential-domain": "user-session",
        "x-operator-action": "encryption.create",
        "x-required-roles": [
          "admin"
        ]
      }
    },
    "/api/v1/encryption/keys/confirm-export": {
      "post": {
        "description": "Verify a saved encrypted export and record the admin's custody attestation.",
        "operationId": "confirm_export_custody_api_v1_encryption_keys_confirm_export_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_confirm_export_custody_api_v1_encryption_keys_confirm_export_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "key_ids": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "location": {
                      "type": "string"
                    },
                    "sha256": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "key_ids",
                    "sha256",
                    "location"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/encryption.py:306",
              "backend/routers/encryption.py:315"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:303 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/encryption.py:311"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Confirm Export Custody",
        "tags": [
          "encryption"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ],
        "x-response-source": "routers/encryption.py:confirm_export_custody"
      }
    },
    "/api/v1/encryption/keys/export": {
      "post": {
        "description": "Export keys as password-protected file (local provider only)",
        "operationId": "export_keys_api_v1_encryption_keys_export_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ExportKeysRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/octet-stream": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            },
            "description": "Binary attachment. Saving the response does not confirm independent encryption-key backup custody.",
            "headers": {
              "Content-Disposition": {
                "description": "Attachment filename.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/encryption.py:232",
              "backend/routers/encryption.py:254"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:228 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Export Keys",
        "tags": [
          "encryption"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ]
      }
    },
    "/api/v1/encryption/keys/import": {
      "post": {
        "description": "Import keys from password-protected export file",
        "operationId": "import_keys_api_v1_encryption_keys_import_post",
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "$ref": "#/components/schemas/Body_import_keys_api_v1_encryption_keys_import_post"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "count": {
                      "type": "integer"
                    },
                    "imported_key_ids": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "imported_key_ids",
                    "count"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/encryption.py:269",
              "backend/routers/encryption.py:274",
              "backend/routers/encryption.py:291"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:265 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Import Keys",
        "tags": [
          "encryption"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ],
        "x-response-source": "routers/encryption.py:import_keys"
      }
    },
    "/api/v1/encryption/keys/{key_id}": {
      "get": {
        "description": "Get encryption key details + backup count",
        "operationId": "get_key_api_v1_encryption_keys__key_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "key_id",
            "required": true,
            "schema": {
              "title": "Key Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EncryptionKeyMetadata"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:148 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/encryption.py:156"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Key",
        "tags": [
          "encryption"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ],
        "x-response-source": "routers/encryption.py:_key_to_response"
      }
    },
    "/api/v1/encryption/keys/{key_id}/revoke": {
      "post": {
        "description": "Revoke a key (soft delete). Fails if backups still reference it.",
        "operationId": "revoke_key_api_v1_encryption_keys__key_id__revoke_post",
        "parameters": [
          {
            "in": "path",
            "name": "key_id",
            "required": true,
            "schema": {
              "title": "Key Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "key_id": {
                      "type": "string"
                    },
                    "status": {
                      "const": "revoked"
                    }
                  },
                  "required": [
                    "status",
                    "key_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/encryption.py:218"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:208 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Revoke Key",
        "tags": [
          "encryption"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ],
        "x-response-source": "routers/encryption.py:revoke_key"
      }
    },
    "/api/v1/encryption/keys/{key_id}/rotate": {
      "post": {
        "description": "Replay names the same successor; a new request for a stale key conflicts.",
        "operationId": "rotate_key_api_v1_encryption_keys__key_id__rotate_post",
        "parameters": [
          {
            "in": "path",
            "name": "key_id",
            "required": true,
            "schema": {
              "title": "Key Id",
              "type": "string"
            }
          },
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RotateKeyRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "algorithm": {
                      "type": "string"
                    },
                    "backed_up": {
                      "type": "boolean"
                    },
                    "backed_up_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "backed_up_locations": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "backup_count": {
                      "type": "integer"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_by": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "key_hash": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "provider": {
                      "type": "string"
                    },
                    "replaced_by_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "request_id": {
                      "format": "uuid",
                      "type": "string"
                    },
                    "rotated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "algorithm",
                    "key_hash",
                    "status",
                    "provider",
                    "created_at",
                    "created_by",
                    "rotated_at",
                    "replaced_by_id",
                    "backed_up",
                    "backed_up_at",
                    "backed_up_locations",
                    "backup_count",
                    "request_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Invalid domain request.",
            "x-error-sources": [
              "backend/routers/encryption.py:188"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:168 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Authorized resource unavailable."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "provider_admission_contract_unavailable",
                              "type": "string"
                            }
                          },
                          "required": [
                            "code"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "stale_key_predecessor",
                              "type": "string"
                            }
                          },
                          "required": [
                            "code"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract.",
            "x-error-sources": [
              "backend/routers/encryption.py:171",
              "backend/routers/encryption.py:186"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit."
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Rotate Key",
        "tags": [
          "encryption"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-credential-domain": "user-session",
        "x-operator-action": "encryption.rotate",
        "x-required-roles": [
          "admin"
        ]
      }
    },
    "/api/v1/encryption/provider": {
      "get": {
        "description": "Get current KMS provider info",
        "operationId": "get_provider_info_api_v1_encryption_provider_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "active_key": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/EncryptionKeyMetadata"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "error": {
                      "type": "string"
                    },
                    "keys_not_backed_up": {
                      "type": "integer"
                    },
                    "provider": {
                      "const": "local"
                    },
                    "supports_export": {
                      "type": "boolean"
                    },
                    "total_keys": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "provider",
                    "supports_export",
                    "active_key",
                    "total_keys",
                    "keys_not_backed_up"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/encryption.py:334 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Provider Info",
        "tags": [
          "encryption"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ],
        "x-response-source": "routers/encryption.py:get_provider_info"
      }
    },
    "/api/v1/features": {
      "get": {
        "description": "Report configured versus successfully loaded installed capabilities.\n\nCertificates are advisory and never select these flags.",
        "operationId": "get_features_api_v1_features_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "configured_modules": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "edition": {
                      "type": "string"
                    },
                    "features": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "flags": {
                      "additionalProperties": false,
                      "properties": {
                        "advanced_rbac": {
                          "type": "boolean"
                        },
                        "billing_api": {
                          "type": "boolean"
                        },
                        "client_encryption": {
                          "type": "boolean"
                        },
                        "compliance_reports": {
                          "type": "boolean"
                        },
                        "multi_tenancy": {
                          "type": "boolean"
                        },
                        "white_labeling": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "multi_tenancy",
                        "white_labeling",
                        "billing_api",
                        "advanced_rbac",
                        "compliance_reports",
                        "client_encryption"
                      ],
                      "type": "object"
                    },
                    "installed_profile": {
                      "$ref": "#/components/schemas/ProtocolInstalledProfile"
                    },
                    "license_enforcement": {
                      "const": "advisory",
                      "type": "string"
                    },
                    "loaded_modules": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "tier": {
                      "enum": [
                        "oss",
                        "commercial"
                      ]
                    },
                    "tier_source": {
                      "const": "installed_distribution",
                      "type": "string"
                    }
                  },
                  "required": [
                    "tier",
                    "tier_source",
                    "installed_profile",
                    "license_enforcement",
                    "edition",
                    "features",
                    "configured_modules",
                    "loaded_modules",
                    "flags"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Get Features",
        "tags": [
          "public"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/groups": {
      "get": {
        "description": "List all VM groups with pagination",
        "operationId": "list_groups_api_v1_groups_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "search",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Search"
            }
          },
          {
            "in": "query",
            "name": "group_type",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Group Type"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "has_more": {
                      "type": "boolean"
                    },
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "description": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "group_type": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "tags": {
                            "items": {
                              "type": "string"
                            },
                            "type": "array"
                          },
                          "vm_count": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "description",
                          "tags",
                          "group_type",
                          "vm_count",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit",
                    "has_more"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Groups",
        "tags": [
          "groups"
        ],
        "x-credential-domain": "user-session"
      },
      "post": {
        "description": "Create a new VM group (operator or admin only)",
        "operationId": "create_group_api_v1_groups_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VMGroupCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "description": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "group_type": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "tags": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "vm_count": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "description",
                    "tags",
                    "group_type",
                    "vm_count",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:88",
              "backend/routers/groups.py:102",
              "backend/routers/groups.py:97"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:82"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Group",
        "tags": [
          "groups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/groups/{group_id}": {
      "delete": {
        "description": "Delete a VM group (operator or admin only)",
        "operationId": "delete_group_api_v1_groups__group_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "group_id",
            "required": true,
            "schema": {
              "title": "Group Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "deleted_id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "deleted_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:245"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Group",
        "tags": [
          "groups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      },
      "get": {
        "description": "Get group details with paginated VM list",
        "operationId": "get_group_api_v1_groups__group_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "group_id",
            "required": true,
            "schema": {
              "title": "Group Id",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "title": "Limit",
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "description": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "group_type": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "rules": {
                      "anyOf": [
                        {
                          "items": {
                            "additionalProperties": true,
                            "properties": {
                              "field": {
                                "enum": [
                                  "name",
                                  "state",
                                  "agent_id"
                                ],
                                "type": "string"
                              },
                              "op": {
                                "enum": [
                                  "eq",
                                  "neq",
                                  "regex",
                                  "glob",
                                  "in"
                                ],
                                "type": "string"
                              },
                              "value": {
                                "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                                "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                              }
                            },
                            "required": [
                              "field",
                              "op",
                              "value"
                            ],
                            "type": "object",
                            "x-open-schema-reason": "Group validators inspect field/op/value and retain additional rule metadata."
                          },
                          "type": "array"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "rules_match": {
                      "enum": [
                        "all",
                        "any"
                      ],
                      "type": "string"
                    },
                    "tags": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "vms": {
                      "additionalProperties": false,
                      "properties": {
                        "has_more": {
                          "type": "boolean"
                        },
                        "items": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "agent_hostname": {
                                "type": "string"
                              },
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "state": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "state",
                              "agent_hostname"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "limit": {
                          "type": "integer"
                        },
                        "skip": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "items",
                        "total",
                        "skip",
                        "limit",
                        "has_more"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "description",
                    "tags",
                    "group_type",
                    "created_at",
                    "rules",
                    "rules_match",
                    "vms"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:136"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Group",
        "tags": [
          "groups"
        ],
        "x-credential-domain": "user-session"
      },
      "put": {
        "description": "Update group name, description, tags, type, and rules (operator or admin only)",
        "operationId": "update_group_api_v1_groups__group_id__put",
        "parameters": [
          {
            "in": "path",
            "name": "group_id",
            "required": true,
            "schema": {
              "title": "Group Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VMGroupUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "description": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "group_type": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "tags": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "vm_count": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "description",
                    "tags",
                    "group_type",
                    "vm_count",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:200",
              "backend/routers/groups.py:209",
              "backend/routers/groups.py:216"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:182"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:187"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Group",
        "tags": [
          "groups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/groups/{group_id}/preview": {
      "post": {
        "description": "Preview which VMs match given rules (without saving).",
        "operationId": "preview_group_rules_api_v1_groups__group_id__preview_post",
        "parameters": [
          {
            "in": "path",
            "name": "group_id",
            "required": true,
            "schema": {
              "title": "Group Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "rules": {
                    "items": {
                      "additionalProperties": true,
                      "properties": {
                        "field": {
                          "enum": [
                            "name",
                            "state",
                            "agent_id"
                          ],
                          "type": "string"
                        },
                        "op": {
                          "enum": [
                            "eq",
                            "neq",
                            "regex",
                            "glob",
                            "in"
                          ],
                          "type": "string"
                        },
                        "value": {
                          "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                          "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                        }
                      },
                      "required": [
                        "field",
                        "op",
                        "value"
                      ],
                      "type": "object",
                      "x-open-schema-reason": "Group validators inspect field/op/value and retain additional rule metadata."
                    },
                    "type": "array"
                  },
                  "rules_match": {
                    "description": "Only the value any selects OR; all other JSON values select AND in the preview handler.",
                    "x-open-schema-reason": "Only the value any selects OR; all other JSON values select AND in the preview handler."
                  }
                },
                "required": [
                  "rules"
                ],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "total": {
                      "type": "integer"
                    },
                    "truncated": {
                      "type": "boolean"
                    },
                    "vms": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_hostname": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "state": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "state",
                          "agent_hostname"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "vms",
                    "total",
                    "truncated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:363",
              "backend/routers/groups.py:367"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Preview Group Rules",
        "tags": [
          "groups"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/groups/{group_id}/vms": {
      "post": {
        "description": "Add VMs to a group (operator or admin only). Only for static/hybrid groups.",
        "operationId": "add_vms_to_group_api_v1_groups__group_id__vms_post",
        "parameters": [
          {
            "in": "path",
            "name": "group_id",
            "required": true,
            "schema": {
              "title": "Group Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VMGroupAddVMs"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "added": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "already_in_group": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "group_id": {
                      "type": "string"
                    },
                    "group_name": {
                      "type": "string"
                    },
                    "not_found": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "total_vms": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "group_id",
                    "group_name",
                    "added",
                    "already_in_group",
                    "not_found",
                    "total_vms"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:271"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:268"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Add Vms To Group",
        "tags": [
          "groups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/groups/{group_id}/vms/{vm_id}": {
      "delete": {
        "description": "Remove a VM from a group (operator or admin only)",
        "operationId": "remove_vm_from_group_api_v1_groups__group_id__vms__vm_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "group_id",
            "required": true,
            "schema": {
              "title": "Group Id",
              "type": "string"
            }
          },
          {
            "in": "path",
            "name": "vm_id",
            "required": true,
            "schema": {
              "title": "Vm Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "group_id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "vm_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "group_id",
                    "vm_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:323"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/groups.py:320",
              "backend/routers/groups.py:330",
              "backend/routers/groups.py:333"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Remove Vm From Group",
        "tags": [
          "groups"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/health": {
      "get": {
        "description": "Consolidated system health endpoint.\n\nReturns comprehensive health data for all system components. Use the `include`\nparameter to request specific sections only.\n\nArgs:\n    include: Comma-separated list of sections to include. Options:\n             database, agents, storage, s3, api, metrics, services.\n             If not specified, all sections are included.\n\nReturns:\n    Health data for requested sections.",
        "operationId": "get_health_api_v1_health_get",
        "parameters": [
          {
            "in": "query",
            "name": "include",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Include"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agents": {
                      "additionalProperties": false,
                      "properties": {
                        "degraded": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "issues": {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              "name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "name",
                              "issues"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "healthy": {
                          "type": "integer"
                        },
                        "online": {
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "status",
                        "total",
                        "online",
                        "healthy",
                        "degraded"
                      ],
                      "type": "object"
                    },
                    "api": {
                      "additionalProperties": false,
                      "properties": {
                        "status": {
                          "type": "string"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "status",
                        "version"
                      ],
                      "type": "object"
                    },
                    "database": {
                      "additionalProperties": false,
                      "properties": {
                        "connections": {
                          "type": "integer"
                        },
                        "max_connections": {
                          "type": "integer"
                        },
                        "response_time": {
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "status",
                        "response_time",
                        "connections",
                        "max_connections"
                      ],
                      "type": "object"
                    },
                    "metrics": {
                      "additionalProperties": false,
                      "properties": {
                        "active_backups": {
                          "type": "integer"
                        },
                        "failed_jobs_24h": {
                          "type": "integer"
                        },
                        "online_agents": {
                          "type": "integer"
                        },
                        "pending_jobs": {
                          "type": "integer"
                        },
                        "total_backups": {
                          "type": "integer"
                        },
                        "total_vms": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "active_backups",
                        "pending_jobs",
                        "failed_jobs_24h",
                        "online_agents",
                        "total_vms",
                        "total_backups"
                      ],
                      "type": "object"
                    },
                    "s3": {
                      "additionalProperties": false,
                      "properties": {
                        "bucket": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "configured": {
                          "type": "boolean"
                        },
                        "endpoint": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "error": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_check": {
                          "anyOf": [
                            {
                              "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "configured",
                        "status",
                        "endpoint",
                        "bucket",
                        "error",
                        "last_check"
                      ],
                      "type": "object"
                    },
                    "services": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "description",
                          "status"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "status": {
                      "type": "string"
                    },
                    "storage": {
                      "additionalProperties": false,
                      "properties": {
                        "backup_count": {
                          "type": "integer"
                        },
                        "note": {
                          "type": "string"
                        },
                        "status": {
                          "type": "string"
                        },
                        "used_space": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "status",
                        "used_space",
                        "backup_count",
                        "note"
                      ],
                      "type": "object"
                    },
                    "timestamp": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "status",
                    "timestamp"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Health",
        "tags": [
          "health"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/health/agents": {
      "get": {
        "description": "DEPRECATED: Use /api/v1/health instead. This endpoint will be removed in v4.0.",
        "operationId": "get_agent_health_deprecated_api_v1_health_agents_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agents": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "hostname": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "last_heartbeat": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "time_since_heartbeat_seconds": {
                            "type": "integer"
                          },
                          "vm_count": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "id",
                          "hostname",
                          "status",
                          "last_heartbeat",
                          "time_since_heartbeat_seconds",
                          "vm_count"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "summary": {
                      "additionalProperties": false,
                      "properties": {
                        "health_percentage": {
                          "type": "number"
                        },
                        "offline": {
                          "type": "integer"
                        },
                        "online": {
                          "type": "integer"
                        },
                        "total_agents": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total_agents",
                        "online",
                        "offline",
                        "health_percentage"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "summary",
                    "agents"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Agent Health Deprecated",
        "tags": [
          "health"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/health/agents/{agent_id}/heartbeat": {
      "post": {
        "description": "Agent heartbeat endpoint - requires agent API key authentication.\n\nCalled by agent every 30 seconds to report it's alive and send metrics.\n\nArgs:\n    agent_id: Agent ID from URL path\n    request: Request body with metrics\n    agent: Authenticated agent (from X-Agent-Key header)\n    db: Database session\n\nReturns:\n    dict: Status and timestamp",
        "operationId": "agent_heartbeat_api_v1_health_agents__agent_id__heartbeat_post",
        "parameters": [
          {
            "in": "path",
            "name": "agent_id",
            "required": true,
            "schema": {
              "title": "Agent Id",
              "type": "string"
            }
          },
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "active_backups": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "active_restores": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "backup_storage_free_bytes": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "backup_storage_path": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "backup_storage_total_bytes": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "capabilities": {
                    "additionalProperties": true,
                    "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                    "type": "object",
                    "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                  },
                  "cpu_cores": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "cpu_usage_percent": {
                    "anyOf": [
                      {
                        "type": "number"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "disk_usage_percent": {
                    "anyOf": [
                      {
                        "type": "number"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "events": {
                    "items": {
                      "additionalProperties": true,
                      "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                      "type": "object",
                      "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                    },
                    "type": "array"
                  },
                  "ip_address": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "libvirt_accessible": {
                    "anyOf": [
                      {
                        "type": "boolean"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "load_average_15m": {
                    "anyOf": [
                      {
                        "type": "number"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "memory_usage_percent": {
                    "anyOf": [
                      {
                        "type": "number"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "port": {
                    "anyOf": [
                      {
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "provider": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "provider_accessible": {
                    "anyOf": [
                      {
                        "type": "boolean"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "scope": {
                    "anyOf": [
                      {
                        "additionalProperties": true,
                        "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                        "type": "object",
                        "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "status": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "storage_measurement_error": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "storage_role": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "version": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [],
                "type": "object"
              }
            }
          },
          "description": "Legacy receiver treats malformed/empty JSON as an empty heartbeat; non-object JSON has no successful path. Extra fields are ignored. Provider events and capabilities are extensible observations, not publication authority.",
          "required": false
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agent_id": {
                      "type": "string"
                    },
                    "config": {
                      "additionalProperties": true,
                      "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                      "type": "object",
                      "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                    },
                    "s3_config": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "access_key": {
                              "type": "string"
                            },
                            "bucket": {
                              "type": "string"
                            },
                            "delete_local": {
                              "type": "boolean"
                            },
                            "enabled": {
                              "const": true,
                              "type": "boolean"
                            },
                            "endpoint": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "prefix": {
                              "type": "string"
                            },
                            "region": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "secret_key": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "enabled",
                            "endpoint",
                            "region",
                            "bucket",
                            "prefix",
                            "access_key",
                            "secret_key",
                            "delete_local"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "const": "ok",
                      "type": "string"
                    },
                    "timestamp": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "status",
                    "timestamp",
                    "agent_id",
                    "config",
                    "s3_config"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/health.py:903",
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Agent Heartbeat",
        "tags": [
          "health"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/health/backups": {
      "get": {
        "description": "DEPRECATED: Use /api/v1/health instead. This endpoint will be removed in v4.0.",
        "operationId": "get_backup_health_deprecated_api_v1_health_backups_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "health_metrics": {
                      "additionalProperties": false,
                      "properties": {
                        "avg_backup_size_bytes": {
                          "type": "integer"
                        },
                        "old_backups_past_retention": {
                          "type": "integer"
                        },
                        "recent_completions_24h": {
                          "type": "integer"
                        },
                        "recent_failures_24h": {
                          "type": "integer"
                        },
                        "success_rate_7d": {
                          "type": "number"
                        },
                        "total_storage_bytes": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "recent_failures_24h",
                        "recent_completions_24h",
                        "old_backups_past_retention",
                        "avg_backup_size_bytes",
                        "total_storage_bytes",
                        "success_rate_7d"
                      ],
                      "type": "object"
                    },
                    "health_status": {
                      "type": "string"
                    },
                    "recent_failures": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_at": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "error": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "vm_id": {
                            "type": "string"
                          },
                          "vm_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "vm_id",
                          "vm_name",
                          "error",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "summary": {
                      "additionalProperties": false,
                      "properties": {
                        "completed": {
                          "type": "integer"
                        },
                        "failed": {
                          "type": "integer"
                        },
                        "pending": {
                          "type": "integer"
                        },
                        "running": {
                          "type": "integer"
                        },
                        "total_backups": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total_backups",
                        "completed",
                        "failed",
                        "running",
                        "pending"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "summary",
                    "health_metrics",
                    "recent_failures",
                    "health_status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Backup Health Deprecated",
        "tags": [
          "health"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/health/detailed": {
      "get": {
        "description": "DEPRECATED: Use /api/v1/health instead. This endpoint will be removed in v4.0.",
        "operationId": "get_detailed_health_deprecated_api_v1_health_detailed_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "agents": {
                      "additionalProperties": false,
                      "properties": {
                        "degraded": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "issues": {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              "name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "name",
                              "issues"
                            ],
                            "type": "object"
                          },
                          "type": "array"
                        },
                        "healthy": {
                          "type": "integer"
                        },
                        "online": {
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "status",
                        "total",
                        "online",
                        "healthy",
                        "degraded"
                      ],
                      "type": "object"
                    },
                    "api": {
                      "additionalProperties": false,
                      "properties": {
                        "status": {
                          "type": "string"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "status",
                        "version"
                      ],
                      "type": "object"
                    },
                    "database": {
                      "additionalProperties": false,
                      "properties": {
                        "connections": {
                          "type": "integer"
                        },
                        "max_connections": {
                          "type": "integer"
                        },
                        "response_time": {
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "status",
                        "response_time",
                        "connections",
                        "max_connections"
                      ],
                      "type": "object"
                    },
                    "metrics": {
                      "additionalProperties": false,
                      "properties": {
                        "active_backups": {
                          "type": "integer"
                        },
                        "failed_jobs_24h": {
                          "type": "integer"
                        },
                        "online_agents": {
                          "type": "integer"
                        },
                        "pending_jobs": {
                          "type": "integer"
                        },
                        "total_backups": {
                          "type": "integer"
                        },
                        "total_vms": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "active_backups",
                        "pending_jobs",
                        "failed_jobs_24h",
                        "online_agents",
                        "total_vms",
                        "total_backups"
                      ],
                      "type": "object"
                    },
                    "s3": {
                      "additionalProperties": false,
                      "properties": {
                        "bucket": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "configured": {
                          "type": "boolean"
                        },
                        "endpoint": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "error": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "last_check": {
                          "anyOf": [
                            {
                              "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "configured",
                        "status",
                        "endpoint",
                        "bucket",
                        "error",
                        "last_check"
                      ],
                      "type": "object"
                    },
                    "services": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "description",
                          "status"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "status": {
                      "type": "string"
                    },
                    "storage": {
                      "additionalProperties": false,
                      "properties": {
                        "backup_count": {
                          "type": "integer"
                        },
                        "note": {
                          "type": "string"
                        },
                        "status": {
                          "type": "string"
                        },
                        "used_space": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "status",
                        "used_space",
                        "backup_count",
                        "note"
                      ],
                      "type": "object"
                    },
                    "timestamp": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "status",
                    "timestamp",
                    "database",
                    "agents",
                    "storage",
                    "s3",
                    "api",
                    "metrics",
                    "services"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Detailed Health Deprecated",
        "tags": [
          "health"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/health/diagnostics": {
      "get": {
        "description": "Admin-only, organization-scoped download; collection never repairs state.",
        "operationId": "support_diagnostics_api_v1_health_diagnostics_get",
        "parameters": [
          {
            "in": "query",
            "name": "backup_id",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "format": "uuid",
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Backup Id"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backend_version": {
                      "type": "string"
                    },
                    "collected_at": {
                      "type": "string"
                    },
                    "guidance": {
                      "additionalProperties": false,
                      "properties": {
                        "failed": {
                          "type": "string"
                        },
                        "held": {
                          "type": "string"
                        },
                        "unavailable": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "held",
                        "failed",
                        "unavailable"
                      ],
                      "type": "object"
                    },
                    "limits": {
                      "additionalProperties": false,
                      "properties": {
                        "query_timeout_ms": {
                          "type": "integer"
                        },
                        "rows_per_section": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "rows_per_section",
                        "query_timeout_ms"
                      ],
                      "type": "object"
                    },
                    "privacy": {
                      "type": "string"
                    },
                    "report_id": {
                      "type": "string"
                    },
                    "schema": {
                      "type": "string"
                    },
                    "scope": {
                      "type": "string"
                    },
                    "sections": {
                      "additionalProperties": false,
                      "properties": {
                        "agents": {
                          "oneOf": [
                            {
                              "additionalProperties": false,
                              "properties": {
                                "rows": {
                                  "items": {
                                    "additionalProperties": false,
                                    "properties": {
                                      "cert_expires_at": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "last_heartbeat": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "mtls_enabled": {
                                        "anyOf": [
                                          {
                                            "type": "boolean"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "status": {
                                        "type": "string"
                                      },
                                      "version": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "required": [
                                      "id",
                                      "status",
                                      "last_heartbeat",
                                      "cert_expires_at",
                                      "mtls_enabled",
                                      "version"
                                    ],
                                    "type": "object"
                                  },
                                  "type": "array"
                                },
                                "status": {
                                  "const": "observed",
                                  "type": "string"
                                },
                                "truncated": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "status",
                                "truncated",
                                "rows"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "reason": {
                                  "const": "collection_failed",
                                  "type": "string"
                                },
                                "status": {
                                  "const": "unavailable",
                                  "type": "string"
                                }
                              },
                              "required": [
                                "status",
                                "reason"
                              ],
                              "type": "object"
                            }
                          ]
                        },
                        "backups": {
                          "oneOf": [
                            {
                              "additionalProperties": false,
                              "properties": {
                                "rows": {
                                  "items": {
                                    "additionalProperties": false,
                                    "properties": {
                                      "backup_type": {
                                        "type": "string"
                                      },
                                      "capacity_state": {
                                        "type": "string"
                                      },
                                      "chain_position": {
                                        "anyOf": [
                                          {
                                            "type": "integer"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "completed_at": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "created_at": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "native_failure_evidence_present": {
                                        "anyOf": [
                                          {
                                            "type": "boolean"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "native_intent_present": {
                                        "anyOf": [
                                          {
                                            "type": "boolean"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "native_inventory_present": {
                                        "anyOf": [
                                          {
                                            "type": "boolean"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "parent_backup_id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "progress": {
                                        "anyOf": [
                                          {
                                            "type": "integer"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "status": {
                                        "type": "string"
                                      },
                                      "vm_id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "required": [
                                      "id",
                                      "vm_id",
                                      "parent_backup_id",
                                      "status",
                                      "capacity_state",
                                      "backup_type",
                                      "created_at",
                                      "completed_at",
                                      "native_intent_present",
                                      "native_inventory_present",
                                      "native_failure_evidence_present",
                                      "progress",
                                      "chain_position"
                                    ],
                                    "type": "object"
                                  },
                                  "type": "array"
                                },
                                "status": {
                                  "const": "observed",
                                  "type": "string"
                                },
                                "truncated": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "status",
                                "truncated",
                                "rows"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "reason": {
                                  "const": "collection_failed",
                                  "type": "string"
                                },
                                "status": {
                                  "const": "unavailable",
                                  "type": "string"
                                }
                              },
                              "required": [
                                "status",
                                "reason"
                              ],
                              "type": "object"
                            }
                          ]
                        },
                        "restores": {
                          "oneOf": [
                            {
                              "additionalProperties": false,
                              "properties": {
                                "rows": {
                                  "items": {
                                    "additionalProperties": false,
                                    "properties": {
                                      "backup_id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "completed_at": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "created_at": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "error_recorded": {
                                        "anyOf": [
                                          {
                                            "type": "boolean"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "progress": {
                                        "anyOf": [
                                          {
                                            "type": "integer"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "status": {
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "id",
                                      "backup_id",
                                      "status",
                                      "created_at",
                                      "completed_at",
                                      "error_recorded",
                                      "progress"
                                    ],
                                    "type": "object"
                                  },
                                  "type": "array"
                                },
                                "status": {
                                  "const": "observed",
                                  "type": "string"
                                },
                                "truncated": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "status",
                                "truncated",
                                "rows"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "reason": {
                                  "const": "collection_failed",
                                  "type": "string"
                                },
                                "status": {
                                  "const": "unavailable",
                                  "type": "string"
                                }
                              },
                              "required": [
                                "status",
                                "reason"
                              ],
                              "type": "object"
                            }
                          ]
                        },
                        "verifications": {
                          "oneOf": [
                            {
                              "additionalProperties": false,
                              "properties": {
                                "rows": {
                                  "items": {
                                    "additionalProperties": false,
                                    "properties": {
                                      "backup_id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "completed_at": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "created_at": {
                                        "anyOf": [
                                          {
                                            "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "status": {
                                        "type": "string"
                                      },
                                      "verification_cancel_requested": {
                                        "anyOf": [
                                          {
                                            "type": "boolean"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "verification_read_attempts": {
                                        "anyOf": [
                                          {
                                            "type": "integer"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "verification_read_limit": {
                                        "anyOf": [
                                          {
                                            "type": "integer"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "verification_worker_id": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "required": [
                                      "id",
                                      "backup_id",
                                      "verification_worker_id",
                                      "status",
                                      "created_at",
                                      "completed_at",
                                      "verification_cancel_requested",
                                      "verification_read_attempts",
                                      "verification_read_limit"
                                    ],
                                    "type": "object"
                                  },
                                  "type": "array"
                                },
                                "status": {
                                  "const": "observed",
                                  "type": "string"
                                },
                                "truncated": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "status",
                                "truncated",
                                "rows"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "reason": {
                                  "const": "collection_failed",
                                  "type": "string"
                                },
                                "status": {
                                  "const": "unavailable",
                                  "type": "string"
                                }
                              },
                              "required": [
                                "status",
                                "reason"
                              ],
                              "type": "object"
                            }
                          ]
                        }
                      },
                      "required": [
                        "agents",
                        "backups",
                        "restores",
                        "verifications"
                      ],
                      "type": "object"
                    },
                    "status": {
                      "enum": [
                        "collected",
                        "partial"
                      ]
                    }
                  },
                  "required": [
                    "schema",
                    "report_id",
                    "collected_at",
                    "backend_version",
                    "scope",
                    "privacy",
                    "limits",
                    "sections",
                    "guidance",
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Support Diagnostics",
        "tags": [
          "health"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/health/system": {
      "get": {
        "description": "DEPRECATED: Use /api/v1/health instead. This endpoint will be removed in v4.0.",
        "operationId": "get_system_health_deprecated_api_v1_health_system_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "activity": {
                      "additionalProperties": false,
                      "properties": {
                        "recent_actions_1h": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "recent_actions_1h"
                      ],
                      "type": "object"
                    },
                    "metrics": {
                      "additionalProperties": false,
                      "properties": {
                        "agents": {
                          "additionalProperties": false,
                          "properties": {
                            "offline": {
                              "type": "integer"
                            },
                            "online": {
                              "type": "integer"
                            },
                            "total": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "total",
                            "online",
                            "offline"
                          ],
                          "type": "object"
                        },
                        "backups": {
                          "additionalProperties": false,
                          "properties": {
                            "running": {
                              "type": "integer"
                            },
                            "total": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "total",
                            "running"
                          ],
                          "type": "object"
                        },
                        "schedules": {
                          "additionalProperties": false,
                          "properties": {
                            "active": {
                              "type": "integer"
                            },
                            "inactive": {
                              "type": "integer"
                            },
                            "total": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "total",
                            "active",
                            "inactive"
                          ],
                          "type": "object"
                        },
                        "storage": {
                          "additionalProperties": false,
                          "properties": {
                            "total_bytes": {
                              "type": "integer"
                            },
                            "total_gb": {
                              "type": "number"
                            }
                          },
                          "required": [
                            "total_bytes",
                            "total_gb"
                          ],
                          "type": "object"
                        },
                        "users": {
                          "additionalProperties": false,
                          "properties": {
                            "total": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "total"
                          ],
                          "type": "object"
                        },
                        "vms": {
                          "additionalProperties": false,
                          "properties": {
                            "total": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "total"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "agents",
                        "vms",
                        "backups",
                        "schedules",
                        "users",
                        "storage"
                      ],
                      "type": "object"
                    },
                    "status": {
                      "type": "string"
                    },
                    "timestamp": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "status",
                    "timestamp",
                    "metrics",
                    "activity"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get System Health Deprecated",
        "tags": [
          "health"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/license/info": {
      "get": {
        "description": "Legacy installed capability projection, independent of certificate status.\n\nThis endpoint does not validate a certificate or publish customer details.",
        "operationId": "get_license_info_api_v1_license_info_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "edition_name": {
                      "type": "string"
                    },
                    "features": {
                      "additionalProperties": false,
                      "properties": {
                        "advanced_rbac": {
                          "type": "boolean"
                        },
                        "billing_api": {
                          "type": "boolean"
                        },
                        "client_encryption": {
                          "type": "boolean"
                        },
                        "compliance_reports": {
                          "type": "boolean"
                        },
                        "dr_orchestration": {
                          "type": "boolean"
                        },
                        "hsm_support": {
                          "type": "boolean"
                        },
                        "ldap_auth": {
                          "type": "boolean"
                        },
                        "multi_tenancy": {
                          "type": "boolean"
                        },
                        "saml_auth": {
                          "type": "boolean"
                        },
                        "storage_tiering": {
                          "type": "boolean"
                        },
                        "vault_integration": {
                          "type": "boolean"
                        },
                        "white_labeling": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "multi_tenancy",
                        "white_labeling",
                        "billing_api",
                        "advanced_rbac",
                        "compliance_reports",
                        "client_encryption",
                        "vault_integration",
                        "ldap_auth",
                        "saml_auth",
                        "dr_orchestration",
                        "storage_tiering",
                        "hsm_support"
                      ],
                      "type": "object"
                    },
                    "installed_profile": {
                      "$ref": "#/components/schemas/ProtocolInstalledProfile"
                    },
                    "license_enforcement": {
                      "const": "advisory",
                      "type": "string"
                    },
                    "tier": {
                      "enum": [
                        "oss",
                        "commercial"
                      ]
                    },
                    "tier_source": {
                      "const": "installed_distribution",
                      "type": "string"
                    }
                  },
                  "required": [
                    "tier",
                    "tier_source",
                    "installed_profile",
                    "license_enforcement",
                    "edition_name",
                    "features"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Get License Info",
        "tags": [
          "public"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/licensing": {
      "get": {
        "operationId": "licensing_details_api_v1_licensing_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "acknowledgement": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "acknowledged_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "actor": {
                              "additionalProperties": false,
                              "properties": {
                                "kind": {
                                  "type": "string"
                                },
                                "label": {
                                  "type": "string"
                                },
                                "user_id": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "user_id",
                                "label",
                                "kind"
                              ],
                              "type": "object"
                            },
                            "notice_scope": {
                              "type": "string"
                            },
                            "policy_version": {
                              "type": "string"
                            },
                            "schema_version": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "schema_version",
                            "notice_scope",
                            "actor",
                            "acknowledged_at",
                            "policy_version"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "certificate": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "class": {
                              "enum": [
                                "free",
                                "paid"
                              ],
                              "type": "string"
                            },
                            "coverage": {
                              "additionalProperties": false,
                              "properties": {
                                "modules": {
                                  "items": {
                                    "type": "string"
                                  },
                                  "type": "array"
                                }
                              },
                              "required": [
                                "modules"
                              ],
                              "type": "object"
                            },
                            "customer_id": {
                              "type": "string"
                            },
                            "expires_at": {
                              "type": "string"
                            },
                            "installation_id": {
                              "type": "string"
                            },
                            "issued_at": {
                              "type": "string"
                            },
                            "license_id": {
                              "type": "string"
                            },
                            "not_before": {
                              "type": "string"
                            },
                            "policy_version": {
                              "type": "string"
                            },
                            "product": {
                              "const": "vesta",
                              "type": "string"
                            }
                          },
                          "required": [
                            "product",
                            "license_id",
                            "customer_id",
                            "class",
                            "issued_at",
                            "coverage"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "community_usage": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "inventoried_vms": {
                              "type": "integer"
                            },
                            "registered_agents": {
                              "type": "integer"
                            },
                            "schedule_version": {
                              "type": "string"
                            },
                            "successful_backups": {
                              "type": "integer"
                            },
                            "threshold_reached": {
                              "type": "boolean"
                            }
                          },
                          "required": [
                            "schedule_version",
                            "successful_backups",
                            "inventoried_vms",
                            "registered_agents",
                            "threshold_reached"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "installation_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "additionalProperties": false,
                      "properties": {
                        "acknowledged": {
                          "type": "boolean"
                        },
                        "can_manage": {
                          "type": "boolean"
                        },
                        "notice_required": {
                          "type": "boolean"
                        },
                        "notice_scope": {
                          "type": "string"
                        },
                        "policy": {
                          "additionalProperties": false,
                          "properties": {
                            "usage_rules_configured": {
                              "type": "boolean"
                            },
                            "version": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "version",
                            "usage_rules_configured"
                          ],
                          "type": "object"
                        },
                        "reason_code": {
                          "type": "string"
                        },
                        "registration_url": {
                          "type": "string"
                        },
                        "schema_version": {
                          "const": 1,
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "schema_version",
                        "status",
                        "reason_code",
                        "notice_required",
                        "acknowledged",
                        "can_manage",
                        "registration_url",
                        "notice_scope",
                        "policy"
                      ],
                      "type": "object"
                    },
                    "trust_store": {
                      "additionalProperties": false,
                      "properties": {
                        "fingerprints": {
                          "additionalProperties": {
                            "type": "string"
                          },
                          "description": "Trusted key IDs mapped to SHA-256 public-key fingerprints.",
                          "type": "object",
                          "x-open-schema-reason": "Trusted key IDs mapped to SHA-256 public-key fingerprints."
                        },
                        "key_ids": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        },
                        "state": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "state",
                        "key_ids",
                        "fingerprints"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "status",
                    "community_usage",
                    "certificate",
                    "installation_id",
                    "trust_store",
                    "acknowledgement"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "installation_authority_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "core/license_registration.py:334 _authorize",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "core/license_registration.py:38 RegistrationError default status; routers/licensing.py:62 _invoke"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Licensing Details",
        "tags": [
          "licensing"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/licensing/acknowledgement": {
      "delete": {
        "operationId": "clear_acknowledgement_api_v1_licensing_acknowledgement_delete",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "acknowledged": {
                      "type": "boolean"
                    },
                    "can_manage": {
                      "type": "boolean"
                    },
                    "notice_required": {
                      "type": "boolean"
                    },
                    "notice_scope": {
                      "type": "string"
                    },
                    "policy": {
                      "additionalProperties": false,
                      "properties": {
                        "usage_rules_configured": {
                          "type": "boolean"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "version",
                        "usage_rules_configured"
                      ],
                      "type": "object"
                    },
                    "reason_code": {
                      "type": "string"
                    },
                    "registration_url": {
                      "type": "string"
                    },
                    "schema_version": {
                      "const": 1,
                      "type": "integer"
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "schema_version",
                    "status",
                    "reason_code",
                    "notice_required",
                    "acknowledged",
                    "can_manage",
                    "registration_url",
                    "notice_scope",
                    "policy"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "installation_authority_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "core/license_registration.py:334 _authorize",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "core/license_registration.py:38 RegistrationError default status; routers/licensing.py:62 _invoke"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Clear Acknowledgement",
        "tags": [
          "licensing"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/licensing/acknowledgement/confirm": {
      "post": {
        "operationId": "confirm_acknowledgement_api_v1_licensing_acknowledgement_confirm_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "challenge": {
                    "maxLength": 128,
                    "minLength": 16,
                    "title": "Challenge",
                    "type": "string"
                  },
                  "confirm": {
                    "title": "Confirm",
                    "type": "boolean"
                  },
                  "phrase": {
                    "maxLength": 128,
                    "title": "Phrase",
                    "type": "string"
                  }
                },
                "required": [
                  "confirm",
                  "challenge",
                  "phrase"
                ],
                "title": "ConfirmRequest",
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "acknowledged": {
                      "type": "boolean"
                    },
                    "can_manage": {
                      "type": "boolean"
                    },
                    "notice_required": {
                      "type": "boolean"
                    },
                    "notice_scope": {
                      "type": "string"
                    },
                    "policy": {
                      "additionalProperties": false,
                      "properties": {
                        "usage_rules_configured": {
                          "type": "boolean"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "version",
                        "usage_rules_configured"
                      ],
                      "type": "object"
                    },
                    "reason_code": {
                      "type": "string"
                    },
                    "registration_url": {
                      "type": "string"
                    },
                    "schema_version": {
                      "const": 1,
                      "type": "integer"
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "schema_version",
                    "status",
                    "reason_code",
                    "notice_required",
                    "acknowledged",
                    "can_manage",
                    "registration_url",
                    "notice_scope",
                    "policy"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "installation_authority_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "core/license_registration.py:334 _authorize",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "request_too_large",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:76"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "invalid_request",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:88",
              "core/license_registration.py:38 RegistrationError default status; routers/licensing.py:62 _invoke"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Confirm Acknowledgement",
        "tags": [
          "licensing"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/licensing/acknowledgement/prepare": {
      "post": {
        "operationId": "prepare_acknowledgement_api_v1_licensing_acknowledgement_prepare_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "confirm": {
                    "title": "Confirm",
                    "type": "boolean"
                  }
                },
                "required": [
                  "confirm"
                ],
                "title": "PrepareRequest",
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "challenge": {
                      "type": "string"
                    },
                    "expected_phrase": {
                      "type": "string"
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "notice_scope": {
                      "type": "string"
                    },
                    "status": {
                      "additionalProperties": false,
                      "properties": {
                        "acknowledged": {
                          "type": "boolean"
                        },
                        "can_manage": {
                          "type": "boolean"
                        },
                        "notice_required": {
                          "type": "boolean"
                        },
                        "notice_scope": {
                          "type": "string"
                        },
                        "policy": {
                          "additionalProperties": false,
                          "properties": {
                            "usage_rules_configured": {
                              "type": "boolean"
                            },
                            "version": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "version",
                            "usage_rules_configured"
                          ],
                          "type": "object"
                        },
                        "reason_code": {
                          "type": "string"
                        },
                        "registration_url": {
                          "type": "string"
                        },
                        "schema_version": {
                          "const": 1,
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "schema_version",
                        "status",
                        "reason_code",
                        "notice_required",
                        "acknowledged",
                        "can_manage",
                        "registration_url",
                        "notice_scope",
                        "policy"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "challenge",
                    "expected_phrase",
                    "notice_scope",
                    "expires_at",
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "installation_authority_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "core/license_registration.py:334 _authorize",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "request_too_large",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:76"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "invalid_request",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:88",
              "core/license_registration.py:38 RegistrationError default status; routers/licensing.py:62 _invoke"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Prepare Acknowledgement",
        "tags": [
          "licensing"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/licensing/import": {
      "post": {
        "operationId": "import_registration_api_v1_licensing_import_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "envelope": {
                    "maxLength": 65536,
                    "title": "Envelope",
                    "type": "string"
                  }
                },
                "required": [
                  "envelope"
                ],
                "title": "ImportRequest",
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "acknowledgement": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "acknowledged_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "actor": {
                              "additionalProperties": false,
                              "properties": {
                                "kind": {
                                  "type": "string"
                                },
                                "label": {
                                  "type": "string"
                                },
                                "user_id": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "user_id",
                                "label",
                                "kind"
                              ],
                              "type": "object"
                            },
                            "notice_scope": {
                              "type": "string"
                            },
                            "policy_version": {
                              "type": "string"
                            },
                            "schema_version": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "schema_version",
                            "notice_scope",
                            "actor",
                            "acknowledged_at",
                            "policy_version"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "certificate": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "class": {
                              "enum": [
                                "free",
                                "paid"
                              ],
                              "type": "string"
                            },
                            "coverage": {
                              "additionalProperties": false,
                              "properties": {
                                "modules": {
                                  "items": {
                                    "type": "string"
                                  },
                                  "type": "array"
                                }
                              },
                              "required": [
                                "modules"
                              ],
                              "type": "object"
                            },
                            "customer_id": {
                              "type": "string"
                            },
                            "expires_at": {
                              "type": "string"
                            },
                            "installation_id": {
                              "type": "string"
                            },
                            "issued_at": {
                              "type": "string"
                            },
                            "license_id": {
                              "type": "string"
                            },
                            "not_before": {
                              "type": "string"
                            },
                            "policy_version": {
                              "type": "string"
                            },
                            "product": {
                              "const": "vesta",
                              "type": "string"
                            }
                          },
                          "required": [
                            "product",
                            "license_id",
                            "customer_id",
                            "class",
                            "issued_at",
                            "coverage"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "community_usage": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "inventoried_vms": {
                              "type": "integer"
                            },
                            "registered_agents": {
                              "type": "integer"
                            },
                            "schedule_version": {
                              "type": "string"
                            },
                            "successful_backups": {
                              "type": "integer"
                            },
                            "threshold_reached": {
                              "type": "boolean"
                            }
                          },
                          "required": [
                            "schedule_version",
                            "successful_backups",
                            "inventoried_vms",
                            "registered_agents",
                            "threshold_reached"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "installation_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "additionalProperties": false,
                      "properties": {
                        "acknowledged": {
                          "type": "boolean"
                        },
                        "can_manage": {
                          "type": "boolean"
                        },
                        "notice_required": {
                          "type": "boolean"
                        },
                        "notice_scope": {
                          "type": "string"
                        },
                        "policy": {
                          "additionalProperties": false,
                          "properties": {
                            "usage_rules_configured": {
                              "type": "boolean"
                            },
                            "version": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "version",
                            "usage_rules_configured"
                          ],
                          "type": "object"
                        },
                        "reason_code": {
                          "type": "string"
                        },
                        "registration_url": {
                          "type": "string"
                        },
                        "schema_version": {
                          "const": 1,
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "schema_version",
                        "status",
                        "reason_code",
                        "notice_required",
                        "acknowledged",
                        "can_manage",
                        "registration_url",
                        "notice_scope",
                        "policy"
                      ],
                      "type": "object"
                    },
                    "trust_store": {
                      "additionalProperties": false,
                      "properties": {
                        "fingerprints": {
                          "additionalProperties": {
                            "type": "string"
                          },
                          "description": "Trusted key IDs mapped to SHA-256 public-key fingerprints.",
                          "type": "object",
                          "x-open-schema-reason": "Trusted key IDs mapped to SHA-256 public-key fingerprints."
                        },
                        "key_ids": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        },
                        "state": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "state",
                        "key_ids",
                        "fingerprints"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "status",
                    "community_usage",
                    "certificate",
                    "installation_id",
                    "trust_store",
                    "acknowledgement"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "installation_authority_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "core/license_registration.py:334 _authorize",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "request_too_large",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:76"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "invalid_request",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:88",
              "core/license_registration.py:38 RegistrationError default status; routers/licensing.py:62 _invoke"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Import Registration",
        "tags": [
          "licensing"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/licensing/registration-url": {
      "put": {
        "operationId": "registration_url_api_v1_licensing_registration_url_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "properties": {
                  "url": {
                    "maxLength": 2048,
                    "title": "Url",
                    "type": "string"
                  }
                },
                "required": [
                  "url"
                ],
                "title": "RegistrationURLRequest",
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "acknowledgement": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "acknowledged_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "actor": {
                              "additionalProperties": false,
                              "properties": {
                                "kind": {
                                  "type": "string"
                                },
                                "label": {
                                  "type": "string"
                                },
                                "user_id": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "user_id",
                                "label",
                                "kind"
                              ],
                              "type": "object"
                            },
                            "notice_scope": {
                              "type": "string"
                            },
                            "policy_version": {
                              "type": "string"
                            },
                            "schema_version": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "schema_version",
                            "notice_scope",
                            "actor",
                            "acknowledged_at",
                            "policy_version"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "certificate": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "class": {
                              "enum": [
                                "free",
                                "paid"
                              ],
                              "type": "string"
                            },
                            "coverage": {
                              "additionalProperties": false,
                              "properties": {
                                "modules": {
                                  "items": {
                                    "type": "string"
                                  },
                                  "type": "array"
                                }
                              },
                              "required": [
                                "modules"
                              ],
                              "type": "object"
                            },
                            "customer_id": {
                              "type": "string"
                            },
                            "expires_at": {
                              "type": "string"
                            },
                            "installation_id": {
                              "type": "string"
                            },
                            "issued_at": {
                              "type": "string"
                            },
                            "license_id": {
                              "type": "string"
                            },
                            "not_before": {
                              "type": "string"
                            },
                            "policy_version": {
                              "type": "string"
                            },
                            "product": {
                              "const": "vesta",
                              "type": "string"
                            }
                          },
                          "required": [
                            "product",
                            "license_id",
                            "customer_id",
                            "class",
                            "issued_at",
                            "coverage"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "community_usage": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "inventoried_vms": {
                              "type": "integer"
                            },
                            "registered_agents": {
                              "type": "integer"
                            },
                            "schedule_version": {
                              "type": "string"
                            },
                            "successful_backups": {
                              "type": "integer"
                            },
                            "threshold_reached": {
                              "type": "boolean"
                            }
                          },
                          "required": [
                            "schedule_version",
                            "successful_backups",
                            "inventoried_vms",
                            "registered_agents",
                            "threshold_reached"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "installation_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "additionalProperties": false,
                      "properties": {
                        "acknowledged": {
                          "type": "boolean"
                        },
                        "can_manage": {
                          "type": "boolean"
                        },
                        "notice_required": {
                          "type": "boolean"
                        },
                        "notice_scope": {
                          "type": "string"
                        },
                        "policy": {
                          "additionalProperties": false,
                          "properties": {
                            "usage_rules_configured": {
                              "type": "boolean"
                            },
                            "version": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "version",
                            "usage_rules_configured"
                          ],
                          "type": "object"
                        },
                        "reason_code": {
                          "type": "string"
                        },
                        "registration_url": {
                          "type": "string"
                        },
                        "schema_version": {
                          "const": 1,
                          "type": "integer"
                        },
                        "status": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "schema_version",
                        "status",
                        "reason_code",
                        "notice_required",
                        "acknowledged",
                        "can_manage",
                        "registration_url",
                        "notice_scope",
                        "policy"
                      ],
                      "type": "object"
                    },
                    "trust_store": {
                      "additionalProperties": false,
                      "properties": {
                        "fingerprints": {
                          "additionalProperties": {
                            "type": "string"
                          },
                          "description": "Trusted key IDs mapped to SHA-256 public-key fingerprints.",
                          "type": "object",
                          "x-open-schema-reason": "Trusted key IDs mapped to SHA-256 public-key fingerprints."
                        },
                        "key_ids": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        },
                        "state": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "state",
                        "key_ids",
                        "fingerprints"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "status",
                    "community_usage",
                    "certificate",
                    "installation_id",
                    "trust_store",
                    "acknowledgement"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "installation_authority_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "core/license_registration.py:334 _authorize",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "request_too_large",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:76"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "invalid_request",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/licensing.py:88",
              "core/license_registration.py:38 RegistrationError default status; routers/licensing.py:62 _invoke"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Registration Url",
        "tags": [
          "licensing"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/licensing/status": {
      "get": {
        "operationId": "licensing_status_api_v1_licensing_status_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "acknowledged": {
                      "type": "boolean"
                    },
                    "can_manage": {
                      "type": "boolean"
                    },
                    "notice_required": {
                      "type": "boolean"
                    },
                    "notice_scope": {
                      "type": "string"
                    },
                    "policy": {
                      "additionalProperties": false,
                      "properties": {
                        "usage_rules_configured": {
                          "type": "boolean"
                        },
                        "version": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "version",
                        "usage_rules_configured"
                      ],
                      "type": "object"
                    },
                    "reason_code": {
                      "type": "string"
                    },
                    "registration_url": {
                      "type": "string"
                    },
                    "schema_version": {
                      "const": 1,
                      "type": "integer"
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "schema_version",
                    "status",
                    "reason_code",
                    "notice_required",
                    "acknowledged",
                    "can_manage",
                    "registration_url",
                    "notice_scope",
                    "policy"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "core/license_registration.py:38 RegistrationError default status; routers/licensing.py:62 _invoke"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Licensing Status",
        "tags": [
          "licensing"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications": {
      "get": {
        "description": "List notifications for the current user (from notification logs).",
        "operationId": "list_notifications_api_v1_notifications_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "title": "Limit",
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "notifications": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "message": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "read": {
                            "type": "boolean"
                          },
                          "status": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "title": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "type": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "type",
                          "title",
                          "message",
                          "status",
                          "read",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "notifications",
                    "total"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Notifications",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/logs": {
      "get": {
        "description": "List notification logs",
        "operationId": "list_notification_logs_api_v1_notifications_logs_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "title": "Limit",
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "event_type": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "recipient": {
                            "type": "string"
                          },
                          "rule_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "subject": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "rule_id",
                          "event_type",
                          "recipient",
                          "subject",
                          "status",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Notification Logs",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/mark-all-read": {
      "post": {
        "description": "Mark all notifications as read.",
        "operationId": "mark_all_notifications_read_api_v1_notifications_mark_all_read_post",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "status": {
                      "const": "ok",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Mark All Notifications Read",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/rules": {
      "get": {
        "description": "List notification rules",
        "operationId": "list_notification_rules_api_v1_notifications_rules_get",
        "parameters": [
          {
            "in": "query",
            "name": "event_type",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Event Type"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "items": {
                    "additionalProperties": false,
                    "properties": {
                      "created_at": {
                        "anyOf": [
                          {
                            "format": "date-time",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "enabled": {
                        "anyOf": [
                          {
                            "type": "boolean"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "event_type": {
                        "type": "string"
                      },
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "notification_type": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "recipients": {
                        "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                        "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                      }
                    },
                    "required": [
                      "id",
                      "name",
                      "event_type",
                      "enabled",
                      "recipients",
                      "created_at",
                      "notification_type"
                    ],
                    "type": "object"
                  },
                  "type": "array"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Notification Rules",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      },
      "post": {
        "description": "Create a notification rule",
        "operationId": "create_notification_rule_api_v1_notifications_rules_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "description": "Legacy dict input; database constraints apply after decoding.",
                "properties": {
                  "conditions": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "enabled": {
                    "anyOf": [
                      {
                        "type": "boolean"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "event_type": {
                    "type": "string"
                  },
                  "name": {
                    "type": "string"
                  },
                  "notification_type": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "recipients": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "template": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "anyOf": [
                        {
                          "type": "boolean"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "event_type": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "recipients": {
                      "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                      "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "event_type",
                    "enabled",
                    "recipients",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/notifications.py:25 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Notification Rule",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/rules/{rule_id}": {
      "delete": {
        "description": "Delete notification rule",
        "operationId": "delete_notification_rule_api_v1_notifications_rules__rule_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "rule_id",
            "required": true,
            "schema": {
              "title": "Rule Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/notifications.py:156 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/notifications.py:160"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Notification Rule",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      },
      "get": {
        "description": "Get notification rule details",
        "operationId": "get_notification_rule_api_v1_notifications_rules__rule_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "rule_id",
            "required": true,
            "schema": {
              "title": "Rule Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "conditions": {
                      "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                      "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "anyOf": [
                        {
                          "type": "boolean"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "event_type": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "notification_type": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "recipients": {
                      "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                      "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                    },
                    "template": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "event_type",
                    "enabled",
                    "recipients",
                    "created_at",
                    "notification_type",
                    "conditions",
                    "template"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/notifications.py:95"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Notification Rule",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      },
      "put": {
        "description": "Update notification rule",
        "operationId": "update_notification_rule_api_v1_notifications_rules__rule_id__put",
        "parameters": [
          {
            "in": "path",
            "name": "rule_id",
            "required": true,
            "schema": {
              "title": "Rule Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "description": "Legacy dict input; database constraints apply after decoding.",
                "properties": {
                  "conditions": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "enabled": {
                    "anyOf": [
                      {
                        "type": "boolean"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "event_type": {
                    "type": "string"
                  },
                  "name": {
                    "type": "string"
                  },
                  "notification_type": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "recipients": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "template": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/notifications.py:118 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/notifications.py:122"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Notification Rule",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/settings": {
      "get": {
        "description": "Get notification preferences for the current user.",
        "operationId": "get_notification_settings_api_v1_notifications_settings_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "settings": {
                      "additionalProperties": false,
                      "properties": {
                        "agent_offline": {
                          "type": "boolean"
                        },
                        "backup_failure": {
                          "type": "boolean"
                        },
                        "backup_success": {
                          "type": "boolean"
                        },
                        "email_enabled": {
                          "type": "boolean"
                        },
                        "storage_low": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "email_enabled",
                        "backup_success",
                        "backup_failure",
                        "agent_offline",
                        "storage_low"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "settings"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Notification Settings",
        "tags": [
          "notifications"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      },
      "put": {
        "description": "Update notification preferences.",
        "operationId": "update_notification_settings_api_v1_notifications_settings_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "description": "Known keys use JSON truthiness to store booleans.",
                "properties": {
                  "agent_offline": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "backup_failure": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "backup_success": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "email_enabled": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "storage_low": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "status": {
                      "const": "ok",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Notification Settings",
        "tags": [
          "notifications"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/test": {
      "post": {
        "description": "Send a test notification email (admin only).\n\nValidates SMTP configuration by sending a test email to the specified recipient.",
        "operationId": "test_notification_api_v1_notifications_test_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "description": "Recipient passed through to email helper; settings test defaults to current user email when omitted.",
                "properties": {
                  "recipient": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "recipient": {
                      "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                      "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                    }
                  },
                  "required": [
                    "message",
                    "recipient"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/notifications.py:227",
              "backend/routers/notifications.py:241",
              "backend/routers/notifications.py:243",
              "backend/routers/notifications.py:245"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "backend/routers/notifications.py:260",
              "backend/routers/notifications.py:279",
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Test Notification",
        "tags": [
          "notifications"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/{notification_id}": {
      "delete": {
        "description": "Delete a notification.",
        "operationId": "delete_notification_api_v1_notifications__notification_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "notification_id",
            "required": true,
            "schema": {
              "title": "Notification Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "status": {
                      "const": "ok",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/notifications.py:429"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Notification",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/notifications/{notification_id}/read": {
      "put": {
        "description": "Mark a notification as read.",
        "operationId": "mark_notification_read_api_v1_notifications__notification_id__read_put",
        "parameters": [
          {
            "in": "path",
            "name": "notification_id",
            "required": true,
            "schema": {
              "title": "Notification Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "status": {
                      "const": "ok",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/notifications.py:400"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Mark Notification Read",
        "tags": [
          "notifications"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/operator/capabilities": {
      "get": {
        "operationId": "operator_capabilities_api_v1_operator_capabilities_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "actions": {
                      "items": {
                        "enum": [
                          "backup.bulk_create",
                          "backup.close_unreserved",
                          "backup.create",
                          "credential.agent.rotate",
                          "credential.orchestrator.create",
                          "credential.registration.create",
                          "encryption.create",
                          "encryption.rotate",
                          "queue.create",
                          "restore.create"
                        ],
                        "type": "string"
                      },
                      "type": "array",
                      "uniqueItems": true
                    },
                    "agent_key_rotation": {
                      "const": "staged-candidate-activation"
                    },
                    "caller_identity_required_for_lost_reply_recovery": {
                      "const": true
                    },
                    "contract_version": {
                      "const": 1,
                      "type": "integer"
                    },
                    "encryption_admission_provider": {
                      "const": "local"
                    },
                    "external_effects": {
                      "const": "original-attempt-reconciliation"
                    },
                    "max_bulk_targets": {
                      "const": 200,
                      "type": "integer"
                    },
                    "polling_contract": {
                      "const": 2
                    },
                    "request_header": {
                      "const": "Idempotency-Key"
                    },
                    "request_identity": {
                      "const": "uuid"
                    },
                    "retention": {
                      "const": "permanent-no-reuse"
                    },
                    "scope": {
                      "const": "organization-and-original-principal"
                    },
                    "secret_replay": {
                      "const": false
                    }
                  },
                  "required": [
                    "contract_version",
                    "request_header",
                    "request_identity",
                    "caller_identity_required_for_lost_reply_recovery",
                    "scope",
                    "actions",
                    "encryption_admission_provider",
                    "retention",
                    "secret_replay",
                    "max_bulk_targets",
                    "agent_key_rotation",
                    "polling_contract",
                    "external_effects"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Authorized current state; the immutable receipt remains separate from current dispatch/resource state."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity."
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Operator Capabilities",
        "tags": [
          "operator-recovery"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/operator/requests/{request_id}": {
      "get": {
        "operationId": "operator_request_outcome_api_v1_operator_requests__request_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "request_id",
            "required": true,
            "schema": {
              "title": "Request Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "action": {
                      "enum": [
                        "backup.bulk_create",
                        "backup.close_unreserved",
                        "backup.create",
                        "credential.agent.rotate",
                        "credential.orchestrator.create",
                        "credential.registration.create",
                        "encryption.create",
                        "encryption.rotate",
                        "queue.create",
                        "restore.create"
                      ],
                      "type": "string"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "contract_version": {
                      "const": 1,
                      "type": "integer"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "current_resource": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "id": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "resource_present": {
                              "const": false,
                              "type": "boolean"
                            }
                          },
                          "required": [
                            "resource_present"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "activated_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "agent_id": {
                              "type": "string"
                            },
                            "created_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "expires_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "key_prefix": {
                              "type": "string"
                            },
                            "rotation_id": {
                              "type": "string"
                            },
                            "state": {
                              "enum": [
                                "pending",
                                "activated",
                                "cancelled",
                                "expired"
                              ],
                              "type": "string"
                            }
                          },
                          "required": [
                            "rotation_id",
                            "agent_id",
                            "state",
                            "key_prefix",
                            "created_at",
                            "expires_at",
                            "activated_at"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "enabled": {
                              "type": "boolean"
                            },
                            "expires_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "is_valid": {
                              "type": "boolean"
                            },
                            "resource_present": {
                              "const": true,
                              "type": "boolean"
                            }
                          },
                          "required": [
                            "id",
                            "resource_present",
                            "enabled",
                            "is_valid",
                            "expires_at"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "id": {
                              "type": "string"
                            },
                            "replaced_by_id": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "resource_present": {
                              "const": true,
                              "type": "boolean"
                            },
                            "status": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "resource_present",
                            "status",
                            "replaced_by_id"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "hold_reason": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "resource_present": {
                              "const": true,
                              "type": "boolean"
                            },
                            "started_backup_id": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "status": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "resource_present",
                            "status",
                            "hold_reason",
                            "started_backup_id"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "dispatches": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "kind": {
                            "enum": [
                              "backup",
                              "restore"
                            ],
                            "type": "string"
                          },
                          "reason": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "resource_id": {
                            "type": "string"
                          },
                          "resource_present": {
                            "type": "boolean"
                          },
                          "resource_status": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "state": {
                            "enum": [
                              "pending",
                              "dispatching",
                              "delivered",
                              "held"
                            ],
                            "type": "string"
                          }
                        },
                        "required": [
                          "kind",
                          "resource_id",
                          "state",
                          "reason",
                          "resource_status",
                          "resource_present"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "receipt": {
                      "anyOf": [
                        {
                          "discriminator": {
                            "propertyName": "status"
                          },
                          "oneOf": [
                            {
                              "additionalProperties": false,
                              "properties": {
                                "executor": {
                                  "enum": [
                                    "real",
                                    "mock"
                                  ],
                                  "type": "string"
                                },
                                "id": {
                                  "type": "string"
                                },
                                "message": {
                                  "type": "string"
                                },
                                "request_id": {
                                  "format": "uuid",
                                  "type": "string"
                                },
                                "status": {
                                  "const": "pending",
                                  "type": "string"
                                },
                                "vm_id": {
                                  "type": "string"
                                },
                                "vm_name": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "id",
                                "vm_id",
                                "vm_name",
                                "status",
                                "message",
                                "executor",
                                "request_id"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "message": {
                                  "type": "string"
                                },
                                "queue_id": {
                                  "type": "string"
                                },
                                "request_id": {
                                  "format": "uuid",
                                  "type": "string"
                                },
                                "status": {
                                  "const": "queued",
                                  "type": "string"
                                },
                                "vm_id": {
                                  "type": "string"
                                },
                                "vm_name": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "status",
                                "queue_id",
                                "vm_id",
                                "vm_name",
                                "message",
                                "request_id"
                              ],
                              "type": "object"
                            }
                          ]
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "hold_reason": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            },
                            "position": {
                              "type": "integer"
                            },
                            "priority": {
                              "type": "integer"
                            },
                            "queued_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "started_backup_id": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "status": {
                              "type": "string"
                            },
                            "vm_id": {
                              "type": "string"
                            },
                            "vm_name": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "vm_id",
                            "vm_name",
                            "position",
                            "priority",
                            "queued_at",
                            "status",
                            "hold_reason",
                            "started_backup_id",
                            "message",
                            "request_id"
                          ],
                          "type": "object"
                        },
                        {
                          "oneOf": [
                            {
                              "additionalProperties": false,
                              "properties": {
                                "backup_id": {
                                  "type": "string"
                                },
                                "created_at": {
                                  "anyOf": [
                                    {
                                      "format": "date-time",
                                      "type": "string"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "id": {
                                  "type": "string"
                                },
                                "message": {
                                  "type": "string"
                                },
                                "progress": {
                                  "type": "integer"
                                },
                                "request_id": {
                                  "format": "uuid",
                                  "type": "string"
                                },
                                "restore_to_original": {
                                  "type": "boolean"
                                },
                                "status": {
                                  "const": "pending",
                                  "type": "string"
                                },
                                "target_vm_id": {
                                  "anyOf": [
                                    {
                                      "type": "string"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "target_vm_name": {
                                  "anyOf": [
                                    {
                                      "type": "string"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "backup_id",
                                "status",
                                "progress",
                                "restore_to_original",
                                "target_vm_name",
                                "message",
                                "target_vm_id",
                                "created_at",
                                "request_id"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "backup_id": {
                                  "type": "string"
                                },
                                "id": {
                                  "type": "string"
                                },
                                "message": {
                                  "type": "string"
                                },
                                "native_target": {
                                  "additionalProperties": false,
                                  "description": "Accepted native target with its server-allocated fresh VM UUID.",
                                  "properties": {
                                    "disks": {
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 128,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "drop_excluded_disks": {
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 128,
                                      "minItems": 0,
                                      "type": "array"
                                    },
                                    "networks": {
                                      "items": {
                                        "additionalProperties": false,
                                        "properties": {
                                          "network": {
                                            "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                                            "type": "string"
                                          },
                                          "source_mac": {
                                            "pattern": "^(?:[0-9a-f]{2}:){5}[0-9a-f]{2}$",
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "source_mac",
                                          "network"
                                        ],
                                        "type": "object"
                                      },
                                      "maxItems": 128,
                                      "minItems": 0,
                                      "type": "array"
                                    },
                                    "vm_name": {
                                      "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                                      "type": "string"
                                    },
                                    "vm_uuid": {
                                      "format": "uuid",
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "vm_name",
                                    "disks",
                                    "drop_excluded_disks",
                                    "networks",
                                    "vm_uuid"
                                  ],
                                  "type": "object"
                                },
                                "progress": {
                                  "type": "integer"
                                },
                                "request_id": {
                                  "format": "uuid",
                                  "type": "string"
                                },
                                "restore_to_original": {
                                  "type": "boolean"
                                },
                                "status": {
                                  "const": "pending",
                                  "type": "string"
                                },
                                "target_vm_name": {
                                  "anyOf": [
                                    {
                                      "type": "string"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "backup_id",
                                "status",
                                "progress",
                                "restore_to_original",
                                "target_vm_name",
                                "message",
                                "native_target",
                                "request_id"
                              ],
                              "type": "object"
                            },
                            {
                              "additionalProperties": false,
                              "properties": {
                                "backup_id": {
                                  "type": "string"
                                },
                                "id": {
                                  "type": "string"
                                },
                                "kubevirt_target": {
                                  "additionalProperties": false,
                                  "description": "Fresh stopped target mapping for every protected source.volumes disk. Schema-2 known unprotected native participants are omitted from the new VM's volumes and disk devices after exact captured-identity validation. Unknown/duplicate/missing identities refuse work; schema 1 retains its unprotected-persistent-disk guard. Runtime checks fresh names against all native source PVCs, disk capacity and at most one pod network. Excluding boot/application dependencies does not promise guest or application recovery.",
                                  "properties": {
                                    "dependencies": {
                                      "additionalProperties": {
                                        "maxLength": 63,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                        "type": "string"
                                      },
                                      "propertyNames": {
                                        "pattern": "^(secret|configMap)/[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?$"
                                      },
                                      "type": "object"
                                    },
                                    "disks": {
                                      "items": {
                                        "additionalProperties": false,
                                        "properties": {
                                          "access_mode": {
                                            "enum": [
                                              "ReadWriteOnce",
                                              "ReadWriteMany"
                                            ]
                                          },
                                          "capacity_bytes": {
                                            "minimum": 1,
                                            "type": "integer"
                                          },
                                          "pvc_name": {
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "storage_class": {
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "volume_mode": {
                                            "enum": [
                                              "Filesystem",
                                              "Block"
                                            ]
                                          },
                                          "volume_name": {
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "volume_name",
                                          "pvc_name",
                                          "storage_class",
                                          "access_mode",
                                          "volume_mode",
                                          "capacity_bytes"
                                        ],
                                        "type": "object"
                                      },
                                      "maxItems": 32,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "namespace": {
                                      "maxLength": 63,
                                      "minLength": 1,
                                      "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                      "type": "string"
                                    },
                                    "networks": {
                                      "items": {
                                        "oneOf": [
                                          {
                                            "additionalProperties": false,
                                            "properties": {
                                              "name": {
                                                "maxLength": 63,
                                                "minLength": 1,
                                                "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                                "type": "string"
                                              },
                                              "network_name": {
                                                "const": ""
                                              },
                                              "type": {
                                                "const": "pod"
                                              }
                                            },
                                            "required": [
                                              "name",
                                              "type",
                                              "network_name"
                                            ],
                                            "type": "object"
                                          },
                                          {
                                            "additionalProperties": false,
                                            "properties": {
                                              "name": {
                                                "maxLength": 63,
                                                "minLength": 1,
                                                "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                                "type": "string"
                                              },
                                              "network_name": {
                                                "maxLength": 63,
                                                "minLength": 1,
                                                "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                                "type": "string"
                                              },
                                              "type": {
                                                "const": "multus"
                                              }
                                            },
                                            "required": [
                                              "name",
                                              "type",
                                              "network_name"
                                            ],
                                            "type": "object"
                                          }
                                        ]
                                      },
                                      "maxItems": 32,
                                      "minItems": 0,
                                      "type": "array"
                                    },
                                    "vm_name": {
                                      "maxLength": 63,
                                      "minLength": 1,
                                      "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "namespace",
                                    "vm_name",
                                    "disks",
                                    "networks",
                                    "dependencies"
                                  ],
                                  "type": "object"
                                },
                                "message": {
                                  "type": "string"
                                },
                                "progress": {
                                  "type": "integer"
                                },
                                "request_id": {
                                  "format": "uuid",
                                  "type": "string"
                                },
                                "restore_to_original": {
                                  "type": "boolean"
                                },
                                "status": {
                                  "const": "pending",
                                  "type": "string"
                                },
                                "target_vm_name": {
                                  "anyOf": [
                                    {
                                      "type": "string"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "backup_id",
                                "status",
                                "progress",
                                "restore_to_original",
                                "target_vm_name",
                                "message",
                                "kubevirt_target",
                                "request_id"
                              ],
                              "type": "object"
                            }
                          ]
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "details": {
                              "additionalProperties": false,
                              "properties": {
                                "created": {
                                  "items": {
                                    "additionalProperties": false,
                                    "properties": {
                                      "backup_id": {
                                        "type": "string"
                                      },
                                      "vm_id": {
                                        "type": "string"
                                      },
                                      "vm_name": {
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "backup_id",
                                      "vm_id",
                                      "vm_name"
                                    ],
                                    "type": "object"
                                  },
                                  "type": "array"
                                },
                                "failed": {
                                  "items": {
                                    "additionalProperties": false,
                                    "properties": {
                                      "reason": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "vm_id": {
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "vm_id",
                                      "reason"
                                    ],
                                    "type": "object"
                                  },
                                  "type": "array"
                                },
                                "skipped": {
                                  "items": {
                                    "additionalProperties": false,
                                    "properties": {
                                      "reason": {
                                        "anyOf": [
                                          {
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "vm_id": {
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "vm_id",
                                      "reason"
                                    ],
                                    "type": "object"
                                  },
                                  "type": "array"
                                }
                              },
                              "required": [
                                "created",
                                "skipped",
                                "failed"
                              ],
                              "type": "object"
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "summary": {
                              "additionalProperties": false,
                              "properties": {
                                "created": {
                                  "minimum": 0,
                                  "type": "integer"
                                },
                                "failed": {
                                  "minimum": 0,
                                  "type": "integer"
                                },
                                "skipped": {
                                  "minimum": 0,
                                  "type": "integer"
                                },
                                "total": {
                                  "minimum": 0,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "total",
                                "created",
                                "skipped",
                                "failed"
                              ],
                              "type": "object"
                            },
                            "targets": {
                              "items": {
                                "type": "string"
                              },
                              "maxItems": 200,
                              "minItems": 1,
                              "type": "array",
                              "uniqueItems": true
                            }
                          },
                          "required": [
                            "targets",
                            "summary",
                            "details",
                            "request_id"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "created_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "expires_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "key_prefix": {
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            },
                            "name": {
                              "type": "string"
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "secret_delivery": {
                              "const": "unavailable",
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "name",
                            "key_prefix",
                            "expires_at",
                            "created_at",
                            "message",
                            "request_id",
                            "secret_delivery"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "agent_hostname": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "created_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "expires_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "key_prefix": {
                              "type": "string"
                            },
                            "max_uses": {
                              "anyOf": [
                                {
                                  "type": "integer"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "message": {
                              "type": "string"
                            },
                            "name": {
                              "type": "string"
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "secret_delivery": {
                              "const": "unavailable",
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "name",
                            "key_prefix",
                            "expires_at",
                            "created_at",
                            "message",
                            "agent_hostname",
                            "max_uses",
                            "request_id",
                            "secret_delivery"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "activated_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "agent_id": {
                              "type": "string"
                            },
                            "created_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "expires_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "key_prefix": {
                              "type": "string"
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "rotation_id": {
                              "type": "string"
                            },
                            "secret_delivery": {
                              "const": "unavailable",
                              "type": "string"
                            },
                            "state": {
                              "enum": [
                                "pending",
                                "activated",
                                "cancelled",
                                "expired"
                              ],
                              "type": "string"
                            }
                          },
                          "required": [
                            "rotation_id",
                            "agent_id",
                            "state",
                            "key_prefix",
                            "created_at",
                            "expires_at",
                            "activated_at",
                            "request_id",
                            "secret_delivery"
                          ],
                          "type": "object"
                        },
                        {
                          "additionalProperties": false,
                          "properties": {
                            "algorithm": {
                              "type": "string"
                            },
                            "backed_up": {
                              "type": "boolean"
                            },
                            "backed_up_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "backed_up_locations": {
                              "items": {
                                "type": "string"
                              },
                              "type": "array"
                            },
                            "backup_count": {
                              "type": "integer"
                            },
                            "created_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "created_by": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "key_hash": {
                              "type": "string"
                            },
                            "name": {
                              "type": "string"
                            },
                            "provider": {
                              "type": "string"
                            },
                            "replaced_by_id": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "rotated_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "status": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "name",
                            "algorithm",
                            "key_hash",
                            "status",
                            "provider",
                            "created_at",
                            "created_by",
                            "rotated_at",
                            "replaced_by_id",
                            "backed_up",
                            "backed_up_at",
                            "backed_up_locations",
                            "backup_count",
                            "request_id"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "request_id": {
                      "format": "uuid",
                      "type": "string"
                    },
                    "response_status": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "retention": {
                      "const": "permanent-no-reuse",
                      "type": "string"
                    },
                    "secret_delivery": {
                      "enum": [
                        "unavailable",
                        "not_applicable"
                      ],
                      "type": "string"
                    },
                    "state": {
                      "enum": [
                        "admitted",
                        "unresolved"
                      ],
                      "type": "string"
                    }
                  },
                  "required": [
                    "request_id",
                    "action",
                    "contract_version",
                    "state",
                    "created_at",
                    "completed_at",
                    "response_status",
                    "receipt",
                    "secret_delivery",
                    "dispatches",
                    "current_resource",
                    "retention"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Authorized current state; the immutable receipt remains separate from current dispatch/resource state."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "request_not_found",
                              "type": "string"
                            },
                            "outcome": {
                              "const": "unknown",
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "outcome"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Unavailable authority/resource. Lookup 404 means unknown at observation time, not permission to submit another identity.",
            "x-error-sources": [
              "backend/routers/operator.py:78",
              "backend/routers/operator.py:64"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Operator Request Outcome",
        "tags": [
          "operator-recovery"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/orchestrator-keys": {
      "get": {
        "description": "List all orchestrator API keys (admin only)",
        "operationId": "list_orchestrator_keys_api_v1_orchestrator_keys_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "enabled": {
                            "type": "boolean"
                          },
                          "expires_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "is_expired": {
                            "type": "boolean"
                          },
                          "is_valid": {
                            "type": "boolean"
                          },
                          "key_prefix": {
                            "type": "string"
                          },
                          "last_used_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "key_prefix",
                          "expires_at",
                          "enabled",
                          "is_expired",
                          "is_valid",
                          "last_used_at",
                          "created_at",
                          "created_by"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Orchestrator Keys",
        "tags": [
          "api-keys"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending; equal timestamps have no specified tie order",
          "pagination": "unpaginated",
          "snapshot": false
        }
      },
      "post": {
        "description": "Create new orchestrator API key (admin only)",
        "operationId": "create_orchestrator_key_api_v1_orchestrator_keys_post",
        "parameters": [
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrchestratorAPIKeyCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "discriminator": {
                    "propertyName": "secret_delivery"
                  },
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "api_key": {
                          "description": "First response only. Permanently absent from replay and outcome lookup.",
                          "type": "string",
                          "writeOnly": true
                        },
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "expires_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "id": {
                          "type": "string"
                        },
                        "key_prefix": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "secret_delivery": {
                          "const": "one_time",
                          "type": "string"
                        },
                        "usage_snippet": {
                          "description": "First response only. Permanently absent from replay and outcome lookup.",
                          "type": "string",
                          "writeOnly": true
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "key_prefix",
                        "expires_at",
                        "created_at",
                        "message",
                        "request_id",
                        "secret_delivery",
                        "api_key",
                        "usage_snippet"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "expires_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "id": {
                          "type": "string"
                        },
                        "key_prefix": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "secret_delivery": {
                          "const": "unavailable",
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "key_prefix",
                        "expires_at",
                        "created_at",
                        "message",
                        "request_id",
                        "secret_delivery"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Invalid domain request."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Authorized resource unavailable."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract."
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit."
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Orchestrator Key",
        "tags": [
          "api-keys"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-operator-action": "credential.orchestrator.create"
      }
    },
    "/api/v1/orchestrator-keys/{key_id}": {
      "delete": {
        "description": "Delete orchestrator API key (admin only)",
        "operationId": "delete_orchestrator_key_api_v1_orchestrator_keys__key_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "key_id",
            "required": true,
            "schema": {
              "title": "Key Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/api_keys.py:179"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Orchestrator Key",
        "tags": [
          "api-keys"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/api_keys.py:delete_orchestrator_key"
      },
      "patch": {
        "description": "Update orchestrator API key (admin only)",
        "operationId": "update_orchestrator_key_api_v1_orchestrator_keys__key_id__patch",
        "parameters": [
          {
            "in": "path",
            "name": "key_id",
            "required": true,
            "schema": {
              "title": "Key Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrchestratorAPIKeyUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "enabled": {
                      "type": "boolean"
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "is_valid": {
                      "type": "boolean"
                    },
                    "key_prefix": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "key_prefix",
                    "expires_at",
                    "enabled",
                    "is_valid",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/api_keys.py:137"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Orchestrator Key",
        "tags": [
          "api-keys"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/api_keys.py:update_orchestrator_key"
      }
    },
    "/api/v1/pki/backend-cert": {
      "get": {
        "description": "Download backend client cert+key for OKD secret mounting (admin only).\n\nReturns JSON with cert and key PEM for manual deployment.",
        "operationId": "get_backend_cert_api_v1_pki_backend_cert_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "cert_pem": {
                      "type": "string"
                    },
                    "key_pem": {
                      "type": "string"
                    },
                    "usage": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "cert_pem",
                    "key_pem",
                    "usage"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/pki.py:95"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Backend Cert",
        "tags": [
          "pki"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/pki/ca": {
      "get": {
        "description": "Download CA certificate (public, no auth required for trust distribution).",
        "operationId": "get_ca_cert_api_v1_pki_ca_get",
        "responses": {
          "200": {
            "content": {
              "application/x-pem-file": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            },
            "description": "Successful response",
            "headers": {
              "Content-Disposition": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/pki.py:70"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Get Ca Cert",
        "tags": [
          "pki"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/pki/certificates": {
      "get": {
        "description": "List all issued certificates.",
        "operationId": "list_certificates_api_v1_pki_certificates_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_id": {
                            "type": "string"
                          },
                          "common_name": {
                            "type": "string"
                          },
                          "expires_at": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "expiring_soon": {
                            "anyOf": [
                              {
                                "type": "boolean"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "fingerprint": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "issued_at": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "revoked_at": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "serial_number": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "agent_id",
                          "serial_number",
                          "fingerprint",
                          "common_name",
                          "status",
                          "issued_at",
                          "expires_at",
                          "revoked_at",
                          "expiring_soon"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "items"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Certificates",
        "tags": [
          "pki"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/pki/certificates/{cert_id}/revoke": {
      "post": {
        "description": "Revoke an agent certificate.",
        "operationId": "revoke_certificate_api_v1_pki_certificates__cert_id__revoke_post",
        "parameters": [
          {
            "in": "path",
            "name": "cert_id",
            "required": true,
            "schema": {
              "title": "Cert Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/pki.py:188"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/pki.py:191"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Revoke Certificate",
        "tags": [
          "pki"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/pki/initialize": {
      "post": {
        "description": "Initialize the built-in CA (one-time operation).",
        "operationId": "initialize_ca_api_v1_pki_initialize_post",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "ca": {
                      "$ref": "#/components/schemas/ProtocolCA"
                    },
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "ca"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/pki.py:34"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Initialize Ca",
        "tags": [
          "pki"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/pki/renew": {
      "post": {
        "description": "Agent submits CSR for certificate renewal.",
        "operationId": "renew_certificate_api_v1_pki_renew_post",
        "parameters": [
          {
            "in": "header",
            "name": "X-Agent-Key",
            "required": false,
            "schema": {
              "title": "X-Agent-Key",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "csr": {
                    "minLength": 1,
                    "type": "string"
                  }
                },
                "required": [
                  "csr"
                ],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "cert_pem": {
                      "type": "string"
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "fingerprint": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "cert_pem",
                    "fingerprint",
                    "expires_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/pki.py:230",
              "backend/routers/pki.py:239"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
            "x-error-conditions": [
              "Missing/invalid agent or registration credential, or required verified TLS transport unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:_authenticate_agent/registration_database; core/callback_identity.py:authenticate_callback",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Agent identity or key is invalid, disabled, expired or no longer available",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Agent identity or key is invalid, disabled, expired or no longer available",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:_verify_agent_cert/_verify_agent_key",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/pki.py:234"
            ]
          }
        },
        "security": [
          {
            "AgentMTLS": []
          }
        ],
        "summary": "Renew Certificate",
        "tags": [
          "pki"
        ],
        "x-credential-domain": "agent",
        "x-transport-policy": "Only a certificate verified by TLS transport is proof. Forwarded fingerprint headers are not credentials. A verified certificate selects certificate authentication; API-key fallback is unavailable when it is present."
      }
    },
    "/api/v1/pki/status": {
      "get": {
        "description": "Get CA status and certificate statistics.",
        "operationId": "get_pki_status_api_v1_pki_status_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "ca": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/ProtocolCA"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "certificates": {
                      "additionalProperties": false,
                      "properties": {
                        "active": {
                          "type": "integer"
                        },
                        "expired": {
                          "type": "integer"
                        },
                        "revoked": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "active",
                        "expired",
                        "revoked"
                      ],
                      "type": "object"
                    },
                    "initialized": {
                      "type": "boolean"
                    },
                    "require_mtls": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "initialized",
                    "ca",
                    "certificates"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Pki Status",
        "tags": [
          "pki"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/registration-keys": {
      "get": {
        "description": "List all agent registration keys (admin only)",
        "operationId": "list_registration_keys_api_v1_registration_keys_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "agent_hostname": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "enabled": {
                            "type": "boolean"
                          },
                          "expires_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "is_expired": {
                            "type": "boolean"
                          },
                          "is_max_uses_reached": {
                            "type": "boolean"
                          },
                          "is_valid": {
                            "type": "boolean"
                          },
                          "key_prefix": {
                            "type": "string"
                          },
                          "last_used_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "max_uses": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "name": {
                            "type": "string"
                          },
                          "use_count": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "key_prefix",
                          "expires_at",
                          "enabled",
                          "is_expired",
                          "is_valid",
                          "last_used_at",
                          "created_at",
                          "created_by",
                          "agent_hostname",
                          "max_uses",
                          "use_count",
                          "is_max_uses_reached"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Registration Keys",
        "tags": [
          "api-keys"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending; equal timestamps have no specified tie order",
          "pagination": "unpaginated",
          "snapshot": false
        }
      },
      "post": {
        "description": "Create new agent registration key (admin only)",
        "operationId": "create_registration_key_api_v1_registration_keys_post",
        "parameters": [
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AgentRegistrationKeyCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "discriminator": {
                    "propertyName": "secret_delivery"
                  },
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "agent_hostname": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "api_key": {
                          "description": "First response only. Permanently absent from replay and outcome lookup.",
                          "type": "string",
                          "writeOnly": true
                        },
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "expires_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "id": {
                          "type": "string"
                        },
                        "key_prefix": {
                          "type": "string"
                        },
                        "max_uses": {
                          "anyOf": [
                            {
                              "type": "integer"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "message": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "secret_delivery": {
                          "const": "one_time",
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "key_prefix",
                        "expires_at",
                        "created_at",
                        "message",
                        "agent_hostname",
                        "max_uses",
                        "request_id",
                        "secret_delivery",
                        "api_key"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "agent_hostname": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "expires_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "id": {
                          "type": "string"
                        },
                        "key_prefix": {
                          "type": "string"
                        },
                        "max_uses": {
                          "anyOf": [
                            {
                              "type": "integer"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "message": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "secret_delivery": {
                          "const": "unavailable",
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "key_prefix",
                        "expires_at",
                        "created_at",
                        "message",
                        "agent_hostname",
                        "max_uses",
                        "request_id",
                        "secret_delivery"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Invalid domain request."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Authorized resource unavailable."
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract."
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit."
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Registration Key",
        "tags": [
          "api-keys"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-operator-action": "credential.registration.create"
      }
    },
    "/api/v1/registration-keys/{key_id}": {
      "delete": {
        "description": "Delete agent registration key (admin only)",
        "operationId": "delete_registration_key_api_v1_registration_keys__key_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "key_id",
            "required": true,
            "schema": {
              "title": "Key Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/api_keys.py:362"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Registration Key",
        "tags": [
          "api-keys"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/api_keys.py:delete_registration_key"
      },
      "patch": {
        "description": "Update agent registration key (admin only)",
        "operationId": "update_registration_key_api_v1_registration_keys__key_id__patch",
        "parameters": [
          {
            "in": "path",
            "name": "key_id",
            "required": true,
            "schema": {
              "title": "Key Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AgentRegistrationKeyUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "enabled": {
                      "type": "boolean"
                    },
                    "expires_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "is_valid": {
                      "type": "boolean"
                    },
                    "key_prefix": {
                      "type": "string"
                    },
                    "max_uses": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "message": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "use_count": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "key_prefix",
                    "expires_at",
                    "enabled",
                    "is_valid",
                    "message",
                    "max_uses",
                    "use_count"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/api_keys.py:309"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/api_keys.py:320"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Registration Key",
        "tags": [
          "api-keys"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/api_keys.py:update_registration_key"
      }
    },
    "/api/v1/report-executions/{execution_id}": {
      "get": {
        "description": "Get details of a specific report execution",
        "operationId": "get_report_execution_api_v1_report_executions__execution_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "execution_id",
            "required": true,
            "schema": {
              "title": "Execution Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "error_message": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "file_path": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "file_size_bytes": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "file_size_mb": {
                      "type": "number"
                    },
                    "id": {
                      "type": "string"
                    },
                    "report_id": {
                      "type": "string"
                    },
                    "report_name": {
                      "type": "string"
                    },
                    "started_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "status",
                    "file_path",
                    "file_size_bytes",
                    "file_size_mb",
                    "error_message",
                    "started_at",
                    "completed_at",
                    "created_at",
                    "report_id",
                    "report_name"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:444"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Report Execution",
        "tags": [
          "reports"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/report-executions/{execution_id}/download": {
      "get": {
        "description": "Download a generated report file",
        "operationId": "download_report_api_v1_report_executions__execution_id__download_get",
        "parameters": [
          {
            "in": "path",
            "name": "execution_id",
            "required": true,
            "schema": {
              "title": "Execution Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              },
              "application/octet-stream": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              },
              "application/pdf": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              },
              "text/csv": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              },
              "text/html": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            },
            "description": "Binary attachment. Saving the response does not confirm independent encryption-key backup custody.",
            "headers": {
              "Content-Disposition": {
                "description": "Attachment filename.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:482"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:479",
              "backend/routers/reports.py:512"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Download Report",
        "tags": [
          "reports"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/reports": {
      "get": {
        "description": "List all reports",
        "operationId": "list_reports_api_v1_reports_get",
        "parameters": [
          {
            "in": "query",
            "name": "report_type",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Report Type"
            }
          },
          {
            "in": "query",
            "name": "enabled",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Enabled"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "reports": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_by_user": {
                            "anyOf": [
                              {
                                "additionalProperties": false,
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "username": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "id",
                                  "username"
                                ],
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "enabled": {
                            "type": "boolean"
                          },
                          "filters": {
                            "anyOf": [
                              {
                                "additionalProperties": true,
                                "description": "Extensible domain metadata; keys are not a closed schema.",
                                "type": "object",
                                "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "format": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "last_run_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "name": {
                            "type": "string"
                          },
                          "next_run_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "recipients": {
                            "anyOf": [
                              {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "report_type": {
                            "type": "string"
                          },
                          "schedule": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "report_type",
                          "schedule",
                          "format",
                          "recipients",
                          "filters",
                          "enabled",
                          "last_run_at",
                          "next_run_at",
                          "created_at",
                          "created_by_user"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "reports",
                    "total"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Reports",
        "tags": [
          "reports"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending; equal timestamps have no specified tie order",
          "pagination": "unpaginated",
          "snapshot": false
        }
      },
      "post": {
        "description": "Create a new report configuration",
        "operationId": "create_report_api_v1_reports_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReportCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "type": "boolean"
                    },
                    "filters": {
                      "anyOf": [
                        {
                          "additionalProperties": true,
                          "description": "Extensible domain metadata; keys are not a closed schema.",
                          "type": "object",
                          "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "format": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "recipients": {
                      "anyOf": [
                        {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "report_type": {
                      "type": "string"
                    },
                    "schedule": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "report_type",
                    "schedule",
                    "format",
                    "recipients",
                    "filters",
                    "enabled",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:48",
              "backend/routers/reports.py:55"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Report",
        "tags": [
          "reports"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/reports/{report_id}": {
      "delete": {
        "description": "Delete a report configuration",
        "operationId": "delete_report_api_v1_reports__report_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "report_id",
            "required": true,
            "schema": {
              "title": "Report Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:259"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Report",
        "tags": [
          "reports"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      },
      "get": {
        "description": "Get a specific report configuration",
        "operationId": "get_report_api_v1_reports__report_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "report_id",
            "required": true,
            "schema": {
              "title": "Report Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_by_user": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "id": {
                              "type": "string"
                            },
                            "role": {
                              "type": "string"
                            },
                            "username": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "username",
                            "role"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "type": "boolean"
                    },
                    "filters": {
                      "anyOf": [
                        {
                          "additionalProperties": true,
                          "description": "Extensible domain metadata; keys are not a closed schema.",
                          "type": "object",
                          "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "format": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "last_execution": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "last_run_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "name": {
                      "type": "string"
                    },
                    "next_run_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "recipients": {
                      "anyOf": [
                        {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "report_type": {
                      "type": "string"
                    },
                    "schedule": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "updated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "report_type",
                    "schedule",
                    "format",
                    "recipients",
                    "filters",
                    "enabled",
                    "last_run_at",
                    "next_run_at",
                    "created_at",
                    "created_by_user",
                    "last_execution",
                    "updated_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:151"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Report",
        "tags": [
          "reports"
        ],
        "x-credential-domain": "user-session"
      },
      "put": {
        "description": "Update a report configuration",
        "operationId": "update_report_api_v1_reports__report_id__put",
        "parameters": [
          {
            "in": "path",
            "name": "report_id",
            "required": true,
            "schema": {
              "title": "Report Id",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "name",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Name"
            }
          },
          {
            "in": "query",
            "name": "schedule",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Schedule"
            }
          },
          {
            "in": "query",
            "name": "format",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Format"
            }
          },
          {
            "in": "query",
            "name": "enabled",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Enabled"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Body_update_report_api_v1_reports__report_id__put"
              }
            }
          }
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "enabled": {
                      "type": "boolean"
                    },
                    "filters": {
                      "anyOf": [
                        {
                          "additionalProperties": true,
                          "description": "Extensible domain metadata; keys are not a closed schema.",
                          "type": "object",
                          "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "format": {
                      "type": "string"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "recipients": {
                      "anyOf": [
                        {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "report_type": {
                      "type": "string"
                    },
                    "schedule": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "updated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "report_type",
                    "schedule",
                    "format",
                    "recipients",
                    "filters",
                    "enabled",
                    "updated_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:213"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:204"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Report",
        "tags": [
          "reports"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/reports/{report_id}/executions": {
      "get": {
        "description": "List execution history for a report",
        "operationId": "list_report_executions_api_v1_reports__report_id__executions_get",
        "parameters": [
          {
            "in": "path",
            "name": "report_id",
            "required": true,
            "schema": {
              "title": "Report Id",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 20,
              "maximum": 100,
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "offset",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Offset",
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "executions": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "completed_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "error_message": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "file_path": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "file_size_bytes": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "file_size_mb": {
                            "type": "number"
                          },
                          "id": {
                            "type": "string"
                          },
                          "started_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "status",
                          "file_path",
                          "file_size_bytes",
                          "file_size_mb",
                          "error_message",
                          "started_at",
                          "completed_at",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "offset": {
                      "type": "integer"
                    },
                    "report_id": {
                      "type": "string"
                    },
                    "report_name": {
                      "type": "string"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "executions",
                    "total",
                    "offset",
                    "limit",
                    "report_id",
                    "report_name"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:390"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Report Executions",
        "tags": [
          "reports"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending; equal timestamps have no specified tie order",
          "pagination": "offset",
          "snapshot": false
        }
      }
    },
    "/api/v1/reports/{report_id}/generate": {
      "post": {
        "description": "Generate a report immediately",
        "operationId": "generate_report_api_v1_reports__report_id__generate_post",
        "parameters": [
          {
            "in": "path",
            "name": "report_id",
            "required": true,
            "schema": {
              "title": "Report Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "error": {
                      "type": "string"
                    },
                    "execution_id": {
                      "type": "string"
                    },
                    "file_path": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "file_size_bytes": {
                      "type": "integer"
                    },
                    "file_size_mb": {
                      "type": "number"
                    },
                    "report_id": {
                      "type": "string"
                    },
                    "started_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "execution_id",
                    "report_id",
                    "status",
                    "file_path",
                    "started_at",
                    "completed_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/reports.py:292"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Generate Report",
        "tags": [
          "reports"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/restores": {
      "get": {
        "description": "Get list of restore operations",
        "operationId": "get_restores_api_v1_restores_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "description": "Clamped to 100 per page",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "description": "Clamped to 100 per page",
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "status",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Status"
            }
          },
          {
            "in": "query",
            "name": "backup_id",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Backup Id"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "backup": {
                            "additionalProperties": false,
                            "properties": {
                              "created_at": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "id": {
                                "type": "string"
                              },
                              "size_bytes": {
                                "anyOf": [
                                  {
                                    "type": "integer"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "vm_name",
                              "created_at",
                              "size_bytes"
                            ],
                            "type": "object"
                          },
                          "backup_id": {
                            "type": "string"
                          },
                          "completed_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_by_user": {
                            "additionalProperties": false,
                            "properties": {
                              "role": {
                                "type": "string"
                              },
                              "username": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "username",
                              "role"
                            ],
                            "type": "object"
                          },
                          "error_message": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "kubevirt_target": {
                            "anyOf": [
                              {
                                "$ref": "#/components/schemas/KubeVirtRestoreTarget"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "native_target": {
                            "anyOf": [
                              {
                                "$ref": "#/components/schemas/NativeRestoreTarget"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "operator_dispatch": {
                            "anyOf": [
                              {
                                "additionalProperties": false,
                                "properties": {
                                  "reason": {
                                    "anyOf": [
                                      {
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "request_id": {
                                    "format": "uuid",
                                    "type": "string"
                                  },
                                  "state": {
                                    "enum": [
                                      "pending",
                                      "dispatching",
                                      "delivered",
                                      "held"
                                    ],
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "state",
                                  "reason",
                                  "request_id"
                                ],
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "progress": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "restore_to_original": {
                            "type": "boolean"
                          },
                          "result": {
                            "anyOf": [
                              {
                                "oneOf": [
                                  {
                                    "$ref": "#/components/schemas/KubeVirtRestoreResult"
                                  },
                                  {
                                    "$ref": "#/components/schemas/NativeRestoreResult"
                                  }
                                ]
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "started_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "target_vm_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "target_vm_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "backup_id",
                          "status",
                          "progress",
                          "restore_to_original",
                          "target_vm_name",
                          "target_vm_id",
                          "created_by",
                          "created_at",
                          "started_at",
                          "completed_at",
                          "error_message",
                          "kubevirt_target",
                          "native_target",
                          "result",
                          "operator_dispatch"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Restores",
        "tags": [
          "restores"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending, id descending",
          "pagination": "offset",
          "snapshot": false
        }
      },
      "post": {
        "description": "Create a restore operation from a backup",
        "operationId": "create_restore_api_v1_restores_post",
        "parameters": [
          {
            "description": "Caller-supplied UUID identifying this intent permanently. Reuse only for the same original principal, organization, action and normalized input. Not HTTP X-Request-ID.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": false,
            "schema": {
              "format": "uuid",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RestoreCreateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "oneOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "backup_id": {
                          "type": "string"
                        },
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "id": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "progress": {
                          "type": "integer"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "restore_to_original": {
                          "type": "boolean"
                        },
                        "status": {
                          "const": "pending",
                          "type": "string"
                        },
                        "target_vm_id": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "target_vm_name": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "backup_id",
                        "status",
                        "progress",
                        "restore_to_original",
                        "target_vm_name",
                        "message",
                        "target_vm_id",
                        "created_at",
                        "request_id"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "backup_id": {
                          "type": "string"
                        },
                        "id": {
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        },
                        "native_target": {
                          "additionalProperties": false,
                          "description": "Accepted native target with its server-allocated fresh VM UUID.",
                          "properties": {
                            "disks": {
                              "items": {
                                "type": "string"
                              },
                              "maxItems": 128,
                              "minItems": 1,
                              "type": "array"
                            },
                            "drop_excluded_disks": {
                              "items": {
                                "type": "string"
                              },
                              "maxItems": 128,
                              "minItems": 0,
                              "type": "array"
                            },
                            "networks": {
                              "items": {
                                "additionalProperties": false,
                                "properties": {
                                  "network": {
                                    "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                                    "type": "string"
                                  },
                                  "source_mac": {
                                    "pattern": "^(?:[0-9a-f]{2}:){5}[0-9a-f]{2}$",
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "source_mac",
                                  "network"
                                ],
                                "type": "object"
                              },
                              "maxItems": 128,
                              "minItems": 0,
                              "type": "array"
                            },
                            "vm_name": {
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$",
                              "type": "string"
                            },
                            "vm_uuid": {
                              "format": "uuid",
                              "type": "string"
                            }
                          },
                          "required": [
                            "vm_name",
                            "disks",
                            "drop_excluded_disks",
                            "networks",
                            "vm_uuid"
                          ],
                          "type": "object"
                        },
                        "progress": {
                          "type": "integer"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "restore_to_original": {
                          "type": "boolean"
                        },
                        "status": {
                          "const": "pending",
                          "type": "string"
                        },
                        "target_vm_name": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "backup_id",
                        "status",
                        "progress",
                        "restore_to_original",
                        "target_vm_name",
                        "message",
                        "native_target",
                        "request_id"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "backup_id": {
                          "type": "string"
                        },
                        "id": {
                          "type": "string"
                        },
                        "kubevirt_target": {
                          "additionalProperties": false,
                          "description": "Fresh stopped target mapping for every protected source.volumes disk. Schema-2 known unprotected native participants are omitted from the new VM's volumes and disk devices after exact captured-identity validation. Unknown/duplicate/missing identities refuse work; schema 1 retains its unprotected-persistent-disk guard. Runtime checks fresh names against all native source PVCs, disk capacity and at most one pod network. Excluding boot/application dependencies does not promise guest or application recovery.",
                          "properties": {
                            "dependencies": {
                              "additionalProperties": {
                                "maxLength": 63,
                                "minLength": 1,
                                "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                "type": "string"
                              },
                              "propertyNames": {
                                "pattern": "^(secret|configMap)/[a-z0-9](?:[-a-z0-9]{0,61}[a-z0-9])?$"
                              },
                              "type": "object"
                            },
                            "disks": {
                              "items": {
                                "additionalProperties": false,
                                "properties": {
                                  "access_mode": {
                                    "enum": [
                                      "ReadWriteOnce",
                                      "ReadWriteMany"
                                    ]
                                  },
                                  "capacity_bytes": {
                                    "minimum": 1,
                                    "type": "integer"
                                  },
                                  "pvc_name": {
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                    "type": "string"
                                  },
                                  "storage_class": {
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                    "type": "string"
                                  },
                                  "volume_mode": {
                                    "enum": [
                                      "Filesystem",
                                      "Block"
                                    ]
                                  },
                                  "volume_name": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "volume_name",
                                  "pvc_name",
                                  "storage_class",
                                  "access_mode",
                                  "volume_mode",
                                  "capacity_bytes"
                                ],
                                "type": "object"
                              },
                              "maxItems": 32,
                              "minItems": 1,
                              "type": "array"
                            },
                            "namespace": {
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                              "type": "string"
                            },
                            "networks": {
                              "items": {
                                "oneOf": [
                                  {
                                    "additionalProperties": false,
                                    "properties": {
                                      "name": {
                                        "maxLength": 63,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                        "type": "string"
                                      },
                                      "network_name": {
                                        "const": ""
                                      },
                                      "type": {
                                        "const": "pod"
                                      }
                                    },
                                    "required": [
                                      "name",
                                      "type",
                                      "network_name"
                                    ],
                                    "type": "object"
                                  },
                                  {
                                    "additionalProperties": false,
                                    "properties": {
                                      "name": {
                                        "maxLength": 63,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                        "type": "string"
                                      },
                                      "network_name": {
                                        "maxLength": 63,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                                        "type": "string"
                                      },
                                      "type": {
                                        "const": "multus"
                                      }
                                    },
                                    "required": [
                                      "name",
                                      "type",
                                      "network_name"
                                    ],
                                    "type": "object"
                                  }
                                ]
                              },
                              "maxItems": 32,
                              "minItems": 0,
                              "type": "array"
                            },
                            "vm_name": {
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                              "type": "string"
                            }
                          },
                          "required": [
                            "namespace",
                            "vm_name",
                            "disks",
                            "networks",
                            "dependencies"
                          ],
                          "type": "object"
                        },
                        "message": {
                          "type": "string"
                        },
                        "progress": {
                          "type": "integer"
                        },
                        "request_id": {
                          "format": "uuid",
                          "type": "string"
                        },
                        "restore_to_original": {
                          "type": "boolean"
                        },
                        "status": {
                          "const": "pending",
                          "type": "string"
                        },
                        "target_vm_name": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "backup_id",
                        "status",
                        "progress",
                        "restore_to_original",
                        "target_vm_name",
                        "message",
                        "kubevirt_target",
                        "request_id"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Durable admission receipt; pending/queued is not proof of external execution or success. A replay returns the original nonsecret receipt.",
            "headers": {
              "Cache-Control": {
                "schema": {
                  "const": "no-store"
                }
              },
              "Idempotency-Key": {
                "schema": {
                  "format": "uuid",
                  "type": "string"
                }
              },
              "Idempotency-Replayed": {
                "schema": {
                  "enum": [
                    "true",
                    "false"
                  ],
                  "type": "string"
                }
              },
              "X-Request-ID": {
                "description": "Per-HTTP-request correlation, separate from durable admission identity.",
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Invalid domain request.",
            "x-error-sources": [
              "backend/routers/restores.py:64",
              "backend/routers/restores.py:86",
              "backend/routers/restores.py:95"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authentication unavailable.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Current action authority unavailable.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/restores.py:45 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Authorized resource unavailable.",
            "x-error-sources": [
              "backend/routers/restores.py:61"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Identity conflict, unresolved/retired outcome, pending agent rotation, stale KEK predecessor or unsupported provider contract.",
            "x-error-sources": [
              "backend/routers/restores.py:268",
              "backend/routers/restores.py:195"
            ]
          },
          "413": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Normalized intent exceeds admission limit."
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/OperatorAdmissionError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Malformed identity, request validation or bulk target limit.",
            "x-error-sources": [
              "backend/routers/restores.py:234",
              "backend/routers/restores.py:161"
            ]
          },
          "423": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Existing source or operation custody prevents admission."
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              },
              "text/plain": {
                "schema": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "const": "Internal Server Error",
                      "type": "string"
                    }
                  ]
                }
              }
            },
            "description": "Outcome may be unknown after a lost/failing commit response. Reconcile the same request identity.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OperatorAdmissionError"
                }
              }
            },
            "description": "Admission dependency unavailable."
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Restore",
        "tags": [
          "restores"
        ],
        "x-admission-contract": {
          "external_effects": "original-attempt-reconciliation",
          "identity_header": "Idempotency-Key",
          "legacy_header_omission": "Server allocates an identity; lost first responses cannot be correlated by the caller.",
          "reauthorization": "Current principal, organization and action authority are rechecked on replay and lookup.",
          "retention": "permanent-no-reuse",
          "scope": "organization-and-original-principal",
          "version": 1
        },
        "x-credential-domain": "user-session",
        "x-operator-action": "restore.create"
      }
    },
    "/api/v1/restores/{restore_id}": {
      "get": {
        "description": "Get restore operation details",
        "operationId": "get_restore_api_v1_restores__restore_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "restore_id",
            "required": true,
            "schema": {
              "title": "Restore Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup": {
                      "additionalProperties": false,
                      "properties": {
                        "created_at": {
                          "anyOf": [
                            {
                              "format": "date-time",
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "id": {
                          "type": "string"
                        },
                        "size_bytes": {
                          "anyOf": [
                            {
                              "type": "integer"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "status": {
                          "type": "string"
                        },
                        "vm_id": {
                          "type": "string"
                        },
                        "vm_name": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "vm_name",
                        "created_at",
                        "size_bytes",
                        "vm_id",
                        "status"
                      ],
                      "type": "object"
                    },
                    "backup_id": {
                      "type": "string"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_by": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_by_user": {
                      "additionalProperties": false,
                      "properties": {
                        "role": {
                          "type": "string"
                        },
                        "username": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "username",
                        "role"
                      ],
                      "type": "object"
                    },
                    "error_message": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "kubevirt_target": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/KubeVirtRestoreTarget"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "native_target": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/NativeRestoreTarget"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "operator_dispatch": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "reason": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "request_id": {
                              "format": "uuid",
                              "type": "string"
                            },
                            "state": {
                              "enum": [
                                "pending",
                                "dispatching",
                                "delivered",
                                "held"
                              ],
                              "type": "string"
                            }
                          },
                          "required": [
                            "state",
                            "reason",
                            "request_id"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "progress": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "restore_to_original": {
                      "type": "boolean"
                    },
                    "result": {
                      "anyOf": [
                        {
                          "oneOf": [
                            {
                              "$ref": "#/components/schemas/KubeVirtRestoreResult"
                            },
                            {
                              "$ref": "#/components/schemas/NativeRestoreResult"
                            }
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "started_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "target_vm": {
                      "additionalProperties": false,
                      "properties": {
                        "agent_hostname": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "id": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "state": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "state",
                        "agent_hostname"
                      ],
                      "type": "object"
                    },
                    "target_vm_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "target_vm_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "backup_id",
                    "status",
                    "progress",
                    "restore_to_original",
                    "target_vm_name",
                    "target_vm_id",
                    "created_by",
                    "created_at",
                    "started_at",
                    "completed_at",
                    "error_message",
                    "kubevirt_target",
                    "native_target",
                    "result",
                    "operator_dispatch"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/restores.py:373"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Restore",
        "tags": [
          "restores"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/restores/{restore_id}/cancel": {
      "patch": {
        "description": "Cancel a running restore operation",
        "operationId": "cancel_restore_api_v1_restores__restore_id__cancel_patch",
        "parameters": [
          {
            "in": "path",
            "name": "restore_id",
            "required": true,
            "schema": {
              "title": "Restore Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "restore_id": {
                      "type": "string"
                    },
                    "status": {
                      "const": "cancelled"
                    }
                  },
                  "required": [
                    "message",
                    "restore_id",
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/restores.py:486"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/restores.py:470 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/restores.py:476"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/restores.py:479"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Cancel Restore",
        "tags": [
          "restores"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin",
          "operator"
        ],
        "x-response-source": "routers/restores.py:cancel_restore"
      }
    },
    "/api/v1/restores/{restore_id}/resume": {
      "post": {
        "description": "Resume backend monitoring/uncertain dispatch using the same durable plan.\n\nThe agent independently reopens its local journal after restart; this never\nallocates a new restore ID or overwrites failed/uncertain destinations.",
        "operationId": "resume_kubevirt_restore_api_v1_restores__restore_id__resume_post",
        "parameters": [
          {
            "in": "path",
            "name": "restore_id",
            "required": true,
            "schema": {
              "title": "Restore Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "202": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "status": {
                      "enum": [
                        "pending",
                        "dispatching",
                        "running"
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "status",
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/restores.py:437 -> backend/deps.py:check_role",
              "backend/routers/restores.py:444",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/restores.py:442"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/restores.py:452"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Resume Kubevirt Restore",
        "tags": [
          "restores"
        ],
        "x-additional-authorization": "Caller must be the original enrolled restore principal.",
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin",
          "operator"
        ],
        "x-response-source": "routers/restores.py:resume_kubevirt_restore"
      }
    },
    "/api/v1/s3/discover": {
      "get": {
        "description": "Discover chain manifests in S3 and report import status.",
        "operationId": "discover_chains_api_v1_s3_discover_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "chains": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "backup_count": {
                            "type": "integer"
                          },
                          "chain_id": {
                            "type": "string"
                          },
                          "conflicts": {
                            "items": {
                              "additionalProperties": false,
                              "properties": {
                                "backup_id": {
                                  "type": "string"
                                },
                                "existing_chain_id": {
                                  "anyOf": [
                                    {
                                      "type": "string"
                                    },
                                    {
                                      "type": "null"
                                    }
                                  ]
                                },
                                "manifest_chain_id": {
                                  "type": "string"
                                },
                                "reason": {
                                  "enum": [
                                    "exists_different_chain",
                                    "exists_different_vm"
                                  ]
                                }
                              },
                              "required": [
                                "backup_id",
                                "reason",
                                "existing_chain_id",
                                "manifest_chain_id"
                              ],
                              "type": "object"
                            },
                            "type": "array"
                          },
                          "encrypted": {
                            "type": "boolean"
                          },
                          "imported_count": {
                            "type": "integer"
                          },
                          "kek_available": {
                            "type": "boolean"
                          },
                          "kek_ids": {
                            "items": {
                              "type": "string"
                            },
                            "type": "array"
                          },
                          "newest_backup": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "oldest_backup": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "enum": [
                              "available",
                              "imported",
                              "partial",
                              "conflict",
                              "kek_missing"
                            ]
                          },
                          "total_size_bytes": {
                            "type": "integer"
                          },
                          "vm_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "chain_id",
                          "vm_name",
                          "backup_count",
                          "imported_count",
                          "total_size_bytes",
                          "oldest_backup",
                          "newest_backup",
                          "encrypted",
                          "kek_available",
                          "kek_ids",
                          "status",
                          "conflicts"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "s3_bucket": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "s3_endpoint": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "chains",
                    "s3_endpoint",
                    "s3_bucket"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/s3_import.py:286 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/s3_import.py:81"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Discover Chains",
        "tags": [
          "s3-import"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ],
        "x-response-source": "routers/s3_import.py:discover_chains,_classify_chain"
      }
    },
    "/api/v1/s3/import": {
      "post": {
        "description": "Import a backup chain from S3 manifests. Idempotent — skips existing records.",
        "operationId": "import_chain_api_v1_s3_import_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ImportRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "imported_count": {
                      "type": "integer"
                    },
                    "skipped_count": {
                      "type": "integer"
                    },
                    "status": {
                      "const": "ok"
                    },
                    "vm_created": {
                      "type": "boolean"
                    },
                    "vm_id": {
                      "type": "string"
                    },
                    "vm_name": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "imported_count",
                    "skipped_count",
                    "vm_name",
                    "vm_id",
                    "vm_created",
                    "status"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/s3_import.py:359"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/s3_import.py:309 -> backend/deps.py:check_role",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/s3_import.py:81",
              "backend/routers/s3_import.py:334"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/s3_import.py:394",
              "backend/routers/s3_import.py:405"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Import Chain",
        "tags": [
          "s3-import"
        ],
        "x-credential-domain": "user-session",
        "x-required-roles": [
          "admin"
        ],
        "x-response-source": "routers/s3_import.py:import_chain"
      }
    },
    "/api/v1/saved-searches": {
      "get": {
        "description": "List saved searches",
        "operationId": "list_saved_searches_api_v1_saved_searches_get",
        "parameters": [
          {
            "in": "query",
            "name": "search_type",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Search Type"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "items": {
                    "additionalProperties": false,
                    "properties": {
                      "created_at": {
                        "anyOf": [
                          {
                            "format": "date-time",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "description": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "filters": {
                        "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                        "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                      },
                      "id": {
                        "type": "string"
                      },
                      "is_owner": {
                        "type": "boolean"
                      },
                      "is_public": {
                        "type": "boolean"
                      },
                      "name": {
                        "type": "string"
                      },
                      "search_type": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "id",
                      "name",
                      "search_type",
                      "filters",
                      "is_public",
                      "created_at",
                      "description",
                      "is_owner"
                    ],
                    "type": "object"
                  },
                  "type": "array"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Saved Searches",
        "tags": [
          "search"
        ],
        "x-credential-domain": "user-session"
      },
      "post": {
        "description": "Create a saved search",
        "operationId": "create_saved_search_api_v1_saved_searches_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "description": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "filters": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  },
                  "is_public": {
                    "type": "boolean"
                  },
                  "name": {
                    "type": "string"
                  },
                  "search_type": {
                    "type": "string"
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "filters": {
                      "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                      "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                    },
                    "id": {
                      "type": "string"
                    },
                    "is_public": {
                      "type": "boolean"
                    },
                    "name": {
                      "type": "string"
                    },
                    "search_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "search_type",
                    "filters",
                    "is_public",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Saved Search",
        "tags": [
          "search"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/saved-searches/{search_id}": {
      "delete": {
        "description": "Delete a saved search",
        "operationId": "delete_saved_search_api_v1_saved_searches__search_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "search_id",
            "required": true,
            "schema": {
              "title": "Search Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/search.py:170",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/search.py:167"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Saved Search",
        "tags": [
          "search"
        ],
        "x-credential-domain": "user-session"
      },
      "get": {
        "description": "Get saved search details",
        "operationId": "get_saved_search_api_v1_saved_searches__search_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "search_id",
            "required": true,
            "schema": {
              "title": "Search Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "description": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "filters": {
                      "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                      "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                    },
                    "id": {
                      "type": "string"
                    },
                    "is_public": {
                      "type": "boolean"
                    },
                    "name": {
                      "type": "string"
                    },
                    "search_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "search_type",
                    "filters",
                    "is_public",
                    "created_at",
                    "description"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/search.py:145",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/search.py:142"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Saved Search",
        "tags": [
          "search"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/saved-searches/{search_id}/execute": {
      "post": {
        "description": "Execute a saved search and return results",
        "operationId": "execute_saved_search_api_v1_saved_searches__search_id__execute_post",
        "parameters": [
          {
            "in": "path",
            "name": "search_id",
            "required": true,
            "schema": {
              "title": "Search Id",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "title": "Limit",
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "description": "backup/vm searches include search_name; unsupported stored types return an empty page without search_name.",
                  "properties": {
                    "items": {
                      "items": {
                        "anyOf": [
                          {
                            "additionalProperties": false,
                            "properties": {
                              "created_at": {
                                "anyOf": [
                                  {
                                    "format": "date-time",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "id": {
                                "type": "string"
                              },
                              "status": {
                                "type": "string"
                              },
                              "vm_name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "vm_name",
                              "status",
                              "created_at"
                            ],
                            "type": "object"
                          },
                          {
                            "additionalProperties": false,
                            "properties": {
                              "agent_hostname": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "id": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "state": {
                                "anyOf": [
                                  {
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "state",
                              "agent_hostname"
                            ],
                            "type": "object"
                          }
                        ]
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "search_name": {
                      "type": "string"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/search.py:201",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/search.py:198"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Execute Saved Search",
        "tags": [
          "search"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/schedules": {
      "get": {
        "description": "List all backup schedules",
        "operationId": "list_schedules_api_v1_schedules_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "enabled",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Enabled"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "has_more": {
                      "type": "boolean"
                    },
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "authority_revision": {
                            "type": "integer"
                          },
                          "authority_state": {
                            "enum": [
                              "retired",
                              "unenrolled",
                              "binding_invalid",
                              "revoked",
                              "org_epoch_held",
                              "active",
                              "paused"
                            ],
                            "type": "string"
                          },
                          "backup_policy": {
                            "anyOf": [
                              {
                                "additionalProperties": false,
                                "properties": {
                                  "full_every_days": {
                                    "maximum": 36500,
                                    "minimum": 1,
                                    "type": "integer"
                                  },
                                  "max_incrementals": {
                                    "maximum": 255,
                                    "minimum": 1,
                                    "type": "integer"
                                  },
                                  "schema": {
                                    "const": 1,
                                    "type": "integer"
                                  }
                                },
                                "required": [
                                  "schema",
                                  "full_every_days",
                                  "max_incrementals"
                                ],
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "backup_type": {
                            "type": "string"
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "cron_expression": {
                            "type": "string"
                          },
                          "current_grant_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "enabled": {
                            "anyOf": [
                              {
                                "type": "boolean"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "exclude_disks": {
                            "items": {
                              "type": "string"
                            },
                            "type": "array"
                          },
                          "id": {
                            "type": "string"
                          },
                          "last_run_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "name": {
                            "type": "string"
                          },
                          "next_run_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "retention_days": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "tags": {
                            "anyOf": [
                              {
                                "additionalProperties": true,
                                "description": "User-defined tag keys and JSON values.",
                                "type": "object",
                                "x-open-schema-reason": "User-defined tag keys and JSON values."
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "updated_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_group_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_group_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "workers": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "authority_revision",
                          "current_grant_id",
                          "authority_state",
                          "id",
                          "name",
                          "vm_id",
                          "vm_group_id",
                          "cron_expression",
                          "backup_type",
                          "backup_policy",
                          "exclude_disks",
                          "workers",
                          "retention_days",
                          "tags",
                          "enabled",
                          "next_run_at",
                          "created_at",
                          "last_run_at",
                          "updated_at",
                          "vm_name",
                          "vm_group_name"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit",
                    "has_more"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Schedules",
        "tags": [
          "schedules"
        ],
        "x-credential-domain": "user-session"
      },
      "post": {
        "description": "Create a new backup schedule (operator or admin only)",
        "operationId": "create_schedule_api_v1_schedules_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduleCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "authority_revision": {
                      "type": "integer"
                    },
                    "authority_state": {
                      "enum": [
                        "retired",
                        "unenrolled",
                        "binding_invalid",
                        "revoked",
                        "org_epoch_held",
                        "active",
                        "paused"
                      ],
                      "type": "string"
                    },
                    "backup_policy": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "full_every_days": {
                              "maximum": 36500,
                              "minimum": 1,
                              "type": "integer"
                            },
                            "max_incrementals": {
                              "maximum": 255,
                              "minimum": 1,
                              "type": "integer"
                            },
                            "schema": {
                              "const": 1,
                              "type": "integer"
                            }
                          },
                          "required": [
                            "schema",
                            "full_every_days",
                            "max_incrementals"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "backup_type": {
                      "type": "string"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "cron_expression": {
                      "type": "string"
                    },
                    "current_grant_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "anyOf": [
                        {
                          "type": "boolean"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "exclude_disks": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "next_run_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "retention_days": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "tags": {
                      "anyOf": [
                        {
                          "additionalProperties": true,
                          "description": "User-defined tag keys and JSON values.",
                          "type": "object",
                          "x-open-schema-reason": "User-defined tag keys and JSON values."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_group_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "workers": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "authority_revision",
                    "current_grant_id",
                    "authority_state",
                    "id",
                    "name",
                    "vm_id",
                    "vm_group_id",
                    "cron_expression",
                    "backup_type",
                    "backup_policy",
                    "exclude_disks",
                    "workers",
                    "retention_days",
                    "tags",
                    "enabled",
                    "next_run_at",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:239",
              "backend/routers/schedules.py:245",
              "backend/routers/schedules.py:272"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:254",
              "backend/routers/schedules.py:264"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:226"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/schedules.py:235"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create Schedule",
        "tags": [
          "schedules"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/schedules/{schedule_id}": {
      "delete": {
        "description": "Delete schedule (operator or admin only)",
        "operationId": "delete_schedule_api_v1_schedules__schedule_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:541"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete Schedule",
        "tags": [
          "schedules"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      },
      "get": {
        "description": "Get schedule details",
        "operationId": "get_schedule_api_v1_schedules__schedule_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "authority_revision": {
                      "type": "integer"
                    },
                    "authority_state": {
                      "enum": [
                        "retired",
                        "unenrolled",
                        "binding_invalid",
                        "revoked",
                        "org_epoch_held",
                        "active",
                        "paused"
                      ],
                      "type": "string"
                    },
                    "backup_policy": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "full_every_days": {
                              "maximum": 36500,
                              "minimum": 1,
                              "type": "integer"
                            },
                            "max_incrementals": {
                              "maximum": 255,
                              "minimum": 1,
                              "type": "integer"
                            },
                            "schema": {
                              "const": 1,
                              "type": "integer"
                            }
                          },
                          "required": [
                            "schema",
                            "full_every_days",
                            "max_incrementals"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "backup_type": {
                      "type": "string"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "cron_expression": {
                      "type": "string"
                    },
                    "current_grant_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "anyOf": [
                        {
                          "type": "boolean"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "exclude_disks": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "last_run_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "name": {
                      "type": "string"
                    },
                    "next_run_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "retention_days": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "tags": {
                      "anyOf": [
                        {
                          "additionalProperties": true,
                          "description": "User-defined tag keys and JSON values.",
                          "type": "object",
                          "x-open-schema-reason": "User-defined tag keys and JSON values."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "updated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_group_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_group_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "workers": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "authority_revision",
                    "current_grant_id",
                    "authority_state",
                    "id",
                    "name",
                    "vm_id",
                    "vm_group_id",
                    "cron_expression",
                    "backup_type",
                    "backup_policy",
                    "exclude_disks",
                    "workers",
                    "retention_days",
                    "tags",
                    "enabled",
                    "next_run_at",
                    "created_at",
                    "last_run_at",
                    "updated_at",
                    "vm_name",
                    "vm_group_name"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:341"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Schedule",
        "tags": [
          "schedules"
        ],
        "x-credential-domain": "user-session"
      },
      "put": {
        "description": "Update schedule (operator or admin only)",
        "operationId": "update_schedule_api_v1_schedules__schedule_id__put",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduleUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "authority_revision": {
                      "type": "integer"
                    },
                    "authority_state": {
                      "enum": [
                        "retired",
                        "unenrolled",
                        "binding_invalid",
                        "revoked",
                        "org_epoch_held",
                        "active",
                        "paused"
                      ],
                      "type": "string"
                    },
                    "backup_policy": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "full_every_days": {
                              "maximum": 36500,
                              "minimum": 1,
                              "type": "integer"
                            },
                            "max_incrementals": {
                              "maximum": 255,
                              "minimum": 1,
                              "type": "integer"
                            },
                            "schema": {
                              "const": 1,
                              "type": "integer"
                            }
                          },
                          "required": [
                            "schema",
                            "full_every_days",
                            "max_incrementals"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "backup_type": {
                      "type": "string"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "cron_expression": {
                      "type": "string"
                    },
                    "current_grant_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "anyOf": [
                        {
                          "type": "boolean"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "exclude_disks": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "last_run_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "name": {
                      "type": "string"
                    },
                    "next_run_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "retention_days": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "tags": {
                      "anyOf": [
                        {
                          "additionalProperties": true,
                          "description": "User-defined tag keys and JSON values.",
                          "type": "object",
                          "x-open-schema-reason": "User-defined tag keys and JSON values."
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "updated_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_group_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "workers": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "authority_revision",
                    "current_grant_id",
                    "authority_state",
                    "id",
                    "name",
                    "vm_id",
                    "vm_group_id",
                    "cron_expression",
                    "backup_type",
                    "backup_policy",
                    "exclude_disks",
                    "workers",
                    "retention_days",
                    "tags",
                    "enabled",
                    "next_run_at",
                    "created_at",
                    "last_run_at",
                    "updated_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:439"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:387"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:392",
              "backend/routers/schedules.py:424"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/HTTPValidationError"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Validation Error",
            "x-error-sources": [
              "backend/routers/schedules.py:401"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Schedule",
        "tags": [
          "schedules"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/schedules/{schedule_id}/grant": {
      "delete": {
        "operationId": "revoke_schedule_grant_api_v1_schedules__schedule_id__grant_delete",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "authority_revision": {
                      "type": "integer"
                    },
                    "authority_state": {
                      "enum": [
                        "retired",
                        "unenrolled",
                        "binding_invalid",
                        "revoked",
                        "org_epoch_held",
                        "active",
                        "paused"
                      ],
                      "type": "string"
                    },
                    "current_grant_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "authority_revision",
                    "current_grant_id",
                    "authority_state",
                    "enabled"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:153"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Revoke Schedule Grant",
        "tags": [
          "schedules"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      },
      "get": {
        "operationId": "get_schedule_grant_api_v1_schedules__schedule_id__grant_get",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "authority_revision": {
                      "type": "integer"
                    },
                    "authority_state": {
                      "enum": [
                        "retired",
                        "unenrolled",
                        "binding_invalid",
                        "revoked",
                        "org_epoch_held",
                        "active",
                        "paused"
                      ],
                      "type": "string"
                    },
                    "current_grant_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "revision": {
                      "maximum": 9223372036854775807,
                      "minimum": 1,
                      "type": "integer"
                    },
                    "scope": {
                      "additionalProperties": false,
                      "properties": {
                        "configuration_sha256": {
                          "pattern": "^[0-9a-f]{64}$",
                          "type": "string"
                        },
                        "encryption": {
                          "additionalProperties": false,
                          "properties": {
                            "format": {
                              "type": "string"
                            },
                            "key_ref": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "required": [
                            "format",
                            "key_ref"
                          ],
                          "type": "object"
                        },
                        "members": {
                          "items": {
                            "additionalProperties": false,
                            "properties": {
                              "agent_id": {
                                "type": "string"
                              },
                              "namespace": {
                                "type": "string"
                              },
                              "provider": {
                                "enum": [
                                  "libvirt",
                                  "kubevirt"
                                ],
                                "type": "string"
                              },
                              "source_sha256": {
                                "pattern": "^[0-9a-f]{64}$",
                                "type": "string"
                              },
                              "vm_id": {
                                "type": "string"
                              },
                              "vm_uid": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "vm_id",
                              "agent_id",
                              "vm_uid",
                              "namespace",
                              "provider",
                              "source_sha256"
                            ],
                            "type": "object"
                          },
                          "maxItems": 256,
                          "minItems": 1,
                          "type": "array"
                        },
                        "options": {
                          "additionalProperties": false,
                          "properties": {
                            "backup_policy": {
                              "additionalProperties": false,
                              "properties": {
                                "full_every_days": {
                                  "maximum": 36500,
                                  "minimum": 1,
                                  "type": "integer"
                                },
                                "max_incrementals": {
                                  "maximum": 255,
                                  "minimum": 1,
                                  "type": "integer"
                                },
                                "schema": {
                                  "const": 1,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "schema",
                                "full_every_days",
                                "max_incrementals"
                              ],
                              "type": "object"
                            },
                            "backup_type": {
                              "enum": [
                                "full",
                                "incremental",
                                "automatic"
                              ],
                              "type": "string"
                            },
                            "exclude_disks": {
                              "items": {
                                "type": "string"
                              },
                              "type": "array"
                            },
                            "retention_days": {
                              "maximum": 36500,
                              "minimum": 1,
                              "type": "integer"
                            },
                            "workers": {
                              "anyOf": [
                                {
                                  "maximum": 256,
                                  "minimum": 1,
                                  "type": "integer"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "required": [
                            "backup_type",
                            "retention_days",
                            "exclude_disks",
                            "workers"
                          ],
                          "type": "object"
                        },
                        "org_id": {
                          "type": "string"
                        },
                        "revision": {
                          "maximum": 9223372036854775807,
                          "minimum": 1,
                          "type": "integer"
                        },
                        "schedule_id": {
                          "type": "string"
                        },
                        "schema": {
                          "const": 1,
                          "type": "integer"
                        },
                        "target": {
                          "additionalProperties": false,
                          "properties": {
                            "bucket": {
                              "type": "string"
                            },
                            "capability_profile": {
                              "type": "string"
                            },
                            "endpoint": {
                              "type": "string"
                            },
                            "prefix": {
                              "type": "string"
                            },
                            "region": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "endpoint",
                            "bucket",
                            "region",
                            "prefix",
                            "capability_profile"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "schema",
                        "org_id",
                        "schedule_id",
                        "revision",
                        "configuration_sha256",
                        "members",
                        "target",
                        "encryption",
                        "options"
                      ],
                      "type": "object"
                    },
                    "scope_sha256": {
                      "pattern": "^[0-9a-f]{64}$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "authority_revision",
                    "current_grant_id",
                    "authority_state",
                    "scope",
                    "scope_sha256",
                    "revision"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:77"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:81"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Schedule Grant",
        "tags": [
          "schedules"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      },
      "post": {
        "operationId": "enroll_schedule_grant_api_v1_schedules__schedule_id__grant_post",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GrantEnrollment"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "authority_revision": {
                      "type": "integer"
                    },
                    "authority_state": {
                      "enum": [
                        "retired",
                        "unenrolled",
                        "binding_invalid",
                        "revoked",
                        "org_epoch_held",
                        "active",
                        "paused"
                      ],
                      "type": "string"
                    },
                    "current_grant_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "enabled": {
                      "type": "boolean"
                    },
                    "grant_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "authority_revision",
                    "current_grant_id",
                    "authority_state",
                    "grant_id",
                    "enabled"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:125"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Enroll Schedule Grant",
        "tags": [
          "schedules"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/schedules/{schedule_id}/run-now": {
      "post": {
        "description": "Manually trigger a schedule to run immediately (operator or admin only)",
        "operationId": "run_schedule_now_api_v1_schedules__schedule_id__run_now_post",
        "parameters": [
          {
            "in": "path",
            "name": "schedule_id",
            "required": true,
            "schema": {
              "title": "Schedule Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "schedule_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message",
                    "schedule_id"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/schedules.py:580"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Run Schedule Now",
        "tags": [
          "schedules"
        ],
        "x-authorization-dependency": "get_operator_or_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/search": {
      "post": {
        "description": "Cross-entity search for VMs and backups by name.",
        "operationId": "global_search_api_v1_search_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "filters": {
                    "additionalProperties": true,
                    "description": "Search switches vms/backups use JSON truthiness; unknown switches ignored.",
                    "type": "object",
                    "x-open-schema-reason": "Search switches vms/backups use JSON truthiness; unknown switches ignored."
                  },
                  "query": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backups": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          },
                          "vm_name": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "vm_name",
                          "status",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "vms": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "hostname": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "state": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "state",
                          "hostname"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "vms",
                    "backups"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Global Search",
        "tags": [
          "search"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/settings": {
      "get": {
        "description": "Get system settings",
        "operationId": "get_settings_api_v1_settings_get",
        "parameters": [
          {
            "in": "query",
            "name": "category",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Category"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "settings": {
                      "additionalProperties": true,
                      "description": "Legacy settings are keyed by arbitrary database setting names; values decode according to each stored value_type.",
                      "type": "object",
                      "x-open-schema-reason": "Legacy settings are keyed by arbitrary database setting names; values decode according to each stored value_type."
                    }
                  },
                  "required": [
                    "settings"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Settings",
        "tags": [
          "config"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      },
      "put": {
        "description": "Update multiple system settings at once",
        "operationId": "update_settings_bulk_api_v1_settings_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "description": "Legacy settings are keyed by arbitrary database setting names; values decode according to each stored value_type.",
                "type": "object",
                "x-open-schema-reason": "Legacy settings are keyed by arbitrary database setting names; values decode according to each stored value_type."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "updated_count": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "message",
                    "updated_count"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Settings Bulk",
        "tags": [
          "config"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/settings/test-email": {
      "post": {
        "description": "Test email settings by sending a test email",
        "operationId": "test_email_settings_api_v1_settings_test_email_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "description": "Recipient passed through to email helper; settings test defaults to current user email when omitted.",
                "properties": {
                  "recipient": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "recipient": {
                      "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                      "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                    }
                  },
                  "required": [
                    "message",
                    "recipient"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/config.py:379",
              "backend/routers/config.py:399",
              "backend/routers/config.py:403",
              "backend/routers/config.py:405"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "backend/routers/config.py:417",
              "backend/routers/config.py:432",
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Test Email Settings",
        "tags": [
          "config"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/settings/test-s3": {
      "post": {
        "description": "Test S3 connection with current settings.",
        "operationId": "test_s3_connection_api_v1_settings_test_s3_post",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "bucket": {
                      "type": "string"
                    },
                    "endpoint": {
                      "type": "string"
                    },
                    "message": {
                      "type": "string"
                    },
                    "status": {
                      "const": "ok",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status",
                    "message",
                    "bucket",
                    "endpoint"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/config.py:273",
              "backend/routers/config.py:319",
              "backend/routers/config.py:316"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Test S3 Connection",
        "tags": [
          "config"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/settings/v3": {
      "get": {
        "description": "Get v3 settings (storage and OIDC config) with secret status.",
        "operationId": "get_settings_v3_api_v1_settings_v3_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "encryption_configured": {
                      "type": "boolean"
                    },
                    "secrets": {
                      "additionalProperties": false,
                      "properties": {
                        "oidc.client_secret": {
                          "additionalProperties": false,
                          "properties": {
                            "configured": {
                              "type": "boolean"
                            },
                            "source": {
                              "enum": [
                                "ui",
                                "env",
                                null
                              ]
                            }
                          },
                          "required": [
                            "configured",
                            "source"
                          ],
                          "type": "object"
                        },
                        "pki.ca_key": {
                          "additionalProperties": false,
                          "properties": {
                            "configured": {
                              "type": "boolean"
                            },
                            "source": {
                              "enum": [
                                "ui",
                                "env",
                                null
                              ]
                            }
                          },
                          "required": [
                            "configured",
                            "source"
                          ],
                          "type": "object"
                        },
                        "storage.s3.access_key": {
                          "additionalProperties": false,
                          "properties": {
                            "configured": {
                              "type": "boolean"
                            },
                            "source": {
                              "enum": [
                                "ui",
                                "env",
                                null
                              ]
                            }
                          },
                          "required": [
                            "configured",
                            "source"
                          ],
                          "type": "object"
                        },
                        "storage.s3.secret_key": {
                          "additionalProperties": false,
                          "properties": {
                            "configured": {
                              "type": "boolean"
                            },
                            "source": {
                              "enum": [
                                "ui",
                                "env",
                                null
                              ]
                            }
                          },
                          "required": [
                            "configured",
                            "source"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "storage.s3.access_key",
                        "storage.s3.secret_key",
                        "oidc.client_secret",
                        "pki.ca_key"
                      ],
                      "type": "object"
                    },
                    "settings": {
                      "additionalProperties": false,
                      "properties": {
                        "backup.admission_pause": {
                          "anyOf": [
                            {
                              "additionalProperties": false,
                              "description": "Installation-owned pause for new backup capacity reservations, including scheduled backups. Already reserved work may continue under its original authority and safety checks. Null on GET means no separate pause; capacity policy remains required. A changed value requires a strictly increased revision. A pause never releases custody or bypasses maintenance.",
                              "properties": {
                                "paused": {
                                  "type": "boolean"
                                },
                                "revision": {
                                  "maximum": 9223372036854775807,
                                  "minimum": 1,
                                  "type": "integer"
                                },
                                "schema": {
                                  "const": 1,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "schema",
                                "revision",
                                "paused"
                              ],
                              "type": "object"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "backup.capacity_admission": {
                          "anyOf": [
                            {
                              "additionalProperties": false,
                              "description": "Changing a prior policy requires a strictly increased revision. Maintenance blocks new reservations and existing effect continuations. Use backup.admission_pause to stop new reservations while admitted work drains.",
                              "properties": {
                                "limit": {
                                  "maximum": 100000,
                                  "minimum": 1,
                                  "type": "integer"
                                },
                                "maintenance": {
                                  "type": "boolean"
                                },
                                "revision": {
                                  "maximum": 9223372036854775807,
                                  "minimum": 1,
                                  "type": "integer"
                                },
                                "schema": {
                                  "const": 1,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "schema",
                                "revision",
                                "limit",
                                "maintenance"
                              ],
                              "type": "object"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "oidc.admin_values": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "oidc.client_id": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "oidc.default_role": {
                          "anyOf": [
                            {
                              "enum": [
                                "viewer",
                                "operator"
                              ],
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "oidc.enabled": {
                          "type": "boolean"
                        },
                        "oidc.issuer": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "oidc.operator_values": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "oidc.role_claim": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "oidc.scopes": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "pki.ca_cert": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "pki.require_mtls": {
                          "type": "boolean"
                        },
                        "storage.path": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "storage.s3.bucket": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "storage.s3.delete_local": {
                          "type": "boolean"
                        },
                        "storage.s3.endpoint": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "storage.s3.prefix": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "storage.s3.region": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "storage.type": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "backup.capacity_admission",
                        "backup.admission_pause",
                        "storage.type",
                        "storage.path",
                        "storage.s3.endpoint",
                        "storage.s3.bucket",
                        "storage.s3.region",
                        "storage.s3.prefix",
                        "storage.s3.delete_local",
                        "pki.ca_cert",
                        "pki.require_mtls",
                        "oidc.enabled",
                        "oidc.issuer",
                        "oidc.client_id",
                        "oidc.scopes",
                        "oidc.role_claim",
                        "oidc.admin_values",
                        "oidc.operator_values",
                        "oidc.default_role"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "settings",
                    "secrets",
                    "encryption_configured"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Settings V3",
        "tags": [
          "config"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      },
      "put": {
        "description": "Update v3 settings (storage and OIDC config).",
        "operationId": "update_settings_v3_api_v1_settings_v3_put",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": false,
                "description": "Flat settings patch; unknown keys and null are invalid. Omitted values retain prior state. String values are trimmed; booleans require JSON booleans. Effective OIDC configuration is validated together. Authorization precedes sensitive JSON decoding; malformed input returns 400 after authorization.",
                "properties": {
                  "backup.admission_pause": {
                    "additionalProperties": false,
                    "description": "Installation-owned pause for new backup capacity reservations, including scheduled backups. Already reserved work may continue under its original authority and safety checks. Null on GET means no separate pause; capacity policy remains required. A changed value requires a strictly increased revision. A pause never releases custody or bypasses maintenance.",
                    "properties": {
                      "paused": {
                        "type": "boolean"
                      },
                      "revision": {
                        "maximum": 9223372036854775807,
                        "minimum": 1,
                        "type": "integer"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "revision",
                      "paused"
                    ],
                    "type": "object"
                  },
                  "backup.capacity_admission": {
                    "additionalProperties": false,
                    "description": "Changing a prior policy requires a strictly increased revision. Maintenance blocks new reservations and existing effect continuations. Use backup.admission_pause to stop new reservations while admitted work drains.",
                    "properties": {
                      "limit": {
                        "maximum": 100000,
                        "minimum": 1,
                        "type": "integer"
                      },
                      "maintenance": {
                        "type": "boolean"
                      },
                      "revision": {
                        "maximum": 9223372036854775807,
                        "minimum": 1,
                        "type": "integer"
                      },
                      "schema": {
                        "const": 1,
                        "type": "integer"
                      }
                    },
                    "required": [
                      "schema",
                      "revision",
                      "limit",
                      "maintenance"
                    ],
                    "type": "object"
                  },
                  "oidc.admin_values": {
                    "type": "string"
                  },
                  "oidc.client_id": {
                    "type": "string"
                  },
                  "oidc.client_secret": {
                    "description": "Omitted, empty, whitespace-only or entirely */• masked strings retain the current secret. Null is invalid. No clear-secret operation.",
                    "type": "string",
                    "writeOnly": true
                  },
                  "oidc.default_role": {
                    "enum": [
                      "viewer",
                      "operator"
                    ],
                    "type": "string"
                  },
                  "oidc.enabled": {
                    "type": "boolean"
                  },
                  "oidc.issuer": {
                    "type": "string"
                  },
                  "oidc.operator_values": {
                    "type": "string"
                  },
                  "oidc.role_claim": {
                    "type": "string"
                  },
                  "oidc.scopes": {
                    "type": "string"
                  },
                  "pki.ca_cert": {
                    "type": "string"
                  },
                  "pki.ca_key": {
                    "description": "Omitted, empty, whitespace-only or entirely */• masked strings retain the current secret. Null is invalid. No clear-secret operation.",
                    "type": "string",
                    "writeOnly": true
                  },
                  "pki.require_mtls": {
                    "type": "boolean"
                  },
                  "storage.path": {
                    "type": "string"
                  },
                  "storage.s3.access_key": {
                    "description": "Omitted, empty, whitespace-only or entirely */• masked strings retain the current secret. Null is invalid. No clear-secret operation.",
                    "type": "string",
                    "writeOnly": true
                  },
                  "storage.s3.bucket": {
                    "type": "string"
                  },
                  "storage.s3.delete_local": {
                    "type": "boolean"
                  },
                  "storage.s3.endpoint": {
                    "type": "string"
                  },
                  "storage.s3.prefix": {
                    "type": "string"
                  },
                  "storage.s3.region": {
                    "type": "string"
                  },
                  "storage.s3.secret_key": {
                    "description": "Omitted, empty, whitespace-only or entirely */• masked strings retain the current secret. Null is invalid. No clear-secret operation.",
                    "type": "string",
                    "writeOnly": true
                  },
                  "storage.type": {
                    "type": "string"
                  }
                },
                "required": [],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "status": {
                      "const": "ok",
                      "type": "string"
                    },
                    "updated_secrets": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    },
                    "updated_settings": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "status",
                    "updated_settings",
                    "updated_secrets"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Invalid configuration after authorization; secret values are never echoed.",
            "x-error-sources": [
              "backend/routers/config.py:196",
              "backend/routers/config.py:194",
              "backend/routers/config.py:218",
              "backend/routers/config.py:231"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Invalid or disabled authenticated identity.",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Installation authority required.",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              },
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Settings transaction failed and rolled back.",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "backend/routers/config.py:253",
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Settings V3",
        "tags": [
          "config"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/settings/{setting_id}": {
      "put": {
        "description": "Update a system setting",
        "operationId": "update_setting_api_v1_settings__setting_id__put",
        "parameters": [
          {
            "in": "path",
            "name": "setting_id",
            "required": true,
            "schema": {
              "title": "Setting Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "value": {
                    "description": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained.",
                    "x-open-schema-reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
                  }
                },
                "required": [],
                "type": "object",
                "x-open-schema-reason": "Unknown input keys are ignored by this legacy dict handler."
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "setting": {
                      "additionalProperties": false,
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "key": {
                          "type": "string"
                        },
                        "value": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "key",
                        "value"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "message",
                    "setting"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/config.py:334"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update Setting",
        "tags": [
          "config"
        ],
        "x-authorization-dependency": "get_installation_admin",
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/stats": {
      "get": {
        "description": "Get system statistics for dashboard",
        "operationId": "get_stats_api_v1_stats_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backups": {
                      "additionalProperties": false,
                      "properties": {
                        "completed": {
                          "type": "integer"
                        },
                        "failed": {
                          "type": "integer"
                        },
                        "running": {
                          "type": "integer"
                        },
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total",
                        "running",
                        "completed",
                        "failed"
                      ],
                      "type": "object"
                    },
                    "storage": {
                      "additionalProperties": false,
                      "properties": {
                        "total_bytes": {
                          "type": "integer"
                        },
                        "total_gb": {
                          "type": "number"
                        }
                      },
                      "required": [
                        "total_bytes",
                        "total_gb"
                      ],
                      "type": "object"
                    },
                    "vms": {
                      "additionalProperties": false,
                      "properties": {
                        "total": {
                          "type": "integer"
                        }
                      },
                      "required": [
                        "total"
                      ],
                      "type": "object"
                    }
                  },
                  "required": [
                    "vms",
                    "backups",
                    "storage"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Stats",
        "tags": [
          "stats"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/updates": {
      "get": {
        "description": "Best-effort process-local invalidations, not lossless history.\n\ncontract=2 returns ordered items and an opaque continuation bound to this\nprocess and authenticated organization/user/role. History retains at most\n1000 events for 300 seconds. Initial/missing, expired, overflowed, restarted\nor different-worker/scope cursors explicitly require authoritative full-state\nresynchronization. Capture next_cursor, read snapshots, then continue from\nthat cursor. Socket messages are hints; use this feed for continuation.\n\nThe legacy since array is deprecated. It returns the oldest matching limit\nwith strict greater-than timestamps; ties and limits cannot prove completeness.\nsince requires Z or an explicit UTC offset; malformed/naive values return 400.",
        "operationId": "get_updates_api_v1_updates_get",
        "parameters": [
          {
            "description": "Deprecated aware ISO8601 timestamp; oldest-first limited array, no completeness guarantee",
            "in": "query",
            "name": "since",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "description": "Deprecated aware ISO8601 timestamp; oldest-first limited array, no completeness guarantee",
              "title": "Since"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 100,
              "maximum": 500,
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "description": "Set 2 for the cursor envelope",
            "in": "query",
            "name": "contract",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "integer"
                },
                {
                  "type": "null"
                }
              ],
              "description": "Set 2 for the cursor envelope",
              "title": "Contract"
            }
          },
          {
            "description": "Opaque continuation from contract=2",
            "in": "query",
            "name": "cursor",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "maxLength": 2048,
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "description": "Opaque continuation from contract=2",
              "title": "Cursor"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/RealtimePage"
                    },
                    {
                      "items": {
                        "$ref": "#/components/schemas/LegacyRealtimeEvent"
                      },
                      "type": "array"
                    }
                  ],
                  "title": "Response Get Updates Api V1 Updates Get"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "examples": {
                  "invalid_cursor": {
                    "value": {
                      "detail": {
                        "code": "realtime_cursor_invalid",
                        "message": "Invalid realtime cursor"
                      }
                    }
                  },
                  "unsupported_contract": {
                    "value": {
                      "detail": {
                        "code": "realtime_contract_unsupported",
                        "message": "Unsupported realtime contract"
                      }
                    }
                  }
                },
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/RealtimeErrorResponse"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "realtime_contract_unsupported",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "realtime_cursor_contract_required",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "realtime_parameters_conflict",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "realtime_cursor_invalid",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "realtime_timestamp_invalid",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Stable coded contract, cursor or timestamp refusal; no cursor content is echoed.",
            "x-error-sources": [
              "backend/routers/realtime.py:267",
              "backend/routers/realtime.py:299",
              "backend/routers/realtime.py:276",
              "backend/routers/realtime.py:291",
              "backend/routers/realtime.py:314"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Updates",
        "tags": [
          "realtime"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/users": {
      "get": {
        "description": "List all users (admin only)",
        "operationId": "list_users_api_v1_users_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "description": "Clamped to 100 per page",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "description": "Clamped to 100 per page",
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "has_more": {
                      "type": "boolean"
                    },
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "auth_source": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "email": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "full_name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "is_active": {
                            "type": "boolean"
                          },
                          "last_login": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "oidc_issuer": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "oidc_subject": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "org_id": {
                            "type": "string"
                          },
                          "role": {
                            "type": "string"
                          },
                          "role_source": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "username": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "email",
                          "full_name",
                          "auth_source",
                          "role_source",
                          "oidc_subject",
                          "oidc_issuer",
                          "id",
                          "username",
                          "org_id",
                          "role",
                          "is_active",
                          "last_login",
                          "created_at"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit",
                    "has_more"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Users",
        "tags": [
          "users"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "created_at descending, id descending",
          "pagination": "offset",
          "snapshot": false
        }
      },
      "post": {
        "description": "Create a new user (admin only)",
        "operationId": "create_user_api_v1_users_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UserCreate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "role": {
                      "type": "string"
                    },
                    "username": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "username",
                    "role",
                    "created_at"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:127",
              "backend/routers/users.py:135",
              "backend/routers/users.py:143",
              "backend/routers/users.py:182"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Create User",
        "tags": [
          "users"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/users.py:create_user"
      }
    },
    "/api/v1/users/{user_id}": {
      "delete": {
        "description": "Delete user (admin only)",
        "operationId": "delete_user_api_v1_users__user_id__delete",
        "parameters": [
          {
            "in": "path",
            "name": "user_id",
            "required": true,
            "schema": {
              "title": "User Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "message": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "message"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:388"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/users.py:38",
              "backend/routers/users.py:41",
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/users.py:43",
              "backend/routers/users.py:386",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:51"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:62",
              "backend/routers/users.py:411"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Delete User",
        "tags": [
          "users"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/users.py:delete_user"
      },
      "get": {
        "description": "Get user details (admin only)",
        "operationId": "get_user_api_v1_users__user_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "user_id",
            "required": true,
            "schema": {
              "title": "User Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "auth_source": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "email": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "full_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "is_active": {
                      "type": "boolean"
                    },
                    "last_login": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "oidc_issuer": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "oidc_subject": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "role": {
                      "type": "string"
                    },
                    "role_source": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "username": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "username",
                    "role",
                    "is_active",
                    "created_at",
                    "full_name",
                    "email",
                    "auth_source",
                    "role_source",
                    "oidc_subject",
                    "oidc_issuer",
                    "last_login"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Persisted identity lacks required role or installation/platform authority",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:198"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get User",
        "tags": [
          "users"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/users.py:get_user"
      },
      "put": {
        "description": "Update user (admin only)",
        "operationId": "update_user_api_v1_users__user_id__put",
        "parameters": [
          {
            "in": "path",
            "name": "user_id",
            "required": true,
            "schema": {
              "title": "User Id",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UserUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "auth_source": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "email": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "full_name": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "is_active": {
                      "type": "boolean"
                    },
                    "oidc_issuer": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "oidc_subject": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "role": {
                      "type": "string"
                    },
                    "role_source": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "username": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "username",
                    "role",
                    "is_active",
                    "created_at",
                    "full_name",
                    "email",
                    "auth_source",
                    "role_source",
                    "oidc_subject",
                    "oidc_issuer"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:236",
              "backend/routers/users.py:238",
              "backend/routers/users.py:241",
              "backend/routers/users.py:245",
              "backend/routers/users.py:248",
              "backend/routers/users.py:253",
              "backend/routers/users.py:257",
              "backend/routers/users.py:267",
              "backend/routers/users.py:273",
              "backend/routers/users.py:299",
              "backend/routers/users.py:310",
              "backend/routers/users.py:317",
              "backend/routers/users.py:330",
              "backend/routers/users.py:368"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/routers/users.py:38",
              "backend/routers/users.py:41",
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DEMO_POLICY_DENIED",
                              "type": "string"
                            },
                            "message": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "code",
                            "message"
                          ],
                          "type": "object"
                        },
                        "environment": {
                          "const": "demo",
                          "type": "string"
                        },
                        "simulated": {
                          "const": true,
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "detail",
                        "environment",
                        "simulated"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Request refused or failed",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Persisted identity lacks required role or installation/platform authority",
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/routers/users.py:43",
              "backend/routers/users.py:230",
              "backend/deps.py:RBAC dependencies",
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:51"
            ]
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/users.py:62"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Update User",
        "tags": [
          "users"
        ],
        "x-authorization-dependency": "get_admin_user",
        "x-credential-domain": "user-session",
        "x-response-source": "routers/users.py:update_user"
      }
    },
    "/api/v1/verifications": {
      "get": {
        "description": "List all verification records",
        "operationId": "list_all_verifications_api_v1_verifications_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "maximum": 200,
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "status",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Status"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "backup_id": {
                            "type": "string"
                          },
                          "cancel_requested": {
                            "type": "boolean"
                          },
                          "completed_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "created_by": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "id": {
                            "type": "string"
                          },
                          "read_attempts": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "read_limit": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "recorded_status": {
                            "type": "string"
                          },
                          "result_message": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "started_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "status": {
                            "type": "string"
                          },
                          "verification_type": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "status",
                          "recorded_status",
                          "created_by",
                          "read_attempts",
                          "read_limit",
                          "cancel_requested",
                          "result_message",
                          "verification_type",
                          "started_at",
                          "completed_at",
                          "created_at",
                          "backup_id"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List All Verifications",
        "tags": [
          "verification"
        ],
        "x-credential-domain": "user-session",
        "x-response-source": "routers/verification.py:list_all_verifications"
      }
    },
    "/api/v1/verifications/{verification_id}": {
      "get": {
        "description": "Get details of a specific verification",
        "operationId": "get_verification_api_v1_verifications__verification_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "verification_id",
            "required": true,
            "schema": {
              "title": "Verification Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "backup": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "created_at": {
                              "anyOf": [
                                {
                                  "format": "date-time",
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "size_bytes": {
                              "anyOf": [
                                {
                                  "type": "integer"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "status": {
                              "type": "string"
                            },
                            "vm_id": {
                              "type": "string"
                            },
                            "vm_name": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "vm_id",
                            "vm_name",
                            "status",
                            "size_bytes",
                            "created_at"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "backup_id": {
                      "type": "string"
                    },
                    "cancel_requested": {
                      "type": "boolean"
                    },
                    "completed_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_by": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "created_by_user": {
                      "anyOf": [
                        {
                          "additionalProperties": false,
                          "properties": {
                            "id": {
                              "type": "string"
                            },
                            "role": {
                              "type": "string"
                            },
                            "username": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "username",
                            "role"
                          ],
                          "type": "object"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "id": {
                      "type": "string"
                    },
                    "read_attempts": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "read_limit": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "recorded_status": {
                      "type": "string"
                    },
                    "result": {
                      "anyOf": [
                        {
                          "anyOf": [
                            {
                              "$ref": "#/components/schemas/VerificationResult"
                            },
                            {
                              "additionalProperties": true,
                              "description": "Extensible domain metadata; keys are not a closed schema.",
                              "type": "object",
                              "x-open-schema-reason": "Historical verification rows predate receipt-bound results; recorded JSON is returned without normalization and is not accepted evidence."
                            }
                          ]
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "result_message": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "started_at": {
                      "anyOf": [
                        {
                          "format": "date-time",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "status": {
                      "type": "string"
                    },
                    "verification_type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "id",
                    "status",
                    "recorded_status",
                    "created_by",
                    "read_attempts",
                    "read_limit",
                    "cancel_requested",
                    "result_message",
                    "verification_type",
                    "started_at",
                    "completed_at",
                    "created_at",
                    "backup_id",
                    "result",
                    "backup",
                    "created_by_user"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response; resource state is separate from HTTP acceptance."
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/verification.py:268"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Verification",
        "tags": [
          "verification"
        ],
        "x-credential-domain": "user-session",
        "x-response-source": "routers/verification.py:get_verification"
      }
    },
    "/api/v1/version": {
      "get": {
        "description": "Get API version information",
        "operationId": "get_version_api_v1_version_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "build_date": {
                      "type": "string"
                    },
                    "expected_compatible": {
                      "type": "string"
                    },
                    "features": {
                      "additionalProperties": false,
                      "properties": {
                        "agent_lifecycle": {
                          "type": "boolean"
                        },
                        "agent_remote_config": {
                          "type": "boolean"
                        },
                        "custom_ca_support": {
                          "type": "boolean"
                        },
                        "key_management": {
                          "type": "boolean"
                        },
                        "multi_key_authentication": {
                          "type": "boolean"
                        },
                        "virtnbdbackup_advanced_options": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "key_management",
                        "agent_lifecycle",
                        "custom_ca_support",
                        "multi_key_authentication",
                        "virtnbdbackup_advanced_options",
                        "agent_remote_config"
                      ],
                      "type": "object"
                    },
                    "major": {
                      "type": "integer"
                    },
                    "minor": {
                      "type": "integer"
                    },
                    "patch": {
                      "type": "integer"
                    },
                    "service": {
                      "type": "string"
                    },
                    "version": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "version",
                    "major",
                    "minor",
                    "patch",
                    "service",
                    "build_date",
                    "expected_compatible",
                    "features"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Get Version",
        "tags": [
          "public"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/api/v1/vms": {
      "get": {
        "description": "List all VMs with pagination, filtering, and sorting (protected)",
        "operationId": "list_vms_api_v1_vms_get",
        "parameters": [
          {
            "in": "query",
            "name": "skip",
            "required": false,
            "schema": {
              "default": 0,
              "minimum": 0,
              "title": "Skip",
              "type": "integer"
            }
          },
          {
            "description": "Clamped to 100 per page",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 50,
              "description": "Clamped to 100 per page",
              "minimum": 1,
              "title": "Limit",
              "type": "integer"
            }
          },
          {
            "in": "query",
            "name": "search",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Search"
            }
          },
          {
            "in": "query",
            "name": "agent_id",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Agent Id"
            }
          },
          {
            "in": "query",
            "name": "state",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "State"
            }
          },
          {
            "in": "query",
            "name": "group_id",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Group Id"
            }
          },
          {
            "in": "query",
            "name": "sort_by",
            "required": false,
            "schema": {
              "default": "name",
              "title": "Sort By",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "sort_order",
            "required": false,
            "schema": {
              "default": "asc",
              "title": "Sort Order",
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "inventory_present",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Inventory Present"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "has_more": {
                      "type": "boolean"
                    },
                    "items": {
                      "items": {
                        "additionalProperties": false,
                        "properties": {
                          "absent_since": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp; historical UTC values may omit the timezone offset.",
                                "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})?$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "agent_hostname": {
                            "type": "string"
                          },
                          "agent_id": {
                            "type": "string"
                          },
                          "backup_eligibility": {
                            "additionalProperties": false,
                            "properties": {
                              "eligible": {
                                "type": "boolean"
                              },
                              "has_raw": {
                                "type": "boolean"
                              },
                              "warnings": {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              }
                            },
                            "required": [
                              "eligible",
                              "has_raw",
                              "warnings"
                            ],
                            "type": "object"
                          },
                          "created_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "disks": {
                            "items": {
                              "additionalProperties": true,
                              "description": "Extensible domain metadata; keys are not a closed schema.",
                              "type": "object",
                              "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                            },
                            "type": "array"
                          },
                          "id": {
                            "type": "string"
                          },
                          "inventory_present": {
                            "type": "boolean"
                          },
                          "last_backup_at": {
                            "anyOf": [
                              {
                                "format": "date-time",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_backup_status": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_backup_type": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "last_observed_at": {
                            "anyOf": [
                              {
                                "description": "ISO 8601 timestamp; historical UTC values may omit the timezone offset.",
                                "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?(?:Z|[+-]\\d{2}:\\d{2})?$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "memory_kb": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "metadata": {
                            "additionalProperties": true,
                            "description": "Extensible domain metadata; keys are not a closed schema.",
                            "type": "object",
                            "x-open-schema-reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
                          },
                          "name": {
                            "type": "string"
                          },
                          "namespace": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "provider": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "replaces_vm_id": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "state": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "uuid": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vcpu_count": {
                            "anyOf": [
                              {
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vm_uid": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "vmi_uid": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "uuid",
                          "state",
                          "provider",
                          "namespace",
                          "vm_uid",
                          "vmi_uid",
                          "replaces_vm_id",
                          "last_backup_type",
                          "last_backup_status",
                          "id",
                          "name",
                          "memory_kb",
                          "vcpu_count",
                          "disks",
                          "metadata",
                          "inventory_present",
                          "last_observed_at",
                          "absent_since",
                          "agent_id",
                          "agent_hostname",
                          "created_at",
                          "last_backup_at",
                          "backup_eligibility"
                        ],
                        "type": "object"
                      },
                      "type": "array"
                    },
                    "limit": {
                      "type": "integer"
                    },
                    "skip": {
                      "type": "integer"
                    },
                    "total": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items",
                    "total",
                    "skip",
                    "limit",
                    "has_more"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful Response"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:347",
              "backend/routers/agents.py:352"
            ]
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "List Vms",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "user-session",
        "x-list-contract": {
          "completeness": "Current authorized query; concurrent changes can move offset boundaries. Counts and items are not a single snapshot.",
          "ordering": "requested sort field and direction, then id ascending",
          "pagination": "offset",
          "snapshot": false
        }
      }
    },
    "/api/v1/vms/ids-by-filter": {
      "post": {
        "description": "Get VM IDs matching filter criteria (for 'select all matching' across pages).",
        "operationId": "get_vm_ids_by_filter_api_v1_vms_ids_by_filter_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "additionalProperties": true,
                "properties": {
                  "agent_id": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "group_id": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "search": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "state": {
                    "anyOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [],
                "type": "object"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "count": {
                      "type": "integer"
                    },
                    "vm_ids": {
                      "items": {
                        "type": "string"
                      },
                      "type": "array"
                    }
                  },
                  "required": [
                    "vm_ids",
                    "count"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Vm Ids By Filter",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/api/v1/vms/{vm_id}": {
      "get": {
        "description": "Get VM details (protected)",
        "operationId": "get_vm_api_v1_vms__vm_id__get",
        "parameters": [
          {
            "in": "path",
            "name": "vm_id",
            "required": true,
            "schema": {
              "title": "Vm Id",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "absent_since": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "agent_hostname": {
                      "type": "string"
                    },
                    "agent_id": {
                      "type": "string"
                    },
                    "backup_count": {
                      "type": "integer"
                    },
                    "backup_eligibility": {
                      "additionalProperties": false,
                      "properties": {
                        "eligible": {
                          "type": "boolean"
                        },
                        "has_raw": {
                          "type": "boolean"
                        },
                        "warnings": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "eligible",
                        "has_raw",
                        "warnings"
                      ],
                      "type": "object"
                    },
                    "created_at": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "disks": {
                      "items": {
                        "additionalProperties": true,
                        "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                        "type": "object",
                        "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                      },
                      "type": "array"
                    },
                    "id": {
                      "type": "string"
                    },
                    "inventory_present": {
                      "type": "boolean"
                    },
                    "last_observed_at": {
                      "anyOf": [
                        {
                          "description": "ISO 8601 timestamp as serialized by the handler; legacy values may omit a UTC offset.",
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "memory_kb": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "name": {
                      "type": "string"
                    },
                    "namespace": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "provider": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "replaces_vm_id": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "state": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "uuid": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vcpu_count": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vm_metadata": {
                      "additionalProperties": true,
                      "description": "Provider and agent supplied domain metadata; keys vary by provider and installed capability.",
                      "type": "object",
                      "x-open-schema-reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
                    },
                    "vm_uid": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "vmi_uid": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "id",
                    "name",
                    "state",
                    "uuid",
                    "memory_kb",
                    "vcpu_count",
                    "disks",
                    "provider",
                    "namespace",
                    "vm_uid",
                    "vmi_uid",
                    "replaces_vm_id",
                    "inventory_present",
                    "last_observed_at",
                    "absent_since",
                    "vm_metadata",
                    "agent_id",
                    "agent_hostname",
                    "backup_count",
                    "created_at",
                    "backup_eligibility"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    },
                    {
                      "additionalProperties": false,
                      "properties": {
                        "detail": {
                          "const": "Invalid tenant credentials",
                          "type": "string"
                        }
                      },
                      "required": [
                        "detail"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Bearer absent, invalid, disabled, stale or organization unavailable",
            "headers": {
              "WWW-Authenticate": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Bearer absent, invalid, disabled, stale or organization unavailable",
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/deps.py:get_current_user/require_enabled_organization",
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "additionalProperties": false,
                      "properties": {
                        "code": {
                          "const": "DEMO_POLICY_DENIED",
                          "type": "string"
                        },
                        "message": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "code",
                        "message"
                      ],
                      "type": "object"
                    },
                    "environment": {
                      "const": "demo",
                      "type": "string"
                    },
                    "simulated": {
                      "const": true,
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "detail",
                    "environment",
                    "simulated"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Only in demo deployment mode: ordinary API surface is denied before handlers",
            "headers": {
              "X-Vnbui-Environment": {
                "schema": {
                  "type": "string"
                }
              },
              "X-Vnbui-Simulated": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "x-error-conditions": [
              "Only in demo deployment mode: ordinary API surface is denied before handlers"
            ],
            "x-error-sources": [
              "backend/middleware.py:DemoPolicyMiddleware.dispatch"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/agents.py:474"
            ]
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            },
            "description": "Validation Error"
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "security": [
          {
            "OAuth2PasswordBearer": []
          }
        ],
        "summary": "Get Vm",
        "tags": [
          "agents"
        ],
        "x-credential-domain": "user-session"
      }
    },
    "/health": {
      "get": {
        "description": "Shallow liveness check — always 200 while the process is up.\n\nMust stay dependency-free: liveness gates pod restarts, and coupling it to\nan external dependency (DB/S3) turns a dependency outage into a restart\nkill-loop. Deep dependency checks belong in /ready.",
        "operationId": "health_check_health_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "service": {
                      "const": "vnbui-api",
                      "type": "string"
                    },
                    "status": {
                      "const": "ok",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status",
                    "service"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Health Check",
        "tags": [
          "public"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/metrics": {
      "get": {
        "description": "Prometheus metrics endpoint for monitoring",
        "operationId": "prometheus_metrics_metrics_get",
        "responses": {
          "200": {
            "content": {
              "text/plain": {
                "schema": {
                  "type": "string"
                }
              }
            },
            "description": "Prometheus text exposition, version 0.0.4; UTF-8"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Request refused or failed",
            "x-error-sources": [
              "backend/routers/public.py:82"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          }
        },
        "summary": "Prometheus Metrics",
        "tags": [
          "public"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    },
    "/ready": {
      "get": {
        "description": "Deep readiness check — verifies required dependencies (PostgreSQL).\n\nReadiness gates Service endpoints, so a Postgres outage drains traffic from\nthe pod instead of masking the degradation behind 'Running 1/1'. Liveness\nmust NOT use this endpoint (a DB outage should drain, not kill-loop).",
        "operationId": "readiness_check_ready_get",
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "checks": {
                      "additionalProperties": false,
                      "properties": {
                        "database": {
                          "additionalProperties": false,
                          "properties": {
                            "required": {
                              "const": true,
                              "type": "boolean"
                            },
                            "status": {
                              "const": "ok",
                              "type": "string"
                            }
                          },
                          "required": [
                            "status",
                            "required"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "database"
                      ],
                      "type": "object"
                    },
                    "status": {
                      "const": "ready",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status",
                    "checks"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Successful response"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "detail": {
                      "const": "Invalid tenant credentials",
                      "type": "string"
                    }
                  },
                  "required": [
                    "detail"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch",
            "x-error-conditions": [
              "If a Bearer header is supplied, middleware may reject malformed tenant credentials before route dispatch"
            ],
            "x-error-sources": [
              "backend/core/tenant_context.py:184 tenant_middleware"
            ]
          },
          "500": {
            "content": {
              "text/plain": {
                "schema": {
                  "const": "Internal Server Error",
                  "type": "string"
                }
              }
            },
            "description": "Unhandled exception outside route-level conversion; body is plain text",
            "x-error-conditions": [
              "Unhandled exception outside route-level conversion; body is plain text"
            ],
            "x-error-sources": [
              "Starlette ServerErrorMiddleware (application debug=False)"
            ]
          },
          "503": {
            "content": {
              "application/json": {
                "schema": {
                  "additionalProperties": false,
                  "properties": {
                    "checks": {
                      "additionalProperties": false,
                      "properties": {
                        "database": {
                          "additionalProperties": false,
                          "properties": {
                            "code": {
                              "const": "DATABASE_UNAVAILABLE",
                              "type": "string"
                            },
                            "required": {
                              "const": true,
                              "type": "boolean"
                            },
                            "status": {
                              "const": "error",
                              "type": "string"
                            }
                          },
                          "required": [
                            "status",
                            "required",
                            "code"
                          ],
                          "type": "object"
                        }
                      },
                      "required": [
                        "database"
                      ],
                      "type": "object"
                    },
                    "status": {
                      "const": "not_ready",
                      "type": "string"
                    }
                  },
                  "required": [
                    "status",
                    "checks"
                  ],
                  "type": "object"
                }
              }
            },
            "description": "Required database probe failed"
          }
        },
        "summary": "Readiness Check",
        "tags": [
          "public"
        ],
        "x-credential-domain": "public-or-route-specific"
      }
    }
  },
  "x-contract-export-kind": "offline-source-schema; not observed live wire compatibility",
  "x-installed-profile": {
    "auth_mode": "single_organization",
    "edition": "community",
    "enabled_modules": []
  },
  "x-operator-contract-version": 1,
  "x-operator-first-support": {
    "planned_version": "6.0.75",
    "status": "DRAFT"
  },
  "x-registered-rate-limit-error": {
    "reachability": "Handler registered when enabled, but shipped routes have no limiter decorators or SlowAPIMiddleware; not asserted as an active route error.",
    "schema": {
      "additionalProperties": false,
      "properties": {
        "error": {
          "type": "string"
        }
      },
      "required": [
        "error"
      ],
      "type": "object"
    },
    "source": "backend/middleware.py:setup_rate_limiting -> slowapi._rate_limit_exceeded_handler",
    "status": 429
  },
  "x-response-schema-inventory": {
    "described_count": 190,
    "intentional_open_field_count": 46,
    "intentional_open_fields": [
      {
        "location": "200:application/json/properties/activities/items/properties/details",
        "method": "GET",
        "path": "/api/v1/activity",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/activities/items/properties/details",
        "method": "GET",
        "path": "/api/v1/activity/unified",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/items/properties/metrics",
        "method": "GET",
        "path": "/api/v1/agents",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/oneOf/2/properties/authority/properties/headers",
        "method": "POST",
        "path": "/api/v1/agents/backups/{backup_id}/storage-control",
        "reason": "Dynamic HTTP header names, each with a string value."
      },
      {
        "location": "200:application/json/properties/capabilities",
        "method": "GET",
        "path": "/api/v1/agents/{agent_id}",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/config",
        "method": "GET",
        "path": "/api/v1/agents/{agent_id}",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/metrics",
        "method": "GET",
        "path": "/api/v1/agents/{agent_id}",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/vms/items/properties/disks/items",
        "method": "GET",
        "path": "/api/v1/agents/{agent_id}",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/vms/items/properties/metadata",
        "method": "GET",
        "path": "/api/v1/agents/{agent_id}",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/config",
        "method": "PATCH",
        "path": "/api/v1/agents/{agent_id}/settings",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/items/items/properties/tags",
        "method": "GET",
        "path": "/api/v1/backups",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/details/properties/updated/items/properties/new_tags",
        "method": "POST",
        "path": "/api/v1/backups/bulk-tag",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/details/properties/updated/items/properties/old_tags",
        "method": "POST",
        "path": "/api/v1/backups/bulk-tag",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/tags",
        "method": "GET",
        "path": "/api/v1/backups/{backup_id}",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/vms/properties/by_status",
        "method": "GET",
        "path": "/api/v1/dashboard/summary",
        "reason": "Current VM state strings mapped to counts; null state normalizes to unknown."
      },
      {
        "location": "200:application/json/properties/rules/anyOf/0/items/additionalProperties",
        "method": "GET",
        "path": "/api/v1/groups/{group_id}",
        "reason": "Group validators inspect field/op/value and retain additional rule metadata."
      },
      {
        "location": "200:application/json/properties/rules/anyOf/0/items/properties/value",
        "method": "GET",
        "path": "/api/v1/groups/{group_id}",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/config",
        "method": "POST",
        "path": "/api/v1/health/agents/{agent_id}/heartbeat",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/trust_store/properties/fingerprints",
        "method": "GET",
        "path": "/api/v1/licensing",
        "reason": "Trusted key IDs mapped to SHA-256 public-key fingerprints."
      },
      {
        "location": "200:application/json/properties/trust_store/properties/fingerprints",
        "method": "POST",
        "path": "/api/v1/licensing/import",
        "reason": "Trusted key IDs mapped to SHA-256 public-key fingerprints."
      },
      {
        "location": "200:application/json/properties/trust_store/properties/fingerprints",
        "method": "PUT",
        "path": "/api/v1/licensing/registration-url",
        "reason": "Trusted key IDs mapped to SHA-256 public-key fingerprints."
      },
      {
        "location": "200:application/json/items/properties/recipients",
        "method": "GET",
        "path": "/api/v1/notifications/rules",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "201:application/json/properties/recipients",
        "method": "POST",
        "path": "/api/v1/notifications/rules",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/conditions",
        "method": "GET",
        "path": "/api/v1/notifications/rules/{rule_id}",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/recipients",
        "method": "GET",
        "path": "/api/v1/notifications/rules/{rule_id}",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/recipient",
        "method": "POST",
        "path": "/api/v1/notifications/test",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/reports/items/properties/filters/anyOf/0",
        "method": "GET",
        "path": "/api/v1/reports",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/filters/anyOf/0",
        "method": "POST",
        "path": "/api/v1/reports",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/filters/anyOf/0",
        "method": "GET",
        "path": "/api/v1/reports/{report_id}",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/filters/anyOf/0",
        "method": "PUT",
        "path": "/api/v1/reports/{report_id}",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/items/properties/filters",
        "method": "GET",
        "path": "/api/v1/saved-searches",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/filters",
        "method": "POST",
        "path": "/api/v1/saved-searches",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/filters",
        "method": "GET",
        "path": "/api/v1/saved-searches/{search_id}",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/properties/items/items/properties/tags/anyOf/0",
        "method": "GET",
        "path": "/api/v1/schedules",
        "reason": "User-defined tag keys and JSON values."
      },
      {
        "location": "201:application/json/properties/tags/anyOf/0",
        "method": "POST",
        "path": "/api/v1/schedules",
        "reason": "User-defined tag keys and JSON values."
      },
      {
        "location": "200:application/json/properties/tags/anyOf/0",
        "method": "GET",
        "path": "/api/v1/schedules/{schedule_id}",
        "reason": "User-defined tag keys and JSON values."
      },
      {
        "location": "200:application/json/properties/tags/anyOf/0",
        "method": "PUT",
        "path": "/api/v1/schedules/{schedule_id}",
        "reason": "User-defined tag keys and JSON values."
      },
      {
        "location": "200:application/json/properties/settings",
        "method": "GET",
        "path": "/api/v1/settings",
        "reason": "Legacy settings are keyed by arbitrary database setting names; values decode according to each stored value_type."
      },
      {
        "location": "200:application/json/properties/recipient",
        "method": "POST",
        "path": "/api/v1/settings/test-email",
        "reason": "Persisted JSON from an unvalidated dict input; arbitrary JSON values are retained."
      },
      {
        "location": "200:application/json/anyOf/0 -> #/components/schemas/RealtimePage/properties/items/items -> #/components/schemas/CursorRealtimeEvent/properties/payload",
        "method": "GET",
        "path": "/api/v1/updates",
        "reason": "Realtime producers attach event-specific JSON metadata; this best-effort feed is not an execution or snapshot protocol."
      },
      {
        "location": "200:application/json/anyOf/1/items -> #/components/schemas/LegacyRealtimeEvent/properties/payload",
        "method": "GET",
        "path": "/api/v1/updates",
        "reason": "Realtime producers attach event-specific JSON metadata; this best-effort feed is not an execution or snapshot protocol."
      },
      {
        "location": "200:application/json/properties/result/anyOf/0/anyOf/1",
        "method": "GET",
        "path": "/api/v1/verifications/{verification_id}",
        "reason": "Historical verification rows predate receipt-bound results; recorded JSON is returned without normalization and is not accepted evidence."
      },
      {
        "location": "200:application/json/properties/items/items/properties/disks/items",
        "method": "GET",
        "path": "/api/v1/vms",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/items/items/properties/metadata",
        "method": "GET",
        "path": "/api/v1/vms",
        "reason": "Persisted/provider-supplied domain metadata permits additional JSON values."
      },
      {
        "location": "200:application/json/properties/disks/items",
        "method": "GET",
        "path": "/api/v1/vms/{vm_id}",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      },
      {
        "location": "200:application/json/properties/vm_metadata",
        "method": "GET",
        "path": "/api/v1/vms/{vm_id}",
        "reason": "Provider and agent supplied domain metadata; keys vary by provider and installed capability."
      }
    ],
    "operation_count": 190,
    "qualification": "Recursive response-description inventory, including references, arrays, unions and bodyless/redirect outcomes. Intentional open fields remain listed separately. Coverage is not runtime validation, execution evidence or consumer compatibility.",
    "untyped": [],
    "untyped_count": 0
  },
  "x-source-commit": "8ed3ad2007d822c8e707477bb7037ec8fc9485d2",
  "x-source-tree-clean": true
}
