Guides
Usage
What every response meters, and reading your key’s running totals from GET /v1/usage.
What every response meters
Each generation response carries a usage object — the metered quantities for that call:
{ "usage": { "input_chars": 42, "input_audio_seconds": 6.5, "output_audio_seconds": 3.2 } }| Field | Meaning |
|---|---|
input_chars | Characters of input text billed for the request. |
input_audio_seconds | Seconds of audio you supplied (spoken history / reference clips in converse). |
output_audio_seconds | Seconds of audio generated for you. |
Log these on your side if you want per-request attribution — the API's own accounting is keyed to your API key, not to your users.
Your running totals
GET /v1/usage returns the running totals for the key making the request:
curl -s https://api.kalpalabs.ai/v1/usage -H "Authorization: Bearer $KALPA_API_KEY"{
"key_id": "acme",
"requests": 1284,
"input_chars": 91230,
"input_audio_seconds": 411.0,
"output_audio_seconds": 3120.5,
"last_request_ts": 1751500000.0
}key_id is the non-secret label of your key (it's what appears in our logs — the key itself never does). For invoicing-grade reports or historical breakdowns, write to [email protected].