Skip to main content

CLI Reference

Quick-reference table and flag reference for the lumio CLI.

Installation

npm install -g @zaflun/lumio-cli
# or
pnpm add -g @zaflun/lumio-cli

Commands

CommandDescription
lumio loginAuthenticate to your developer account
lumio logoutRemove stored credentials
lumio initScaffold a new extension
lumio devStart local development server
lumio buildBuild for production
lumio deployDeploy a new version
lumio statusShow extension status
lumio logsStream server function logs
lumio secrets set <KEY> <VALUE>Store a secret
lumio secrets delete <KEY>Delete a secret
lumio secrets listList secret key names

lumio login

lumio login [--token <api_key>]

Without --token, opens a browser-based OAuth flow. With --token, uses the provided API key directly (useful in CI).

FlagDescription
--token <key>Authenticate with an API key instead of browser flow

lumio init

lumio init [name] [--template <template>]
FlagDescription
--template <name>Scaffold from a template: blank, alert, scoreboard, poll, chat
--dir <path>Directory to create the project in (default: ./<name>)

lumio dev

lumio dev [--port <port>] [--no-open]

Starts a local development server with hot module replacement. Opens the preview URL in the browser automatically.

FlagDescription
--port <n>HTTP port for the dev server (default: 3010)
--no-openDo not open the browser automatically
--mock <file>Load a mock events file for simulating stream events

The dev server injects a mock Lumio runtime so useLumioEvent, useLumioConfig, and useLumioAction all work without a real connected overlay.


lumio build

lumio build [--outdir <path>]

Compiles and bundles all surfaces for production. Output goes to dist/ by default.

FlagDescription
--outdir <path>Output directory (default: dist)
--analyzePrint bundle size breakdown after build

Build fails if:

  • A surface bundle exceeds 5 MB (gzipped)
  • TypeScript type errors are present
  • lumio.config.json fails schema validation

lumio deploy

lumio deploy [--version <semver>] [--changelog <text>] [--dry-run]

Builds the extension and submits it as a new version for review. Equivalent to lumio build followed by POST /extensions/:id/versions.

FlagDescription
--version <semver>Override version from lumio.config.json
--changelog <text>Short changelog for this version
--dry-runBuild and validate but do not upload
--no-buildSkip the build step (use existing dist/)

After deploying, the version enters pending status and awaits review.


lumio status

lumio status [extension-id]

Prints the current extension status, latest version, install count, and pending review details.

FlagDescription
--jsonOutput as JSON

lumio logs

lumio logs [--tail] [--since <duration>] [--level <level>]

Streams server function logs to stdout. Requires the extension to have server functions enabled.

FlagDescription
--tailFollow new logs in real time (default: true)
--no-tailPrint recent logs and exit
--since <duration>Show logs from the past duration, e.g. 1h, 30m, 7d
--level <level>Filter by log level: debug, info, warn, error
--jsonRaw JSON log output

lumio secrets

lumio secrets set <KEY> <VALUE>
lumio secrets delete <KEY>
lumio secrets list

Manages secrets stored in Lumio Vault for your extension. Secrets are available in server functions via ctx.secrets.get().

SubcommandDescription
set <KEY> <VALUE>Create or update a secret
delete <KEY>Delete a secret
listList key names (values are never shown)

Secret keys must match [A-Z][A-Z0-9_]* (uppercase, starting with a letter).


Environment variables

VariableDescription
LUMIO_API_KEYAPI key — overrides stored credentials
LUMIO_EXTENSION_IDExtension ID — overrides lumio.config.json
LUMIO_API_URLOverride the API base URL (for self-hosted / staging)
NO_COLORDisable colored output

Exit codes

CodeMeaning
0Success
1General error (see stderr)
2Authentication error
3Validation error (config or bundle)
4Network error / API unreachable
5Rate limit exceeded