These endpoints let you track how much of your plan you’ve used and how much capacity you have right now.
Get Usage
Return request and document counts for the current API key, both for the current calendar month and all-time.
Endpoint
GET /api/v1/usage
Response
Requests made this calendar month
Documents ingested this calendar month
Queries made this calendar month
Number of documents currently in your workspace
Example
curl "https://app.polyvia.ai/api/v1/usage" \
-H "Authorization: Bearer poly_<your-key>"
{
"usage" : {
"requests" : { "period" : 142 , "total" : 3801 },
"ingests" : { "period" : 12 , "total" : 204 },
"queries" : { "period" : 130 , "total" : 3597 },
"documents_stored" : 47
}
}
Get Rate Limits
Return the rate-limit thresholds for your plan and how much capacity remains right now.
Endpoint
GET /api/v1/rate-limits
Response
Hard limits for your plan (requests per minute, per month, etc.)
Real-time headroom — how much capacity remains in each window.
ISO 8601 timestamps of when each counter resets. When the per-minute window resets
When the monthly counters reset (first day of next month)
Example
curl "https://app.polyvia.ai/api/v1/rate-limits" \
-H "Authorization: Bearer poly_<your-key>"
{
"limits" : {
"requests_per_minute" : 60 ,
"requests_per_month" : 10000 ,
"documents_per_month" : 500 ,
"queries_per_month" : 2000
},
"current" : {
"remaining_this_minute" : 58 ,
"remaining_requests_this_month" : 9858 ,
"remaining_documents_this_month" : 488 ,
"remaining_queries_this_month" : 1870
},
"resets_at" : {
"minute" : "2025-04-23T14:32:00Z" ,
"month" : "2025-05-01T00:00:00Z"
}
}
Rate limits are informational — the API does not block requests when limits are reached, but you should monitor these values and implement back-off logic in production integrations.