Global flags
Global flags apply to one invocation. See the command reference.Credentials file and profiles
~/.testsprite/credentials is an INI file (directory 0700, file 0600, atomic writes). Each profile is a section holding an api_key, for example one for interactive use and one for CI.
testsprite setup writes a profile; --from-env skips the prompt in CI. Select a profile per command or per shell session:
Environment variables
The CLI checks
TESTSPRITE_API_KEY before the active profile’s api_key.
Output
--output json is the stable contract (Output & Scripting). Errors become a JSON envelope on stderr; exit codes are stable in either mode (Exit Codes & Errors).
Request timeouts
The per-request limit defaults to 120 seconds. Pass--request-timeout 30 or set TESTSPRITE_REQUEST_TIMEOUT_MS=30000 for a 30-second limit. The CLI separately applies --timeout to the whole wait on run --wait, run wait and ci run.
The dashboard link
The CLI prints a dashboard link when the server supplies one. In JSON, read the optionaldashboardUrl from the run receipt. To get the run IDs even when there is no link:
launch.json using the launch example in Output & Scripting.