Platform
ScaiWave ScaiGrid ScaiCore ScaiBot ScaiDrive ScaiKey Models Tools & Services
Solutions
Organisations Developers Internet Service Providers Managed Service Providers AI-in-a-Box
Resources
Support Documentation Blog Downloads
Company
About Research Careers Investment Opportunities Contact
Log in

CLI reference

scaiwave — operator and developer tooling. Installed as part of the ScaiWave Python package; available wherever you can run the venv.

bash
1
scaiwave --help

Top-level structure#

text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
scaiwave
├── sync                        # ScaiKey identity sync
│   ├── register
│   ├── status
│   └── (default)               # full sync
├── admin                       # tenant + partner admin
│   ├── list-tenants
│   ├── create-tenant
│   ├── federation
│   │   └── key {generate|rotate}
│   └── ...
├── role                        # role management
│   └── ...
├── room                        # room export / import
│   ├── export
│   └── import
└── (top-level convenience commands)
    ├── register
    ├── status
    ├── show-config
    └── export-env

sync#

ScaiKey identity reconciliation.

bash
1
2
3
scaiwave sync register           # interactive: register this server with ScaiKey
scaiwave sync status             # registration / drift status
scaiwave sync                    # run a full reconcile (idempotent)

The full sync also runs every 10 minutes off-zero as an ARQ cron; this command is for manual runs. See docs/integrations/scaikey/sync.md.

admin#

list-tenants#

bash
1
scaiwave admin list-tenants

Tabular dump: slug, name, member count, room count, storage, AI tokens MTD.

create-tenant#

bash
1
2
scaiwave admin create-tenant --slug acme --name "Acme Corp" \
  --scaikey-tenant-id <id>

For partner-managed tenants, pass --partner-id.

federation key#

bash
1
2
scaiwave admin federation key generate   # initial key
scaiwave admin federation key rotate     # new key, 30-day overlap

room#

export#

bash
1
scaiwave room export <room-id> --tenant <tenant-slug> > out.zip

Pipes a ZIP bundle to stdout. Same content as GET /v1/rooms/{id}/export.

import#

bash
1
2
scaiwave room import <workspace-id> --tenant <tenant-slug> \
  --as <participant-id> < bundle.zip

Convenience commands#

These are aliases for the most-used sub-commands; useful in shell scripts.

Command Equivalent
scaiwave register scaiwave sync register
scaiwave status scaiwave sync status
scaiwave show-config scaiwave sync show-config
scaiwave export-env scaiwave sync export-env

Backfill scripts#

Not part of the scaiwave entry-point but useful operator tooling under scripts/:

bash
1
2
3
4
5
6
7
8
# Backfill the search index for historical messages.
.venv/bin/python scripts/backfill_search_index.py --execute --inline

# Smoke-test ScaiGrid service-token path.
.venv/bin/python scripts/scaigrid_service_token_smoke.py

# Push docs to scailabs.ai.
.venv/bin/python scripts/publish_docs.py --execute

Run them from the project root with the venv activated.

Authentication#

Every CLI command that talks to ScaiKey or ScaiGrid uses the same configuration as the API server (env vars in .env). For production use, the operator's environment should have the right admin scopes — typically a service account with tenant_admin or partner_admin role.

For one-off admin sessions:

bash
1
2
export SCAIWAVE_ADMIN_TOKEN="..."
scaiwave admin list-tenants

Exit codes#

Code Meaning
0 Success.
1 Domain error (e.g. tenant not found, bad slug).
2 Configuration error (missing env, unreachable backend).
3 Auth error.
Updated 2026-05-18 12:07:12 View source (.md) rev 4