Documentation
ReferenceCLIAuthentication

Authentication

Sign in from the browser, use a token in CI, pick the organization and project, and confirm protected actions with sudo.

Sign in

nulvless login

The CLI opens the Nulvless sign-in and consent screen in your browser. Once you approve, the browser hands the session back to the CLI on your own machine and the terminal confirms who you are signed in as.

The session is stored in your system keychain: macOS Keychain, Windows Credential Manager, or the Secret Service (GNOME Keyring, KWallet) on Linux. Where there is no keychain, it falls back to ~/.config/nulvless/session.json, readable only by your user. The access token is renewed automatically, so you stay signed in until you run nulvless logout or the session is revoked.

Whether the browser asks you to confirm your identity again depends on the Nulvless CLI app. When your last sign-in is older than its sign-in window, the consent screen asks for a code before it lets the CLI in.

nulvless whoami    # who is signed in, and their organizations
nulvless logout    # remove the session from this computer

In CI

Set NULVLESS_TOKEN to an access token. It takes precedence over any stored session, and the CLI never prompts when it is not attached to a terminal.

NULVLESS_TOKEN=… nulvless functions deploy --org acme --project shop --json

Organization and project

Commands that act on a project need to know which one. The CLI looks in this order:

SourceOrganizationProject
Flag--org <slug>--project <slug>
Environment variableNULVLESS_ORGNULVLESS_PROJECT
Workspaceorganization in nulvless/nulvless.jsoncproject in nulvless/nulvless.jsonc
Automaticthe only organization of your account—
Interactivea list to choose froma list to choose from

Outside a terminal there is no list to choose from, so a missing value is an error that names the flag to pass.

Environment

Commands that act on one environment, such as users, keys and oauth, take --env and default to main, which is production. templates is the exception: it always asks for --env, so you never push to production by accident.

Sudo

Some actions ask you to confirm it is you first: creating or revoking API keys, rotating signing keys and merging environments. The CLI sends a code to your email, phone or authenticator, asks for it, and runs the action. Sudo then stays active for a few minutes.

nulvless sudo    # confirm now, before a batch of protected actions

Outside a terminal, protected actions fail with a hint to run nulvless sudo in a terminal first. NULVLESS_TOKEN cannot be elevated.

On this page