Get usage summary
Returns daily cost and activity for the project, broken down per model and summed across all models. The project is implied by the API key used for authentication. Usage is aggregated by whole UTC day. The window is half-open, `[start_time, end_time)`, and a day is included when the window covers any part of it, so an `end_time` exactly at midnight excludes that day. The window must not cover more than 366 UTC days.
Returns daily cost and activity for the project, broken down per model and summed across all models. The project is implied by the API key used for authentication.
Usage is aggregated by whole UTC day. The window is half-open, [start_time, end_time), and a day is included when the window covers any part of it, so an end_time exactly at midnight excludes that day. The window must not cover more than 366 UTC days.
Headers
AuthorizationRequiredBearer <SONIOX_API_KEY>Query parameters
start_timeRequiredstringStart of the window (inclusive). Must be an ISO 8601 timestamp in UTC (e.g. 2026-04-01T00:00:00Z). Its UTC day is included.
end_timeRequiredstringEnd of the window (exclusive). Must be an ISO 8601 timestamp in UTC (e.g. 2026-04-03T00:00:00Z) and strictly after start_time. Its UTC day is included unless it falls exactly on midnight.
Response
200
Daily cost and activity aggregates.
totalRequiredobjectCost and activity across all models. Its model is null.
modelsRequiredarray<object>One entry per model that recorded usage in the window. Empty when the project had no usage.
Errors
Daily cost and activity aggregates.
{
"total": {
"model": null,
"days": [
"2026-04-01",
"2026-04-02"
],
"total_cost_usd": "0.2567250000",
"total_input_cost_usd": "0.0415500000",
"total_output_cost_usd": "0.2151750000",
"total_duration_cost_usd": "0.0000000000",
"cost_usd": [
"0.1711500000",
"0.0855750000"
],
"input_cost_usd": [
"0.0277000000",
"0.0138500000"
],
"output_cost_usd": [
"0.1434500000",
"0.0717250000"
],
"duration_cost_usd": [
"0.0000000000",
"0.0000000000"
],
"total_num_requests": 285,
"total_input_text_tokens": 4800,
"total_input_audio_tokens": 15000,
"total_input_audio_duration_ms": 1800000,
"total_output_text_tokens": 10800,
"total_output_audio_tokens": 8250,
"total_output_audio_duration_ms": 990000,
"total_duration_ms": 0,
"num_requests": [
190,
95
],
"input_text_tokens": [
3200,
1600
],
"input_audio_tokens": [
10000,
5000
],
"input_audio_duration_ms": [
1200000,
600000
],
"output_text_tokens": [
7200,
3600
],
"output_audio_tokens": [
5500,
2750
],
"output_audio_duration_ms": [
660000,
330000
],
"duration_ms": [
0,
0
]
},
"models": [
{
"model": "stt-async-v5",
"days": [
"2026-04-01",
"2026-04-02"
],
"total_cost_usd": "0.0613500000",
"total_input_cost_usd": "0.0235500000",
"total_output_cost_usd": "0.0378000000",
"total_duration_cost_usd": "0.0000000000",
"cost_usd": [
"0.0409000000",
"0.0204500000"
],
"input_cost_usd": [
"0.0157000000",
"0.0078500000"
],
"output_cost_usd": [
"0.0252000000",
"0.0126000000"
],
"duration_cost_usd": [
"0.0000000000",
"0.0000000000"
],
"total_num_requests": 60,
"total_input_text_tokens": 300,
"total_input_audio_tokens": 15000,
"total_input_audio_duration_ms": 1800000,
"total_output_text_tokens": 10800,
"total_output_audio_tokens": 0,
"total_output_audio_duration_ms": 0,
"total_duration_ms": 0,
"num_requests": [
40,
20
],
"input_text_tokens": [
200,
100
],
"input_audio_tokens": [
10000,
5000
],
"input_audio_duration_ms": [
1200000,
600000
],
"output_text_tokens": [
7200,
3600
],
"output_audio_tokens": [
0,
0
],
"output_audio_duration_ms": [
0,
0
],
"duration_ms": [
0,
0
]
},
{
"model": "tts-rt-v1",
"days": [
"2026-04-01",
"2026-04-02"
],
"total_cost_usd": "0.1953750000",
"total_input_cost_usd": "0.0180000000",
"total_output_cost_usd": "0.1773750000",
"total_duration_cost_usd": "0.0000000000",
"cost_usd": [
"0.1302500000",
"0.0651250000"
],
"input_cost_usd": [
"0.0120000000",
"0.0060000000"
],
"output_cost_usd": [
"0.1182500000",
"0.0591250000"
],
"duration_cost_usd": [
"0.0000000000",
"0.0000000000"
],
"total_num_requests": 225,
"total_input_text_tokens": 4500,
"total_input_audio_tokens": 0,
"total_input_audio_duration_ms": 0,
"total_output_text_tokens": 0,
"total_output_audio_tokens": 8250,
"total_output_audio_duration_ms": 990000,
"total_duration_ms": 0,
"num_requests": [
150,
75
],
"input_text_tokens": [
3000,
1500
],
"input_audio_tokens": [
0,
0
],
"input_audio_duration_ms": [
0,
0
],
"output_text_tokens": [
0,
0
],
"output_audio_tokens": [
5500,
2750
],
"output_audio_duration_ms": [
660000,
330000
],
"duration_ms": [
0,
0
]
}
]
}Invalid request.
Error types:
invalid_request: A query parameter is missing or invalid. Common causes:start_time/end_timenot parseable as ISO 8601,end_timenot strictly afterstart_time, or the window covers more than 366 UTC days.
{
"status_code": 400,
"error_type": "invalid_request",
"message": "Your request did not pass validation. One or more fields in the request body are missing or have invalid values. See `validation_errors` for the specific field and retry with corrected values.",
"validation_errors": [
{
"error_type": "value_error",
"location": "query.payload",
"message": "The window covers 517 UTC days, which exceeds the maximum of 366."
}
],
"request_id": "3d37a3bd-5078-47ee-a369-b204e3bbedda",
"more_info": "https://soniox.com/docs/api-reference/errors#invalid-request"
}Authentication error.
{
"status_code": 401,
"error_type": "unauthenticated",
"message": "Incorrect API key provided. You can get an API key at https://console.soniox.com",
"validation_errors": [],
"request_id": "3d37a3bd-5078-47ee-a369-b204e3bbedda",
"more_info": "https://soniox.com/docs/api-reference/errors#unauthenticated"
}Not found.
Error types:
not_found: The project could not be resolved while collecting its usage. Retry, and contact support if it persists.
{
"status_code": 0,
"error_type": "string",
"message": "string",
"validation_errors": [
{
"error_type": "string",
"location": "string",
"message": "string"
}
],
"request_id": "string",
"more_info": "string"
}Rate / capacity limit exceeded.
Error types:
limit_exceeded: The caller hit a per-minute request rate or other capacity limit. Themessagedescribes which limit was hit.
{
"status_code": 429,
"error_type": "limit_exceeded",
"message": "Requests per minute limit has been exceeded for your organization.",
"validation_errors": [],
"request_id": "3d37a3bd-5078-47ee-a369-b204e3bbedda",
"more_info": "https://soniox.com/docs/api-reference/errors#limit-exceeded"
}Internal server error.
{
"status_code": 500,
"error_type": "internal_error",
"message": "The server encountered an error. Please try again. If the issue persists contact support@soniox.com.",
"validation_errors": [],
"request_id": "3d37a3bd-5078-47ee-a369-b204e3bbedda",
"more_info": "https://soniox.com/docs/api-reference/errors#internal-error"
}Get usage logs GET
Returns per-request usage log entries for the project. The project is implied by the API key used for authentication. Filters by request end time. The window between start_time and end_time must not exceed 31 days. start_time must not be earlier than 91 days ago.
Errors
Reference for every error type returned by Soniox APIs (REST, async, STT WebSocket, TTS WebSocket, TTS REST), with the cause and how to resolve each one.