Skip to main content

Burndown

A local, real-time cockpit for your Claude credit burn. Burn rate · runway forecast · budget alerts — so you see "I'll run dry in 3 days" before it happens, not after.

PyPI License: MIT Python 3.10+ Zero dependencies 100%25 local


Anthropic split programmatic Claude usage into a separate monthly credit pool that can run out mid-month. The existing tools show you what you already spent — a bank statement, after the fact. Burndown is the fuel gauge: how fast you're burning right now, when you'll hit zero, and a check that fires before you overspend.

It reads the usage logs Claude Code already writes on your machine. Nothing leaves your computer — zero dependencies, no network, read-only on your logs, and it never touches your prompts or code (see SECURITY.md).

Quickstart

pipx install burndown        # from PyPI · or: pip install burndown
burndown                     # snapshot of this period
burndown budget 100          # set your monthly credit-pool budget → get a runway
burndown scope programmatic  # guardian mode: meter just the credit pool
burndown currency INR        # show INR next to USD (static rate, no live fetch)
burndown watch               # live terminal dashboard …
burndown serve               # … or a web dashboard at http://127.0.0.1:8787

No install? From a clone: python -m burndown (needs Python 3.11+, nothing else).

  BURNDOWN   monthly period · resets Jul 01

  $41.80 / $100.00   ███████████░░░░░░░░░░░░░░░░░  42%

  burn rate   $6.10/day   (last 24h)      avg $3.20/day
  runway      9.6 days  (Jun 22)   ✓ lasts the period
  projected   $89.40 by reset

  top projects
    memcon                     $22.10
    burndown                   $11.40
    barq-firmware              $8.30

  last 14d    ▂▁▃▅▂▇█▄▃▂▅▆▃▄

  1,204 billable msgs · 38,902,114 tokens · 100% local, nothing sent anywhere

Commands

Command What it does
burndown / burndown status one-shot snapshot
burndown watch [--interval 5] live dashboard, re-reads logs every few seconds
burndown budget <amount> [--tokens] [--reset-day N] set the budget runway is measured against (dollars, or --tokens to skip pricing)
burndown scope programmatic guardian mode — meter just the June-2026 credit pool (programmatic usage); all / interactive also available
burndown currency INR [--rate R] show a second currency next to USD (static rate, no live fetch)
burndown check exit 0 ok · 1 projected-over · 2 over — wire it into your own pre-run hook / CI
burndown report [--html out.html] self-contained local HTML report (opens from file://, no server)
burndown serve [--port 8787] live web dashboard on 127.0.0.1 — local only, auto-refreshing (nice if you don't live in a terminal)
burndown config show config + verify which logs are being read

How it works

Claude Code logs every assistant message to ~/.claude/projects/**/*.jsonl with a usage block (input / output / cache-write / cache-read tokens). Burndown reads those numbers (only those — never the message text), prices them with a configurable per-model table, rolls them into your current billing period, computes burn rate from the last 24 hours, and projects when you'll hit your budget.

Honest limitations

  • Pricing is estimated and configurable. Default per-model rates are best-effort; correct them in ~/.config/burndown/config.toml (burndown config shows the active table). The burn-rate/runway math is exact regardless — prices only scale the dollar figure. Prefer not to trust a dollar estimate? burndown budget <N> --tokens forecasts in raw tokens.
  • It reads local Claude Code logs. If your usage doesn't write those logs (e.g. a flow that doesn't log locally), Burndown can't see it yet.
  • The "budget stop" is a check you act on, not an auto-kill (on purpose — see ADR-005).

Trust

Zero dependencies · no outbound network (the optional dashboard is loopback-only) · read-only · content-blind · cross-platform (macOS/Linux/Windows) · MIT. Verify it yourself in one line:

grep -REn "urllib|httpx|requests|telemetry|analytics|0\.0\.0\.0|socket\.socket|create_connection|\.connect\(" burndown/   # → nothing (the only socket binds 127.0.0.1)

Decisions are logged in docs/DECISIONS.md; the threat model is in docs/SECURITY.md.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

burndown-0.1.2.tar.gz (45.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

burndown-0.1.2-py3-none-any.whl (25.8 kB view details)

Uploaded Python 3

File details

Details for the file burndown-0.1.2.tar.gz.

File metadata

  • Download URL: burndown-0.1.2.tar.gz
  • Upload date:
  • Size: 45.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.9

File hashes

Hashes for burndown-0.1.2.tar.gz
Algorithm Hash digest
SHA256 f6c154f6263ed643d2a8dbc8a10de19194640f11e715dd71447dbaebdee1d367
MD5 c6ca67792cde22b7adb2f063675192e3
BLAKE2b-256 cd1a888cde5e9783ff9570d91d54f7eb70b35be4c9bcbe1327981f07da14283a

See more details on using hashes here.

File details

Details for the file burndown-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: burndown-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 25.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.9

File hashes

Hashes for burndown-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 7d29eff4042b7494f2e0db01d6607aa0b7d9c66c0363e94d68680539dae36fef
MD5 3578e527cf824ad4760900f9f6a5f2da
BLAKE2b-256 52286d76d70b4b1a74e9214bd976b3d3352773c182830e160e335cd2d0f43972

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.2 This release

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page