Skip to main content
Pick one: a browser login for your laptop, or API credentials in environment variables for CI and coding agents. Both end up as a named profile you can switch between.

Log in with a browser

Connect the CLI to your Plivo account with a browser-based login flow. The CLI opens the Plivo Console in your default browser; you sign in there and approve access. Your password never touches the CLI. After approval, the CLI stores a profile in ~/.plivo/config.toml and keeps the auth token in your operating system’s secure credential store (Keychain on macOS, Credential Manager on Windows, Secret Service on Linux). Use plivo auth list to see saved profiles and plivo auth use to switch between them. To remove a profile and its stored token, use plivo logout.
Running in CI, a container, or an AI coding agent where a browser can’t open? Skip plivo login entirely and set credentials as environment variables.
Command: plivo login Flags
  • -n, --name <profile>: name to save the profile under (default default).
  • --no-verify: skip the validation request to GET /Account/ after login (offline or mock use only).
Examples

Use API credentials (CI and agents)

For CI pipelines, containers, and AI coding agents, skip the browser login and pass your Auth ID and Auth Token as environment variables. Every command reads them automatically; environment variables take precedence over the active profile.
Find your Auth ID and Auth Token on the Console overview. Never commit them; load them from a secrets manager or a local .env file that is not checked in.
Anyone with these two values can act as your account. Prefer a subaccount with the minimum products enabled for automated use.
Useful companions in scripts:

Switch between accounts

A profile is a saved set of credentials. Most people have one; if you work across several Plivo accounts or subaccounts, save one profile per account and switch between them. Command: plivo auth <subcommand>

plivo auth list

List saved profiles and show which one is active.

plivo auth use <name>

Make a saved profile the active one for subsequent commands.

plivo auth whoami

Show the account behind the credentials the CLI would use right now: including whether they came from a profile or from environment variables ("meta": {"source": "env"}).

plivo auth remove <name>

Delete a profile and its stored token. Per-command override Any command accepts --profile <name> to run once under a different profile without switching:
Credential precedence is: --profile flag → PLIVO_AUTH_ID / PLIVO_AUTH_TOKEN environment variables → the active profile.

Log out

Remove a saved profile and delete its auth token from the operating system’s credential store. Command: plivo logout [profile] Flags
  • [profile]: the profile to log out (default: the active profile).
Examples