Skip to main content

lium whoami

Show which API key the CLI is using, the account it belongs to, the balance, the SSH key and the CLI version. It is the first thing to run when a command fails in a way you did not expect.

lium whoami [OPTIONS]

Options​

FlagEffect
--jsonPrint machine-readable JSON

What it shows​

RowMeaning
API keyThe key's fingerprint (never the key itself) and where it came from: LIUM_API_KEY, the config file, or a workspace key when a workspace is selected
AccountThe account id the key belongs to
EmailThe account's e-mail, when it has one
BalanceThe account balance in USD
APIThe API base URL and whether it answered, with the round-trip time
SSH keyThe private key the CLI would use (ssh.key_path, else ~/.ssh/id_ed25519, id_rsa or id_ecdsa) and whether its public half is registered on the account
CLIThe installed lium version

Examples​

lium whoami # Human-readable summary
lium whoami --json | jq .account_id # One field for a script

--json prints one object with the keys account_id, api_base_url, api_error, api_key_fingerprint, api_key_source, api_latency_ms, api_reachable, balance_usd, cli_version, email, rsync_client, ssh_client, ssh_key_path, ssh_key_registered, ssh_public_key_found and warnings. A field the CLI could not read is null.

Exit codes​

CodeWhen
0The key works and the API answered
2No API key is configured (no_api_key)
3The API could not be reached (api_unreachable), or answered with an error
otherThe API refused the key: the same code and exit status any other command gives (for example invalid_api_key)

Without --json the summary is printed first, then the error. With --json stdout stays empty on a failure and the error envelope on stderr carries the same fields as data.

See also​