---
title: CLI reference
description: Every hubzoid command and subcommand in Hubzoid 1.0.1, with usage lines, arguments, options, defaults and exit codes for each one.
canonical_url: https://hubzoid.com/docs/reference/cli
last_updated: 2026-09-27
---

# CLI reference

Every hubzoid command and subcommand in Hubzoid 1.0.1, with usage lines, arguments, options, defaults and exit codes for each one.

The `hubzoid` command is installed with the package. `python -m hubzoid` runs the same CLI, which is useful from a source checkout. Every command accepts `--help`.

## Conventions

- A Hub path argument defaults to `.` (the current directory) unless the usage line shows it as required. Paths resolve against the directory you run the command from.
- The Hub's `.env` is loaded by the commands that build or serve the Hub, and it wins over variables already set in your shell. See [configuration](https://hubzoid.com/docs/reference/configuration).
- Commands that change access or runs (`grant`, `revoke`, `schedule pause`, `schedule resume`, `schedule cancel`, `backup`) record the operator as the actor, for example `cli:alice` or `cli:alice@build-host`.
- Exit code `0` means success. Where a command defines other codes, they are listed with the command.

## Command index

| Command | Purpose |
| --- | --- |
| [`hubzoid init`](https://hubzoid.com/docs/reference/cli#hubzoid-init) | Create a new Hub from a bundled template. |
| [`hubzoid new workflow`](https://hubzoid.com/docs/reference/cli#hubzoid-new-workflow) | Scaffold a code workflow in an existing Hub. |
| [`hubzoid run`](https://hubzoid.com/docs/reference/cli#hubzoid-run) | Serve one Hub: bridge, web chat, edge and optional surfaces. |
| [`hubzoid gateway`](https://hubzoid.com/docs/reference/cli#hubzoid-gateway) | Serve several Hubs behind one shared web chat. |
| [`hubzoid slack`](https://hubzoid.com/docs/reference/cli#hubzoid-slack) | Run the Slack adapter or print its manifest and service unit. |
| [`hubzoid inbound`](https://hubzoid.com/docs/reference/cli#hubzoid-inbound) | Run the WhatsApp, Telegram and webhook receiver or print its service unit. |
| [`hubzoid test`](https://hubzoid.com/docs/reference/cli#hubzoid-test) | Send one prompt to the Hub's agent and print the reply. |
| [`hubzoid doctor`](https://hubzoid.com/docs/reference/cli#hubzoid-doctor) | Check a Hub and its deployment. |
| [`hubzoid eval`](https://hubzoid.com/docs/reference/cli#hubzoid-eval) | Run and inspect the Hub's eval cases. |
| [`hubzoid schedule`](https://hubzoid.com/docs/reference/cli#hubzoid-schedule) | Inspect, fire, pause, resume and cancel scheduled work. |
| [`hubzoid grant`](https://hubzoid.com/docs/reference/cli#hubzoid-grant) | Grant a permission to a person. |
| [`hubzoid revoke`](https://hubzoid.com/docs/reference/cli#hubzoid-revoke) | Revoke a permission. |
| [`hubzoid access`](https://hubzoid.com/docs/reference/cli#hubzoid-access) | Check, list, bootstrap, migrate and sync access. |
| [`hubzoid audit`](https://hubzoid.com/docs/reference/cli#hubzoid-audit) | Show restricted tool decisions. |
| [`hubzoid backup`](https://hubzoid.com/docs/reference/cli#hubzoid-backup) | Save a deployment's state to one archive. |
| [`hubzoid restore`](https://hubzoid.com/docs/reference/cli#hubzoid-restore) | Put a backup back. |
| [`hubzoid version`](https://hubzoid.com/docs/reference/cli#hubzoid-version) | Print the installed version. |

## Create a Hub

### hubzoid init

Scaffold a new Hub folder from a bundled template.

```bash
hubzoid init [NAME] [--template minimal|demo|watchtower] [--model MODEL] [--force]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `NAME` | `path` | `"demo-hub"` | Folder to create under the current directory. Pass . to initialize the current directory itself. |
| `--template, -t` | `string` | `"minimal"` | Bundled template. minimal is a small runnable Hub with one example of each file type. demo is a guided tour with a guide agent, teaching skills and knowledge pages. watchtower is a workflow-first sample that checks bundled metrics on a schedule. |
| `--model` | `string` |  | Model for a new Hub, written to MODEL in .env, for example codex-local, claude-local or a provider model id. |
| `--force` | `boolean` | `false` | Overwrite files that already exist in the Hub folder. |

What it writes:

- Every file of the template into the Hub folder. Existing files are skipped unless you pass `--force`. Runtime state (`.hubzoid/`, `.openwebui-data/`) is never copied.
- A `.env` with a random `BRIDGE_API_KEYS` value, created with mode `0600`. `MODEL` is `--model` when given. Otherwise, in an interactive terminal on a new Hub, Hubzoid detects authenticated local `claude` and `codex` logins, uses the only one it finds, or asks once when both are usable. Without either, `MODEL=claude-local`.
- When the parent folder looks new (empty, or holding only dotfiles, `README.md`, `requirements.txt`, `LICENSE`, `LICENSE.md` or `.env`), a repository wrapper in the parent: `requirements.txt` pinned to the installed Hubzoid version, `.gitignore` and `README.md`. Existing parent files are never overwritten, even with `--force`.

Run `hubzoid init` again in the same parent to add another Hub beside the first. An unknown template name exits with code `2` and lists the templates that exist. See [templates](https://hubzoid.com/docs/getting-started/templates).

### hubzoid new workflow

Scaffold `workflows/<name>/main.py` with a runnable example workflow.

```bash
hubzoid new workflow NAME [HUB_DIR]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `NAME` | `string` | Required | Workflow folder name, for example review-prs. The function name is the slugified name with hyphens turned into underscores. |
| `HUB_DIR` | `path` | `"."` | Hub directory. |

The generated file declares a manual workflow with `@workflow()`, reads and writes `hub.state`, and performs a side effect in a `@step`. It needs no model or outside service. The command prints the `hubzoid schedule run` line that runs it once. Add a schedule and timezone after you have tested its effects. The command exits with code `1` if the folder already exists. See [code workflows](https://hubzoid.com/docs/guides/code-workflows).

## Serve

### hubzoid run

Start one Hub: the bridge, the web chat (Open WebUI), the public edge and any surfaces you ask for.

```bash
hubzoid run [HUB] [--port N] [--bridge-port N] [--host ADDR] [--no-ui] [--slack] [--whatsapp] [--telegram] [--webhook]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | Hub directory. It must contain AGENTS.md. |
| `--port` | `integer` | `PORT, else 3080` | Public port for the web chat and the edge. |
| `--bridge-port` | `integer` | `BRIDGE_PORT, else 8000` | Port of the bridge. The bridge always binds 127.0.0.1. |
| `--host` | `string` | `"127.0.0.1"` | Interface the public port binds to. Use 0.0.0.0 to listen on every interface. Also read from HUBZOID\_HOST. |
| `--no-ui` | `boolean` | `false` | Start the bridge only, without the web chat or edge. |
| `--slack, -s` | `boolean` | `false` | Also start the Slack adapter in Socket Mode. Skipped with a warning when SLACK\_BOT\_TOKEN or SLACK\_APP\_TOKEN is missing. |
| `--whatsapp` | `boolean` | `false` | Also serve the WhatsApp webhook. Skipped with a warning when a WHATSAPP\_ variable is missing. |
| `--telegram` | `boolean` | `false` | Also serve the Telegram webhook. Skipped with a warning when a TELEGRAM\_ variable is missing. |
| `--webhook` | `boolean` | `false` | Also serve the generic webhook receiver for alerting, CI and automations. Skipped when WEBHOOK\_INBOUND\_SECRET is missing. |

What starts, in order:

1. The bridge on `127.0.0.1:<bridge-port>`. The command waits up to 60 seconds for `/healthz` and exits with code `1` if the bridge does not come up.
2. The web chat on a loopback port. By default this is the public port plus 40000 (or plus 1 when that would pass 65000). `HUBZOID_OWUI_PORT` overrides it.
3. The edge on `<host>:<port>`. It forwards `/artifacts` and `/portal` to the bridge, `/mcp` when `MCP_SERVER=true`, `/webhooks/<hub>` when an inbound surface is enabled, and everything else to the web chat.
4. The Slack adapter and the inbound receiver as child processes, when requested and configured.

With `HUBZOID_DISABLE_EDGE=1`, no edge runs and the web chat binds the public port itself. `Ctrl+C` stops every child process. The command exits with code `2` when the Hub folder or its `AGENTS.md` is missing. See [architecture](https://hubzoid.com/docs/concepts/architecture) and [single server](https://hubzoid.com/docs/deploy/single-server).

### hubzoid gateway

Run one shared web chat over several Hubs, with one headless bridge per Hub.

```bash
hubzoid gateway HUB [HUB ...] [--port N] [--host ADDR] [--public-url URL] [--name NAME] [--data-dir DIR] [--launch-bridges | --no-bridges]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUBS` | `path list` | Required | Hub directories to serve. Folder names must be unique, ignoring case, and each must contain AGENTS.md. |
| `--port` | `integer` | `PORT, else 3080` | Public port of the shared web chat. |
| `--host` | `string` | `"127.0.0.1"` | Interface the public edge binds to. Also read from HUBZOID\_HOST. |
| `--public-url` | `string` | `HUBZOID_PUBLIC_URL` | Public base URL, for example https\://hub.example.com. Used to build download links for each Hub. |
| `--name` | `string` | `"Hubzoid"` | Display name of the shared web chat. |
| `--data-dir` | `path` | `"./.hubzoid-gateway"` | State folder for the shared web chat, the deployment manifest and the shared operational database. |
| `--launch-bridges / --no-bridges` | `boolean` | `--launch-bridges` | Launch each Hub bridge as a child process. Use --no-bridges when bridges already run as separate services. |

Behavior worth knowing:

- The gateway writes `<data-dir>/deployment.json`. Bridges and operator commands discover it, so a `hubzoid grant` run in any Hub folder lands in the store the gateway reads.
- All bridges share one operational database, `sqlite:///<data-dir>/hubzoid-operational.db`, unless `HUBZOID_OPERATIONAL_DB` or `DATABASE_URL` is set. Workflow engine databases stay per Hub. A multi-Hub gateway refuses a SQLite `HUBZOID_DBOS_DB`.
- Each bridge runs as `hubzoid run <hub> --no-ui` with scheduled code workflows enabled.
- Downloads route through `/b/<hub>/artifacts`, MCP through `/b/<hub>/mcp` for Hubs with `MCP_SERVER=true`, and the Console through `/portal`.
- With `HUBZOID_GATEWAY_ADMIN_EMAIL`, `HUBZOID_GATEWAY_ADMIN_PASSWORD` and `WEBUI_AUTH=true`, each Hub's model entry and team group are provisioned in the web chat at boot.

See [gateway deployment](https://hubzoid.com/docs/deploy/gateway).

### hubzoid slack

Slack chat surface. The adapter uses Socket Mode, so it needs no public URL.

```bash
hubzoid slack run [HUB]
hubzoid slack manifest [HUB] [--format json|yaml]
hubzoid slack systemd [HUB] [--user USER] [--python PATH]
```

| Subcommand | What it does |
| --- | --- |
| `run` | Starts the adapter in the foreground. The Hub's bridge must already be running (`hubzoid run`). Reads `SLACK_BOT_TOKEN` and `SLACK_APP_TOKEN` from the Hub's `.env` and exits with code `2` when either is missing. |
| `manifest` | Prints a Slack app manifest filled in from `AGENTS.md` to stdout. Paste it into Slack's app creation page. |
| `systemd` | Prints a systemd unit for `hubzoid-slack@<hub>.service` to stdout. |

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | Hub directory. |
| `--format, -f` | `string` | `"json"` | manifest only. Output format, json or yaml. |
| `--user` | `string` | `"hubzoid"` | systemd only. Linux user that runs the service. |
| `--python` | `path` | `the interpreter running the command` | systemd only. Python interpreter for the unit. |

See [Slack](https://hubzoid.com/docs/chat/slack).

### hubzoid inbound

The receiver for WhatsApp, Telegram and the generic webhook.

```bash
hubzoid inbound run [HUB]
hubzoid inbound systemd [HUB] [--user USER] [--python PATH]
```

| Subcommand | What it does |
| --- | --- |
| `run` | Serves every configured surface on `127.0.0.1:HUBZOID_INBOUND_PORT` (default `8100`) under `/webhooks/<hub>/`. The bridge must already be running. Exits with code `1` when no surface is configured and `2` when the Hub has no `AGENTS.md`. |
| `systemd` | Prints a systemd unit for `hubzoid-inbound@<hub>.service` to stdout. Takes the same `--user` and `--python` options as `hubzoid slack systemd`. |

`hubzoid run --whatsapp`, `--telegram` or `--webhook` starts the same receiver for you. See [WhatsApp and Telegram](https://hubzoid.com/docs/chat/whatsapp-and-telegram) and [webhooks](https://hubzoid.com/docs/guides/webhooks).

## Test and check

### hubzoid test

Send one prompt to the Hub's agent and print the reply. Runs in process, with no bridge or web chat.

```bash
hubzoid test [HUB] [--prompt TEXT] [--file PATH ...]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | Hub directory. |
| `--prompt` | `string` | `"Reply with the single word: pong"` | The prompt to send. |
| `--file, -f` | `path` |  | Attach a local file. Repeatable. Files are staged into the cli-test chat so the agent reads them with read\_upload, or sees them directly when they are images. |

The backend follows the Hub's model: `claude-local` runs on the Claude Agent SDK, `codex-local` on local Codex, and anything else on the OpenAI Agents SDK. With `--file`, uploads and artifacts live in `<hub>/.hubzoid/chats/cli-test/`. A file larger than `HUBZOID_MAX_UPLOAD_BYTES` exits with code `2` before the model is called.

### hubzoid doctor

Check a Hub and its deployment. Read only.

```bash
hubzoid doctor [HUB] [--json] [--skip-secret-fetch]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | Hub directory. |
| `--json` | `boolean` | `false` | Print the checks as JSON with stable check ids. |
| `--skip-secret-fetch` | `boolean` | `false` | Do not call AWS Secrets Manager. Named secrets are listed but not read. |

Exit codes: `0` when no check fails, `1` when any check fails, `2` when the Hub folder does not exist. Every check id is described in the [doctor reference](https://hubzoid.com/docs/reference/doctor).

### hubzoid eval

Run the Hub's eval cases from `evals/*.md` and inspect results.

```bash
hubzoid eval run [HUB] [--tag TAG] [--case GLOB] [--no-judge] [--judge-model MODEL] [--model MODEL] [--compare] [--quiet]
hubzoid eval list [HUB]
hubzoid eval status [HUB]
hubzoid eval explain HUB CASE
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | Hub directory. Required for explain. |
| `CASE` | `string` |  | explain only. Case name, the file name without .md. |
| `--tag` | `string` |  | run only. Only cases carrying this tag. |
| `--case` | `string` |  | run only. Only cases whose name matches this glob, for example refund-\*. |
| `--no-judge` | `boolean` | `false` | run only. Skip the grading call. The agent still runs. |
| `--judge-model` | `string` | `HUBZOID_EVAL_JUDGE_MODEL, else the Hub model` | run only. Model that grades. |
| `--model` | `string` |  | run only. Override the model under test for this run. |
| `--compare` | `boolean` | `false` | run only. Also show what changed since the previous run. |
| `--quiet, -q` | `boolean` | `false` | run only. Print only the summary and failures. |

| Subcommand | What it does |
| --- | --- |
| `run` | Runs the selected cases through the Hub's own runtime and writes `.hubzoid/evals/<timestamp>.json`. Exits with code `1` when any case fails, `2` when a case file cannot be parsed, and `0` when there are no cases. |
| `list` | Lists each case with its checks, tags and schedule. |
| `status` | Shows the last run, its pass rate and the cases failing now. |
| `explain` | Prints the prompt, full response, tool calls, each check's verdict and the judge's reasoning for one case from the last run. |

See [evals](https://hubzoid.com/docs/guides/evals).

## Schedules and runs

### hubzoid schedule

Inspect and control markdown tasks (`schedule/*.md`) and code workflows (`workflows/<name>/*.py`). Scheduled work fires inside the running bridge. These commands inspect it and act on it.

```bash
hubzoid schedule list [HUB]
hubzoid schedule status [HUB]
hubzoid schedule run HUB TASK [--timeout SECONDS] [--max-rounds N] [--model MODEL] [--dry-run]
hubzoid schedule pause HUB NAME
hubzoid schedule resume HUB NAME
hubzoid schedule cancel HUB RUN_ID
```

| Subcommand | What it does |
| --- | --- |
| `list` | One line per code workflow and markdown task (as `md:<task>`) with state, timezone, next run and the account it runs as, or `cannot run:` with the fix. Then markdown tasks with their cron in words, next fire time, last result and flags (script, model, commit, push). Webhook tasks show their trigger. Exits with code `1` when any task file is invalid. |
| `status` | Code workflow state, next run and missed slots, the 20 most recent runs with status and duration, and each markdown task's first seen, last fired, last result and last run log. |
| `run` | Fires one task or workflow now. See below. |
| `pause` | Stops scheduled runs of one markdown task or code workflow until resumed. Runs already queued or running continue (use `cancel`). Manual runs still work. Recorded in the access audit. |
| `resume` | Resumes scheduled runs. A markdown task that became due while paused runs once. Code workflows do not back-fill missed slots. |
| `cancel` | Cancels a queued or running run by id. The run stops at its next step boundary. Work already done, such as a sent message or a pushed commit, is not undone. Recorded in the access audit. |

`schedule run` looks for a markdown task named `TASK` first. It runs on the Hub's workflow engine on the same one-at-a-time markdown queue as scheduled fires, so it never overlaps a scheduled run, and it ignores the cron and the idle gate. When no markdown task matches, it looks for a code workflow by folder or function name (hyphens and underscores are interchangeable) and runs it.

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | Hub directory. Required for run, pause, resume and cancel. Defaults to the current directory for list and status. |
| `TASK` | `string` | Required | run only. Markdown task name (the file name without .md) or code workflow name. |
| `NAME` | `string` | Required | pause and resume. Markdown task or code workflow name. An md: prefix is accepted for markdown tasks. |
| `RUN_ID` | `string` | Required | cancel only. The run id from schedule status or the Console. |
| `--timeout` | `integer` |  | run only. Override the task per-round timeout in seconds. Markdown tasks only. |
| `--max-rounds` | `integer` |  | run only. Override the task round cap. Markdown tasks only. |
| `--model` | `string` |  | run only. Override the model for an agent task, for example claude-local/opus. Ignored for run: script tasks. |
| `--dry-run` | `boolean` | `false` | run only. Print the first-round prompt, or the script command, and exit. For a code workflow, print which workflow would run. |

Exit codes for `schedule run`: `0` when the task reported done or the workflow returned, `1` when the run failed or ended without finishing, `2` when no task or workflow matched or a workflow was given `--timeout`, `--max-rounds` or `--model`. See [operating runs](https://hubzoid.com/docs/guides/operating-runs) and [markdown tasks](https://hubzoid.com/docs/guides/markdown-tasks).

## Access

These commands act on the access store for the Hub, or on the shared store of a gateway when the Hub belongs to one. `grant` and `revoke` print the store they write to, with any password hidden. See [access administration](https://hubzoid.com/docs/deploy/access-administration).

### hubzoid grant

```bash
hubzoid grant SUBJECT PERMISSION [HUB_DIR] [--hub NAME] [--org]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `SUBJECT` | `string` | Required | Who receives the permission: an account email. The account need not exist yet. A legacy workflow identity such as workflow:\<name> is still accepted, but runs that act as an account do not use its grants. |
| `PERMISSION` | `string` | Required | Permission name, for example use\_hub, manage\_access or the file stem of a restricted tool. |
| `HUB_DIR` | `path` | `"."` | Hub directory, used to find the access store. |
| `--hub` | `string` | `the Hub folder name` | Hub name the grant applies to. |
| `--org` | `boolean` | `false` | Grant across every Hub. Only manage\_access can be granted this way. |

Granting any tool permission also grants `use_hub` in the same Hub. The wildcard permission `*` is never grantable. New access for everyone signed in (the subject `*`) is refused and exits with code `1`. An existing one can still be removed with `hubzoid revoke '*' use_hub --hub <hub>`. Scheduled work runs as an account, so grant the permissions a workflow needs to the account it runs as.

### hubzoid revoke

```bash
hubzoid revoke SUBJECT PERMISSION [HUB_DIR] [--hub NAME] [--org]
```

Takes the same arguments as `grant`. Revoking `use_hub` removes every permission the subject holds in that Hub. The command refuses to remove the last organization admin and exits with code `1`.

### hubzoid access

```bash
hubzoid access check SUBJECT [HUB_DIR] [--hub NAME]
hubzoid access list [HUB_DIR] [--hub NAME]
hubzoid access bootstrap [HUB_DIR] [--admin SUBJECT ...] [--authoritative]
hubzoid access migrate [HUB_DIR] [--from-owui URL] [--model-id ID] [--standalone-public] [--apply] [--remigrate]
hubzoid access diff [HUB_DIR] [--from-owui URL] [--model-id ID] [--standalone-public]
hubzoid access rollback BACKUP [HUB_DIR]
hubzoid access sync [HUB_DIR]
```

| Subcommand | What it does |
| --- | --- |
| `check` | Prints every permission a subject effectively holds in a Hub, including organization and public grants. |
| `list` | Lists all grants as subject, permission and Hub. `--hub` limits the list to one Hub. |
| `bootstrap` | First boot. Grants organization `manage_access` to each `--admin` once (idempotent). `--authoritative` makes the access store the authority for this Hub on a fresh install with nothing to migrate. |
| `migrate` | Turns legacy access (`identity/access.csv`, plus Open WebUI groups and model access with `--from-owui`) into direct grants. A dry run by default. `--apply` performs the cutover. |
| `diff` | Shows grants the migration plan would add (`+`) and stale grants in the store (`-`). A zero diff is the cutover gate. |
| `rollback` | Restores an access snapshot written by `migrate --apply`. The snapshot must belong to the selected Hub. |
| `sync` | Recomputes which Hubs each person can see and mirrors that into the web chat. The recovery path when a projection was missed. Exits with code `1` on error. |

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `--admin` | `string` |  | bootstrap. Subject to make an organization admin. Repeatable. |
| `--authoritative` | `boolean` | `false` | bootstrap. Make the access store authoritative now. |
| `--from-owui` | `string` |  | migrate and diff. Open WebUI database URL to read groups and model access from. |
| `--model-id` | `string` |  | migrate and diff. Which Open WebUI model is this Hub, required when several exist. |
| `--standalone-public` | `boolean` | `false` | migrate and diff. Confirm the legacy standalone signed-in public entry for a Hub that is not in a gateway. |
| `--apply` | `boolean` | `false` | migrate. Apply the plan and make the access store authoritative. |
| `--remigrate` | `boolean` | `false` | migrate. Allow --apply on a Hub that is already migrated. This overwrites access edits made since the first migration. |

`migrate --apply` refuses to run without model evidence (`--from-owui` or `--standalone-public`), refuses an empty plan, writes a snapshot to `.hubzoid/backups/access-<id>.json` before it changes anything, and exits with code `1` unless the store matches the plan exactly afterwards. It exits with code `2` when the migration is blocked, when effective access would change, or when the Hub is already migrated and `--remigrate` is absent.

### hubzoid audit

Show restricted tool decisions: who called which restricted tool, on which surface, and whether it was allowed.

```bash
hubzoid audit [HUB] [--limit N] [--user EMAIL] [--denied]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | Hub directory. |
| `--limit, -n` | `integer` | `50` | Show the most recent N decisions. |
| `--user` | `string` |  | Only this user. |
| `--denied` | `boolean` | `false` | Only denied attempts. |

Each line shows the time, user, `ALLOW` or `DENY`, the tool, and the surface with the reason. The Console's Activity page shows the same decisions. See [people and activity](https://hubzoid.com/docs/console/people-and-activity).

## Operations

### hubzoid backup

Save a deployment's databases, chat data and Hub state to one archive while chat keeps working.

```bash
hubzoid backup [HUB] [--out PATH] [--include-secrets] [--wait SECONDS]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `HUB` | `path` | `"."` | A Hub directory. A Hub that belongs to a gateway backs up the whole gateway. |
| `--out, -o` | `path` | `"./hubzoid-backup-<YYYYMMDD-HHMMSS>.tar.gz"` | Archive path. |
| `--include-secrets` | `boolean` | `false` | Also save .env files, signing keys and database passwords. |
| `--wait` | `integer` | `600` | Seconds to wait for running scheduled work to finish. 0 does not wait. |

New scheduled runs are held while the backup runs, and running ones finish first. Hub content (`AGENTS.md`, skills, knowledge) belongs in Git and is not included. PostgreSQL databases are not included either. The command names each one so you can back it up with `pg_dump`. The archive holds user accounts and chats, so store it like a secret. Exits with code `1` on error. See [backup and restore](https://hubzoid.com/docs/deploy/backup-and-restore).

### hubzoid restore

Put a backup back. Stop the Hub or gateway first.

```bash
hubzoid restore ARCHIVE [--move OLD=NEW ...] [--dry-run]
```

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| `ARCHIVE` | `path` | Required | An archive written by hubzoid backup. |
| `--move` | `string` |  | OLD=NEW. Restore paths under OLD to NEW instead. Repeatable. |
| `--dry-run` | `boolean` | `false` | Print where everything would go and stop. |

Everything returns to its original path unless moved. Whatever is at a target now is kept beside it as `<name>.pre-restore-<time>`. When database passwords were left out of the saved deployment manifest, the command says so. Start the gateway before any bridge, because `hubzoid gateway` rewrites that manifest from its environment. Run `hubzoid doctor` after starting.

### hubzoid version

```bash
hubzoid version
```

Prints the installed Hubzoid version.

## Next steps

- [Configuration](https://hubzoid.com/docs/reference/configuration): Every environment variable the commands and the runtime read.
- [Doctor checks](https://hubzoid.com/docs/reference/doctor): What each doctor check id means and how to fix a failure.
- [Operating runs](https://hubzoid.com/docs/guides/operating-runs): Pause, resume, cancel and inspect scheduled work.
- [Hub files](https://hubzoid.com/docs/reference/hub-files): Every file and folder a Hub can contain.
