Use the REST API to interact with self-hosted runners in GitHub Actions.
You can use the REST API to register, view, and delete self-hosted runners in GitHub Actions. Self-hosted runners allow you to host your own runners and customize the environment used to run jobs in your GitHub Actions workflows. For more information, see Managing self-hosted runners.
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}/actions/runners
Lists all self-hosted runners configured in an organization.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint. If the repository is private, the repo scope is also required.
accept (string)application/vnd.github+json is recommended.name (string)
The name of a self-hosted runner.
org (string) (required)
The organization name. The name is not case sensitive.
per_page (integer)
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Default: 30
page (integer)
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Default: 1
Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/actions/runners
Response schema (Status: 200):
total_count: required, integerrunners: required, array of Self hosted runners:
id: required, integerrunner_group_id: integername: required, stringos: required, stringstatus: required, stringbusy: required, booleanlabels: required, array of Self hosted runner label:
id: integername: required, stringtype: string, enum: read-only, customephemeral: booleanversion: string or nullGET /orgs/{org}/actions/runners/deprecations/{version}
Gets the end-of-life schedule for a specific runner version in an organization. Returns the runner version
and the dates when registration and runtime support will end.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
version (string) (required)
The runner version to look up.
Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/actions/runners/deprecations/VERSION
Response schema (Status: 200):
runner_version: required, stringregistration_deprecates_at: string or null, format: date-timeruntime_deprecates_at: string or null, format: date-timeGET /orgs/{org}/actions/runners/downloads
Lists binaries for the runner application that you can download and run.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint. If the repository is private, the repo scope is also required.
accept (string)application/vnd.github+json is recommended.org (string) (required)Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/actions/runners/downloads
Response schema (Status: 200):
Array of Runner Application:
os: required, stringarchitecture: required, stringdownload_url: required, stringfilename: required, stringtemp_download_token: stringsha256_checksum: stringPOST /orgs/{org}/actions/runners/generate-jitconfig
Generates a configuration that can be passed to the runner application at startup.
The authenticated user must have admin access to the organization.
OAuth tokens and personal access tokens (classic) need theadmin:org scope to use this endpoint. If the repository is private, OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)name (string) (required)
The name of the new runner.
runner_group_id (integer) (required)
The ID of the runner group to register the runner to.
labels (array of strings) (required)
The names of the custom labels to add to the runner. Minimum items: 1. Maximum items: 100.
work_folder (string)
The working directory to be used for job execution, relative to the runner install directory.
Default: _work
201 - Created
404 - Resource not found
409 - Conflict
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X POST \
https://api.github.com/orgs/ORG/actions/runners/generate-jitconfig \
-d '{
"name": "New runner",
"runner_group_id": 1,
"labels": [
"self-hosted",
"X64",
"macOS",
"no-gpu"
],
"work_folder": "_work"
}'
Response schema (Status: 201):
runner: required, Self hosted runners:
id: required, integerrunner_group_id: integername: required, stringos: required, stringstatus: required, stringbusy: required, booleanlabels: required, array of Self hosted runner label:
id: integername: required, stringtype: string, enum: read-only, customephemeral: booleanversion: string or nullencoded_jit_config: required, stringPOST /orgs/{org}/actions/runners/registration-token
Returns a token that you can pass to the config script. The token expires after one hour.
For example, you can replace TOKEN in the following example with the registration token provided by this endpoint to configure your self-hosted runner:
./config.sh --url https://github.com/octo-org --token TOKEN
Authenticated users must have admin access to the organization to use this endpoint.
OAuth tokens and personal access tokens (classic) need theadmin:org scope to use this endpoint. If the repository is private, OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)Request:
curl -L \
-X POST \
https://api.github.com/orgs/ORG/actions/runners/registration-token
Response schema (Status: 201):
token: required, stringexpires_at: required, string, format: date-timepermissions: objectrepositories: array of Repository:
id: required, integer, format: int64node_id: required, stringname: required, stringfull_name: required, stringlicense: required, any of:
key: required, stringname: required, stringurl: required, string or null, format: urispdx_id: required, string or nullnode_id: required, stringhtml_url: string, format: uriforks: required, integerpermissions: object:
admin: required, booleanpull: required, booleantriage: booleanpush: required, booleanmaintain: booleanowner: required, Simple User:
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: stringprivate: required, boolean, default: falsehtml_url: required, string, format: uridescription: required, string or nullfork: required, booleanurl: required, string, format: uriarchive_url: required, stringassignees_url: required, stringblobs_url: required, stringbranches_url: required, stringcollaborators_url: required, stringcomments_url: required, stringcommits_url: required, stringcompare_url: required, stringcontents_url: required, stringcontributors_url: required, string, format: urideployments_url: required, string, format: uridownloads_url: required, string, format: urievents_url: required, string, format: uriforks_url: required, string, format: urigit_commits_url: required, stringgit_refs_url: required, stringgit_tags_url: required, stringgit_url: required, stringissue_comment_url: required, stringissue_events_url: required, stringissues_url: required, stringkeys_url: required, stringlabels_url: required, stringlanguages_url: required, string, format: urimerges_url: required, string, format: urimilestones_url: required, stringnotifications_url: required, stringpulls_url: required, stringreleases_url: required, stringssh_url: required, stringstargazers_url: required, string, format: uristatuses_url: required, stringsubscribers_url: required, string, format: urisubscription_url: required, string, format: uritags_url: required, string, format: uriteams_url: required, string, format: uritrees_url: required, stringclone_url: required, stringmirror_url: required, string or null, format: urihooks_url: required, string, format: urisvn_url: required, string, format: urihomepage: required, string or null, format: urilanguage: required, string or nullforks_count: required, integerstargazers_count: required, integerwatchers_count: required, integersize: required, integerdefault_branch: required, stringopen_issues_count: required, integeris_template: boolean, default: falsetopics: array of stringhas_issues: required, boolean, default: truehas_projects: required, boolean, default: truehas_wiki: required, boolean, default: truehas_pages: required, booleanhas_discussions: boolean, default: falsehas_pull_requests: boolean, default: truepull_request_creation_policy: string, enum: all, collaborators_onlyarchived: required, boolean, default: falsedisabled: required, booleanvisibility: string, default: "public"pushed_at: required, string or null, format: date-timecreated_at: required, string or null, format: date-timeupdated_at: required, string or null, format: date-timeallow_rebase_merge: boolean, default: truetemp_clone_token: stringallow_squash_merge: boolean, default: trueallow_auto_merge: boolean, default: falsedelete_branch_on_merge: boolean, default: falseallow_update_branch: boolean, default: falsesquash_merge_commit_title: string, enum: PR_TITLE, COMMIT_OR_PR_TITLEsquash_merge_commit_message: string, enum: PR_BODY, COMMIT_MESSAGES, BLANKmerge_commit_title: string, enum: PR_TITLE, MERGE_MESSAGEmerge_commit_message: string, enum: PR_BODY, PR_TITLE, BLANKallow_merge_commit: boolean, default: trueallow_forking: booleanweb_commit_signoff_required: boolean, default: falseopen_issues: required, integerwatchers: required, integerstarred_at: stringanonymous_access_enabled: booleancode_search_index_status: object:
lexical_search_ok: booleanlexical_commit_sha: stringsingle_file: string or nullrepository_selection: string, enum: all, selectedPOST /orgs/{org}/actions/runners/remove-token
Returns a token that you can pass to the config script to remove a self-hosted runner from an organization. The token expires after one hour.
For example, you can replace TOKEN in the following example with the registration token provided by this endpoint to remove your self-hosted runner from an organization:
./config.sh remove --token TOKEN
Authenticated users must have admin access to the organization to use this endpoint.
OAuth tokens and personal access tokens (classic) need theadmin:org scope to use this endpoint. If the repository is private, OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)Request:
curl -L \
-X POST \
https://api.github.com/orgs/ORG/actions/runners/remove-token
Response schema (Status: 201):
Same response schema as Create a registration token for an organization.
GET /orgs/{org}/actions/runners/{runner_id}
Gets a specific self-hosted runner configured in an organization.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint. If the repository is private, the repo scope is also required.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/actions/runners/RUNNER_ID
Response schema (Status: 200):
id: required, integerrunner_group_id: integername: required, stringos: required, stringstatus: required, stringbusy: required, booleanlabels: required, array of Self hosted runner label:
id: integername: required, stringtype: string, enum: read-only, customephemeral: booleanversion: string or nullDELETE /orgs/{org}/actions/runners/{runner_id}
Forces the removal of a self-hosted runner from an organization. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth tokens and personal access tokens (classic) need theadmin:org scope to use this endpoint. If the repository is private, OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
204 - No Content
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X DELETE \
https://api.github.com/orgs/ORG/actions/runners/RUNNER_ID
Response schema (Status: 204):
GET /orgs/{org}/actions/runners/{runner_id}/labels
Lists all labels for a self-hosted runner configured in an organization.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint. If the repository is private, the repo scope is also required.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
200 - OK
404 - Resource not found
Request:
curl -L \
-X GET \
https://api.github.com/orgs/ORG/actions/runners/RUNNER_ID/labels
Response schema (Status: 200):
total_count: required, integerlabels: required, array of Self hosted runner label:
id: integername: required, stringtype: string, enum: read-only, customPOST /orgs/{org}/actions/runners/{runner_id}/labels
Adds custom labels to a self-hosted runner configured in an organization.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth tokens and personal access tokens (classic) need the admin:org scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
labels (array of strings) (required)200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X POST \
https://api.github.com/orgs/ORG/actions/runners/RUNNER_ID/labels \
-d '{
"labels": [
"gpu",
"accelerated"
]
}'
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
PUT /orgs/{org}/actions/runners/{runner_id}/labels
Remove all previous custom labels and set the new custom labels for a specific
self-hosted runner configured in an organization.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint. If the repository is private, the repo scope is also required.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
labels (array of strings) (required)200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X PUT \
https://api.github.com/orgs/ORG/actions/runners/RUNNER_ID/labels \
-d '{
"labels": [
"gpu",
"accelerated"
]
}'
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
DELETE /orgs/{org}/actions/runners/{runner_id}/labels
Remove all custom labels from a self-hosted runner configured in an
organization. Returns the remaining read-only labels from the runner.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint. If the repository is private, the repo scope is also required.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
200 - OK
404 - Resource not found
Request:
curl -L \
-X DELETE \
https://api.github.com/orgs/ORG/actions/runners/RUNNER_ID/labels
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
DELETE /orgs/{org}/actions/runners/{runner_id}/labels/{name}
Remove a custom label from a self-hosted runner configured
in an organization. Returns the remaining labels from the runner.
This endpoint returns a 404 Not Found status if the custom label is not
present on the runner.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint. If the repository is private, the repo scope is also required.
accept (string)application/vnd.github+json is recommended.org (string) (required)
The organization name. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
name (string) (required)
The name of a self-hosted runner's custom label.
200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X DELETE \
https://api.github.com/orgs/ORG/actions/runners/RUNNER_ID/labels/NAME
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
GET /repos/{owner}/{repo}/actions/runners
Lists all self-hosted runners configured in a repository.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.name (string)
The name of a self-hosted runner.
owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
per_page (integer)
The number of results per page (max 100). For more information, see "Using pagination in the REST API."
Default: 30
page (integer)
The page number of the results to fetch. For more information, see "Using pagination in the REST API."
Default: 1
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/actions/runners
Response schema (Status: 200):
Same response schema as List self-hosted runners for an organization.
GET /repos/{owner}/{repo}/actions/runners/deprecations/{version}
Gets the end-of-life schedule for a specific runner version in a repository. Returns the runner version
and the dates when registration and runtime support will end.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
version (string) (required)
The runner version to look up.
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/actions/runners/deprecations/VERSION
Response schema (Status: 200):
Same response schema as Get runner version end-of-life schedule for an organization.
GET /repos/{owner}/{repo}/actions/runners/downloads
Lists binaries for the runner application that you can download and run.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/actions/runners/downloads
Response schema (Status: 200):
Same response schema as List runner applications for an organization.
POST /repos/{owner}/{repo}/actions/runners/generate-jitconfig
Generates a configuration that can be passed to the runner application at startup.
The authenticated user must have admin access to the repository.
OAuth tokens and personal access tokens (classic) need therepo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
name (string) (required)
The name of the new runner.
runner_group_id (integer) (required)
The ID of the runner group to register the runner to.
labels (array of strings) (required)
The names of the custom labels to add to the runner. Minimum items: 1. Maximum items: 100.
work_folder (string)
The working directory to be used for job execution, relative to the runner install directory.
Default: _work
201 - Created
404 - Resource not found
409 - Conflict
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X POST \
https://api.github.com/repos/OWNER/REPO/actions/runners/generate-jitconfig \
-d '{
"name": "New runner",
"runner_group_id": 1,
"labels": [
"self-hosted",
"X64",
"macOS",
"no-gpu"
],
"work_folder": "_work"
}'
Response schema (Status: 201):
Same response schema as Create configuration for a just-in-time runner for an organization.
POST /repos/{owner}/{repo}/actions/runners/registration-token
Returns a token that you can pass to the config script. The token expires after one hour.
For example, you can replace TOKEN in the following example with the registration token provided by this endpoint to configure your self-hosted runner:
./config.sh --url https://github.com/octo-org --token TOKEN
Authenticated users must have admin access to the repository to use this endpoint.
OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
Request:
curl -L \
-X POST \
https://api.github.com/repos/OWNER/REPO/actions/runners/registration-token
Response schema (Status: 201):
Same response schema as Create a registration token for an organization.
POST /repos/{owner}/{repo}/actions/runners/remove-token
Returns a token that you can pass to the config script to remove a self-hosted runner from an repository. The token expires after one hour.
For example, you can replace TOKEN in the following example with the registration token provided by this endpoint to remove your self-hosted runner from an organization:
./config.sh remove --token TOKEN
Authenticated users must have admin access to the repository to use this endpoint.
OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
Request:
curl -L \
-X POST \
https://api.github.com/repos/OWNER/REPO/actions/runners/remove-token
Response schema (Status: 201):
Same response schema as Create a registration token for an organization.
GET /repos/{owner}/{repo}/actions/runners/{runner_id}
Gets a specific self-hosted runner configured in a repository.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/actions/runners/RUNNER_ID
Response schema (Status: 200):
Same response schema as Get a self-hosted runner for an organization.
DELETE /repos/{owner}/{repo}/actions/runners/{runner_id}
Forces the removal of a self-hosted runner from a repository. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
204 - No Content
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X DELETE \
https://api.github.com/repos/OWNER/REPO/actions/runners/RUNNER_ID
Response schema (Status: 204):
GET /repos/{owner}/{repo}/actions/runners/{runner_id}/labels
Lists all labels for a self-hosted runner configured in a repository.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
200 - OK
404 - Resource not found
Request:
curl -L \
-X GET \
https://api.github.com/repos/OWNER/REPO/actions/runners/RUNNER_ID/labels
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
POST /repos/{owner}/{repo}/actions/runners/{runner_id}/labels
Adds custom labels to a self-hosted runner configured in a repository.
Authenticated users must have admin access to the organization to use this endpoint.
OAuth tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
labels (array of strings) (required)200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X POST \
https://api.github.com/repos/OWNER/REPO/actions/runners/RUNNER_ID/labels \
-d '{
"labels": [
"gpu",
"accelerated"
]
}'
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
PUT /repos/{owner}/{repo}/actions/runners/{runner_id}/labels
Remove all previous custom labels and set the new custom labels for a specific
self-hosted runner configured in a repository.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
labels (array of strings) (required)200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X PUT \
https://api.github.com/repos/OWNER/REPO/actions/runners/RUNNER_ID/labels \
-d '{
"labels": [
"gpu",
"accelerated"
]
}'
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
DELETE /repos/{owner}/{repo}/actions/runners/{runner_id}/labels
Remove all custom labels from a self-hosted runner configured in a
repository. Returns the remaining read-only labels from the runner.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
200 - OK
404 - Resource not found
Request:
curl -L \
-X DELETE \
https://api.github.com/repos/OWNER/REPO/actions/runners/RUNNER_ID/labels
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.
DELETE /repos/{owner}/{repo}/actions/runners/{runner_id}/labels/{name}
Remove a custom label from a self-hosted runner configured
in a repository. Returns the remaining labels from the runner.
This endpoint returns a 404 Not Found status if the custom label is not
present on the runner.
Authenticated users must have admin access to the repository to use this endpoint.
OAuth app tokens and personal access tokens (classic) need the repo scope to use this endpoint.
accept (string)application/vnd.github+json is recommended.owner (string) (required)
The account owner of the repository. The name is not case sensitive.
repo (string) (required)
The name of the repository without the .git extension. The name is not case sensitive.
runner_id (integer) (required)
Unique identifier of the self-hosted runner.
name (string) (required)
The name of a self-hosted runner's custom label.
200 - OK
404 - Resource not found
422 - Validation failed, or the endpoint has been spammed.
Request:
curl -L \
-X DELETE \
https://api.github.com/repos/OWNER/REPO/actions/runners/RUNNER_ID/labels/NAME
Response schema (Status: 200):
Same response schema as List labels for a self-hosted runner for an organization.