@blnayan/token-burn
v0.1.15
Published
CLI for syncing Claude Code and Codex usage to Token Burn.
Downloads
1,550
Readme
Token Burn CLI
Sync local Claude Code and Codex usage totals to a Token Burn leaderboard.
Quick Start
Requires Node.js 24 LTS or newer.
npx @blnayan/token-burn@latest setupsetup prints a login approval URL, waits for approval, runs the first sync, and installs automatic sync.
You can still install the CLI globally if you prefer:
npm install -g @blnayan/token-burn
token-burn setupCommands
Command names are shown as token-burn; use npx @blnayan/token-burn@latest <command> for no-install usage, or run them after a global install.
token-burn setupauthenticates, syncs once, and installs automatic sync.token-burn loginauthenticates the CLI withhttps://tokenburn.nayanbhut.dev.token-burn login --server-url <url>authenticates with another Token Burn server.token-burn syncsends aggregate usage totals.token-burn statusshows auth and last sync state.token-burn scheduler installinstalls automatic sync.token-burn scheduler install --dry-runpreviews scheduler changes.token-burn scheduler uninstallremoves automatic sync.token-burn install-schedulerandtoken-burn uninstall-schedulerremain available as compatibility aliases.
Output Modes
- Interactive terminals use rich Clean Operator output by default.
- Non-TTY output, cron, CI, and
NO_COLORuse plain output. - Use
--plainfor log-safe human text. - Use
--jsonfor machine-readable output where supported. - Use
--no-colorto keep rich layout without ANSI color.
Privacy
Token Burn syncs aggregate daily usage only.
Stored by Token Burn:
- Daily aggregate token totals
- Provider name
- Model names when
ccusagereports them - Token categories such as input, output, cache creation, and cache read
- Reasoning output token details when reported
- Cost estimates when
ccusagereports them - Device name, OS, CLI version,
ccusageversion, and sync timestamp
Not stored by Token Burn:
- Prompts
- Raw conversation text
- Project paths or file paths
- Session IDs
- Raw
ccusagerows - GitHub OAuth tokens
- Raw CLI tokens
Leaderboard periods use UTC boundaries. "Today" means the current UTC date.
If sync reports that the ccusage native binary is not executable after a global npm install, do not run token-burn sync with sudo; root has a separate Token Burn config. Reinstall Node/npm in a user-writable environment such as nvm, or fix the native binary execute bit once.
