Analytics
Get total usage
post/usage/total
Request
- Base URLhttps://api.us-east-1.langdb.ai
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Headers
X-Project-Idstring required
LangDB project ID
Request body
Example request
{
"start_time_us": 1693062345678
}Response
OK
Example response
{
"models": [
{
"provider": "openai",
"model_name": "gpt-4o",
"total_input_tokens": 3196182,
"total_output_tokens": 74096,
"total_cost": 10.4776979999,
"cost_per_input_token": 3,
"cost_per_output_token": 12
}
],
"total": {
"total_input_tokens": 4181386,
"total_output_tokens": 206547,
"total_cost": 11.8904386859
},
"period_start": 1737504000000000,
"period_end": 1740120949421000
}Changes
No recorded changes to this operation across all 1 revision of this API.