Create a self-hosted runner group for an organization
Creates a new self-hosted runner group for an organization.
OAuth tokens and personal access tokens (classic) need the admin:org scope to use this endpoint.
Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ”The organization name. The name is not case sensitive.
Request Body required
Section titled “ Request Body required ”object
Name of the runner group.
Visibility of a runner group. You can select all repositories, select individual repositories, or limit access to private repositories.
List of repository IDs that can access the runner group.
List of runner IDs to add to the runner group.
Whether the runner group can be used by public repositories.
If true, the runner group will be restricted to running only the workflows specified in the selected_workflows array.
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows is set to true.
The identifier of a hosted compute network configuration.
Examples
{ "name": "Expensive hardware runners", "visibility": "selected", "selected_repository_ids": [ 32, 91 ], "runners": [ 9, 2 ]}Responses
Section titled “ Responses ”Response
object
Link to the selected repositories resource for this runner group. Not present unless visibility was set to selected
The identifier of a hosted compute network configuration.
If true, the restricted_to_workflows and selected_workflows fields cannot be modified.
If true, the runner group will be restricted to running only the workflows specified in the selected_workflows array.
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows is set to true.
Examples
{ "id": 2, "name": "octo-runner-group", "visibility": "selected", "default": false, "selected_repositories_url": "https://api.github.com/orgs/octo-org/actions/runner-groups/2/repositories", "runners_url": "https://api.github.com/orgs/octo-org/actions/runner_groups/2/runners", "hosted_runners_url": "https://api.github.com/orgs/octo-org/actions/runner_groups/2/hosted-runners", "network_configuration_id": "EC486D5D793175D7E3B29C27318D5C1AAE49A7833FC85F2E82C3D2C54AC7D3BA", "inherited": false, "allows_public_repositories": true, "restricted_to_workflows": true, "selected_workflows": [ "octo-org/octo-repo/.github/workflows/deploy.yaml@refs/heads/main" ], "workflow_restrictions_read_only": false}