lb login
Synopsis
Section titled “Synopsis”lb login [options]Description
Section titled “Description”lb login opens your default browser to the LoomBrain dashboard login page. After you complete authentication, the dashboard redirects to a local callback server, and the CLI stores credentials in ~/.config/loombrain/config.json.
The flow times out after 5 minutes if no callback is received.
Options
Section titled “Options”| Option | Type | Default | Description |
|---|---|---|---|
--api-url <url> | string | https://api.loombrain.com | Override the API base URL. |
--dashboard-url <url> | string | https://app.loombrain.com | Override the dashboard URL used for the OAuth redirect. |
--non-interactive | flag | — | Force non-interactive mode. Prints instructions for API key auth and exits. |
Non-interactive detection
Section titled “Non-interactive detection”When a browser cannot be opened, lb login detects the environment and exits with an error. Non-interactive mode is triggered by any of the following:
| Signal | Meaning |
|---|---|
SSH_CONNECTION set | Running over SSH |
SSH_CLIENT set | Running over SSH (older clients) |
SSH_TTY set | SSH with a TTY allocated |
CI=true set | Running in CI |
LB_NON_INTERACTIVE=1 set | Explicitly forced |
In non-interactive environments, use an API key instead:
export LB_TOKEN=lbk_...Generate API keys in the LoomBrain dashboard under Settings → API Keys. See Authentication for full details.
Examples
Section titled “Examples”Standard login (opens browser):
lb loginLogin against a self-hosted or staging API:
lb login --api-url https://api.staging.loombrain.com --dashboard-url https://app.staging.loombrain.comForce non-interactive mode to confirm the environment is detected correctly:
lb login --non-interactive