I saw Obscurity and Concealment - Discussions - Cursor - Community Forum and about the issue with bonus pricing no longer be there… I realized we can still access it, and now I’ve added it! We can now access the included usage and the bonus credits.
This is functionally equivalent but you can now
- View previous billing cycles for included usage, not just the on-demand usage.
- Show the bonus credits, technically calculable, but people really liked this feature.
- Multi-Currency support!!
This will be released soon. And for the concerns about security, you can upload your own account’s json file as an alternative for now, but I understand the concerns. I am preparing in making it open source soon.
The curl required is as follows:
Business/Teams Account
curl -X POST 'https://api.cursor.com/teams/filtered-usage-events' \
-H 'Content-Type: application/json' \
-H 'Authorization: Basic YOUR_API_KEY' \
-d '{
"pageSize": 10000,
"startDate": 0,
"page": 1
}' \
-o cursor-usage.json
Pro/Ultra/Plus Account
curl -X POST 'https://cursor.com/api/dashboard/get-filtered-usage-events' \
-H 'Content-Type: application/json' \
-H 'Cookie: WorkosCursorSessionToken=YOUR_SESSION_TOKEN' \
-H 'Origin: https://cursor.com' \
-d '{
"pageSize": 10000,
"startDate": 0,
"page": 1
}' \
-o cursor-usage.json
Response structure:
{
"totalUsageEventsCount": 12345,
"usageEventsDisplay": [
{
"timestamp": "1704067200000",
"model": "claude-4.5-sonnet",
"tokenUsage": {
"inputTokens": 100,
"outputTokens": 50,
"totalCents": 1.23
}
// ... more fields
}
]
}
Then click “Import JSON” in the dashboard and select usage.json.
If possible, I am trying to see if we could use OAuth in order to make it more secure rather than using sessions. The API key is pretty good but it’s only for teams/business users.
