Get API Call Statistics
GET/organizations/:organizationId/stats/api-calls
Get API call count per organization from CloudWatch Logs. Queries CloudWatch Logs Insights to count API requests for the organization. Results are cached for 1 hour to reduce CloudWatch Logs costs.
Request
Query Parameters
Possible values: ["7", "30", "90"]
Default value: 30
Number of days to query (7, 30, or 90)
Possible values: ["true", "false"]
Force refresh cache (bypass 1-hour cache)
Responses
- 200
- 401
- 403
- application/json
- Schema
- Example (from schema)
- Example
Schema
- Array [
- ]
Total number of API requests in the period
Average requests per day
topEndpoints object[]required
Top 10 most called endpoints
Unix timestamp when data was fetched
Whether the response was served from cache
Number of days queried
{
"totalRequests": 0,
"dailyAverage": 0,
"topEndpoints": [
{
"endpoint": "string",
"count": 0
}
],
"cachedAt": 0,
"isCached": true,
"queryDays": 0
}
{}
The request has not permission.
- application/json
- Schema
- Example (from schema)
- Example
Schema
The request has not permission.
The request has not permission message.
{
"error": "string",
"message": "string"
}
{
"error": "Unauthenticated",
"message": "Authentication is required and has failed or has not yet been provided."
}
The request has not permission.
- application/json
- Schema
- Example (from schema)
- Example
Schema
The request has not permission.
The request has not permission message.
{
"error": "string",
"message": "string"
}
{
"error": "Forbidden",
"message": "Access to the requested resource is forbidden."
}