CLI Reference
The revisium-cli provides commands for schema management, migrations, data export/import, and synchronization between Revisium instances.
Connection URL
All commands use the revisium:// protocol to connect:
revisium://host/org/project/branch?token=...
| Part | Example | Description |
|---|---|---|
host | cloud.revisium.io, localhost:9222 | Revisium instance |
org | admin | Organization (= username) |
project | my-project | Project name |
branch | master | Branch name |
?token=... | JWT token | Authentication (optional for standalone without auth) |
Examples
# Cloud
revisium://cloud.revisium.io/myuser/my-project/master?token=eyJ...
# Standalone (no auth)
revisium://localhost:9222/admin/my-project/master
# Docker
revisium://localhost:8080/admin/my-project/master?token=eyJ...
Authentication
When connecting to a Revisium instance, the CLI supports multiple auth methods:
- Token — paste a JWT from the Admin UI (Settings > Get Token)
- API Key — paste a personal or service API key (
rev_...). Sends viaX-Api-Keyheader. Recommended for programmatic and repeated local use. - Username & Password — enter credentials directly or set via env vars
# JWT token
revisium://localhost:9222/admin/my-project/master?token=eyJ...
# API key (via apikey parameter or auto-detected by rev_ prefix in token)
revisium://localhost:9222/admin/my-project/master?apikey=rev_xxxxxxxxxxxxxxxxxxxx
Environment Variables
Instead of --url, set these:
| Variable | Description |
|---|---|
REVISIUM_URL | Default connection URL |
REVISIUM_TOKEN | JWT token |
REVISIUM_API_KEY | API key (rev_...) — sends via X-Api-Key header |
REVISIUM_USERNAME | Username (for auto-login) |
REVISIUM_PASSWORD | Password (for auto-login) |
Interactive Mode
If --url is not provided and no environment variables are set, the CLI prompts interactively for connection details.