Skip to content
sauce-labs-cli
Menu

Product

The product

sauce-labs-cli wraps two Sauce Labs REST APIs, App Storage and Jobs, in one sauce command with consistent options, output and exit codes.

App Storage

App Storage is the Sauce Labs service that holds the application binaries your tests run against. sauce storage upload sends an App file and prints its File id; sauce storage download writes one back to disk.

sauce storage files lists App files (filter by File id, team id, org id, Kind or a search term), edits a file’s description and deletes files. sauce storage groups lists App groups, shows and updates their Group settings (Orientation, Instrumentation, Resigning or any other key) and deletes groups.

Jobs

sauce jobs list lists recent jobs for your Username; --real switches to Real-device jobs from the Real Device Cloud. sauce jobs info prints a Job summary, or the full API response with --verbose.

sauce jobs edit changes a Virtual-device job’s name, Tags, Visibility, Build, Custom data or Job result. Real-device jobs are read-only here: the Real Device Cloud API does not accept edits.

Output and exit codes

By default each command prints only the identifiers it produced, so output pipes into other tools. --verbose prints the full API response, --output yaml switches it from JSON to YAML, and --silent prints nothing.

Exit code 0 is success, 1 a general, API or validation error, 2 missing or invalid Credentials, and 77 an authentication rejected by Sauce Labs (HTTP 401 or 403).

Programmatic use

The API layer is exported from the package, so Node.js code can call listJobs, uploadFile and the other functions with a SauceClient directly. Failed requests reject with an HttpError carrying the status, URL and parsed body.

Unofficial

sauce-labs-cli is an independent, unofficial project. It is not affiliated with, endorsed by or sponsored by Sauce Labs Inc. “Sauce Labs” is a trademark of its owner and is used here only to name the APIs this tool calls.

You need your own Sauce Labs account to use it.

At a glance

Command
sauce
APIs
Sauce Labs App Storage and Jobs (REST)
Regions
us-west-1 (default), us-east-1, eu-central-1
Output
Terse ids, or JSON / YAML with --verbose
On npm
sauce-labs-cli 0.1.0 (Node.js 20 or later)
Source version
0.2.0, not yet published (Node.js 24 or later)
Prebuilt binaries
None released yet
License
MIT

Script App Storage and Jobs without curl

A Node.js command line tool you run on your machine or in CI, with your own Sauce Labs account. Nothing in between.