Skip to content

greymoth-jp/ccwrapped

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ccwrapped ✺

See your Claude Code usage — then share it. A local-only CLI that reads your ~/.claude transcripts: a clean usage breakdown in your terminal, plus a beautiful, risograph-style Wrapped card on demand — messages, est. value, top model/project, and how much prompt caching quietly saved you.

npm downloads license no network

No account. No servers. Nothing leaves your machine — and the card prints itself.

ccwrapped — Claude Code Wrapped card (example data)

npm i -g @greymoth/ccwrapped
ccwrapped --wrapped       # → claude-code-wrapped.svg  (open in a browser, screenshot, share)
ccwrapped                 # last 30 days, by model (terminal)
ccwrapped --all           # lifetime
ccwrapped --by project    # where your tokens actually go

Why a card?

Because “I ran 12,480 messages through Claude Code this month” is a thing people want to show, not a number buried in a table. --wrapped writes a self-contained SVG (fonts embedded) — open it in any browser, screenshot, post it. Drop --anon and it hides your project names for a clean public share. Seasonal flex, built in: Claude Code Wrapped.

Pairs with ccusage: ccusage is the spreadsheet, ccwrapped is the poster. Same ~/.claude data, different job — numbers vs. a thing you share.

Two looks — pick your share

Add --v2 for the Build Fingerprint: your model mix as one two-ink risograph bar — which models actually did the work, not just a total. It turns the card from a stat readout into a signature.

ccwrapped — Build Fingerprint card (--v2, example data)

ccwrapped --all --wrapped --v2     # → the Build Fingerprint card (example above)

In your terminal — the daily driver

ccwrapped prints a clean per-model breakdown: messages, tokens, est. cost, and what caching saved you.

ccwrapped terminal usage breakdown (example)

Options

ccwrapped [period] [--by model|project|day] [--json] [--wrapped [file.svg]] [--anon] [--v2]
period:  --today | --week | --month (default) | --all | --days N
--v2 (--fingerprint):  the "Build Fingerprint" card — your model mix as a single 2-ink bar

How it works

Reads assistant lines in ~/.claude/projects/**/*.jsonl, deduplicates by message.id (streaming writes the same message several times), and prices tokens against a bundled per-model rate table (input / output / cache-read / cache-write 5m & 1h).

Honest about the numbers

  • Cost is an estimate (API-equivalent). On a Pro/Max plan it is not what you paid — it's the value you'd have spent at API rates.
  • Rates are a bundled snapshot of Anthropic pricing; 1M-context premiums and web-tool fees aren't modelled. Token cost dominates, so totals are close, not exact.
  • 100% local. No network calls (grep the source — there are none). Your transcripts never leave the machine.
  • No Claude Code history yet? Numbers will be near-zero — that's expected, not a bug. Run a few sessions, then come back; nothing here is fetched or synthetic.

Requires Node 18+. Reads ~/.claude/projects (the default Claude Code transcript location).

License

MIT. Bundled fonts: Space Grotesk & JetBrains Mono (SIL Open Font License).


Built by greymoth. If your Wrapped surprised you, a ⭐ helps the next person find it.

About

Local Claude Code usage analytics + a shareable risograph Wrapped card. Reads ~/.claude, sends nothing.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors