Use the REST API to manage the GitHub Copilot Business subscription for your organization.
These endpoints are in public preview and subject to change.
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}/copilot/billing
Note
This endpoint is in public preview and is subject to change.
Gets information about an organization's Copilot subscription, including seat breakdown
and feature policies. To configure these settings, go to your organization's settings on GitHub.com.
For more information, see "Managing policies for Copilot in your organization."
Only organization owners can view details about the organization's Copilot Business or Copilot Enterprise subscription.
OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or read:org scopes to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)200 - OK
401 - Requires authentication
403 - Forbidden
404 - Resource not found
422 - There is a problem with your account's associated payment method.
500 - Internal Error
Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/copilot/billing
Response schema (Status: 200):
seat_breakdown: required, Copilot Seat Breakdown:
total: integeradded_this_cycle: integerpending_cancellation: integerpending_invitation: integeractive_this_cycle: integerinactive_this_cycle: integerpublic_code_suggestions: required, string, enum: allow, block, unconfiguredide_chat: string, enum: enabled, disabled, unconfiguredplatform_chat: string, enum: enabled, disabled, unconfiguredcli: string, enum: enabled, disabled, unconfiguredseat_management_setting: required, string, enum: assign_all, assign_selected, disabled, unconfiguredplan_type: string, enum: business, enterpriseGET /orgs/{org}/copilot/billing/seats
Note
This endpoint is in public preview and is subject to change.
Lists all Copilot seats for which an organization with a Copilot Business or Copilot Enterprise subscription is currently being billed.
Only organization owners can view assigned seats.
Each seat object contains information about the assigned user's most recent Copilot activity. Users must have telemetry enabled in their IDE for Copilot in the IDE activity to be reflected in last_activity_at.
For more information about activity data, see Metrics data properties for GitHub Copilot.
OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or read:org scopes to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
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: 50
200 - OK
401 - Requires authentication
403 - Forbidden
404 - Resource not found
500 - Internal Error
Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/copilot/billing/seats
Response schema (Status: 200):
total_seats: integerseats: array of Copilot Business Seat Detail:
assignee: any of:
name: string or nullemail: string or nulllogin: required, stringid: required, integer, format: int64node_id: required, stringavatar_url: required, string, format: urigravatar_id: required, string or nullurl: required, string, format: urihtml_url: required, string, format: urifollowers_url: required, string, format: urifollowing_url: required, stringgists_url: required, stringstarred_url: required, stringsubscriptions_url: required, string, format: uriorganizations_url: required, string, format: urirepos_url: required, string, format: urievents_url: required, stringreceived_events_url: required, string, format: uritype: required, stringsite_admin: required, booleanstarred_at: stringuser_view_type: stringorganization: any of:
login: required, stringid: required, integernode_id: required, stringurl: required, string, format: urirepos_url: required, string, format: urievents_url: required, string, format: urihooks_url: required, stringissues_url: required, stringmembers_url: required, stringpublic_members_url: required, stringavatar_url: required, stringdescription: required, string or nullassigning_team: one of:
id: required, integernode_id: required, stringname: required, stringslug: required, stringdescription: required, string or nullprivacy: stringnotification_setting: stringpermission: required, stringpermissions: object:
pull: required, booleantriage: required, booleanpush: required, booleanmaintain: required, booleanadmin: required, booleanurl: required, string, format: urihtml_url: required, string, format: urimembers_url: required, stringrepositories_url: required, string, format: uritype: required, string, enum: enterprise, organizationaccess_source: string, enum: direct, organization, enterpriseorganization_id: integerenterprise_id: integerparent: required, any of:
id: required, integernode_id: required, stringurl: required, string, format: urimembers_url: required, stringname: required, stringdescription: required, string or nullpermission: required, stringprivacy: stringnotification_setting: stringhtml_url: required, string, format: urirepositories_url: required, string, format: urislug: required, stringldap_dn: stringtype: required, string, enum: enterprise, organizationorganization_id: integerenterprise_id: integerid: required, integer, format: int64name: required, stringdescription: stringslug: required, stringurl: required, string, format: urisync_to_organizations: stringorganization_selection_type: stringgroup_id: required, string or nullgroup_name: string or nullhtml_url: required, string, format: urimembers_url: required, stringcreated_at: required, string, format: date-timeupdated_at: required, string, format: date-timenotification_setting: string, enum: notifications_enabled, notifications_disabledpending_cancellation_date: string or null, format: datelast_activity_at: string or null, format: date-timelast_activity_editor: string or nulllast_authenticated_at: string or null, format: date-timecreated_at: required, string, format: date-timeupdated_at: string, format: date-time, deprecatedplan_type: string, enum: business, enterprise, unknownPOST /orgs/{org}/copilot/billing/selected_teams
Note
This endpoint is in public preview and is subject to change.
Purchases a GitHub Copilot seat for all users within each specified team.
The organization will be billed for each seat based on the organization's Copilot plan. For more information about Copilot pricing, see "About billing for GitHub Copilot in your organization."
Only organization owners can purchase Copilot seats for their organization members. The organization must have a Copilot Business or Copilot Enterprise subscription and a configured suggestion matching policy.
For more information about setting up a Copilot subscription, see "Subscribing to Copilot for your organization."
For more information about setting a suggestion matching policy, see "Managing policies for Copilot in your organization."
The response contains the total number of new seats that were created and existing seats that were refreshed.
OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:org scopes to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)selected_teams (array of strings) (required)201 - OK
401 - Requires authentication
403 - Forbidden
404 - Resource not found
422 - Copilot Business or Enterprise is not enabled for this organization, billing has not been set up for this organization, a public code suggestions policy has not been set for this organization, or the organization's Copilot access setting is set to enable Copilot for all users or is unconfigured.
500 - Internal Error
Request:
curl -L \
-X POST \
https://api.github.com/orgs/ORG/copilot/billing/selected_teams \
-d '{
"selected_teams": [
"engteam1",
"engteam2",
"engteam3"
]
}'
Response schema (Status: 201):
seats_created: required, integerDELETE /orgs/{org}/copilot/billing/selected_teams
Note
This endpoint is in public preview and is subject to change.
Sets seats for all members of each team specified to "pending cancellation".
This will cause the members of the specified team(s) to lose access to GitHub Copilot at the end of the current billing cycle unless they retain access through another team.
For more information about disabling access to Copilot, see "Revoking access to Copilot for members of your organization."
Only organization owners can cancel Copilot seats for their organization members.
The response contains the total number of seats set to "pending cancellation".
OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:org scopes to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)selected_teams (array of strings) (required)200 - OK
401 - Requires authentication
403 - Forbidden
404 - Resource not found
422 - Copilot Business or Enterprise is not enabled for this organization, billing has not been set up for this organization, a public code suggestions policy has not been set for this organization, or the organization's Copilot access setting is set to enable Copilot for all users or is unconfigured.
500 - Internal Error
Request:
curl -L \
-X DELETE \
https://api.github.com/orgs/ORG/copilot/billing/selected_teams \
-d '{
"selected_teams": [
"engteam1",
"engteam2",
"engteam3"
]
}'
Response schema (Status: 200):
seats_cancelled: required, integerPOST /orgs/{org}/copilot/billing/selected_users
Note
This endpoint is in public preview and is subject to change.
Purchases a GitHub Copilot seat for each user specified.
The organization will be billed for each seat based on the organization's Copilot plan. For more information about Copilot pricing, see "About billing for GitHub Copilot in your organization."
Only organization owners can purchase Copilot seats for their organization members. The organization must have a Copilot Business or Copilot Enterprise subscription and a configured suggestion matching policy.
For more information about setting up a Copilot subscription, see "Subscribing to Copilot for your organization."
For more information about setting a suggestion matching policy, see "Managing policies for Copilot in your organization."
The response contains the total number of new seats that were created and existing seats that were refreshed.
OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:org scopes to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)selected_usernames (array of strings) (required)201 - OK
401 - Requires authentication
403 - Forbidden
404 - Resource not found
422 - Copilot Business or Enterprise is not enabled for this organization, billing has not been set up for this organization, a public code suggestions policy has not been set for this organization, or the organization's Copilot access setting is set to enable Copilot for all users or is unconfigured.
500 - Internal Error
Request:
curl -L \
-X POST \
https://api.github.com/orgs/ORG/copilot/billing/selected_users \
-d '{
"selected_usernames": [
"cooluser1",
"hacker2",
"octocat"
]
}'
Response schema (Status: 201):
Same response schema as Add teams to the Copilot subscription for an organization.
DELETE /orgs/{org}/copilot/billing/selected_users
Note
This endpoint is in public preview and is subject to change.
Sets seats for all users specified to "pending cancellation".
This will cause the specified users to lose access to GitHub Copilot at the end of the current billing cycle unless they retain access through team membership.
For more information about disabling access to Copilot, see "Revoking access to Copilot for members of your organization."
Only organization owners can cancel Copilot seats for their organization members.
The response contains the total number of seats set to "pending cancellation".
OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or admin:org scopes to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)selected_usernames (array of strings) (required)200 - OK
401 - Requires authentication
403 - Forbidden
404 - Resource not found
422 - Copilot Business or Enterprise is not enabled for this organization, billing has not been set up for this organization, a public code suggestions policy has not been set for this organization, the seat management setting is set to enable Copilot for all users or is unconfigured, or a user's seat cannot be cancelled because it was assigned to them via a team.
500 - Internal Error
Request:
curl -L \
-X DELETE \
https://api.github.com/orgs/ORG/copilot/billing/selected_users \
-d '{
"selected_usernames": [
"cooluser1",
"hacker2",
"octocat"
]
}'
Response schema (Status: 200):
Same response schema as Remove teams from the Copilot subscription for an organization.
GET /orgs/{org}/members/{username}/copilot
Note
This endpoint is in public preview and is subject to change.
Gets the GitHub Copilot seat details for a member of an organization who currently has access to GitHub Copilot.
The seat object contains information about the user's most recent Copilot activity. Users must have telemetry enabled in their IDE for Copilot in the IDE activity to be reflected in last_activity_at.
For more information about activity data, see Metrics data properties for GitHub Copilot.
Only organization owners can view Copilot seat assignment details for members of their organization.
OAuth app tokens and personal access tokens (classic) need either the manage_billing:copilot or read:org scopes to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
username (string) (required)
The handle for the GitHub user account.
200 - The user's GitHub Copilot seat details, including usage.
401 - Requires authentication
403 - Forbidden
404 - Resource not found
422 - Copilot Business or Enterprise is not enabled for this organization or the user has a pending organization invitation.
500 - Internal Error
Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/members/USERNAME/copilot
Response schema (Status: 200):
assignee: any of:
name: string or nullemail: string or nulllogin: required, stringid: required, integer, format: int64node_id: required, stringavatar_url: required, string, format: urigravatar_id: required, string or nullurl: required, string, format: urihtml_url: required, string, format: urifollowers_url: required, string, format: urifollowing_url: required, stringgists_url: required, stringstarred_url: required, stringsubscriptions_url: required, string, format: uriorganizations_url: required, string, format: urirepos_url: required, string, format: urievents_url: required, stringreceived_events_url: required, string, format: uritype: required, stringsite_admin: required, booleanstarred_at: stringuser_view_type: stringorganization: any of:
login: required, stringid: required, integernode_id: required, stringurl: required, string, format: urirepos_url: required, string, format: urievents_url: required, string, format: urihooks_url: required, stringissues_url: required, stringmembers_url: required, stringpublic_members_url: required, stringavatar_url: required, stringdescription: required, string or nullassigning_team: one of:
id: required, integernode_id: required, stringname: required, stringslug: required, stringdescription: required, string or nullprivacy: stringnotification_setting: stringpermission: required, stringpermissions: object:
pull: required, booleantriage: required, booleanpush: required, booleanmaintain: required, booleanadmin: required, booleanurl: required, string, format: urihtml_url: required, string, format: urimembers_url: required, stringrepositories_url: required, string, format: uritype: required, string, enum: enterprise, organizationaccess_source: string, enum: direct, organization, enterpriseorganization_id: integerenterprise_id: integerparent: required, any of:
id: required, integernode_id: required, stringurl: required, string, format: urimembers_url: required, stringname: required, stringdescription: required, string or nullpermission: required, stringprivacy: stringnotification_setting: stringhtml_url: required, string, format: urirepositories_url: required, string, format: urislug: required, stringldap_dn: stringtype: required, string, enum: enterprise, organizationorganization_id: integerenterprise_id: integerid: required, integer, format: int64name: required, stringdescription: stringslug: required, stringurl: required, string, format: urisync_to_organizations: stringorganization_selection_type: stringgroup_id: required, string or nullgroup_name: string or nullhtml_url: required, string, format: urimembers_url: required, stringcreated_at: required, string, format: date-timeupdated_at: required, string, format: date-timenotification_setting: string, enum: notifications_enabled, notifications_disabledpending_cancellation_date: string or null, format: datelast_activity_at: string or null, format: date-timelast_activity_editor: string or nulllast_authenticated_at: string or null, format: date-timecreated_at: required, string, format: date-timeupdated_at: string, format: date-time, deprecatedplan_type: string, enum: business, enterprise, unknown