Skip to content

Central Hub REST API Reference

The Central Hub exposes its HTTPS API on port 8081. The web interface is its primary client; endpoint names and response fields can change between releases. Treat this page as an operational integration reference, not a substitute for the UI's safety checks.

Authentication and Authorization

Browser clients authenticate with the Hub session cookie. Obtain a CSRF token from GET /api/csrf-token and include it as X-CSRF-Token on every mutating request. Agent enrollment uses a short-lived bearer token where noted.

Role Access
viewer Read-only fleet status, telemetry, and configured policy.
operator Viewer access plus workload actions and logs.
admin Full configuration, agent, terminal, backup, and destructive-operation access.

Session and Policy

Method Endpoint Access Purpose
GET /api/health Public Hub health check.
GET /api/auth/status Public Login and setup state.
POST /api/auth/setup Public, first-run Creates the initial local account.
POST /api/auth/login, /api/auth/logout Session flow Starts or ends a local session.
GET /api/csrf-token, /api/policy Authenticated CSRF token and effective client policy.
GET, POST /api/auth/users Admin Lists or creates local users.

Fleet, Hosts, and Agents

Method Endpoint Access Purpose
GET /api/hosts Authenticated Configured host inventory and cached state.
POST /api/hosts/batch-status, /api/hosts/batch-stats Authenticated Refreshes state or metrics for multiple hosts.
GET /api/hosts/:ip/status, /api/hosts/:ip/stats Authenticated Live workload state and host metrics.
GET /api/agents/source, /api/agents/policy.json Enrollment flow Agent payload and installation policy.
GET /api/agents/enroll-token, /api/agents/install.sh Enrollment flow Enrollment token and tailored installer.
POST /api/agents/fingerprint, /api/agents/deploy Enrollment / Admin Registers an agent certificate or deploys an agent.
POST /api/agents/update-all, /api/hosts/:ip/agent-update Admin Updates all eligible agents or one host agent.
DELETE /api/agents/:ip Admin Removes a host from Hub management.
GET /api/agent-defaults, /api/hub/settings Admin Reads agent defaults or Hub configuration.
POST /api/hub/settings Admin Updates Hub configuration.
GET, POST /api/hosts/:ip/agent-config Admin Reads or updates one agent's configuration.
POST /api/agents/migrate-paths, /api/hosts/:ip/migrate-paths Admin Performs fleet or host path migration.

Workloads, Files, and Operations

Method Endpoint Access Purpose
POST /api/hosts/:ip/action, /api/hosts/:ip/batch-action Operator Runs lifecycle actions for one or many workloads.
POST /api/hosts/:ip/action-background Operator Starts a long-running action with tracked progress.
GET /api/hosts/:ip/action-status, /api/hosts/:ip/pull-status Authenticated Retrieves action or image-pull progress.
GET /api/hosts/:ip/logs, /app-logs, /system-logs, /logs/stream Operator Retrieves or streams workload and system logs.
GET, POST /api/hosts/:ip/config, /api/hosts/:ip/validate Admin Reads, saves, and dry-run validates managed configuration.
GET /api/hosts/:ip/secrets, /api/hosts/:ip/pod-containers Admin Inspects secrets metadata and a pod's container files.
GET, POST /api/hosts/:ip/volume-paths, /volume-file Admin Inspects or manages approved volume paths and files.
GET /api/hosts/:ip/port-preflight Admin Checks port ownership and firewall readiness.
GET, POST /api/hosts/:ip/remove-info, /remove-storage Admin Previews removal or removes selected managed storage.
POST /api/hosts/:ip/setup Admin Initializes supported host-side workload setup.

Terminal, Backup, and Monitoring

Method Endpoint Access Purpose
POST /api/hosts/:ip/containers/:id/terminal/start, /input, /resize, /close Admin Manages an interactive terminal session.
GET /api/hosts/:ip/containers/:id/terminal/stream Admin Streams terminal output over SSE.
GET, POST /api/hosts/:ip/app-backups, /app-backup, /app-rollback Admin Lists, creates, and restores app-level backups.
POST /api/hosts/:ip/pve-backup, /pve-prune Admin Creates or prunes configured Proxmox backups.
GET /api/pve/status, /api/pve/tasks/:node/:upid Authenticated Checks Proxmox availability or task progress.
GET, POST /api/hosts/:ip/critical-policies, /critical-settings Admin Reads or saves host monitoring configuration.
POST /api/hosts/:ip/critical-check, /notification-test Admin Runs a critical check or tests host notifications.
GET, POST /api/hub/notification-settings, /notification-test Admin Reads, updates, or tests Hub notifications.
GET /api/events Authenticated Server-sent events used for live Hub updates.

Request Guidance

Use URL-encoded path and query values. Mutating operations are audited, rate-limited where appropriate, and may return asynchronous progress rather than a completed result. Poll the relevant status endpoint or subscribe to /api/events instead of retrying a mutation blindly.