Connect your usage
Send usage outside your AI request path, then match it with customer revenue.
1. Create an ingest key
Sign in and open Connectors. Create a key for the workspace receiving usage. Keep it private.
2. Send normalized JSON
Use token counts from your provider response and the exact model identifier in the price table. The example below uses illustrative usage. Replace its counts, identifiers and timestamp with your own.
curl -X POST https://cupelio.com/api/ingest \
-H "Authorization: Bearer YOUR_INGEST_KEY" \
-H "Content-Type: application/json" \
-d '{
"source": "generic",
"events": [{
"external_id": "request-unique-id",
"payload": {
"provider": "anthropic",
"model": "claude-sonnet-5",
"input_tokens": 1000000,
"output_tokens": 1000000,
"customer": "customer-a",
"feature": "document-analysis",
"occurred_at": "2026-10-03T12:00:00Z"
}
}]
}'Include a stable external_id for each event. A retry must reuse it; a different event must have a new identifier.
Response and pricing details
{
"accepted": 1, "duplicates": 0, "priced": 1,
"unpriced": 0, "unattributed": 0,
"not_usage": 0, "failed": 0
}At a matching $2 input and $10 output rate per million tokens, this example estimates $12. Check the effective price record for your event date.
Provider names are normalized to lowercase. Model identifiers are matched exactly, including version suffixes. Unsupported models or dates without a price remain unpriced. Native OTLP exports require an adapter to this JSON contract.
Check response counts and failures before treating an import as complete. Send identifiers and accounting fields, not prompt or completion text.
3. Match customers and revenue
Use the same stable customer identifier in usage and the revenue CSV. Open Customers to import revenue.
customer,amount,period_start,period_end,external_id customer-a,8000,2026-10-01,2026-10-31,revenue-customer-a-oct
Use plain comma-separated values without quoted fields or thousands separators. Amounts are USD. Use a stable external identifier to deduplicate the revenue import.
4. Compare your provider invoice
Record the provider and invoice total for the period in Reconciliation. Differences stay separate from customer costs.
Need help? Contact support. Review the methodology for price coverage and reporting limits.