Files
openclaw/skills/model-usage/references/codexbar-cli.md
Santiago c4f1661f70 docs(skills): allow model-usage with Linux codexbar (#87986)
* docs(skills): support CodexBar CLI on Linux

Enable the existing model-usage skill on Linux when the supported CodexBar CLI is present, and document the official Homebrew, AUR, and release-tarball install paths.

Co-authored-by: Santiago <shbernal.01@gmail.com>

* docs(skills): link CodexBar Linux packages

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-21 11:04:46 -07:00

36 lines
1.3 KiB
Markdown

# CodexBar CLI quick ref (usage + cost)
## Install
- macOS and Linux Homebrew formula: `brew install steipete/tap/codexbar`
- Linux AUR package: `yay -S codexbar-cli`
- macOS and Linux tarballs: [CodexBar releases](https://github.com/steipete/CodexBar/releases)
- macOS app: Preferences -> Advanced -> Install CLI
## Commands
- Usage snapshot (web/cli sources):
- codexbar usage --format json --pretty
- codexbar --provider all --format json
- Local cost usage (Codex + Claude only):
- codexbar cost --format json --pretty
- codexbar cost --provider codex|claude --format json
## Cost JSON fields
The payload is an array (one per provider).
- provider, source, updatedAt
- sessionTokens, sessionCostUSD
- last30DaysTokens, last30DaysCostUSD
- daily[]: date, inputTokens, outputTokens, cacheReadTokens, cacheCreationTokens, totalTokens, totalCost, modelsUsed, modelBreakdowns[]
- modelBreakdowns[]: modelName, cost
- totals: totalInputTokens, totalOutputTokens, cacheReadTokens, cacheCreationTokens, totalTokens, totalCost
## Notes
- Cost usage is local-only. It reads JSONL logs under:
- Codex: ~/.codex/sessions/\*_/_.jsonl
- Claude: ~/.config/claude/projects/**/\*.jsonl or ~/.claude/projects/**/\*.jsonl
- If web usage is required (non-local), use codexbar usage (not cost).