Quickstart
End-to-end flow in curl: tenant → catalog → user → subscription → usage → entitlement check →
invoice. For plan shapes, see Recipes first. Base URL: https://api.hume.run. All money fields are integers in abstract billing units (no currency code).
1. Create a tenant
Public by default (10 req/min). Response includes tenant.id and api_key.
2. Authenticate
Save credentials from step 1, then set the auth header for all following requests:
3. Define catalog (pricing package)
One call creates metrics, features, and a plan. Example payloads by use case: Recipes. Field reference: Plan extensions.
Save plan.id and metrics[0].id from the response.
4. Create a user
Save user.id (e.g. usr_01ARZ3NDEKTSV4RRFFQ69G5FAV).
5. Subscribe the user
6. Record usage
HTTP for domain events; StatsD UDP for high-frequency metering — see StatsD.
7. Check entitlement
8. Generate an invoice
Produces JSON line items for a billing window — pass them to your payment layer.
Next steps
- Recipes — more plan scenarios (tiers, seats, peak/off-peak, caps)
- Webhooks — react to billing events in your app
- Subscriptions — plan changes, pause, cancel-at-period-end
- HTTP API — full endpoint reference
- Concepts — tenants, entities, identifiers