auth
auth login
Authenticate with PgBeam
Authenticate with PgBeam to access your projects and databases. Without flags,
the command opens an interactive prompt where you choose your authentication
method. Credentials are stored in a local profile on disk (~/.config/pgbeam/).
You can maintain multiple profiles for different environments using the
--profile flag.
Usage
pgbeam auth login [flags]Options
| Option | Description | Required | Default |
|---|---|---|---|
--api-key | Authenticate using an API key instead of browser-based OAuth. You will be prompted to paste a key generated from the PgBeam dashboard. | No | false |
Global options
All global options (--token, --profile,
--project, --org, --json, --no-color, --debug) are also available on
this command.
Examples
# Interactive login (prompts for method)
pgbeam auth login
# Login directly with an API key
pgbeam auth login --api-key
# Login with an API key and save to a named profile
pgbeam auth login --api-key --profile productionOutput
On success, prints a confirmation message with the authenticated profile name. The token is stored locally and used for all subsequent commands.