Topograph can notify you about three billing events:Documentation Index
Fetch the complete documentation index at: https://docs.topograph.co/llms.txt
Use this file to discover all available pages before exploring further.
- Low balance: your prepaid credit balance crosses a configured threshold.
- High usage: your spend in a rolling window reaches a configured threshold. High usage has two independent passes, described below.
- Auto top-up: an automatic recharge succeeds or fails.
How notifications fire
Notifications are evaluated after billable usage changes your balance or spend window. A notification is recorded once per threshold crossing, not once per request. The tier is rearmed when you refill or usage drops below the threshold and later crosses it again.Global vs per-workspace high usage
High usage runs two independent passes on every reserve. Both can fire in the same evaluation, and overriding one does not affect the other:- Global (account aggregate): sums billable usage across every workspace over the configured global period and checks it against your global tiers. Use this to alert on total account burn regardless of which workspace drove it.
- Per-workspace: sums billable usage for a single workspace over the configured workspace period and checks it against workspace tiers. Account-level workspace settings act as defaults; specific workspaces can override them.
Channels
Every notification kind has two channels, configured independently:- Email: sent to account admins.
- Webhook: delivered through the same endpoints you already set up for
company.updated.
Webhook event types
All billing webhook payloads carry atype and version: "1". Future schema changes will emit new event types rather than mutate v1.
billing.low_balance.triggered
tier field is one of warning, critical, or depleted. You can configure multiple tiers via the REST API or dashboard.
billing.high_usage.triggered
The high-usage event now carries a scope field that tells you which pass fired:
scope: "workspace"with a setworkspaceId: the per-workspace pass fired for that workspace.scope: "global"withworkspaceId: null: the global aggregate pass fired for the whole account.
highUsageEnabled: false on a workspace override stops that workspace from firing its own per-workspace notifications but does not silence the global pass. If you want to silence the global pass too, turn off globalHighUsageEnabled at the account level.
billing.auto_topup.succeeded
billing.auto_topup.failed
Configuration API
All endpoints are under/v2/billing/notifications and require your standard x-api-key header.
Read the resolved config
false and every channel at true. Each kind ships with a single warning tier so flipping the master on immediately fires on one sensible threshold. Add more tiers (critical, depleted, extra bands) via PATCH if you want finer granularity.
Update the config
{"lowBalanceEmailEnabled": false} to turn off low-balance emails without touching anything else.
List recent notification events
Workspace overrides
If you use workspaces, you can override the high-usage rules for a specific workspace. Low-balance and auto-topup stay at the account level.GET returns both the resolved account config and the raw workspace override row, so you can see which fields are overridden and which are inherited. PATCH upserts an override; any null field falls back to the account config at evaluation time. DELETE removes the override row (the workspace then inherits everything).
Example: give workspace ws_batch a much higher high-usage floor so nightly backfills don’t page you, while keeping everything else at the account defaults:
Verifying webhooks
Billing webhooks use the same webhook endpoint setup as yourcompany.updated webhooks. The signature verification flow is identical:
Verify billing webhook signatures the same way you verify company data webhook signatures, then branch on the type field in the payload.
See the Webhooks guide for the full verification walkthrough and retry semantics.
Idempotency
Every billing notification is deduplicated at evaluation time. If the same threshold crossing is evaluated more than once, only one customer-visible notification is recorded. High-usage notifications are deduplicated inside their rolling evaluation window, so two evaluations of the same threshold crossing do not produce duplicate customer alerts.Rearm semantics
Threshold notifications fire once when you cross a tier, then disarm. They rearm when the condition has clearly reversed:- Low balance: when the balance recovers above the tier threshold.
- High usage: when the rolling spend falls below the tier threshold.
depleted notifications, but a refill followed by another drop can send a fresh notification.
Auto-topup notifications are event-based, not threshold-based. Each attempt is evaluated independently.