feat(accounts): add account control center#251
Open
ozymandiashh wants to merge 4 commits intogetagentseal:mainfrom
Open
feat(accounts): add account control center#251ozymandiashh wants to merge 4 commits intogetagentseal:mainfrom
ozymandiashh wants to merge 4 commits intogetagentseal:mainfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Builds on #227 / issue #208 (multiple Claude config dirs). This PR turns the multi-directory foundation into a user-facing control workflow for people running Claude work, personal, desktop, or client accounts side by side.
Summary
Adds an Account Control Center to CodeBurn: account-level spend, sessions, projects, models, budgets, subscription efficiency, and wrong-account watchlist checks.
The core question this answers is not just "how much did I spend?" but:
What changed
codeburn accountscommand with text and JSON output.codeburn accounts workbehaves likecodeburn accounts --account work.~/.config/codeburn/config.json:planmonthlyUsdbudgetUsdresetDay--accountfiltering added to usage workflows:reporttodaymonthstatusexportaccountsoptimizecompareaccounts.csv/ account rows with plan and budget metadata.Detection / accountability model
Account rollups include:
Watchlist risks include:
Unlabelled provider usage is still grouped as
unlabelled, but it does not create duplicate-project noise against labelled Claude accounts.Power-user workflow
For users with multiple Claude subscriptions or client accounts:
This makes CodeBurn useful for attribution and reimbursement, not just aggregate cost visibility.
Review fixes before push
During pre-push review with Argus / Claude Opus 4.7 and Gemini 3.1 Pro Preview, a few concrete issues were fixed before this PR was opened:
--account workno longer includes a personal account just because the project path contains/work/. Plain filters match account label/account path; account-prefixed project matching now requires theaccount:pathform.accounts set Workstores a canonical key and rollups match config case-insensitively, avoiding duplicateWork/workrows.--budget-usd 0.001no longer render asUSD 0.homeworkno longer trips theworkmarker.accounts.csv/ export JSON include configured plan, monthly USD, budget USD, and utilization fields.report --account,export --account,accounts <name>, and filtered account rollups.Tests
New and updated coverage includes:
codeburn accounts setpersistencecodeburn accounts <name>filteringreport --account --format jsonexport --account -f jsonaccounts.csvaccount rollups and plan/budget metadataValidation
npm run build— passnpm test— 42 files, 551 tests passgit diff --cached --check— passPASS CU OBSERVATII, no blockersPASS CU OBSERVATII, no blockersSecurity
No new attack surface. This is a local read-only aggregation and config workflow over existing parsed session telemetry. No shell execution, eval, network calls, secrets handling, or remote writes beyond normal explicit export/config file writes.
CSV export continues to use the existing cell escaping path for spreadsheet-injection prefixes.
What it does NOT touch
Pricing tables, token parsing, provider discovery outside the existing #227 Claude account labels, model classification, date-range semantics, or core cost math. This PR is scoped to account-level aggregation, filtering, configuration, export, and reporting surfaces.