I3292 — Reported tokens, a price-list estimate and a billed amount are three fields, and the billing mode says which account paid
Give the usage record of I3288 reported_tokens, estimated_cost (class estimated) and billed_cost (absent unless reconciled), plus billing_mode (subscription, api_key, api_credits, unknown) declared by the person, so that on a subscription an API-equivalent price is never shown as spend.
BLOCKED wave 1 · p2 · implementation profile · parallel safe
Blocked. This issue cannot start until I0301, I3287 are done. The status is derived from that, not declared.
Objective
Give the usage record of I3288 reported_tokens, estimated_cost (class estimated) and billed_cost (absent unless reconciled), plus billing_mode (subscription, api_key, api_credits, unknown) declared by the person, so that on a subscription an API-equivalent price is never shown as spend.
Why
The owner works on subscriptions; Claude Code's cost field is an approximation and Admin cost reports are unavailable to individual accounts (dated vendor claims). docs/ECONOMICS.md already classes every number observed, counted, derived, estimated or counterfactual; this record must use those classes, not a second vocabulary. No provider event carries the plan type, so billing_mode needs a named reporter; the critique also found that 'the execution record' could land on the capability-execution type. It extends milestone execution-telemetry. Proposed in ADR 0213 (Usage is observed through each provider's official telemetry into one provider-neutral record, and reported, estimated and billed amounts are never merged) (proposed; it carries no authority until the owner accepts it). Sources: chatgpt-majordomus:c253#2, chatgpt-majordomus:c267#2, chatgpt-majordomus:c267#7.
Current state
The benchmark run record keeps total_cost_usd as reported; no billing mode exists anywhere.
Desired state
Every surface prints the class beside each figure and refuses to sum across classes.
Scope
- apps/majordomus-cli/src/economics
- docs/ECONOMICS.md
- share/schemas/generated/economics-summary.schema.json
- apps/majordomus-cli/tests/economics.rs
- docs/generated/economics.json
Dependencies
- I0301BLOCKED Define the execution record, including what an absence looks like
- I3287READY A provider declares how it reports usage, with the evidence, beside its lifecycle
What waits on this
- I3294BLOCKED /ui shows usage by provider, model, session, task and issue, and every figure opens its reported events
- I3295BLOCKED A task declared over its token budget is told so, and refused only where policy says refuse
- I3422BLOCKED Advisor consultations are economics usage with their measurement class, and a consultation over its plan's budget is a finding
Acceptance criteria
- A subscription session shows its estimate labelled estimated and no spend
- Summing estimated with billed is a compile- or test-time refusal
- An unknown billing mode reads unknown
- reported_tokens, estimated_cost, billed_cost and billing_mode live on the I3288 usage record, never on execution::Execution
- billing_mode is a declaration the person makes through the consented I3289 step, recorded as declared; without one it reads unknown; an inferred value is refused (test)
Validation
- cargo test --manifest-path apps/majordomus-cli/Cargo.toml --test economics
- majordomus economics check
Evidence required
- test_usage_quantities_are_never_merged
Evidence
None recorded. Every token above needs a command or an artifact behind it before this issue can be completed; narrative is refused.
Timeline
- started
- —
- verified
- —
- completed
- —
Those three fields, the evidence above and the state of the dependencies are all the status is made of. There is no status field to disagree with them.
Canonical record: .ai/repo/project/issues/I3292.yaml. Read it back with majordomus plan show I3292.