feat minor 17C feat/phase-2g-bundle
AI Agent git-import/068377df · 115 days ago · Apr 2, 2026 · Diff

feat(17C): operation count metering — searches and index jobs

Replaces the token usage bar with two per-operation usage rows (Searches and Index jobs) across the full billing stack.

Backend: - billing-constants: add MONTHLY_SEARCHES_INCLUDED_BY_TIER and MONTHLY_INDEX_JOBS_INCLUDED_BY_TIER (free/plus/growth/pro allowances; pending calibration from shadow logs before BILLING_ENFORCE=true) - billing-logic: normalizeBillingUser adds monthly_searches_used / monthly_index_jobs_used fields; new effectiveMonthlySearchesIncluded and effectiveMonthlyIndexJobsIncluded helpers; defaultUserRecord adds both fields - billing-store: resetMonthlyTokensIfNeeded resets both counters on period rollover - billing-middleware: increments search/index counters in the same load-modify-save cycle as tryDeduct (zero extra blob round-trips) - billing-http: exposes monthly_searches_used, monthly_searches_included, monthly_index_jobs_used, monthly_index_jobs_included in summary

Frontend: - index.html: replace single token bar with two labelled op rows - hub.js: updateTokenBar → updateUsageBar(fillId, used, inc); loadBillingPanel reads and renders both search and index-job bars; setDash resets both - hub.css: .billing-op-row / .billing-op-label layout helpers

sha256:2413cf8d0fe722d1ea19d7078d060f06585f680aa4c5c1092ca3bc31378817c6 sha
sha256:19d41e36eace4e6f059d90ddb736d9688ceb760e83caa3a90e009c756f1f55ed snapshot
← Older Oldest on feat/phase-2g-bundle
All commits
Newer → Latest on feat/phase-2g-bundle

0 comments

No comments yet. Be the first to start the discussion.

To add a comment, use the Muse CLI: muse hub commit comment sha256:2413cf8d0fe722d1ea19d7078d060f06585f680aa4c5c1092ca3bc31378817c6 --body "your comment"