Authentication
The CLI authenticates with a token. Every session uses a gateway API key — there is no email/password flow. You create the key in the customer console, then hand it to the CLI through a flag, an environment variable, or a config file.
Sign in
Run login. The CLI resolves a token, validates it against the gateway, and saves it so later commands don't have to repeat it.
revenexx login
With no flags, login looks for a token in this order: the --token flag, the REVENEXX_API_KEY environment variable, then a .revenexx.yaml file in the current directory tree. If it finds one, it validates the token against the gateway and persists it to ~/.revenexx/prefs.json. If it finds none, it stops and tells you how to supply one.
For CI and scripts, pass the token and tenant directly:
revenexx login --token <token> --tenant <slug>
The request the CLI makes carries your key as X-Revenexx-Api-Key and the tenant as X-Revenexx-Tenant, against https://api.revenexx.com.
Credential resolution order
Any command that needs auth resolves its credentials the same way. The first source that has a value wins:
- CLI flag —
--token,--endpoint,--tenant - Environment variables —
REVENEXX_API_KEY,REVENEXX_API_URL,REVENEXX_TENANT - Project file — the nearest
.revenexx.yaml, walking up from the current directory - Global config —
~/.revenexx/prefs.json, written byrevenexx login - Built-in default — the endpoint defaults to
https://api.revenexx.com
The tenant slug has its own precedence: the --tenant flag, then the value set by tenants use (stored in ~/.revenexx/tenant), then REVENEXX_TENANT, then .revenexx.yaml.
Select a tenant
tenants scopes your commands to one tenant. Set it once and every later command applies there.
revenexx tenants use <slug>
When a key is available, use validates the slug against the gateway first and rejects a tenant the key can't reach. Pass --force to set it anyway.
Check or list what's active:
revenexx tenants current
revenexx tenants current --check
revenexx tenants list
tenants currentprints the active slug;--checkverifies it against the gateway.tenants listshows every tenant this machine knows about — from flags, environment,.revenexx.yaml, the saved slug, and login sessions — along with where each came from and whether your current key can reach it.
What's next
- Set up project configuration so the CLI knows your endpoint, tenant, and key.
- Run your first commands.
- Wire the CLI into a pipeline with non-interactive use.