Documentation Index
Fetch the complete documentation index at: https://docs.royaltyport.com/llms.txt
Use this file to discover all available pages before exploring further.
The CLI supports two authentication methods. Browser login (default) opens your browser for a secure OAuth sign-in. API tokens are available for headless environments like CI/CD pipelines.
Browser Login (Default)
This opens your browser where you sign in to Royaltyport and approve access. The CLI receives tokens automatically and stores them locally. No token to copy or paste.
Tokens are refreshed automatically — you stay logged in until you explicitly log out.
API Token Login
For CI/CD, automation, or environments without a browser, pass an API token directly:
royaltyport login --token rp_your_token_here
Tokens are created in Organizations > Settings > Tokens. See Authentication for details.
| Option | Short | Description |
|---|
--token <token> | -t | API token (skips browser login) |
Piped / Non-Interactive Login
When stdin is not a terminal (e.g., inside a Docker container or piped from another command), the CLI cannot open a browser. It will prompt for an API token via stdin instead:
echo "rp_your_token_here" | royaltyport login
This is useful in containerized environments or scripts where neither --token nor environment variables are practical.
Custom API URL
Point the CLI at a different API endpoint:
royaltyport login --api-url https://your-api-url.com
| Option | Description |
|---|
--api-url <url> | Custom API base URL (default: https://api.royaltyport.com) |
Environment Variables
For CI/CD pipelines and automation, set environment variables instead of running login:
| Variable | Description |
|---|
ROYALTYPORT_TOKEN | API token — overrides stored credentials |
ROYALTYPORT_API_URL | Custom API base URL (default: https://api.royaltyport.com) |
Environment variables always take priority over stored configuration.
Example
export ROYALTYPORT_TOKEN=rp_your_token_here
royaltyport projects
Auth Resolution Order
The CLI resolves credentials in this order:
ROYALTYPORT_TOKEN environment variable (highest priority)
- OAuth access token (from browser login, auto-refreshed)
- Stored API token in
~/.config/royaltyport/config.json
The API URL is resolved similarly:
ROYALTYPORT_API_URL environment variable
- Stored
apiUrl in config
- Default:
https://api.royaltyport.com
Logout
Clear all stored credentials and configuration:
This removes the config file at ~/.config/royaltyport/config.json. Environment variables are not affected.