AccountUsage
Current-period quota snapshot for the authenticated account.
analysis_unlockedbooleanrequiredWhether paid analysis routes are allowed for this account's effective tier.
configured_tierstringnulloptionalThe plan the account is configured for when `reason` is `billing_incomplete`; `tier` still reports the effective `free`.
period_resetstringrequiredInclusive-exclusive period end (`period_end`) as RFC 3339.
reasonstringnulloptional`billing_incomplete` when this is a paid-tier row that fail-closed to `free` for lack of billing linkage (`AccountContext::degraded_from`). Absent for genuinely free and for fully-linked accounts, so those payloads are byte-for-byte unchanged. Same marker BillingLayer puts in `TIER_REQUIRES_PAID` data: the fix is billing setup, not an upgrade.
tierstringrequiredEffective plan slug (`free`, `hobby`, `pro`, …).
units_limitinteger<int64>requiredEffective hard cap / included units for the period.
units_remaininginteger<int64>required`max(0, units_limit - units_used - units_reserved)` — same headroom `reserve_atomic` enforces. `units_used` stays finalized-only.
units_usedinteger<int64>requiredFinalized units consumed in the current billing period.
upgrade_urlstringrequiredAlways `https://app.statshawk.ai/billing` — required on every success payload, not only near-cap. Same constant BillingLayer uses for `TIER_REQUIRES_PAID` / `QUOTA_EXCEEDED`. MCP prefers this over marketing `/pricing` for logged-in accounts.