Billing usage

Use the REST API to get billing usage information.

The endpoints on this page return usage that is billed to the account associated with the endpoint. For help deciding which level of usage to report on, see Automating usage reporting with the REST API.

To view enterprise-level endpoints, select the dropdown menu at the top of the page and switch from Free, Pro, & Team to GitHub Enterprise Cloud.

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 billing AI credit usage report for an organization

GET /organizations/{org}/settings/billing/ai_credit/usage

Gets a report of AI credit usage for an organization. To use this endpoint, you must be an administrator of an organization within an enterprise or an organization account.
Note: Only data from the past 24 months is accessible via this endpoint.

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/organizations/ORG/settings/billing/ai_credit/usage

Response schema (Status: 200):

Get billing premium request usage report for an organization

GET /organizations/{org}/settings/billing/premium_request/usage

Gets a report of premium request usage for an organization. To use this endpoint, you must be an administrator of an organization within an enterprise or an organization account.
Note: Only data from the past 24 months is accessible via this endpoint.

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/organizations/ORG/settings/billing/premium_request/usage

Response schema (Status: 200):

Same response schema as Get billing AI credit usage report for an organization.

Get billing usage report for an organization

GET /organizations/{org}/settings/billing/usage

Gets a report of the total usage for an organization. To use this endpoint, you must be an administrator of an organization within an enterprise or an organization account.
Note: This endpoint is only available to organizations with access to the enhanced billing platform. For more information, see "About the enhanced billing platform."

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/organizations/ORG/settings/billing/usage

Response schema (Status: 200):

Get billing usage summary for an organization

GET /organizations/{org}/settings/billing/usage/summary

Note

This endpoint is in public preview and is subject to change.

Gets a summary report of usage for an organization. To use this endpoint, you must be an administrator of an organization within an enterprise or an organization account.
Note: Only data from the past 24 months is accessible via this endpoint.

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/organizations/ORG/settings/billing/usage/summary

Response schema (Status: 200):

Get billing AI credit usage report for a user

GET /users/{username}/settings/billing/ai_credit/usage

Gets a report of AI credit usage for a user.
Note: Only data from the past 24 months is accessible via this endpoint.

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/users/USERNAME/settings/billing/ai_credit/usage

Response schema (Status: 200):

Get billing premium request usage report for a user

GET /users/{username}/settings/billing/premium_request/usage

Gets a report of premium request usage for a user.
Note: Only data from the past 24 months is accessible via this endpoint.

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/users/USERNAME/settings/billing/premium_request/usage

Response schema (Status: 200):

Same response schema as Get billing AI credit usage report for a user.

Get billing usage report for a user

GET /users/{username}/settings/billing/usage

Gets a report of the total usage for a user.
Note: This endpoint is only available to users with access to the enhanced billing platform.

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/users/USERNAME/settings/billing/usage

Response schema (Status: 200):

Get billing usage summary for a user

GET /users/{username}/settings/billing/usage/summary

Note

This endpoint is in public preview and is subject to change.

Gets a summary report of usage for a user.
Note: Only data from the past 24 months is accessible via this endpoint.

Parameters

Headers

Path and query parameters

HTTP response status codes

Code examples

Example

Request:

curl -L \
  -X GET \
  https://api.github.com/users/USERNAME/settings/billing/usage/summary

Response schema (Status: 200):