The CLI
Install the Operio CLI, sign in, and point it at a project
@operio/cli is the official command-line client for Operio. It talks to the same API as the web app, so anything you create from the terminal shows up in the UI immediately.
What it's good for
- CI gates — run a suite and fail the build if anything breaks, in one command.
- Tests in your repo — keep test cases as JSON next to the code they cover.
- Bulk work — creating twenty environments is a
forloop, not twenty trips through a UI. - AI agents — JSON output and stable exit codes let an agent run tests and read results on its own. See Agentic Usage.
Install
Requires Node.js 18 or newer.
npm install -g @operio/clipnpm add -g @operio/cliyarn global add @operio/clinpx @operio/cli whoamiA global install also puts op on your PATH — it is an alias for operio.
Authenticate
operio auth loginThis opens your browser to Operio's consent screen. Click Allow and you're done — you never type a password into the terminal.
✓ Logged in as you@example.com (Acme Inc.)Your session is stored under ~/.config/operio/ and refreshes itself as you work.
operio auth status # who you're signed in as
operio auth logout # clear stored credentialsSelect a project
Most commands act on a project. Pick one once instead of passing --project-id every time:
operio teams list
operio teams use <team-id>
operio projects list
operio projects use <project-id>
operio whoami # who you are, and what's currently selectedoperio whoami is the fastest way to answer "why is this hitting the wrong project?".
JSON (the default) reports your account alongside the selected team and project by name:
{
"email": "qa@example.com",
"organizationName": "Acme",
"team": { "id": "…", "name": "Default Team" },
"project": { "id": "…", "name": "Checkout" }
}--output table prints a greeting instead:
Logged in as Ada Lovelace (ada@example.com) 👋
Team: Default Team
Project: CheckoutIf a selection shows "available": false, it points at something this account can
no longer reach — pick a new one with teams use / projects use.
IDs are never guessed from names. Look one up with the matching list command
and pass it explicitly.
Output
Commands print JSON to stdout; progress and errors go to stderr, so redirection gives you a clean file.
operio tests list > tests.json # JSON (default)
operio --output table tests list # human-readable
operio --quiet tests run <id> --wait # no progress chatterList commands return compact summaries. Add --full on a detail command when you need the complete record:
operio runs get <run-id> --fullPasswords, tokens, and environment variables are stripped from every output format.
Exit codes
| Code | Meaning |
|---|---|
0 | Success |
1 | Test failure |
2 | Usage error |
3 | Authentication failure |
4 | Insufficient credits |
5 | Network failure |
6 | Rejected request |
7 | Temporary service failure — retry |
This is what makes --wait usable as a CI gate:
operio suites run <suite-id> --environment-id <env-id> --waitNext steps
- Browse the command reference
- Set up an AI agent to run tests for you