Use the REST API to view statistics for API usage in an organization.
Note
Most endpoints use Authorization: Bearer <YOUR-TOKEN> and Accept: application/vnd.github+json headers, plus X-GitHub-Api-Version: 2026-03-10. Curl examples below omit these standard headers for brevity.
GET /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.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
actor_type (string) (required)
The type of the actor
Can be one of: installation, classic_pat, fine_grained_pat, oauth_app, github_app_user_to_server
actor_id (integer) (required)
The ID of the actor
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
page (integer)
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Default: 1
per_page (integer)
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Default: 30
direction (string)
The direction to sort the results by.
Default: desc
Can be one of: asc, desc
sort (array)
The property to sort the results by.
api_route_substring (string)
Providing a substring will filter results where the API route contains the substring. This is a case-insensitive search.
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/route-stats/ACTOR_TYPE/ACTOR_ID?min_timestamp=MIN_TIMESTAMP"
Response schema (Status: 200):
Array of objects:
http_method: stringapi_route: stringtotal_request_count: integer, format: int64rate_limited_request_count: integer, format: int64last_rate_limited_timestamp: string or nulllast_request_timestamp: stringGET /orgs/{org}/insights/api/subject-stats
Get API request statistics for all subjects within an organization within a specified time frame. Subjects can be users or GitHub Apps.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
page (integer)
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Default: 1
per_page (integer)
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Default: 30
direction (string)
The direction to sort the results by.
Default: desc
Can be one of: asc, desc
sort (array)
The property to sort the results by.
subject_name_substring (string)
Providing a substring will filter results where the subject name contains the substring. This is a case-insensitive search.
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/subject-stats?min_timestamp=MIN_TIMESTAMP"
Response schema (Status: 200):
Array of objects:
subject_type: stringsubject_name: stringsubject_id: integer, format: int64total_request_count: integerrate_limited_request_count: integerlast_rate_limited_timestamp: string or nulllast_request_timestamp: stringGET /orgs/{org}/insights/api/summary-stats
Get overall statistics of API requests made within an organization by all users and apps within a specified time frame.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/summary-stats?min_timestamp=MIN_TIMESTAMP"
Response schema (Status: 200):
total_request_count: integer, format: int64rate_limited_request_count: integer, format: int64GET /orgs/{org}/insights/api/summary-stats/users/{user_id}
Get overall statistics of API requests within the organization for a user.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
user_id (string) (required)
The ID of the user to query for stats
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/summary-stats/users/USER_ID?min_timestamp=MIN_TIMESTAMP"
Response schema (Status: 200):
Same response schema as Get summary stats.
GET /orgs/{org}/insights/api/summary-stats/{actor_type}/{actor_id}
Get overall statistics of API requests within the organization made by a specific actor. Actors can be GitHub App installations, OAuth apps or other tokens on behalf of a user.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
actor_type (string) (required)
The type of the actor
Can be one of: installation, classic_pat, fine_grained_pat, oauth_app, github_app_user_to_server
actor_id (integer) (required)
The ID of the actor
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/summary-stats/ACTOR_TYPE/ACTOR_ID?min_timestamp=MIN_TIMESTAMP"
Response schema (Status: 200):
Same response schema as Get summary stats.
GET /orgs/{org}/insights/api/time-stats
Get the number of API requests and rate-limited requests made within an organization over a specified time period.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
timestamp_increment (string) (required)
The increment of time used to breakdown the query results (5m, 10m, 1h, etc.)
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/time-stats?min_timestamp=MIN_TIMESTAMP×tamp_increment=TIMESTAMP_INCREMENT"
Response schema (Status: 200):
Array of objects:
timestamp: stringtotal_request_count: integer, format: int64rate_limited_request_count: integer, format: int64GET /orgs/{org}/insights/api/time-stats/users/{user_id}
Get the number of API requests and rate-limited requests made within an organization by a specific user over a specified time period.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
user_id (string) (required)
The ID of the user to query for stats
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
timestamp_increment (string) (required)
The increment of time used to breakdown the query results (5m, 10m, 1h, etc.)
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/time-stats/users/USER_ID?min_timestamp=MIN_TIMESTAMP×tamp_increment=TIMESTAMP_INCREMENT"
Response schema (Status: 200):
Same response schema as Get time stats.
GET /orgs/{org}/insights/api/time-stats/{actor_type}/{actor_id}
Get the number of API requests and rate-limited requests made within an organization by a specific actor within a specified time period.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
actor_type (string) (required)
The type of the actor
Can be one of: installation, classic_pat, fine_grained_pat, oauth_app, github_app_user_to_server
actor_id (integer) (required)
The ID of the actor
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
timestamp_increment (string) (required)
The increment of time used to breakdown the query results (5m, 10m, 1h, etc.)
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/time-stats/ACTOR_TYPE/ACTOR_ID?min_timestamp=MIN_TIMESTAMP×tamp_increment=TIMESTAMP_INCREMENT"
Response schema (Status: 200):
Same response schema as Get time stats.
GET /orgs/{org}/insights/api/user-stats/{user_id}
Get API usage statistics within an organization for a user broken down by the type of access.
Under normal conditions, you can expect API data to appear within 4–6 hours after making a request. During incidents or periods of unusually high volume, it may take longer to show up.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
user_id (string) (required)
The ID of the user to query for stats
min_timestamp (string) (required)
The minimum timestamp to query for stats. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
max_timestamp (string)
The maximum timestamp to query for stats. Defaults to the time 30 days ago. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ.
page (integer)
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Default: 1
per_page (integer)
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Default: 30
direction (string)
The direction to sort the results by.
Default: desc
Can be one of: asc, desc
sort (array)
The property to sort the results by.
actor_name_substring (string)
Providing a substring will filter results where the actor name contains the substring. This is a case-insensitive search.
Request:
curl -L \
-X GET \
"https://api.github.com/orgs/ORG/insights/api/user-stats/USER_ID?min_timestamp=MIN_TIMESTAMP"
Response schema (Status: 200):
Array of objects:
actor_type: stringactor_name: stringactor_id: integer, format: int64integration_id: integer or null, format: int64oauth_application_id: integer or null, format: int64total_request_count: integerrate_limited_request_count: integerlast_rate_limited_timestamp: string or nulllast_request_timestamp: string