Skip to content
sauce-labs-cli
Menu

Feature

Credentials and Regions

Credentials from flags, the environment or a .env file, and one of three Sauce Labs Regions per command.

Flags win: --username and --access-key, then SAUCE_USERNAME and SAUCE_ACCESS_KEY. A .env and a .env.local file in the working directory are loaded first, .env.local taking precedence, and never overwrite a variable already set.

The Region comes from --region, then SAUCE_REGION, then us-west-1. The others are us-east-1 and eu-central-1.

--help and --version work without any Credentials; a command that needs them exits with code 2 and names what is missing.