Skip to content
AISpendbook

Finance

Customer margin

Each day's spend allocated to customers by share of telemetry cost, next to their revenue.

Customer margin allocates spend to customers by share of telemetry cost. For each UTC day and provider, the spend (billed where billing exists, otherwise the usage estimate) is split across the customers seen in that day's request telemetry for that provider, in proportion to their telemetry cost.

Every dollar of spend lands in exactly one of three buckets, and the three add up to total spend:

  • Allocated to customers.
  • No customer id: the share that falls on telemetry carrying no customer id.
  • No telemetry: days with spend for a provider but no telemetry cost. This part is not allocated.
ColumnMeaning
Telemetry estimateThe customer's request telemetry cost in the range.
Allocated spendThe customer's share of spend, as described above.
Price varianceAllocated spend minus the telemetry estimate.
RevenueEach month's revenue for the customer, invoiced or recognised, taken in proportion to that month's days inside the range.
AI contributionRevenue minus allocated AI cost and the non-token cost lines recorded with the customer's ID. It is not gross margin.
Gross marginAI contribution minus the other cost of revenue lines allocated to the customer.
  • Other cost of revenue (hosting, support, payment fees, human review) is added on the margin page and turns AI contribution into gross margin. See gross margin and contracts, which also covers recognised revenue, margin by plan and customer contracts.
  • Spend on a provider project, workspace or API key mapped to a customer is attributed first and shown as Of which mapped. See attribution and coverage.
  • Voice cost billed directly by Twilio, Deepgram and ElevenLabs reaches customers. A cost line with a customer ID goes to that customer. Otherwise the account it was billed to (Twilio account or subaccount, Deepgram project, ElevenLabs connection, or a phone number sent through the API with account_ref) goes to the customer an admin maps it to on the Voice cost billed directly card. Anything still unplaced is split by each customer's share of voice minutes that month. The Of which direct voice column shows each customer's amount, and hovering it shows the basis.
  • Twilio is read per connection, so splitting by subaccount needs one connection per subaccount. Customer statements, deal baselines and the margin trend still count only voice lines that carry a customer ID.
  • Revenue is empty when a month in the range has no revenue record for the customer. AI contribution and gross margin are then empty too.
  • Revenue comes from Stripe, a billing system connector, the NetSuite, Salesforce or HubSpot revenue connections, or a revenue import. Customer ids that you have mapped to one customer are grouped together.
  • The revenue connectors have not been run against a live account.
  • At month-end close the allocation is locked with the period, and later changes are shown beside it.