Skip to content

Profiles, Config, and CI

Use local profiles, JSON output, environment variables, and API keys for automation.

View as Markdown

The CLI is designed for both interactive terminal use and non-interactive automation.

Profiles

Profiles let you switch between different Smoketest credentials, workspaces, or API URLs.

Shell
smoketest auth login --profile production
smoketest auth login --profile staging
smoketest profiles list
smoketest profiles use production
smoketest profiles delete staging

The active profile is used when you do not pass --profile.

Default project

Set a default project for the active profile:

Shell
smoketest projects use "Production"

Commands such as tests create, tests list, and env create can then omit --project.

Local config

Shell
smoketest config list
smoketest config get activeProfile
smoketest config set activeProfile production
smoketest config unset activeProfile

Use profiles for credential-oriented operations and config for local defaults.

JSON output

Most resource commands support --json:

Shell
smoketest projects list --json
smoketest tests list --json
smoketest runs get <run> --json
smoketest billing status --json

JSON mode is intended for scripts. It disables interactive prompts, spinners, confirmation dialogs, and live terminal UI.

CI authentication

Create a Smoketest API key in the dashboard, store it in your CI secret manager, and expose it as:

Shell
SMOKETEST_API_KEY=smkt_...

Example:

Shell
SMOKETEST_API_KEY=smkt_... smoketest tests run "Homepage smoke test" --json

For CI, prefer --json and explicit flags so commands do not need a TTY.

Environment variables

VariablePurpose
SMOKETEST_API_KEYUse this API key instead of reading the local keychain
SMOKETEST_API_URLOverride the API origin
SMOKETEST_CONFIGOverride the local CLI config path
SMOKETEST_ALLOW_INSECURE_API_URLAllow non-HTTPS API URLs outside localhost

Shell completion

Print completion setup for your shell:

Shell
smoketest completion zsh
smoketest completion bash
smoketest completion fish

Add the printed snippet to your shell config.

Billing status

Shell
smoketest billing status
smoketest billing status --json

The command shows plan state, subscription/trial/boost credits, daily usage, period dates, and whether checkout or the customer portal is available.

On this page