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

Get billing usage report for a user

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.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

4 parameters
usernamestringrequired
The handle for the GitHub user account.
yearintegeroptional
If specified, only return results for a single year. The value of `year` is an integer with four digits representing a year. For example, `2025`. Default value is the current year.
monthintegeroptional
If specified, only return results for a single month. The value of `month` is an integer between `1` and `12`. If no year is specified the default `year` is used.
dayintegeroptional
If specified, only return results for a single day. The value of `day` is an integer between `1` and `31`. If no `year` or `month` is specified, the default `year` and `month` are used.

5 status codes
200Response when getting a billing usage report
usageItemsarray<object>optional
400Bad Request
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional
403Forbidden
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional
500Internal Error
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional
503Service unavailable
codestringoptional
messagestringoptional
documentation_urlstringoptional

Error handling

A 400 is returned: Bad Request. A 403 is returned: Forbidden. A 500 is returned: Internal Error. A 503 is returned: Service unavailable.

Was this helpful?