Get route stats by actor
/orgs/{org}/insights/api/route-stats/{actor_type}/{actor_id} Get API request count statistics for an actor broken down by route within a specified time frame.
Parameters
path Path Parameters
| Name | Type |
|---|---|
org
required
The organization name. The name is not case sensitive. | string |
actor_type
required
The type of the actor | "installation" | "classic_pat" | "fine_grained_pat" | "oauth_app" | "github_app_user_to_server" |
actor_id
required
The ID of the actor | number |
query Query Parameters
| Name | Type |
|---|---|
min_timestamp
required
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: | string |
max_timestamp The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: | string |
page The page number of the results to fetch. For more information, see "Using pagination in the REST API." | number |
per_page The number of results per page (max 100). For more information, see "Using pagination in the REST API." | number |
direction The direction to sort the results by. | "asc" | "desc" |
sort The property to sort the results by. | ("last_rate_limited_timestamp" | "last_request_timestamp" | "rate_limited_request_count" | "http_method" | "api_route" | "total_request_count")[] |
api_route_substring Providing a substring will filter results where the API route contains the substring. This is a case-insensitive search. | string |
Responses
Response
http_method?: string;
api_route?: string;
total_request_count?: number;
rate_limited_request_count?: number;
last_rate_limited_timestamp?: string | null;
last_request_timestamp?: string;
}[]