Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Track and monitor API usage across your Grantex deployment
USAGE_METERING_ENABLED=true
curl https://api.grantex.dev/v1/usage \ -H "Authorization: Bearer $GRANTEX_KEY"
{ "developerId": "dev_...", "period": "2026-03-02", "tokenExchanges": 42, "authorizations": 18, "verifications": 7, "totalRequests": 67 }
curl "https://api.grantex.dev/v1/usage/history?days=30" \ -H "Authorization: Bearer $GRANTEX_KEY"
// TypeScript const usage = await grantex.usage.current(); console.log(`Today: ${usage.totalRequests} requests`); const history = await grantex.usage.history({ days: 7 }); for (const day of history.entries) { console.log(`${day.date}: ${day.totalRequests}`); }
# Python usage = grantex.usage.current() print(f"Today: {usage.total_requests} requests") history = grantex.usage.history(days=7) for day in history.entries: print(f"{day.date}: {day.total_requests}")