curl --request POST \
--url https://pria.praxislxp.com/api/admin/histories/charts/timeline \
--header 'Content-Type: application/json' \
--header 'x-access-token: <api-key>' \
--data '
{
"granularity": "month",
"range": -3,
"dimension": "count",
"institution": "65cfebc32f5e1b37d4e52329",
"account": "<string>",
"aggregate": false,
"topsearch": 5
}
'{
"success": true,
"data": [
{
"_id": {
"granularity": "2023-11-07T05:31:56Z",
"institution": "<string>"
},
"dimension": 123
}
]
}Get time-series chart data for histories
Optimized endpoint for time-series charts (bar, line, area, heatmap, scatter). Supports count, credits, usage, cached, and price dimensions. Uses a 2-step top-N query to avoid fetching data for all institutions.
curl --request POST \
--url https://pria.praxislxp.com/api/admin/histories/charts/timeline \
--header 'Content-Type: application/json' \
--header 'x-access-token: <api-key>' \
--data '
{
"granularity": "month",
"range": -3,
"dimension": "count",
"institution": "65cfebc32f5e1b37d4e52329",
"account": "<string>",
"aggregate": false,
"topsearch": 5
}
'{
"success": true,
"data": [
{
"_id": {
"granularity": "2023-11-07T05:31:56Z",
"institution": "<string>"
},
"dimension": 123
}
]
}Documentation Index
Fetch the complete documentation index at: https://docs.praxis-ai.com/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
JWT token passed in x-access-token header
Body
Time granularity for bucketing
day, week, month, hour "month"
Time range (negative values for past periods)
-3
Metric to aggregate
count, credits, usage, cached, price "count"
Institution ID (optional, filters by institution)
"65cfebc32f5e1b37d4e52329"
Account ID (optional, filters by account's institutions)
When true, aggregates across all institutions
false
Number of top institutions to return (default 5, -1 for all)
5
Was this page helpful?