Localess
CLI

Login

Authenticate with your Localess instance and store credentials securely.

Authenticate with your Localess instance. Credentials are validated immediately and stored securely in .localess/credentials.json with restricted file permissions (0600).

localess login --origin <origin> --space <space_id> --token <api_token>

If any option is omitted, the CLI will interactively prompt for the missing values.

Options

FlagDescription
-o, --origin <origin>Localess instance URL (e.g., https://my-localess.web.app)
-s, --space <space>Space ID (found in Localess Space settings)
-t, --token <token>API token (input is masked for security)

Examples

# Interactive login (prompts for any missing values)
localess login

# Non-interactive login (CI/CD)
localess login --origin https://my-localess.web.app --space MY_SPACE_ID --token MY_API_TOKEN

Authentication via Environment Variables

For CI/CD pipelines, you can provide credentials through environment variables instead of running localess login. The CLI automatically reads these variables and skips the file-based credentials:

export LOCALESS_ORIGIN=https://my-localess.web.app
export LOCALESS_SPACE=MY_SPACE_ID
export LOCALESS_TOKEN=MY_API_TOKEN

localess translations pull en --path ./public/locales/en.json
VariableDescription
LOCALESS_ORIGINLocaless instance URL
LOCALESS_SPACESpace ID
LOCALESS_TOKENAPI token

On this page