cost-ledger

by bobtat · ★ 2 · updated today

PanesBandsStatus lineGuardsCommandsPromptvalidates

0

Tracks what Claude Code costs — session, calendar-week and calendar-month totals with the month's pace and week-over-week change, a /costs pane with a spend calendar, the most expensive prompts and what filled the context, plus prompt-cache awareness: a cache warm/cold countdown, warnings before a prompt, model switch or large write re-caches the context, a per-category breakdown priced at...

install cost-ledger

Install

/plugin marketplace add bobtat/claude-plugins
/plugin install cost-ledger@bobtat-plugins

Then run /reload-plugins or start a new session. Requires Claude Code 2.1.287+.

View source on GitHub

What it hooks into

From an automated scan with claude plugin validate, not a security review. Mods run with your permissions; read the code before installing.

Events
session.startclassic.SessionStartclassic.PreModelSwitchclassic.PostModelSwitchsession.endprompt.submitturn.startturn.stepturn.completetool.callsession.measurecommand.runui.render
API calls
$.clock.after$.clock.every$.clock.now$.command.register$.env.get$.fs.list$.fs.read$.fs.write$.model.fork$.process.run$.session.id$.session.root$.session.usage$.state.get$.state.set$.store.delete$.store.get$.store.keys$.store.set$.ui.open$.ui.resolve$.ui.status$.ui.toast
Draws
AbovePromptPane
Can see
classic hooksevery promptevery tool call
Reach
level 2 of 3 other: $.state.getother: $.state.setruns processeswrites filesdrives Claudereads filesreads env varspersists statedraws

Origin

How it got here
Automated scan of public GitHub repos, via the CC0 dataset awesome-claude-code-mods (scan of ).
Repository
github.com/bobtat/claude-plugins
Path in repo
plugins/cost-ledger
Source commit
077b4bb the exact code the scan read
Author
@bobtat
License
MIT
First published
Last pushed
First listed here

Name and description come from the mod's own manifest. We link to the code; we don't host it, and it stays under its author's license.

More from bobtat/claude-plugins

subagent-tree

bobtat/claude-plugins

A live /agents-tree pane showing the session's subagents as a tree — status, how long each has run, its tool calls and steps, the tool it is on now and the output tokens it used

★ 2PanesGuardsCommands