Accounts
Accounts CLI Commands
Manage bot accounts through the command line interface.
Overview
The accounts command allows you to list and retrieve information about stored bot accounts. All commands support multiple output formats and never expose sensitive credentials in the output.
Commands
list
List all stored accounts.
Usage:
pow-desktop.exe accounts list [OPTIONS]
Options:
-o, --output <OUTPUT>- Output format (default:text)- Possible values:
text,json,yaml
- Possible values:
Examples:
# List all accounts in text format (default)
pow-desktop.exe accounts list
# List all accounts in JSON format
pow-desktop.exe accounts list --output json
# List all accounts in YAML format
pow-desktop.exe accounts list --output yaml
Output Fields:
ID- Unique account identifierDISPLAY_NAME- Human-readable account nameACCOUNT_TYPE- Type of account (e.g.,jagex,rs3)EMAIL- Account email address (if available)HAS_PASSWORD- Whether a password is saved (yes/no)LAST_USED- Timestamp when the account was last used (if available)CREATED_AT- Timestamp when the account was addedNEEDS_REFRESH- Whether the account needs token refresh (yes/no)
Security Note: Passwords are never displayed in CLI output. Only the HAS_PASSWORD field indicates if a password is stored.
get
Get detailed information about a specific account by ID.
Usage:
pow-desktop.exe accounts get <ID> [OPTIONS]
Arguments:
<ID>- The account ID to retrieve
Options:
-o, --output <OUTPUT>- Output format (default:text)- Possible values:
text,json,yaml
- Possible values:
Examples:
# Get account details in text format
pow-desktop.exe accounts get acc-123
# Get account details in JSON format
pow-desktop.exe accounts get acc-123 --output json
# Get account details in YAML format
pow-desktop.exe accounts get acc-123 --output yaml
Output Fields:
Same as list command. Passwords are never included in the output.
Error Handling: If the account ID is not found, the command will exit with code 1 and display an error message.
Output Formats
Text Format (Default)
Human-readable table format suitable for terminal viewing.
Example (list):
ID DISPLAY_NAME ACCOUNT_TYPE EMAIL HAS_PASSWORD LAST_USED CREATED_AT NEEDS_REFRESH
acc-123 My Account jagex [email protected] yes 2024-01-15T10:30:00Z 2024-01-01T00:00:00Z no
Example (get):
ID acc-123
DISPLAY_NAME My Account
ACCOUNT_TYPE jagex
EMAIL [email protected]
HAS_PASSWORD yes
LAST_USED 2024-01-15T10:30:00Z
CREATED_AT 2024-01-01T00:00:00Z
NEEDS_REFRESH no
JSON Format
Structured JSON output suitable for programmatic processing.
Example:
[
{
"id": "acc-123",
"display_name": "My Account",
"account_type": "jagex",
"email": "[email protected]",
"has_saved_password": true,
"last_used": "2024-01-15T10:30:00Z",
"created_at": "2024-01-01T00:00:00Z",
"needs_refresh": false
}
]
YAML Format
YAML output for configuration files and human-readable structured data.
Example:
- id: acc-123
display_name: My Account
account_type: jagex
email: [email protected]
has_saved_password: true
last_used: "2024-01-15T10:30:00Z"
created_at: "2024-01-01T00:00:00Z"
needs_refresh: false
Security Considerations
- No Credentials Exposed: Passwords and sensitive authentication tokens are never displayed in CLI output
- Read-Only Operations: The CLI only provides read access to account information
- Safe for Scripting: Output can be safely logged or piped to other tools without exposing credentials
Exit Codes
0- Success1- Error (e.g., account not found, database error)
Examples
List all accounts
pow-desktop.exe accounts list
Find accounts that need refresh
# Using JSON output with jq
pow-desktop.exe accounts list --output json | jq '.[] | select(.needs_refresh == true)'
Get account details and save to file
pow-desktop.exe accounts get acc-123 --output json > account.json
Check if account has password saved
pow-desktop.exe accounts get acc-123 --output json | jq '.has_saved_password'
List accounts by type
pow-desktop.exe accounts list --output json | jq '.[] | select(.account_type == "jagex")'
Export all accounts to YAML
pow-desktop.exe accounts list --output yaml > accounts_backup.yaml