Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.baseten.co/llms.txt

Use this file to discover all available pages before exploring further.

Log in, log out, and manage Baseten credentials. Credentials are stored in the system keyring when available, with a plaintext fallback in the config directory.

login

baseten auth login [OPTIONS]
Log in to Baseten via browser (OAuth device flow) or API key. By default, opens a browser for interactive login. Use —web to skip prompts (suitable for non-TTY environments). Use —with-api-key to provide an API key (reads from stdin, or prompts interactively if TTY).

Options

--insecure-storage
BOOL
Store credentials in plain text instead of system keyring
-q, --jq
TEXT
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
--label
TEXT
Label for the API key credential
-o, --output
TEXT
default:"text"
Output formatOne of: text, json, jsonl, none
--remote-url
TEXT
Baseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
--web
BOOL
Use browser login without interactive prompts
--with-api-key
BOOL
Read API key from stdin
-v, --verbose
BOOL
Enable verbose logging

Examples

Browser-based login (OAuth device flow)
baseten auth login --web
Provide an API key on stdin
echo $API_KEY | baseten auth login --with-api-key --label <label>

Filter output with --jq

Print just the logged-in user’s email
baseten auth login --web --jq '.email'

Output

Text mode (--output text): Prints “Logged in as email (workspace)” to stdout on success. JSON mode (--output json): payload type cmd.AuthLoginResult.

logout

baseten auth logout [OPTIONS]
Remove stored credentials for the active user. For OAuth credentials, also revokes the session.

Options

-q, --jq
TEXT
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
-o, --output
TEXT
default:"text"
Output formatOne of: text, json, jsonl, none
--remote-url
TEXT
Baseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
-v, --verbose
BOOL
Enable verbose logging

Examples

Log out the active user
baseten auth logout

Filter output with --jq

Print just the logged-out user label
baseten auth logout --jq '.user'

Output

Text mode (--output text): Prints “Logged out user” to stdout on success. JSON mode (--output json): payload type cmd.AuthLogoutResult.

switch

baseten auth switch [OPTIONS]
Switch the active account for the current host.

Options

-q, --jq
TEXT
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
-o, --output
TEXT
default:"text"
Output formatOne of: text, json, jsonl, none
--remote-url
TEXT
Baseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
--user
TEXT
User to switch to
-v, --verbose
BOOL
Enable verbose logging

Examples

Switch to a specific account non-interactively
baseten auth switch --user <user>

Filter output with --jq

Print just the newly active user
baseten auth switch --user <user> --jq '.user'

Output

Text mode (--output text): Prints “Switched to user” to stdout on success. JSON mode (--output json): payload type cmd.AuthSwitchResult.

status

baseten auth status [OPTIONS]
Show the current authentication state, including the active user and auth type.

Options

-q, --jq
TEXT
Filter JSON output with a jq expression; implies —output json (or jsonl for streamed commands)
-o, --output
TEXT
default:"text"
Output formatOne of: text, json, jsonl, none
--remote-url
TEXT
Baseten remote URL, overrides BASETEN_REMOTE_URL (default https://app.baseten.co)
-v, --verbose
BOOL
Enable verbose logging

Examples

Show the current auth status
baseten auth status

Filter output with --jq

Print just the auth type
baseten auth status --jq '.auth_type'

Output

Text mode (--output text): Three-line summary: host URL, “Logged in as user”, “Auth type: type”. JSON mode (--output json): payload type cmd.AuthStatusResult.