Enterprise Administration
Download SpecEnterprise Administration
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
Response
Response
[
{
"type": "Global",
"id": 1,
"name": "web",
"active": true,
"events": [
"organization",
"user"
],
"config": {
"url": "https://example.com",
"content_type": "json",
"insecure_ssl": "0",
"secret": "********"
},
"updated_at": "2017-12-07T00:14:59Z",
"created_at": "2017-12-07T00:14:59Z",
"url": "https://api.github.com/admin/hooks/1",
"ping_url": "https://api.github.com/admin/hooks/1/pings"
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
type
string
id
int
name
string
active
boolean
events
array[string]
string
config
object (config)
url
string
content_type
string
insecure_ssl
string
secret
string
updated_at
string
created_at
string
url
string
ping_url
string
Link
string
name
string
required
Must be passed as "web".
config
object (config)
required
Key/value pairs to provide settings for this webhook.
url
string
required
The URL to which the payloads will be delivered.
content_type
string
The media type used to serialize the payloads. Supported values include json
and form
. The default is form
.
secret
string
If provided, the secret
will be used as the key
to generate the HMAC hex digest value in the X-Hub-Signature
header.
insecure_ssl
string
Determines whether the SSL certificate of the host for url
will be verified when delivering payloads. Supported values include 0
(verification is performed) and 1
(verification is not performed). The default is 0
. We strongly recommend not setting this to 1
as you are subject to man-in-the-middle and other attacks.
events
array[string]
The events that trigger this webhook. A global webhook can be triggered by user
and organization
events. Default: user
and organization
.
string
active
boolean
Determines if notifications are sent when the webhook is triggered. Set to true
to send notifications.
- Default
- true
Request
{
"name": "web",
"events": [
"organization",
"user"
],
"config": {
"url": "https://example.com/webhook",
"content_type": "json",
"secret": "secret"
}
}
Response
Response
{
"type": "Global",
"id": 1,
"name": "web",
"active": true,
"events": [
"organization",
"user"
],
"config": {
"url": "https://example.com",
"content_type": "json",
"insecure_ssl": "0",
"secret": "********"
},
"updated_at": "2017-12-07T00:14:59Z",
"created_at": "2017-12-07T00:14:59Z",
"url": "https://api.github.com/admin/hooks/1",
"ping_url": "https://api.github.com/admin/hooks/1/pings"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
type
string
id
int
name
string
active
boolean
events
array[string]
string
config
object (config)
url
string
content_type
string
insecure_ssl
string
secret
string
updated_at
string
created_at
string
url
string
ping_url
string
hook_id
int
required
The unique identifier of the hook.
Response
Response
{
"type": "Global",
"id": 1,
"name": "web",
"active": true,
"events": [
"organization",
"user"
],
"config": {
"url": "https://example.com",
"content_type": "json",
"insecure_ssl": "0",
"secret": "********"
},
"updated_at": "2017-12-07T00:14:59Z",
"created_at": "2017-12-07T00:14:59Z",
"url": "https://api.github.com/admin/hooks/1",
"ping_url": "https://api.github.com/admin/hooks/1/pings"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
type
string
id
int
name
string
active
boolean
events
array[string]
string
config
object (config)
url
string
content_type
string
insecure_ssl
string
secret
string
updated_at
string
created_at
string
url
string
ping_url
string
hook_id
int
required
The unique identifier of the hook.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Update a global webhook
Parameters that are not provided will be overwritten with the default value or removed if no default exists.
config
object (config)
Key/value pairs to provide settings for this webhook.
url
string
required
The URL to which the payloads will be delivered.
content_type
string
The media type used to serialize the payloads. Supported values include json
and form
. The default is form
.
secret
string
If provided, the secret
will be used as the key
to generate the HMAC hex digest value in the X-Hub-Signature
header.
insecure_ssl
string
Determines whether the SSL certificate of the host for url
will be verified when delivering payloads. Supported values include 0
(verification is performed) and 1
(verification is not performed). The default is 0
. We strongly recommend not setting this to 1
as you are subject to man-in-the-middle and other attacks.
events
array[string]
The events that trigger this webhook. A global webhook can be triggered by user
and organization
events. Default: user
and organization
.
string
active
boolean
Determines if notifications are sent when the webhook is triggered. Set to true
to send notifications.
- Default
- true
hook_id
int
required
The unique identifier of the hook.
Request
{
"events": [
"organization"
],
"config": {
"url": "https://example.com/webhook"
}
}
Response
Response
{
"type": "Global",
"id": 1,
"name": "web",
"active": true,
"events": [
"organization"
],
"config": {
"url": "https://example.com",
"content_type": "form",
"insecure_ssl": "0"
},
"updated_at": "2017-12-07T00:14:59Z",
"created_at": "2017-12-07T00:14:59Z",
"url": "https://api.github.com/admin/hooks/1",
"ping_url": "https://api.github.com/admin/hooks/1/pings"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
type
string
id
int
name
string
active
boolean
events
array[string]
string
config
object (config)
url
string
content_type
string
insecure_ssl
string
updated_at
string
created_at
string
url
string
ping_url
string
Ping a global webhook
This will trigger a ping event to be sent to the webhook.
hook_id
int
required
The unique identifier of the hook.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
direction
string
The direction to sort the results by.
- Default
- "desc"
- Enum
-
- asc
- desc
sort
string
- Default
- "created"
- Enum
-
- created
- updated
- accessed
since
string
Only show public keys accessed after the given time.
Response
Response
[
{
"key": "2Sg8iYjAxxmI2LvUXpJjkYrMxURPc8r+dB7TJyvv1234",
"id": 2,
"url": "https://api.github.com/user/keys/2",
"title": "ssh-rsa AAAAB3NzaC1yc2EAAA",
"created_at": "2020-06-11T21:31:57Z",
"verified": false,
"read_only": false,
"last_used": "2020-06-11T22:31:57Z",
"user_id": 1,
"repository_id": 2
},
{
"key": "9Og8iYjAyymI9LvABpJerYrMxURPc8r+dB7TJyvv1234",
"id": 3,
"url": "https://api.github.com/user/keys/2",
"title": "ssh-rsa AAAAB3NzaC1yc2EAAA",
"created_at": "2020-06-11T21:31:57Z",
"verified": false,
"read_only": false,
"last_used": "2020-06-11T22:31:57Z",
"user_id": 1,
"repository_id": 2
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
id
int
required
key
string
required
user_id
int or null
required
repository_id
int or null
required
url
string
required
title
string
required
read_only
boolean
required
verified
boolean
required
created_at
string
date-time
required
added_by
string or null
last_used
string or null
date-time
required
Link
string
key_ids
string
required
The unique identifier of the key.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Update LDAP mapping for a team
Updates the distinguished name (DN) of the LDAP entry to map to a team. LDAP synchronization must be enabled to map LDAP entries to a team. Use the Create a team endpoint to create a team with LDAP mapping.
ldap_dn
string
required
The distinguished name (DN) of the LDAP entry to map to a team.
team_id
int
required
The unique identifier of the team.
Request
{
"ldap_dn": "cn=Enterprise Ops,ou=teams,dc=github,dc=com"
}
Response
Response
{
"ldap_dn": "cn=Enterprise Ops,ou=teams,dc=github,dc=com",
"id": 1,
"node_id": "MDQ6VGVhbTE=",
"url": "https://api.github.com/teams/1",
"html_url": "https://github.com/orgs/github/teams/justice-league",
"name": "Justice League",
"slug": "justice-league",
"description": "A great team.",
"privacy": "closed",
"notification_setting": "notifications_enabled",
"permission": "admin",
"members_url": "https://api.github.com/teams/1/members{/member}",
"repositories_url": "https://api.github.com/teams/1/repos",
"parent": null
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
ldap_dn
string
id
int
node_id
string
url
string
html_url
string
name
string
slug
string
description
string or null
privacy
string
permission
string
members_url
string
repositories_url
string
parent
or null
Sync LDAP mapping for a team
Note that this API call does not automatically initiate an LDAP sync. Rather, if a 201
is returned, the sync job is queued successfully, and is performed when the instance is ready.
team_id
int
required
The unique identifier of the team.
Response
Response
{
"status": "queued"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
status
string
ldap_dn
string
required
The distinguished name (DN) of the LDAP entry to map to a team.
username
string
required
The handle for the GitHub user account.
Request
{
"ldap_dn": "uid=asdf,ou=users,dc=github,dc=com"
}
Response
Response
{
"ldap_dn": "uid=asdf,ou=users,dc=github,dc=com",
"login": "octocat",
"id": 1,
"node_id": "MDQ6VXNlcjE=",
"avatar_url": "https://github.com/images/error/octocat_happy.gif",
"gravatar_id": "",
"url": "https://api.github.com/users/octocat",
"html_url": "https://github.com/octocat",
"followers_url": "https://api.github.com/users/octocat/followers",
"following_url": "https://api.github.com/users/octocat/following{/other_user}",
"gists_url": "https://api.github.com/users/octocat/gists{/gist_id}",
"starred_url": "https://api.github.com/users/octocat/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/octocat/subscriptions",
"organizations_url": "https://api.github.com/users/octocat/orgs",
"repos_url": "https://api.github.com/users/octocat/repos",
"events_url": "https://api.github.com/users/octocat/events{/privacy}",
"received_events_url": "https://api.github.com/users/octocat/received_events",
"type": "User",
"site_admin": false,
"name": "monalisa octocat",
"company": "GitHub",
"blog": "https://github.com/blog",
"location": "San Francisco",
"email": "octocat@github.com",
"hireable": false,
"bio": "There once was...",
"twitter_username": "monatheoctocat",
"public_repos": 2,
"public_gists": 1,
"followers": 20,
"following": 0,
"created_at": "2008-01-14T04:33:35Z",
"updated_at": "2008-01-14T04:33:35Z",
"private_gists": 81,
"total_private_repos": 100,
"owned_private_repos": 100,
"disk_usage": 10000,
"collaborators": 8,
"two_factor_authentication": true,
"plan": {
"name": "Medium",
"space": 400,
"private_repos": 20,
"collaborators": 0
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
ldap_dn
string
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
name
string or null
required
- Example
- "monalisa octocat"
company
string or null
required
- Example
- "GitHub"
blog
string or null
required
- Example
- "https://github.com/blog"
location
string or null
required
- Example
- "San Francisco"
string or null
required
- Example
- "octocat@github.com"
hireable
boolean or null
required
bio
string or null
required
- Example
- "There once was..."
twitter_username
string or null
- Example
- "monalisa"
public_repos
int
required
- Example
- 2
public_gists
int
required
- Example
- 1
followers
int
required
- Example
- 20
following
int
required
- Example
- 0
created_at
string
date-time
required
- Example
- "2008-01-14T04:33:35Z"
updated_at
string
date-time
required
- Example
- "2008-01-14T04:33:35Z"
private_gists
int
required
- Example
- 81
total_private_repos
int
required
- Example
- 100
owned_private_repos
int
required
- Example
- 100
disk_usage
int
required
- Example
- 10000
collaborators
int
required
- Example
- 8
two_factor_authentication
boolean
required
- Example
- true
plan
object (plan)
collaborators
int
required
name
string
required
space
int
required
private_repos
int
required
suspended_at
string or null
date-time
business_plus
boolean
Sync LDAP mapping for a user
Note that this API call does not automatically initiate an LDAP sync. Rather, if a 201
is returned, the sync job is queued successfully, and is performed when the instance is ready.
username
string
required
The handle for the GitHub user account.
Response
Response
{
"status": "queued"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
status
string
login
string
required
The organization's username.
admin
string
required
The login of the user who will manage this organization.
profile_name
string
The organization's display name.
Request
{
"login": "github",
"profile_name": "GitHub, Inc.",
"admin": "monalisaoctocat"
}
Response
Response
{
"login": "github",
"id": 1,
"node_id": "MDEyOk9yZ2FuaXphdGlvbjE=",
"url": "https://api.github.com/orgs/github",
"repos_url": "https://api.github.com/orgs/github/repos",
"events_url": "https://api.github.com/orgs/github/events",
"hooks_url": "https://api.github.com/orgs/github/hooks",
"issues_url": "https://api.github.com/orgs/github/issues",
"members_url": "https://api.github.com/orgs/github/members{/member}",
"public_members_url": "https://api.github.com/orgs/github/public_members{/member}",
"avatar_url": "https://github.com/images/error/octocat_happy.gif",
"description": "A great organization"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
login
string
required
- Example
- "github"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDEyOk9yZ2FuaXphdGlvbjE="
url
string
uri
required
- Example
- "https://api.github.com/orgs/github"
repos_url
string
uri
required
- Example
- "https://api.github.com/orgs/github/repos"
events_url
string
uri
required
- Example
- "https://api.github.com/orgs/github/events"
hooks_url
string
required
- Example
- "https://api.github.com/orgs/github/hooks"
issues_url
string
required
- Example
- "https://api.github.com/orgs/github/issues"
members_url
string
required
- Example
- "https://api.github.com/orgs/github/members{/member}"
public_members_url
string
required
- Example
- "https://api.github.com/orgs/github/public_members{/member}"
avatar_url
string
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
description
string or null
required
- Example
- "A great organization"
login
string
required
The organization's new name.
org
string
required
The organization name. The name is not case sensitive.
Request
{
"login": "the-new-octocats"
}
Response
Response
{
"message": "Job queued to rename organization. It may take a few minutes to complete.",
"url": "https://<hostname>/api/v3/organizations/1"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
url
string
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
direction
string
The direction to sort the results by.
- Default
- "desc"
- Enum
-
- asc
- desc
sort
string
- Default
- "created"
- Enum
-
- created
- updated
- name
Response
Response
[
{
"id": 1,
"name": "Default",
"image_url": "githubenterprise://internal",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/1",
"html_url": "https://github.example.com/admin/pre-receive-environments/1",
"default_environment": true,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 14,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/1/downloads/latest",
"state": "not_started",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
},
{
"id": 2,
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2",
"html_url": "https://github.example.com/admin/pre-receive-environments/2",
"default_environment": false,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2/downloads/latest",
"state": "success",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
name
string
required
The new pre-receive environment's name.
image_url
string
required
URL from which to download a tarball of this environment.
Request
{
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz"
}
Response
Response
{
"id": 2,
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2",
"html_url": "https://github.example.com/admin/pre-receive-environments/2",
"default_environment": false,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2/downloads/latest",
"state": "not_started",
"downloaded_at": null,
"message": null
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
pre_receive_environment_id
int
required
The unique identifier of the pre-receive environment.
Response
Response
{
"id": 2,
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2",
"html_url": "https://github.example.com/admin/pre-receive-environments/2",
"default_environment": false,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2/downloads/latest",
"state": "not_started",
"downloaded_at": null,
"message": null
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
Delete a pre-receive environment
If you attempt to delete an environment that cannot be deleted, you will receive a 422 Unprocessable Entity
response.
The possible error messages are:
- Cannot modify or delete the default environment
- Cannot delete environment that has hooks
- Cannot delete environment when download is in progress
pre_receive_environment_id
int
required
The unique identifier of the pre-receive environment.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
message
string
errors
array[object]
object
resource
string
code
string
message
string
Client Errors
{
"message": "Validation Failed",
"errors": [
{
"resource": "PreReceiveEnvironment",
"code": "custom",
"message": "Cannot modify or delete the default environment"
}
]
}
Update a pre-receive environment
You cannot modify the default environment. If you attempt to modify the default environment, you will receive a 422 Unprocessable Entity
response.
name
string
This pre-receive environment's new name.
image_url
string
URL from which to download a tarball of this environment.
pre_receive_environment_id
int
required
The unique identifier of the pre-receive environment.
Request
{
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz"
}
Response
Response
{
"id": 2,
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2",
"html_url": "https://github.example.com/admin/pre-receive-environments/2",
"default_environment": false,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2/downloads/latest",
"state": "success",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
message
string
errors
array[object]
object
resource
string
code
string
message
string
Client Errors
{
"message": "Validation Failed",
"errors": [
{
"resource": "PreReceiveEnvironment",
"code": "custom",
"message": "Cannot modify or delete the default environment"
}
]
}
Start a pre-receive environment download
Triggers a new download of the environment tarball from the environment's image_url
. When the download is finished, the newly downloaded tarball will overwrite the existing environment.
If a download cannot be triggered, you will receive a 422 Unprocessable Entity
response.
The possible error messages are:
- Cannot modify or delete the default environment
- Can not start a new download when a download is in progress
pre_receive_environment_id
int
required
The unique identifier of the pre-receive environment.
Response
Response
{
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/3/downloads/latest",
"state": "not_started",
"downloaded_at": null,
"message": null
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
url
string
state
string
downloaded_at
string or null
message
string or null
message
string
errors
array[object]
object
resource
string
code
string
message
string
Client Errors
{
"message": "Validation Failed",
"errors": [
{
"resource": "PreReceiveEnvironment",
"code": "custom",
"message": "Can not start a new download when a download is in progress"
}
]
}
Get the download status for a pre-receive environment
In addition to seeing the download status at the "Get a pre-receive environment" endpoint, there is also this separate endpoint for just the download status.
pre_receive_environment_id
int
required
The unique identifier of the pre-receive environment.
Response
Response
{
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/3/downloads/latest",
"state": "success",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
url
string
state
string
downloaded_at
string or null
message
string or null
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
direction
string
The direction to sort the results by.
- Default
- "desc"
- Enum
-
- asc
- desc
sort
string
The property to sort the results by.
- Default
- "created"
- Enum
-
- created
- updated
- name
Response
Response
[
{
"id": 1,
"name": "Check Commits",
"enforcement": "disabled",
"script": "scripts/commmit_check.sh",
"script_repository": {
"id": 595,
"full_name": "DevIT/hooks",
"url": "https://github.example.com/api/v3/repos/DevIT/hooks",
"html_url": "https://github.example.com/DevIT/hooks"
},
"environment": {
"id": 2,
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2",
"html_url": "https://github.example.com/admin/pre-receive-environments/2",
"default_environment": false,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2/downloads/latest",
"state": "success",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
},
"allow_downstream_configuration": false
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
id
int
name
string
enforcement
string
script
string
script_repository
object (script_repository)
id
int
full_name
string
url
string
html_url
string
environment
object (environment)
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
allow_downstream_configuration
boolean
name
string
required
The name of the hook.
script
string
required
The script that the hook runs.
script_repository
object (script_repository)
required
The GitHub repository where the script is kept.
environment
object (environment)
required
The pre-receive environment where the script is executed.
enforcement
string
The state of enforcement for this hook. default: disabled
allow_downstream_configuration
boolean
Whether enforcement can be overridden at the org or repo level. default: false
Request
{
"name": "Check Commits",
"script": "scripts/commit_check.sh",
"enforcement": "disabled",
"allow_downstream_configuration": false,
"script_repository": {
"full_name": "DevIT/hooks"
},
"environment": {
"id": 2
}
}
Response
Response
{
"id": 1,
"name": "Check Commits",
"enforcement": "disabled",
"script": "scripts/commmit_check.sh",
"script_repository": {
"id": 595,
"full_name": "DevIT/hooks",
"url": "https://github.example.com/api/v3/repos/DevIT/hooks",
"html_url": "https://github.example.com/DevIT/hooks"
},
"environment": {
"id": 2,
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2",
"html_url": "https://github.example.com/admin/pre-receive-environments/2",
"default_environment": false,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2/downloads/latest",
"state": "success",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
},
"allow_downstream_configuration": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
script
string
script_repository
object (script_repository)
id
int
full_name
string
url
string
html_url
string
environment
object (environment)
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
allow_downstream_configuration
boolean
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Response
Response
{
"id": 1,
"name": "Check Commits",
"enforcement": "disabled",
"script": "scripts/commmit_check.sh",
"script_repository": {
"id": 595,
"full_name": "DevIT/hooks",
"url": "https://github.example.com/api/v3/repos/DevIT/hooks",
"html_url": "https://github.example.com/DevIT/hooks"
},
"environment": {
"id": 2,
"name": "DevTools Hook Env",
"image_url": "https://my_file_server/path/to/devtools_env.tar.gz",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2",
"html_url": "https://github.example.com/admin/pre-receive-environments/2",
"default_environment": false,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/2/downloads/latest",
"state": "success",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
},
"allow_downstream_configuration": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
script
string
script_repository
object (script_repository)
id
int
full_name
string
url
string
html_url
string
environment
object (environment)
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
allow_downstream_configuration
boolean
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
name
string
The name of the hook.
script
string
The script that the hook runs.
script_repository
object (script_repository)
The GitHub repository where the script is kept.
environment
object (environment)
The pre-receive environment where the script is executed.
enforcement
string
The state of enforcement for this hook.
allow_downstream_configuration
boolean
Whether enforcement can be overridden at the org or repo level.
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Request
{
"name": "Check Commits",
"environment": {
"id": 1
},
"allow_downstream_configuration": true
}
Response
Response
{
"id": 1,
"name": "Check Commits",
"enforcement": "disabled",
"script": "scripts/commmit_check.sh",
"script_repository": {
"id": 595,
"full_name": "DevIT/hooks",
"url": "https://github.example.com/api/v3/repos/DevIT/hooks",
"html_url": "https://github.example.com/DevIT/hooks"
},
"environment": {
"id": 1,
"name": "Default",
"image_url": "githubenterprise://internal",
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/1",
"html_url": "https://github.example.com/admin/pre-receive-environments/1",
"default_environment": true,
"created_at": "2016-05-20T11:35:45-05:00",
"hooks_count": 1,
"download": {
"url": "https://github.example.com/api/v3/admin/pre-receive-environments/1/downloads/latest",
"state": "success",
"downloaded_at": "2016-05-26T07:42:53-05:00",
"message": null
}
},
"allow_downstream_configuration": true
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
script
string
script_repository
object (script_repository)
id
int
full_name
string
url
string
html_url
string
environment
object (environment)
id
int
name
string
image_url
string
url
string
html_url
string
default_environment
boolean
created_at
string
hooks_count
int
download
object (download)
url
string
state
string
downloaded_at
string or null
message
string or null
allow_downstream_configuration
boolean
List personal access tokens
Lists personal access tokens for all users, including admin users.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
Response
Response
[
{
"id": 2,
"url": "https://enterprise.octocat.com/api/v3/authorizations/2",
"app": {
"name": "My personal access token",
"url": "https://docs.github.com/enterprise/rest/reference/enterprise-admin#list-personal-access-tokens",
"client_id": "00000000000000000000"
},
"token": "ghp_16C7e42F292c6912E7710c838347Ae178B4a",
"hashed_token": "23cffb2fab1b0a62747863eba88cb9327e561f2f7a0c8661c0d9b83146cb8d45",
"token_last_eight": "Ae178B4a",
"note": "My personal access token",
"note_url": null,
"created_at": "2019-04-24T21:49:02Z",
"updated_at": "2019-04-24T21:49:02Z",
"scopes": [
"admin:business",
"admin:gpg_key",
"admin:org",
"admin:org_hook",
"admin:pre_receive_hook",
"admin:public_key",
"admin:repo_hook",
"delete_repo",
"gist",
"notifications",
"repo",
"user",
"write:discussion"
],
"fingerprint": null
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object (Authorization)]
- Content Type
- application/json
Authorization
object (Authorization)
The authorization for an OAuth app, GitHub App, or a Personal Access Token.
id
int
required
url
string
uri
required
scopes
array[string] or null
required
A list of scopes that this authorization is in.
string
token
string
required
token_last_eight
string or null
required
hashed_token
string or null
required
app
object (app)
required
client_id
string
required
name
string
required
url
string
uri
required
note
string or null
required
note_url
string or null
uri
required
updated_at
string
date-time
required
created_at
string
date-time
required
fingerprint
string or null
required
user
object (user) or null
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
installation
object (installation) or null
permissions
object (permissions)
required
The permissions granted to the user-to-server access token.
- Example
- { "contents": "read", "issues": "read", "deployments": "write", "single_file": "read" }
actions
string
The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts.
- Enum
-
- read
- write
administration
string
The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation.
- Enum
-
- read
- write
checks
string
The level of permission to grant the access token for checks on code.
- Enum
-
- read
- write
contents
string
The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges.
- Enum
-
- read
- write
deployments
string
The level of permission to grant the access token for deployments and deployment statuses.
- Enum
-
- read
- write
environments
string
The level of permission to grant the access token for managing repository environments.
- Enum
-
- read
- write
issues
string
The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones.
- Enum
-
- read
- write
metadata
string
The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata.
- Enum
-
- read
- write
packages
string
The level of permission to grant the access token for packages published to GitHub Packages.
- Enum
-
- read
- write
pages
string
The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds.
- Enum
-
- read
- write
pull_requests
string
The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges.
- Enum
-
- read
- write
repository_hooks
string
The level of permission to grant the access token to manage the post-receive hooks for a repository.
- Enum
-
- read
- write
repository_projects
string
The level of permission to grant the access token to manage repository projects, columns, and cards.
- Enum
-
- read
- write
- admin
secret_scanning_alerts
string
The level of permission to grant the access token to view and manage secret scanning alerts.
- Enum
-
- read
- write
secrets
string
The level of permission to grant the access token to manage repository secrets.
- Enum
-
- read
- write
security_events
string
The level of permission to grant the access token to view and manage security events like code scanning alerts.
- Enum
-
- read
- write
single_file
string
The level of permission to grant the access token to manage just a single file.
- Enum
-
- read
- write
statuses
string
The level of permission to grant the access token for commit statuses.
- Enum
-
- read
- write
vulnerability_alerts
string
The level of permission to grant the access token to manage Dependabot alerts.
- Enum
-
- read
- write
workflows
string
The level of permission to grant the access token to update GitHub Actions workflow files.
- Enum
-
- write
members
string
The level of permission to grant the access token for organization teams and members.
- Enum
-
- read
- write
organization_administration
string
The level of permission to grant the access token to manage access to an organization.
- Enum
-
- read
- write
organization_custom_roles
string
The level of permission to grant the access token for custom repository roles management. This property is in beta and is subject to change.
- Enum
-
- read
- write
organization_announcement_banners
string
The level of permission to grant the access token to view and manage announcement banners for an organization.
- Enum
-
- read
- write
organization_hooks
string
The level of permission to grant the access token to manage the post-receive hooks for an organization.
- Enum
-
- read
- write
organization_personal_access_tokens
string
The level of permission to grant the access token for viewing and managing fine-grained personal access token requests to an organization.
- Enum
-
- read
- write
organization_personal_access_token_requests
string
The level of permission to grant the access token for viewing and managing fine-grained personal access tokens that have been approved by an organization.
- Enum
-
- read
- write
organization_plan
string
The level of permission to grant the access token for viewing an organization's plan.
- Enum
-
- read
organization_projects
string
The level of permission to grant the access token to manage organization projects and projects beta (where available).
- Enum
-
- read
- write
- admin
organization_packages
string
The level of permission to grant the access token for organization packages published to GitHub Packages.
- Enum
-
- read
- write
organization_secrets
string
The level of permission to grant the access token to manage organization secrets.
- Enum
-
- read
- write
organization_self_hosted_runners
string
The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization.
- Enum
-
- read
- write
organization_user_blocking
string
The level of permission to grant the access token to view and manage users blocked by the organization.
- Enum
-
- read
- write
team_discussions
string
The level of permission to grant the access token to manage team discussions and related comments.
- Enum
-
- read
- write
repository_selection
string
required
Describe whether all repositories have been selected or there's a selection involved
- Enum
-
- all
- selected
single_file_name
string or null
required
- Example
- "config.yaml"
has_multiple_single_files
boolean
- Example
- true
single_file_paths
array[string]
- Example
- [ "config.yml", ".github/issue_TEMPLATE.md" ]
string
repositories_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
account
object (account)
required
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
expires_at
string or null
date-time
required
Link
string
Delete a personal access token
Deletes a personal access token. Returns a 403 - Forbidden
status when a personal access token is in use. For example, if you access this endpoint with the same personal access token that you are trying to delete, you will receive this error.
token_id
int
required
The unique identifier of the token.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Create a user
If an external authentication mechanism is used, the login name should match the login name in the external system. If you are using LDAP authentication, you should also update the LDAP mapping for the user.
The login name will be normalized to only contain alphanumeric characters or single hyphens. For example, if you send "octo_cat"
as the login, a user named "octo-cat"
will be created.
If the login name or email address is already associated with an account, the server will return a 422
response.
login
string
required
The user's username.
string
Required for built-in authentication. The user's email address. This parameter can be omitted when using CAS, LDAP, or SAML. For more information, see "About authentication for your enterprise."
suspended
boolean
Whether to set the user as suspended when the user is created.
- Default
- false
Request
{
"login": "monalisa",
"email": "octocat@github.com"
}
Response
Response
{
"login": "octocat",
"id": 1,
"node_id": "MDQ6VXNlcjE=",
"avatar_url": "https://github.com/images/error/octocat_happy.gif",
"gravatar_id": "",
"url": "https://api.github.com/users/octocat",
"html_url": "https://github.com/octocat",
"followers_url": "https://api.github.com/users/octocat/followers",
"following_url": "https://api.github.com/users/octocat/following{/other_user}",
"gists_url": "https://api.github.com/users/octocat/gists{/gist_id}",
"starred_url": "https://api.github.com/users/octocat/starred{/owner}{/repo}",
"subscriptions_url": "https://api.github.com/users/octocat/subscriptions",
"organizations_url": "https://api.github.com/users/octocat/orgs",
"repos_url": "https://api.github.com/users/octocat/repos",
"events_url": "https://api.github.com/users/octocat/events{/privacy}",
"received_events_url": "https://api.github.com/users/octocat/received_events",
"type": "User",
"site_admin": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
Delete a user
Deleting a user will delete all their repositories, gists, applications, and personal settings. Suspending a user is often a better option.
You can delete any user account except your own.
username
string
required
The handle for the GitHub user account.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
login
string
required
The user's new username.
username
string
required
The handle for the GitHub user account.
Request
{
"login": "thenewmonalisa"
}
Response
Response
{
"message": "Job queued to rename user. It may take a few minutes to complete.",
"url": "https://api.github.com/user/1"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
url
string
scopes
array[string]
required
A list of scopes.
string
username
string
required
The handle for the GitHub user account.
Request
{
"scopes": [
"public_repo"
]
}
Response
Response when creating a new impersonation OAuth token
{
"id": 1,
"url": "https://api.github.com/authorizations/1",
"scopes": [
"public_repo"
],
"token": "ghu_16C7e42F292c6912E7710c838347Ae178B4a",
"token_last_eight": "Ae178B4a",
"hashed_token": "25f94a2a5c7fbaf499c665bc73d67c1c87e496da8985131633ee0a95819db2e8",
"app": {
"url": "http://my-github-app.com",
"name": "my github app",
"client_id": "abcde12345fghij67890"
},
"note": "optional note",
"note_url": "http://optional/note/url",
"updated_at": "2011-09-06T20:39:23Z",
"created_at": "2011-09-06T17:26:27Z",
"expires_at": "2011-10-06T17:26:27Z",
"fingerprint": "jklmnop12345678"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Response when getting an existing impersonation OAuth token
{
"id": 1,
"url": "https://api.github.com/authorizations/1",
"scopes": [
"public_repo"
],
"token": "ghu_16C7e42F292c6912E7710c838347Ae178B4a",
"token_last_eight": "Ae178B4a",
"hashed_token": "25f94a2a5c7fbaf499c665bc73d67c1c87e496da8985131633ee0a95819db2e8",
"app": {
"url": "http://my-github-app.com",
"name": "my github app",
"client_id": "abcde12345fghij67890"
},
"note": "optional note",
"note_url": "http://optional/note/url",
"updated_at": "2011-09-06T20:39:23Z",
"created_at": "2011-09-06T17:26:27Z",
"expires_at": "2011-10-06T17:26:27Z",
"fingerprint": "jklmnop12345678"
}
id
int
required
url
string
uri
required
scopes
array[string] or null
required
A list of scopes that this authorization is in.
string
token
string
required
token_last_eight
string or null
required
hashed_token
string or null
required
app
object (app)
required
client_id
string
required
name
string
required
url
string
uri
required
note
string or null
required
note_url
string or null
uri
required
updated_at
string
date-time
required
created_at
string
date-time
required
fingerprint
string or null
required
user
object (user) or null
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
installation
object (installation) or null
permissions
object (permissions)
required
The permissions granted to the user-to-server access token.
- Example
- { "contents": "read", "issues": "read", "deployments": "write", "single_file": "read" }
actions
string
The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts.
- Enum
-
- read
- write
administration
string
The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation.
- Enum
-
- read
- write
checks
string
The level of permission to grant the access token for checks on code.
- Enum
-
- read
- write
contents
string
The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges.
- Enum
-
- read
- write
deployments
string
The level of permission to grant the access token for deployments and deployment statuses.
- Enum
-
- read
- write
environments
string
The level of permission to grant the access token for managing repository environments.
- Enum
-
- read
- write
issues
string
The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones.
- Enum
-
- read
- write
metadata
string
The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata.
- Enum
-
- read
- write
packages
string
The level of permission to grant the access token for packages published to GitHub Packages.
- Enum
-
- read
- write
pages
string
The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds.
- Enum
-
- read
- write
pull_requests
string
The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges.
- Enum
-
- read
- write
repository_hooks
string
The level of permission to grant the access token to manage the post-receive hooks for a repository.
- Enum
-
- read
- write
repository_projects
string
The level of permission to grant the access token to manage repository projects, columns, and cards.
- Enum
-
- read
- write
- admin
secret_scanning_alerts
string
The level of permission to grant the access token to view and manage secret scanning alerts.
- Enum
-
- read
- write
secrets
string
The level of permission to grant the access token to manage repository secrets.
- Enum
-
- read
- write
security_events
string
The level of permission to grant the access token to view and manage security events like code scanning alerts.
- Enum
-
- read
- write
single_file
string
The level of permission to grant the access token to manage just a single file.
- Enum
-
- read
- write
statuses
string
The level of permission to grant the access token for commit statuses.
- Enum
-
- read
- write
vulnerability_alerts
string
The level of permission to grant the access token to manage Dependabot alerts.
- Enum
-
- read
- write
workflows
string
The level of permission to grant the access token to update GitHub Actions workflow files.
- Enum
-
- write
members
string
The level of permission to grant the access token for organization teams and members.
- Enum
-
- read
- write
organization_administration
string
The level of permission to grant the access token to manage access to an organization.
- Enum
-
- read
- write
organization_custom_roles
string
The level of permission to grant the access token for custom repository roles management. This property is in beta and is subject to change.
- Enum
-
- read
- write
organization_announcement_banners
string
The level of permission to grant the access token to view and manage announcement banners for an organization.
- Enum
-
- read
- write
organization_hooks
string
The level of permission to grant the access token to manage the post-receive hooks for an organization.
- Enum
-
- read
- write
organization_personal_access_tokens
string
The level of permission to grant the access token for viewing and managing fine-grained personal access token requests to an organization.
- Enum
-
- read
- write
organization_personal_access_token_requests
string
The level of permission to grant the access token for viewing and managing fine-grained personal access tokens that have been approved by an organization.
- Enum
-
- read
- write
organization_plan
string
The level of permission to grant the access token for viewing an organization's plan.
- Enum
-
- read
organization_projects
string
The level of permission to grant the access token to manage organization projects and projects beta (where available).
- Enum
-
- read
- write
- admin
organization_packages
string
The level of permission to grant the access token for organization packages published to GitHub Packages.
- Enum
-
- read
- write
organization_secrets
string
The level of permission to grant the access token to manage organization secrets.
- Enum
-
- read
- write
organization_self_hosted_runners
string
The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization.
- Enum
-
- read
- write
organization_user_blocking
string
The level of permission to grant the access token to view and manage users blocked by the organization.
- Enum
-
- read
- write
team_discussions
string
The level of permission to grant the access token to manage team discussions and related comments.
- Enum
-
- read
- write
repository_selection
string
required
Describe whether all repositories have been selected or there's a selection involved
- Enum
-
- all
- selected
single_file_name
string or null
required
- Example
- "config.yaml"
has_multiple_single_files
boolean
- Example
- true
single_file_paths
array[string]
- Example
- [ "config.yml", ".github/issue_TEMPLATE.md" ]
string
repositories_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
account
object (account)
required
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
expires_at
string or null
date-time
required
id
int
required
url
string
uri
required
scopes
array[string] or null
required
A list of scopes that this authorization is in.
string
token
string
required
token_last_eight
string or null
required
hashed_token
string or null
required
app
object (app)
required
client_id
string
required
name
string
required
url
string
uri
required
note
string or null
required
note_url
string or null
uri
required
updated_at
string
date-time
required
created_at
string
date-time
required
fingerprint
string or null
required
user
object (user) or null
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
installation
object (installation) or null
permissions
object (permissions)
required
The permissions granted to the user-to-server access token.
- Example
- { "contents": "read", "issues": "read", "deployments": "write", "single_file": "read" }
actions
string
The level of permission to grant the access token for GitHub Actions workflows, workflow runs, and artifacts.
- Enum
-
- read
- write
administration
string
The level of permission to grant the access token for repository creation, deletion, settings, teams, and collaborators creation.
- Enum
-
- read
- write
checks
string
The level of permission to grant the access token for checks on code.
- Enum
-
- read
- write
contents
string
The level of permission to grant the access token for repository contents, commits, branches, downloads, releases, and merges.
- Enum
-
- read
- write
deployments
string
The level of permission to grant the access token for deployments and deployment statuses.
- Enum
-
- read
- write
environments
string
The level of permission to grant the access token for managing repository environments.
- Enum
-
- read
- write
issues
string
The level of permission to grant the access token for issues and related comments, assignees, labels, and milestones.
- Enum
-
- read
- write
metadata
string
The level of permission to grant the access token to search repositories, list collaborators, and access repository metadata.
- Enum
-
- read
- write
packages
string
The level of permission to grant the access token for packages published to GitHub Packages.
- Enum
-
- read
- write
pages
string
The level of permission to grant the access token to retrieve Pages statuses, configuration, and builds, as well as create new builds.
- Enum
-
- read
- write
pull_requests
string
The level of permission to grant the access token for pull requests and related comments, assignees, labels, milestones, and merges.
- Enum
-
- read
- write
repository_hooks
string
The level of permission to grant the access token to manage the post-receive hooks for a repository.
- Enum
-
- read
- write
repository_projects
string
The level of permission to grant the access token to manage repository projects, columns, and cards.
- Enum
-
- read
- write
- admin
secret_scanning_alerts
string
The level of permission to grant the access token to view and manage secret scanning alerts.
- Enum
-
- read
- write
secrets
string
The level of permission to grant the access token to manage repository secrets.
- Enum
-
- read
- write
security_events
string
The level of permission to grant the access token to view and manage security events like code scanning alerts.
- Enum
-
- read
- write
single_file
string
The level of permission to grant the access token to manage just a single file.
- Enum
-
- read
- write
statuses
string
The level of permission to grant the access token for commit statuses.
- Enum
-
- read
- write
vulnerability_alerts
string
The level of permission to grant the access token to manage Dependabot alerts.
- Enum
-
- read
- write
workflows
string
The level of permission to grant the access token to update GitHub Actions workflow files.
- Enum
-
- write
members
string
The level of permission to grant the access token for organization teams and members.
- Enum
-
- read
- write
organization_administration
string
The level of permission to grant the access token to manage access to an organization.
- Enum
-
- read
- write
organization_custom_roles
string
The level of permission to grant the access token for custom repository roles management. This property is in beta and is subject to change.
- Enum
-
- read
- write
organization_announcement_banners
string
The level of permission to grant the access token to view and manage announcement banners for an organization.
- Enum
-
- read
- write
organization_hooks
string
The level of permission to grant the access token to manage the post-receive hooks for an organization.
- Enum
-
- read
- write
organization_personal_access_tokens
string
The level of permission to grant the access token for viewing and managing fine-grained personal access token requests to an organization.
- Enum
-
- read
- write
organization_personal_access_token_requests
string
The level of permission to grant the access token for viewing and managing fine-grained personal access tokens that have been approved by an organization.
- Enum
-
- read
- write
organization_plan
string
The level of permission to grant the access token for viewing an organization's plan.
- Enum
-
- read
organization_projects
string
The level of permission to grant the access token to manage organization projects and projects beta (where available).
- Enum
-
- read
- write
- admin
organization_packages
string
The level of permission to grant the access token for organization packages published to GitHub Packages.
- Enum
-
- read
- write
organization_secrets
string
The level of permission to grant the access token to manage organization secrets.
- Enum
-
- read
- write
organization_self_hosted_runners
string
The level of permission to grant the access token to view and manage GitHub Actions self-hosted runners available to an organization.
- Enum
-
- read
- write
organization_user_blocking
string
The level of permission to grant the access token to view and manage users blocked by the organization.
- Enum
-
- read
- write
team_discussions
string
The level of permission to grant the access token to manage team discussions and related comments.
- Enum
-
- read
- write
repository_selection
string
required
Describe whether all repositories have been selected or there's a selection involved
- Enum
-
- all
- selected
single_file_name
string or null
required
- Example
- "config.yaml"
has_multiple_single_files
boolean
- Example
- true
single_file_paths
array[string]
- Example
- [ "config.yml", ".github/issue_TEMPLATE.md" ]
string
repositories_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
account
object (account)
required
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
expires_at
string or null
date-time
required
username
string
required
The handle for the GitHub user account.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Get the global announcement banner
Gets the current message and expiration date of the global announcement banner in your enterprise.
Response
Response
{
"announcement": "Very **important** announcement about _something_.",
"expires_at": "2021-01-01T00:00:00.000+00:00",
"user_dismissible": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
announcement
string or null
required
The announcement text in GitHub Flavored Markdown. For more information about GitHub Flavored Markdown, see "Basic writing and formatting syntax."
- Example
- "Very **important** announcement about _something_."
expires_at
string or null
date-time
The time at which the announcement expires. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ
. To set an announcement that never expires, omit this parameter, set it to null
, or set it to an empty string.
- Example
- "\"2021-01-01T00:00:00.000-07:00\""
Remove the global announcement banner
Removes the global announcement banner in your enterprise.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Set the global announcement banner
Sets the message and expiration time for the global announcement banner in your enterprise.
announcement
string or null
required
The announcement text in GitHub Flavored Markdown. For more information about GitHub Flavored Markdown, see "Basic writing and formatting syntax."
- Example
- "Very **important** announcement about _something_."
expires_at
string or null
date-time
The time at which the announcement expires. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ
. To set an announcement that never expires, omit this parameter, set it to null
, or set it to an empty string.
- Example
- "\"2021-01-01T00:00:00.000-07:00\""
Request
{
"announcement": "Very **important** announcement about _something_.",
"expires_at": "2021-01-01T00:00:00.000+00:00"
}
Response
Response
{
"announcement": "Very **important** announcement about _something_.",
"expires_at": "2021-01-01T00:00:00.000+00:00",
"user_dismissible": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
announcement
string or null
required
The announcement text in GitHub Flavored Markdown. For more information about GitHub Flavored Markdown, see "Basic writing and formatting syntax."
- Example
- "Very **important** announcement about _something_."
expires_at
string or null
date-time
The time at which the announcement expires. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ
. To set an announcement that never expires, omit this parameter, set it to null
, or set it to an empty string.
- Example
- "\"2021-01-01T00:00:00.000-07:00\""
Response
Response
{
"seats": 1400,
"seats_used": 1316,
"seats_available": 84,
"kind": "standard",
"days_until_expiration": 365,
"expire_at": "2016/02/06 12:41:52 -0600"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
seats
One Of
string
int
seats_used
int
seats_available
One Of
string
int
kind
string
days_until_expiration
int
expire_at
string
Response
Response
{
"repos": {
"total_repos": 212,
"root_repos": 194,
"fork_repos": 18,
"org_repos": 51,
"total_pushes": 3082,
"total_wikis": 15
},
"hooks": {
"total_hooks": 27,
"active_hooks": 23,
"inactive_hooks": 4
},
"pages": {
"total_pages": 36
},
"orgs": {
"total_orgs": 33,
"disabled_orgs": 0,
"total_teams": 60,
"total_team_members": 314
},
"users": {
"total_users": 254,
"admin_users": 45,
"suspended_users": 21
},
"pulls": {
"total_pulls": 86,
"merged_pulls": 60,
"mergeable_pulls": 21,
"unmergeable_pulls": 3
},
"issues": {
"total_issues": 179,
"open_issues": 83,
"closed_issues": 96
},
"milestones": {
"total_milestones": 7,
"open_milestones": 6,
"closed_milestones": 1
},
"gists": {
"total_gists": 178,
"private_gists": 151,
"public_gists": 25
},
"comments": {
"total_commit_comments": 6,
"total_gist_comments": 28,
"total_issue_comments": 366,
"total_pull_request_comments": 30
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
repos
object (repos)
total_repos
int
required
root_repos
int
required
fork_repos
int
required
org_repos
int
required
total_pushes
int
required
total_wikis
int
required
hooks
object (hooks)
total_hooks
int
required
active_hooks
int
required
inactive_hooks
int
required
pages
object (pages)
total_pages
int
required
orgs
object (orgs)
total_orgs
int
required
disabled_orgs
int
required
total_teams
int
required
total_team_members
int
required
users
object (users)
total_users
int
required
admin_users
int
required
suspended_users
int
required
pulls
object (pulls)
total_pulls
int
required
merged_pulls
int
required
mergeable_pulls
int
required
unmergeable_pulls
int
required
issues
object (issues)
total_issues
int
required
open_issues
int
required
closed_issues
int
required
milestones
object (milestones)
total_milestones
int
required
open_milestones
int
required
closed_milestones
int
required
gists
object (gists)
total_gists
int
required
private_gists
int
required
public_gists
int
required
comments
object (comments)
total_commit_comments
int
required
total_gist_comments
int
required
total_issue_comments
int
required
total_pull_request_comments
int
required
Response
Response
{
"total_commit_comments": 5000,
"total_gist_comments": 400,
"total_issue_comments": 10900,
"total_pull_request_comments": 9900
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_commit_comments
int
required
total_gist_comments
int
required
total_issue_comments
int
required
total_pull_request_comments
int
required
Response
Response
{
"total_gists": 500,
"private_gists": 30,
"public_gists": 470
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_gists
int
required
private_gists
int
required
public_gists
int
required
Get hooks statistics
Response
Response
{
"total_hooks": 50,
"active_hooks": 47,
"inactive_hooks": 3
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_hooks
int
required
active_hooks
int
required
inactive_hooks
int
required
Response
Response
{
"total_issues": 5000,
"open_issues": 300,
"closed_issues": 4700
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_issues
int
required
open_issues
int
required
closed_issues
int
required
Response
Response
{
"total_milestones": 90,
"open_milestones": 10,
"closed_milestones": 80
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_milestones
int
required
open_milestones
int
required
closed_milestones
int
required
Response
Response
{
"total_orgs": 50,
"disabled_orgs": 1,
"total_teams": 70,
"total_team_members": 700
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_orgs
int
required
disabled_orgs
int
required
total_teams
int
required
total_team_members
int
required
Response
Response
{
"total_pages": 20
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_pages
int
required
Response
Response
{
"total_pulls": 1200,
"merged_pulls": 1100,
"mergeable_pulls": 90,
"unmergeable_pulls": 10
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_pulls
int
required
merged_pulls
int
required
mergeable_pulls
int
required
unmergeable_pulls
int
required
Get repository statistics
Response
Response
{
"total_repos": 200,
"root_repos": 1,
"fork_repos": 10,
"org_repos": 150,
"total_pushes": 39000,
"total_wikis": 5
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_repos
int
required
root_repos
int
required
fork_repos
int
required
org_repos
int
required
total_pushes
int
required
total_wikis
int
required
Response
Response
{
"total_users": 100,
"admin_users": 3,
"suspended_users": 1
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_users
int
required
admin_users
int
required
suspended_users
int
required
Get GitHub Actions permissions for an enterprise
Gets the GitHub Actions permissions policy for organizations and allowed actions in an enterprise.
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"enabled_organizations": "all",
"allowed_actions": "selected",
"selected_actions_url": "https://api.github.com/enterprises/2/actions/permissions/selected-actions"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
enabled_organizations
string
required
The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions.
- Enum
-
- all
- none
- selected
selected_organizations_url
string
The API URL to use to get or set the selected organizations that are allowed to run GitHub Actions, when enabled_organizations
is set to selected
.
allowed_actions
string
The permissions policy that controls the actions that are allowed to run.
- Enum
-
- all
- local_only
- selected
selected_actions_url
string
The API URL to use to get or set the actions that are allowed to run, when allowed_actions
is set to selected
.
Set GitHub Actions permissions for an enterprise
Sets the GitHub Actions permissions policy for organizations and allowed actions in an enterprise.
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
enabled_organizations
string
required
The policy that controls the organizations in the enterprise that are allowed to run GitHub Actions.
- Enum
-
- all
- none
- selected
allowed_actions
string
The permissions policy that controls the actions that are allowed to run.
- Enum
-
- all
- local_only
- selected
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Request
{
"enabled_organizations": "all",
"allowed_actions": "selected"
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
List selected organizations enabled for GitHub Actions in an enterprise
Lists the organizations that are selected to have GitHub Actions enabled in an enterprise. To use this endpoint, the enterprise permission policy for enabled_organizations
must be configured to selected
. For more information, see "Set GitHub Actions permissions for an enterprise."
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"total_count": 1,
"organizations": [
{
"login": "octocat",
"id": 161335,
"node_id": "MDEwOlJlcG9zaXRvcnkxMjk2MjY5",
"url": "https://api.github.com/orgs/octo-org",
"repos_url": "https://api.github.com/orgs/octo-org/repos",
"events_url": "https://api.github.com/orgs/octo-org/events",
"hooks_url": "https://api.github.com/orgs/octo-org/hooks",
"issues_url": "https://api.github.com/orgs/octo-org/issues",
"members_url": "https://api.github.com/orgs/octo-org/members{/member}",
"public_members_url": "https://api.github.com/orgs/octo-org/public_members{/member}",
"avatar_url": "https://github.com/images/error/octocat_happy.gif",
"description": "A great organization"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_count
number
required
organizations
array[object (Organization Simple)]
required
Organization Simple
object (Organization Simple)
A GitHub organization.
login
string
required
- Example
- "github"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDEyOk9yZ2FuaXphdGlvbjE="
url
string
uri
required
- Example
- "https://api.github.com/orgs/github"
repos_url
string
uri
required
- Example
- "https://api.github.com/orgs/github/repos"
events_url
string
uri
required
- Example
- "https://api.github.com/orgs/github/events"
hooks_url
string
required
- Example
- "https://api.github.com/orgs/github/hooks"
issues_url
string
required
- Example
- "https://api.github.com/orgs/github/issues"
members_url
string
required
- Example
- "https://api.github.com/orgs/github/members{/member}"
public_members_url
string
required
- Example
- "https://api.github.com/orgs/github/public_members{/member}"
avatar_url
string
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
description
string or null
required
- Example
- "A great organization"
Set selected organizations enabled for GitHub Actions in an enterprise
Replaces the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for enabled_organizations
must be configured to selected
. For more information, see "Set GitHub Actions permissions for an enterprise."
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
selected_organization_ids
array[int]
required
List of organization IDs to enable for GitHub Actions.
int
Unique identifier of the organization.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Request
{
"selected_organization_ids": [
32,
91
]
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Enable a selected organization for GitHub Actions in an enterprise
Adds an organization to the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for enabled_organizations
must be configured to selected
. For more information, see "Set GitHub Actions permissions for an enterprise."
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
org_id
int
required
The unique identifier of the organization.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Disable a selected organization for GitHub Actions in an enterprise
Removes an organization from the list of selected organizations that are enabled for GitHub Actions in an enterprise. To use this endpoint, the enterprise permission policy for enabled_organizations
must be configured to selected
. For more information, see "Set GitHub Actions permissions for an enterprise."
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
org_id
int
required
The unique identifier of the organization.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Get allowed actions for an enterprise
Gets the selected actions that are allowed in an enterprise. To use this endpoint, the enterprise permission policy for allowed_actions
must be configured to selected
. For more information, see "Set GitHub Actions permissions for an enterprise."
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"github_owned_allowed": true,
"verified_allowed": false,
"patterns_allowed": [
"monalisa/octocat@*",
"docker/*"
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
github_owned_allowed
boolean
required
Whether GitHub-owned actions are allowed. For example, this includes the actions in the actions
organization.
patterns_allowed
array[string]
required
Specifies a list of string-matching patterns to allow specific action(s). Wildcards, tags, and SHAs are allowed. For example, monalisa/octocat@*
, monalisa/octocat@v2
, monalisa/*
.
string
Set allowed actions for an enterprise
Sets the actions that are allowed in an enterprise. To use this endpoint, the enterprise permission policy for allowed_actions
must be configured to selected
. For more information, see "Set GitHub Actions permissions for an enterprise."
You must authenticate using an access token with the admin:enterprise
scope to use this endpoint.
github_owned_allowed
boolean
required
Whether GitHub-owned actions are allowed. For example, this includes the actions in the actions
organization.
patterns_allowed
array[string]
required
Specifies a list of string-matching patterns to allow specific action(s). Wildcards, tags, and SHAs are allowed. For example, monalisa/octocat@*
, monalisa/octocat@v2
, monalisa/*
.
string
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Request
{
"github_owned_allowed": true,
"verified_allowed": false,
"patterns_allowed": [
"monalisa/octocat@*",
"docker/*"
]
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
List self-hosted runner groups for an enterprise
Lists all self-hosted runner groups for an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
visible_to_organization
string
Only return runner groups that are allowed to be used by this organization.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"total_count": 3,
"runner_groups": [
{
"id": 1,
"name": "Default",
"visibility": "all",
"default": true,
"runners_url": "https://api.github.com/enterprises/octo-corp/actions/runner_groups/1/runners",
"allows_public_repositories": false,
"restricted_to_workflows": false,
"selected_workflows": [],
"workflow_restrictions_read_only": false
},
{
"id": 2,
"name": "octo-runner-group",
"visibility": "selected",
"default": false,
"selected_organizations_url": "https://api.github.com/enterprises/octo-corp/actions/runner_groups/2/organizations",
"runners_url": "https://api.github.com/enterprises/octo-corp/actions/runner_groups/2/runners",
"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
},
{
"id": 3,
"name": "expensive-hardware",
"visibility": "private",
"default": false,
"runners_url": "https://api.github.com/enterprises/octo-corp/actions/runner_groups/3/runners",
"allows_public_repositories": true,
"restricted_to_workflows": false,
"selected_workflows": [
"octo-org/octo-repo/.github/workflows/deploy.yaml@refs/heads/main"
],
"workflow_restrictions_read_only": false
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_count
number
required
runner_groups
array[object]
required
object
id
number
required
name
string
required
visibility
string
required
default
boolean
required
selected_organizations_url
string
runners_url
string
required
allows_public_repositories
boolean
required
workflow_restrictions_read_only
boolean
If true
, the restricted_to_workflows
and selected_workflows
fields cannot be modified.
- Default
- false
restricted_to_workflows
boolean
If true
, the runner group will be restricted to running only the workflows specified in the selected_workflows
array.
- Default
- false
selected_workflows
array[string]
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows
is set to true
.
string
Name of workflow the runner group should be allowed to run. Note that a ref, tag, or long SHA is required.
- Example
- "octo-org/octo-repo/.github/workflows/deploy.yaml@main"
Create a self-hosted runner group for an enterprise
Creates a new self-hosted runner group for an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
name
string
required
Name of the runner group.
visibility
string
Visibility of a runner group. You can select all organizations or select individual organization.
- Enum
-
- selected
- all
selected_organization_ids
array[int]
List of organization IDs that can access the runner group.
int
Unique identifier of the organization.
runners
array[int]
List of runner IDs to add to the runner group.
int
Unique identifier of the runner.
allows_public_repositories
boolean
Whether the runner group can be used by public
repositories.
- Default
- false
restricted_to_workflows
boolean
If true
, the runner group will be restricted to running only the workflows specified in the selected_workflows
array.
- Default
- false
selected_workflows
array[string]
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows
is set to true
.
string
Name of workflow the runner group should be allowed to run. Note that a ref, tag, or long SHA is required.
- Example
- "octo-org/octo-repo/.github/workflows/deploy.yaml@main"
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Request
{
"name": "Expensive hardware runners",
"visibility": "selected",
"selected_organization_ids": [
32,
91
],
"runners": [
9,
2
]
}
Response
Response
{
"id": 2,
"name": "octo-runner-group",
"visibility": "selected",
"default": false,
"selected_organizations_url": "https://api.github.com/enterprises/octo-corp/actions/runner-groups/2/organizations",
"runners_url": "https://api.github.com/enterprises/octo-corp/actions/runner-groups/2/runners",
"allows_public_repositories": false,
"restricted_to_workflows": true,
"selected_workflows": [
"octo-org/octo-repo/.github/workflows/deploy.yaml@refs/heads/main"
],
"workflow_restrictions_read_only": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
number
required
name
string
required
visibility
string
required
default
boolean
required
selected_organizations_url
string
runners_url
string
required
allows_public_repositories
boolean
required
workflow_restrictions_read_only
boolean
If true
, the restricted_to_workflows
and selected_workflows
fields cannot be modified.
- Default
- false
restricted_to_workflows
boolean
If true
, the runner group will be restricted to running only the workflows specified in the selected_workflows
array.
- Default
- false
selected_workflows
array[string]
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows
is set to true
.
string
Name of workflow the runner group should be allowed to run. Note that a ref, tag, or long SHA is required.
- Example
- "octo-org/octo-repo/.github/workflows/deploy.yaml@main"
Get a self-hosted runner group for an enterprise
Gets a specific self-hosted runner group for an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
Response
Response
{
"id": 2,
"name": "octo-runner-group",
"visibility": "selected",
"default": false,
"selected_organizations_url": "https://api.github.com/enterprises/octo-corp/actions/runner-groups/2/organizations",
"runners_url": "https://api.github.com/enterprises/octo-corp/actions/runner-groups/2/runners",
"allows_public_repositories": false,
"restricted_to_workflows": true,
"selected_workflows": [
"octo-org/octo-repo/.github/workflows/deploy.yaml@refs/heads/main"
],
"workflow_restrictions_read_only": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
number
required
name
string
required
visibility
string
required
default
boolean
required
selected_organizations_url
string
runners_url
string
required
allows_public_repositories
boolean
required
workflow_restrictions_read_only
boolean
If true
, the restricted_to_workflows
and selected_workflows
fields cannot be modified.
- Default
- false
restricted_to_workflows
boolean
If true
, the runner group will be restricted to running only the workflows specified in the selected_workflows
array.
- Default
- false
selected_workflows
array[string]
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows
is set to true
.
string
Name of workflow the runner group should be allowed to run. Note that a ref, tag, or long SHA is required.
- Example
- "octo-org/octo-repo/.github/workflows/deploy.yaml@main"
Delete a self-hosted runner group from an enterprise
Deletes a self-hosted runner group for an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Update a self-hosted runner group for an enterprise
Updates the name
and visibility
of a self-hosted runner group in an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
name
string
Name of the runner group.
visibility
string
Visibility of a runner group. You can select all organizations or select individual organizations.
- Default
- "all"
- Enum
-
- selected
- all
allows_public_repositories
boolean
Whether the runner group can be used by public
repositories.
- Default
- false
restricted_to_workflows
boolean
If true
, the runner group will be restricted to running only the workflows specified in the selected_workflows
array.
- Default
- false
selected_workflows
array[string]
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows
is set to true
.
string
Name of workflow the runner group should be allowed to run. Note that a ref, tag, or long SHA is required.
- Example
- "octo-org/octo-repo/.github/workflows/deploy.yaml@main"
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
Request
{
"name": "Expensive hardware runners",
"visibility": "selected"
}
Response
Response
{
"id": 2,
"name": "Expensive hardware runners",
"visibility": "selected",
"default": false,
"selected_organizations_url": "https://api.github.com/enterprises/octo-corp/actions/runner-groups/2/organizations",
"runners_url": "https://api.github.com/enterprises/octo-corp/actions/runner-groups/2/runners",
"allows_public_repositories": true,
"restricted_to_workflows": false,
"selected_workflows": [
"octo-org/octo-repo/.github/workflows/deploy.yaml@refs/heads/main"
],
"workflow_restrictions_read_only": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
number
required
name
string
required
visibility
string
required
default
boolean
required
selected_organizations_url
string
runners_url
string
required
allows_public_repositories
boolean
required
workflow_restrictions_read_only
boolean
If true
, the restricted_to_workflows
and selected_workflows
fields cannot be modified.
- Default
- false
restricted_to_workflows
boolean
If true
, the runner group will be restricted to running only the workflows specified in the selected_workflows
array.
- Default
- false
selected_workflows
array[string]
List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows
is set to true
.
string
Name of workflow the runner group should be allowed to run. Note that a ref, tag, or long SHA is required.
- Example
- "octo-org/octo-repo/.github/workflows/deploy.yaml@main"
List organization access to a self-hosted runner group in an enterprise
Lists the organizations with access to a self-hosted runner group.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
Response
Response
{
"total_count": 1,
"organizations": [
{
"login": "octocat",
"id": 161335,
"node_id": "MDEwOlJlcG9zaXRvcnkxMjk2MjY5",
"url": "https://api.github.com/orgs/octo-org",
"repos_url": "https://api.github.com/orgs/octo-org/repos",
"events_url": "https://api.github.com/orgs/octo-org/events",
"hooks_url": "https://api.github.com/orgs/octo-org/hooks",
"issues_url": "https://api.github.com/orgs/octo-org/issues",
"members_url": "https://api.github.com/orgs/octo-org/members{/member}",
"public_members_url": "https://api.github.com/orgs/octo-org/public_members{/member}",
"avatar_url": "https://github.com/images/error/octocat_happy.gif",
"description": "A great organization"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_count
number
required
organizations
array[object (Organization Simple)]
required
Organization Simple
object (Organization Simple)
A GitHub organization.
login
string
required
- Example
- "github"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDEyOk9yZ2FuaXphdGlvbjE="
url
string
uri
required
- Example
- "https://api.github.com/orgs/github"
repos_url
string
uri
required
- Example
- "https://api.github.com/orgs/github/repos"
events_url
string
uri
required
- Example
- "https://api.github.com/orgs/github/events"
hooks_url
string
required
- Example
- "https://api.github.com/orgs/github/hooks"
issues_url
string
required
- Example
- "https://api.github.com/orgs/github/issues"
members_url
string
required
- Example
- "https://api.github.com/orgs/github/members{/member}"
public_members_url
string
required
- Example
- "https://api.github.com/orgs/github/public_members{/member}"
avatar_url
string
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
description
string or null
required
- Example
- "A great organization"
Set organization access for a self-hosted runner group in an enterprise
Replaces the list of organizations that have access to a self-hosted runner configured in an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
selected_organization_ids
array[int]
required
List of organization IDs that can access the runner group.
int
Unique identifier of the organization.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
Request
{
"selected_organization_ids": [
32,
91
]
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Add organization access to a self-hosted runner group in an enterprise
Adds an organization to the list of selected organizations that can access a self-hosted runner group. The runner group must have visibility
set to selected
. For more information, see "Create a self-hosted runner group for an enterprise."
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
org_id
int
required
The unique identifier of the organization.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Remove organization access to a self-hosted runner group in an enterprise
Removes an organization from the list of selected organizations that can access a self-hosted runner group. The runner group must have visibility
set to selected
. For more information, see "Create a self-hosted runner group for an enterprise."
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
org_id
int
required
The unique identifier of the organization.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
List self-hosted runners in a group for an enterprise
Lists the self-hosted runners that are in a specific enterprise group.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
Response
Response
{
"total_count": 2,
"runners": [
{
"id": 23,
"name": "linux_runner",
"os": "linux",
"status": "online",
"busy": true,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 11,
"name": "Linux",
"type": "read-only"
}
]
},
{
"id": 24,
"name": "mac_runner",
"os": "macos",
"status": "offline",
"busy": false,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
},
{
"id": 21,
"name": "no-gpu",
"type": "custom"
}
]
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_count
number
required
runners
array[object (Self hosted runners)]
required
Self hosted runners
object (Self hosted runners)
A self hosted runner
id
int
required
The id of the runner.
- Example
- 5
runner_group_id
int
The id of the runner group.
- Example
- 1
name
string
required
The name of the runner.
- Example
- "iMac"
os
string
required
The Operating System of the runner.
- Example
- "macos"
status
string
required
The status of the runner.
- Example
- "online"
busy
boolean
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Link
string
Set self-hosted runners in a group for an enterprise
Replaces the list of self-hosted runners that are part of an enterprise runner group.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
runners
array[int]
required
List of runner IDs to add to the runner group.
int
Unique identifier of the runner.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
Request
{
"runners": [
9,
2
]
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Add a self-hosted runner to a group for an enterprise
Adds a self-hosted runner to a runner group configured in an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
runner_id
int
required
Unique identifier of the self-hosted runner.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Remove a self-hosted runner from a group for an enterprise
Removes a self-hosted runner from a group configured in an enterprise. The runner is then returned to the default group.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_group_id
int
required
Unique identifier of the self-hosted runner group.
runner_id
int
required
Unique identifier of the self-hosted runner.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
List self-hosted runners for an enterprise
Lists all self-hosted runners configured for an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"total_count": 2,
"runners": [
{
"id": 23,
"name": "linux_runner",
"os": "linux",
"status": "online",
"busy": true,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 11,
"name": "Linux",
"type": "read-only"
}
]
},
{
"id": 24,
"name": "mac_runner",
"os": "macos",
"status": "offline",
"busy": false,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
},
{
"id": 21,
"name": "no-gpu",
"type": "custom"
}
]
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
total_count
number
runners
array[object (Self hosted runners)]
Self hosted runners
object (Self hosted runners)
A self hosted runner
id
int
required
The id of the runner.
- Example
- 5
runner_group_id
int
The id of the runner group.
- Example
- 1
name
string
required
The name of the runner.
- Example
- "iMac"
os
string
required
The Operating System of the runner.
- Example
- "macos"
status
string
required
The status of the runner.
- Example
- "online"
busy
boolean
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Link
string
List runner applications for an enterprise
Lists binaries for the runner application that you can download and run.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
[
{
"os": "osx",
"architecture": "x64",
"download_url": "https://github.com/actions/runner/releases/download/v2.277.1/actions-runner-osx-x64-2.277.1.tar.gz",
"filename": "actions-runner-osx-x64-2.277.1.tar.gz",
"temp_download_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IkJmSjdCUXpLdXhjWDc4WnJ5NUxnUW53ZFRrMCJ9.eyJuYW1laWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJzY3AiOiJBY3Rpb25zUnVudGltZS5QYWNrYWdlRG93bmxvYWQiLCJJZGVudGl0eVR5cGVDbGFpbSI6IlN5c3RlbTpTZXJ2aWNlSWRlbnRpdHkiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiJERERERERERC1ERERELUREREQtRERERC1EREREREREREREREQiLCJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL3dzLzIwMDgvMDYvaWRlbnRpdHkvY2xhaW1zL3ByaW1hcnlzaWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJhdWkiOiIwZTZkODAxYi02NzVlLTQ1YzAtOWM4NC1jYTkzNjdlZjc1NjciLCJzaWQiOiI4ZTE5MDliZC1kYzU1LTQ2MWYtOTk2Mi1hZTI0OTEzNzU4OWIiLCJpc3MiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJhdWQiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJuYmYiOjE2MTc5MDQxNzUsImV4cCI6MTYxNzkwODM3NX0.YNsRXL9pBuIfLVndnyVQOpru77Br8hgYIX7LPsOaMfKk4K88YG89a2VIXUWPyHRiOaC-4J0lIPei8ujezEtnMfNZCwHdWq0Niiy-2-ywcfGPmcz-RHz_ZglkPFbzKaiZWJcFKCGHCP0Ta3kdXumJQqiVJEIyppxIY-caR_Wsw2L4BZHOefJq-odsJ0guPgm9fVuU9FxVRkucho1UH_bzt0tAMl1gEWOLBLZ88U9LKCzHWaxheFeBV4DTt1lAcSm213gKP1eMbgAGn5heWhR4RMRBzZc2HO3Lf1syu4E8fW8a-esRAxEYPfqPHwN9LNj2jaU3D3nPwa8lHQLLtA1PNA",
"sha256_checksum": "f1fa173889dc9036cd529417e652e1729e5a3f4d35ec0151806d7480fda6b89b"
},
{
"os": "linux",
"architecture": "x64",
"download_url": "https://github.com/actions/runner/releases/download/v2.277.1/actions-runner-linux-x64-2.277.1.tar.gz",
"filename": "actions-runner-linux-x64-2.277.1.tar.gz",
"temp_download_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IkJmSjdCUXpLdXhjWDc4WnJ5NUxnUW53ZFRrMCJ9.eyJuYW1laWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJzY3AiOiJBY3Rpb25zUnVudGltZS5QYWNrYWdlRG93bmxvYWQiLCJJZGVudGl0eVR5cGVDbGFpbSI6IlN5c3RlbTpTZXJ2aWNlSWRlbnRpdHkiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiJERERERERERC1ERERELUREREQtRERERC1EREREREREREREREQiLCJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL3dzLzIwMDgvMDYvaWRlbnRpdHkvY2xhaW1zL3ByaW1hcnlzaWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJhdWkiOiIwZTZkODAxYi02NzVlLTQ1YzAtOWM4NC1jYTkzNjdlZjc1NjciLCJzaWQiOiI4ZTE5MDliZC1kYzU1LTQ2MWYtOTk2Mi1hZTI0OTEzNzU4OWIiLCJpc3MiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJhdWQiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJuYmYiOjE2MTc5MDQxNzUsImV4cCI6MTYxNzkwODM3NX0.YNsRXL9pBuIfLVndnyVQOpru77Br8hgYIX7LPsOaMfKk4K88YG89a2VIXUWPyHRiOaC-4J0lIPei8ujezEtnMfNZCwHdWq0Niiy-2-ywcfGPmcz-RHz_ZglkPFbzKaiZWJcFKCGHCP0Ta3kdXumJQqiVJEIyppxIY-caR_Wsw2L4BZHOefJq-odsJ0guPgm9fVuU9FxVRkucho1UH_bzt0tAMl1gEWOLBLZ88U9LKCzHWaxheFeBV4DTt1lAcSm213gKP1eMbgAGn5heWhR4RMRBzZc2HO3Lf1syu4E8fW8a-esRAxEYPfqPHwN9LNj2jaU3D3nPwa8lHQLLtA1PNA",
"sha256_checksum": "02d710fc9e0008e641274bb7da7fde61f7c9aa1cbb541a2990d3450cc88f4e98"
},
{
"os": "linux",
"architecture": "arm",
"download_url": "https://github.com/actions/runner/releases/download/v2.277.1/actions-runner-linux-arm-2.277.1.tar.gz",
"filename": "actions-runner-linux-arm-2.277.1.tar.gz",
"temp_download_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IkJmSjdCUXpLdXhjWDc4WnJ5NUxnUW53ZFRrMCJ9.eyJuYW1laWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJzY3AiOiJBY3Rpb25zUnVudGltZS5QYWNrYWdlRG93bmxvYWQiLCJJZGVudGl0eVR5cGVDbGFpbSI6IlN5c3RlbTpTZXJ2aWNlSWRlbnRpdHkiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiJERERERERERC1ERERELUREREQtRERERC1EREREREREREREREQiLCJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL3dzLzIwMDgvMDYvaWRlbnRpdHkvY2xhaW1zL3ByaW1hcnlzaWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJhdWkiOiIyYTEzZDRmZC01ZDhkLTRjNzgtYjg2MS0zYTMxZGQ3MmYzNjQiLCJzaWQiOiI0MzZiNTg3YS04ODMyLTRiMTMtOWM2Ny05OWRkMjA2ZTQzNmMiLCJpc3MiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJhdWQiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJuYmYiOjE2MTc5MzE1NzEsImV4cCI6MTYxNzkzNTc3MX0.PMhU7-MOnZRDj5k5a4ieeFlQCmKPl2pQvpVRhGZq-9ByKF5s9G0rsnGBxDcolTYlbvEAmSSkeAEwF486F7P0kMVEb-GI14WbErqqMSyaPL81c3W7UHxMJLaSBnDs9ftHMv_IkJmRzaROS8q1ObzUW-ErlltxCdj2zF_5ruK9G2RR566AOAtiA3AHV6k7-FCY5--sDYJN_YXPgpwI0fPN1TM92fdPm93hJnoXuCJNpBYp1vl5W4gwGtU_Pa07ESdqqFN1YJJHUloedNhiIOczGfGVSapRc8vyGm9P_VCM_yKD8JI-MkOXl8JI5fCfhmjmKsw-vSAh9NW67RGvmehmpw",
"sha256_checksum": "2f2bda21e2fd8fed6938b33182a293f6b1f74e4c5d09acd6d9a0fe3f979f5c85"
},
{
"os": "win",
"architecture": "x64",
"download_url": "https://github.com/actions/runner/releases/download/v2.277.1/actions-runner-win-x64-2.277.1.zip",
"filename": "actions-runner-win-x64-2.277.1.zip",
"temp_download_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IkJmSjdCUXpLdXhjWDc4WnJ5NUxnUW53ZFRrMCJ9.eyJuYW1laWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJzY3AiOiJBY3Rpb25zUnVudGltZS5QYWNrYWdlRG93bmxvYWQiLCJJZGVudGl0eVR5cGVDbGFpbSI6IlN5c3RlbTpTZXJ2aWNlSWRlbnRpdHkiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiJERERERERERC1ERERELUREREQtRERERC1EREREREREREREREQiLCJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL3dzLzIwMDgvMDYvaWRlbnRpdHkvY2xhaW1zL3ByaW1hcnlzaWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJhdWkiOiIwZTZkODAxYi02NzVlLTQ1YzAtOWM4NC1jYTkzNjdlZjc1NjciLCJzaWQiOiI4ZTE5MDliZC1kYzU1LTQ2MWYtOTk2Mi1hZTI0OTEzNzU4OWIiLCJpc3MiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJhdWQiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJuYmYiOjE2MTc5MDQxNzUsImV4cCI6MTYxNzkwODM3NX0.YNsRXL9pBuIfLVndnyVQOpru77Br8hgYIX7LPsOaMfKk4K88YG89a2VIXUWPyHRiOaC-4J0lIPei8ujezEtnMfNZCwHdWq0Niiy-2-ywcfGPmcz-RHz_ZglkPFbzKaiZWJcFKCGHCP0Ta3kdXumJQqiVJEIyppxIY-caR_Wsw2L4BZHOefJq-odsJ0guPgm9fVuU9FxVRkucho1UH_bzt0tAMl1gEWOLBLZ88U9LKCzHWaxheFeBV4DTt1lAcSm213gKP1eMbgAGn5heWhR4RMRBzZc2HO3Lf1syu4E8fW8a-esRAxEYPfqPHwN9LNj2jaU3D3nPwa8lHQLLtA1PNA",
"sha256_checksum": "7215c75a462eeb6a839fa8ed298d79f620617d44d47d37c583114fc3f3b27b30"
},
{
"os": "linux",
"architecture": "arm64",
"download_url": "https://github.com/actions/runner/releases/download/v2.277.1/actions-runner-linux-arm64-2.277.1.tar.gz",
"filename": "actions-runner-linux-arm64-2.277.1.tar.gz",
"temp_download_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IkJmSjdCUXpLdXhjWDc4WnJ5NUxnUW53ZFRrMCJ9.eyJuYW1laWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJzY3AiOiJBY3Rpb25zUnVudGltZS5QYWNrYWdlRG93bmxvYWQiLCJJZGVudGl0eVR5cGVDbGFpbSI6IlN5c3RlbTpTZXJ2aWNlSWRlbnRpdHkiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9zaWQiOiJERERERERERC1ERERELUREREQtRERERC1EREREREREREREREQiLCJodHRwOi8vc2NoZW1hcy5taWNyb3NvZnQuY29tL3dzLzIwMDgvMDYvaWRlbnRpdHkvY2xhaW1zL3ByaW1hcnlzaWQiOiJkZGRkZGRkZC1kZGRkLWRkZGQtZGRkZC1kZGRkZGRkZGRkZGQiLCJhdWkiOiIwZTZkODAxYi02NzVlLTQ1YzAtOWM4NC1jYTkzNjdlZjc1NjciLCJzaWQiOiI4ZTE5MDliZC1kYzU1LTQ2MWYtOTk2Mi1hZTI0OTEzNzU4OWIiLCJpc3MiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJhdWQiOiJ2c3Rva2VuLmNvZGVkZXYubXMiLCJuYmYiOjE2MTc5MDQxNzUsImV4cCI6MTYxNzkwODM3NX0.YNsRXL9pBuIfLVndnyVQOpru77Br8hgYIX7LPsOaMfKk4K88YG89a2VIXUWPyHRiOaC-4J0lIPei8ujezEtnMfNZCwHdWq0Niiy-2-ywcfGPmcz-RHz_ZglkPFbzKaiZWJcFKCGHCP0Ta3kdXumJQqiVJEIyppxIY-caR_Wsw2L4BZHOefJq-odsJ0guPgm9fVuU9FxVRkucho1UH_bzt0tAMl1gEWOLBLZ88U9LKCzHWaxheFeBV4DTt1lAcSm213gKP1eMbgAGn5heWhR4RMRBzZc2HO3Lf1syu4E8fW8a-esRAxEYPfqPHwN9LNj2jaU3D3nPwa8lHQLLtA1PNA",
"sha256_checksum": "a6aa6dd0ba217118ef2b4ea24e9e0a85b02b13c38052a5de0776d6ced3a79c64"
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object (Runner Application)]
- Content Type
- application/json
Runner Application
object (Runner Application)
Runner Application
os
string
required
architecture
string
required
download_url
string
required
filename
string
required
temp_download_token
string
A short lived bearer token used to download the runner, if needed.
sha256_checksum
string
Create a registration token for an enterprise
Returns a token that you can pass to the config
script. The token expires after one hour.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
Example using registration token
Configure your self-hosted runner, replacing TOKEN
with the registration token provided by this endpoint.
./config.sh --url https://github.com/enterprises/octo-enterprise --token TOKEN
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"token": "LLBF3JGZDX3P5PMEXLND6TS6FCWO6",
"expires_at": "2020-01-22T12:13:35.123-08:00"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
token
string
required
The token used for authentication
- Example
- "v1.1f699f1069f60xxx"
expires_at
string
date-time
required
The time this token expires
- Example
- "2016-07-11T22:14:10Z"
permissions
object (permissions)
- Example
- { "issues": "read", "deployments": "write" }
repositories
array[object (Repository)]
The repositories this token has access to
Repository
object (Repository)
A repository on GitHub.
id
int
required
Unique identifier of the repository
- Example
- 42
node_id
string
required
- Example
- "MDEwOlJlcG9zaXRvcnkxMjk2MjY5"
name
string
required
The name of the repository.
- Example
- "Team Environment"
full_name
string
required
- Example
- "octocat/Hello-World"
license
object (license) or null
required
License Simple
key
string
required
- Example
- "mit"
name
string
required
- Example
- "MIT License"
url
string or null
uri
required
- Example
- "https://api.github.com/licenses/mit"
spdx_id
string or null
required
- Example
- "MIT"
node_id
string
required
- Example
- "MDc6TGljZW5zZW1pdA=="
html_url
string
uri
organization
object (organization) or null
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
forks
int
required
permissions
object (permissions)
admin
boolean
required
pull
boolean
required
triage
boolean
push
boolean
required
maintain
boolean
owner
object (owner)
required
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
private
boolean
required
Whether the repository is private or public.
- Default
- false
html_url
string
uri
required
- Example
- "https://github.com/octocat/Hello-World"
description
string or null
required
- Example
- "This your first repo!"
fork
boolean
required
url
string
uri
required
- Example
- "https://api.github.com/repos/octocat/Hello-World"
archive_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/{archive_format}{/ref}"
assignees_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/assignees{/user}"
blobs_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/blobs{/sha}"
branches_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/branches{/branch}"
collaborators_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/collaborators{/collaborator}"
comments_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/comments{/number}"
commits_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/commits{/sha}"
compare_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/compare/{base}...{head}"
contents_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/contents/{+path}"
contributors_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/contributors"
deployments_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/deployments"
downloads_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/downloads"
events_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/events"
forks_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/forks"
git_commits_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/commits{/sha}"
git_refs_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/refs{/sha}"
git_tags_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/tags{/sha}"
git_url
string
required
- Example
- "git:github.com/octocat/Hello-World.git"
issue_comment_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/issues/comments{/number}"
issue_events_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/issues/events{/number}"
issues_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/issues{/number}"
keys_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/keys{/key_id}"
labels_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/labels{/name}"
languages_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/languages"
merges_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/merges"
milestones_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/milestones{/number}"
notifications_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/notifications{?since,all,participating}"
pulls_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/pulls{/number}"
releases_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/releases{/id}"
ssh_url
string
required
- Example
- "git@github.com:octocat/Hello-World.git"
stargazers_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/stargazers"
statuses_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/statuses/{sha}"
subscribers_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/subscribers"
subscription_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/subscription"
tags_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/tags"
teams_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/teams"
trees_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/trees{/sha}"
clone_url
string
required
- Example
- "https://github.com/octocat/Hello-World.git"
mirror_url
string or null
uri
required
- Example
- "git:git.example.com/octocat/Hello-World"
hooks_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/hooks"
svn_url
string
uri
required
- Example
- "https://svn.github.com/octocat/Hello-World"
homepage
string or null
uri
required
- Example
- "https://github.com"
language
string or null
required
forks_count
int
required
- Example
- 9
stargazers_count
int
required
- Example
- 80
watchers_count
int
required
- Example
- 80
size
int
required
The size of the repository. Size is calculated hourly. When a repository is initially created, the size is 0.
- Example
- 108
default_branch
string
required
The default branch of the repository.
- Example
- "master"
open_issues_count
int
required
- Example
- 0
is_template
boolean
Whether this repository acts as a template that can be used to generate new repositories.
- Default
- false
- Example
- true
topics
array[string]
string
has_issues
boolean
required
Whether issues are enabled.
- Default
- true
- Example
- true
has_projects
boolean
required
Whether projects are enabled.
- Default
- true
- Example
- true
has_wiki
boolean
required
Whether the wiki is enabled.
- Default
- true
- Example
- true
has_pages
boolean
required
has_downloads
boolean
required
Whether downloads are enabled.
- Default
- true
- Example
- true
has_discussions
boolean
Whether discussions are enabled.
- Default
- false
- Example
- true
archived
boolean
required
Whether the repository is archived.
- Default
- false
disabled
boolean
required
Returns whether or not this repository disabled.
visibility
string
The repository visibility: public, private, or internal.
- Default
- "public"
pushed_at
string or null
date-time
required
- Example
- "2011-01-26T19:06:43Z"
created_at
string or null
date-time
required
- Example
- "2011-01-26T19:01:12Z"
updated_at
string or null
date-time
required
- Example
- "2011-01-26T19:14:43Z"
allow_rebase_merge
boolean
Whether to allow rebase merges for pull requests.
- Default
- true
- Example
- true
template_repository
object (template_repository) or null
id
int
node_id
string
name
string
full_name
string
owner
object (owner)
login
string
id
int
node_id
string
avatar_url
string
gravatar_id
string
url
string
html_url
string
followers_url
string
following_url
string
gists_url
string
starred_url
string
subscriptions_url
string
organizations_url
string
repos_url
string
events_url
string
received_events_url
string
type
string
site_admin
boolean
private
boolean
html_url
string
description
string
fork
boolean
url
string
archive_url
string
assignees_url
string
blobs_url
string
branches_url
string
collaborators_url
string
comments_url
string
commits_url
string
compare_url
string
contents_url
string
contributors_url
string
deployments_url
string
downloads_url
string
events_url
string
forks_url
string
git_commits_url
string
git_refs_url
string
git_tags_url
string
git_url
string
issue_comment_url
string
issue_events_url
string
issues_url
string
keys_url
string
labels_url
string
languages_url
string
merges_url
string
milestones_url
string
notifications_url
string
pulls_url
string
releases_url
string
ssh_url
string
stargazers_url
string
statuses_url
string
subscribers_url
string
subscription_url
string
tags_url
string
teams_url
string
trees_url
string
clone_url
string
mirror_url
string
hooks_url
string
svn_url
string
homepage
string
language
string
forks_count
int
stargazers_count
int
watchers_count
int
size
int
default_branch
string
open_issues_count
int
is_template
boolean
topics
array[string]
string
has_issues
boolean
has_projects
boolean
has_wiki
boolean
has_pages
boolean
has_downloads
boolean
archived
boolean
disabled
boolean
visibility
string
pushed_at
string
created_at
string
updated_at
string
permissions
object (permissions)
admin
boolean
maintain
boolean
push
boolean
triage
boolean
pull
boolean
allow_rebase_merge
boolean
temp_clone_token
string
allow_squash_merge
boolean
allow_auto_merge
boolean
delete_branch_on_merge
boolean
allow_update_branch
boolean
use_squash_pr_title_as_default
boolean
squash_merge_commit_title
string
The default value for a squash merge commit title:
PR_TITLE
- default to the pull request's title.COMMIT_OR_PR_TITLE
- default to the commit's title (if only one commit) or the pull request's title (when more than one commit).
- Enum
-
- PR_TITLE
- COMMIT_OR_PR_TITLE
squash_merge_commit_message
string
The default value for a squash merge commit message:
PR_BODY
- default to the pull request's body.COMMIT_MESSAGES
- default to the branch's commit messages.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- COMMIT_MESSAGES
- BLANK
merge_commit_title
string
The default value for a merge commit title.
PR_TITLE
- default to the pull request's title.MERGE_MESSAGE
- default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).
- Enum
-
- PR_TITLE
- MERGE_MESSAGE
merge_commit_message
string
The default value for a merge commit message.
PR_TITLE
- default to the pull request's title.PR_BODY
- default to the pull request's body.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- PR_TITLE
- BLANK
allow_merge_commit
boolean
subscribers_count
int
network_count
int
temp_clone_token
string
allow_squash_merge
boolean
Whether to allow squash merges for pull requests.
- Default
- true
- Example
- true
allow_auto_merge
boolean
Whether to allow Auto-merge to be used on pull requests.
- Default
- false
- Example
- false
delete_branch_on_merge
boolean
Whether to delete head branches when pull requests are merged
- Default
- false
- Example
- false
allow_update_branch
boolean
Whether or not a pull request head branch that is behind its base branch can always be updated even if it is not required to be up to date before merging.
- Default
- false
- Example
- false
use_squash_pr_title_as_default
boolean
deprecated
Whether a squash merge commit can use the pull request title as default. **This property has been deprecated. Please use squash_merge_commit_title
instead.
- Default
- false
squash_merge_commit_title
string
The default value for a squash merge commit title:
PR_TITLE
- default to the pull request's title.COMMIT_OR_PR_TITLE
- default to the commit's title (if only one commit) or the pull request's title (when more than one commit).
- Enum
-
- PR_TITLE
- COMMIT_OR_PR_TITLE
squash_merge_commit_message
string
The default value for a squash merge commit message:
PR_BODY
- default to the pull request's body.COMMIT_MESSAGES
- default to the branch's commit messages.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- COMMIT_MESSAGES
- BLANK
merge_commit_title
string
The default value for a merge commit title.
PR_TITLE
- default to the pull request's title.MERGE_MESSAGE
- default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).
- Enum
-
- PR_TITLE
- MERGE_MESSAGE
merge_commit_message
string
The default value for a merge commit message.
PR_TITLE
- default to the pull request's title.PR_BODY
- default to the pull request's body.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- PR_TITLE
- BLANK
allow_merge_commit
boolean
Whether to allow merge commits for pull requests.
- Default
- true
- Example
- true
allow_forking
boolean
Whether to allow forking this repo
web_commit_signoff_required
boolean
Whether to require contributors to sign off on web-based commits
- Default
- false
subscribers_count
int
network_count
int
open_issues
int
required
watchers
int
required
master_branch
string
starred_at
string
- Example
- "\"2020-07-09T00:17:42Z\""
anonymous_access_enabled
boolean
Whether anonymous git access is enabled for this repository
single_file
string or null
- Example
- "config.yaml"
repository_selection
string
Describe whether all repositories have been selected or there's a selection involved
- Enum
-
- all
- selected
Create a remove token for an enterprise
Returns a token that you can pass to the config
script to remove a self-hosted runner from an enterprise. The token expires after one hour.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
Example using remove token
To remove your self-hosted runner from an enterprise, replace TOKEN
with the remove token provided by this
endpoint.
./config.sh remove --token TOKEN
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"token": "AABF3JGZDX3P5PMEXLND6TS6FCWO6",
"expires_at": "2020-01-29T12:13:35.123-08:00"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
token
string
required
The token used for authentication
- Example
- "v1.1f699f1069f60xxx"
expires_at
string
date-time
required
The time this token expires
- Example
- "2016-07-11T22:14:10Z"
permissions
object (permissions)
- Example
- { "issues": "read", "deployments": "write" }
repositories
array[object (Repository)]
The repositories this token has access to
Repository
object (Repository)
A repository on GitHub.
id
int
required
Unique identifier of the repository
- Example
- 42
node_id
string
required
- Example
- "MDEwOlJlcG9zaXRvcnkxMjk2MjY5"
name
string
required
The name of the repository.
- Example
- "Team Environment"
full_name
string
required
- Example
- "octocat/Hello-World"
license
object (license) or null
required
License Simple
key
string
required
- Example
- "mit"
name
string
required
- Example
- "MIT License"
url
string or null
uri
required
- Example
- "https://api.github.com/licenses/mit"
spdx_id
string or null
required
- Example
- "MIT"
node_id
string
required
- Example
- "MDc6TGljZW5zZW1pdA=="
html_url
string
uri
organization
object (organization) or null
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
forks
int
required
permissions
object (permissions)
admin
boolean
required
pull
boolean
required
triage
boolean
push
boolean
required
maintain
boolean
owner
object (owner)
required
A GitHub user.
name
string or null
string or null
login
string
required
- Example
- "octocat"
id
int
required
- Example
- 1
node_id
string
required
- Example
- "MDQ6VXNlcjE="
avatar_url
string
uri
required
- Example
- "https://github.com/images/error/octocat_happy.gif"
gravatar_id
string or null
required
- Example
- "41d064eb2195891e12d0413f63227ea7"
url
string
uri
required
- Example
- "https://api.github.com/users/octocat"
html_url
string
uri
required
- Example
- "https://github.com/octocat"
followers_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/followers"
following_url
string
required
- Example
- "https://api.github.com/users/octocat/following{/other_user}"
gists_url
string
required
- Example
- "https://api.github.com/users/octocat/gists{/gist_id}"
starred_url
string
required
- Example
- "https://api.github.com/users/octocat/starred{/owner}{/repo}"
subscriptions_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/subscriptions"
organizations_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/orgs"
repos_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/repos"
events_url
string
required
- Example
- "https://api.github.com/users/octocat/events{/privacy}"
received_events_url
string
uri
required
- Example
- "https://api.github.com/users/octocat/received_events"
type
string
required
- Example
- "User"
site_admin
boolean
required
starred_at
string
- Example
- "\"2020-07-09T00:17:55Z\""
private
boolean
required
Whether the repository is private or public.
- Default
- false
html_url
string
uri
required
- Example
- "https://github.com/octocat/Hello-World"
description
string or null
required
- Example
- "This your first repo!"
fork
boolean
required
url
string
uri
required
- Example
- "https://api.github.com/repos/octocat/Hello-World"
archive_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/{archive_format}{/ref}"
assignees_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/assignees{/user}"
blobs_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/blobs{/sha}"
branches_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/branches{/branch}"
collaborators_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/collaborators{/collaborator}"
comments_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/comments{/number}"
commits_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/commits{/sha}"
compare_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/compare/{base}...{head}"
contents_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/contents/{+path}"
contributors_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/contributors"
deployments_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/deployments"
downloads_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/downloads"
events_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/events"
forks_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/forks"
git_commits_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/commits{/sha}"
git_refs_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/refs{/sha}"
git_tags_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/tags{/sha}"
git_url
string
required
- Example
- "git:github.com/octocat/Hello-World.git"
issue_comment_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/issues/comments{/number}"
issue_events_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/issues/events{/number}"
issues_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/issues{/number}"
keys_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/keys{/key_id}"
labels_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/labels{/name}"
languages_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/languages"
merges_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/merges"
milestones_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/milestones{/number}"
notifications_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/notifications{?since,all,participating}"
pulls_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/pulls{/number}"
releases_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/releases{/id}"
ssh_url
string
required
- Example
- "git@github.com:octocat/Hello-World.git"
stargazers_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/stargazers"
statuses_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/statuses/{sha}"
subscribers_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/subscribers"
subscription_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/subscription"
tags_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/tags"
teams_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/teams"
trees_url
string
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/git/trees{/sha}"
clone_url
string
required
- Example
- "https://github.com/octocat/Hello-World.git"
mirror_url
string or null
uri
required
- Example
- "git:git.example.com/octocat/Hello-World"
hooks_url
string
uri
required
- Example
- "http://api.github.com/repos/octocat/Hello-World/hooks"
svn_url
string
uri
required
- Example
- "https://svn.github.com/octocat/Hello-World"
homepage
string or null
uri
required
- Example
- "https://github.com"
language
string or null
required
forks_count
int
required
- Example
- 9
stargazers_count
int
required
- Example
- 80
watchers_count
int
required
- Example
- 80
size
int
required
The size of the repository. Size is calculated hourly. When a repository is initially created, the size is 0.
- Example
- 108
default_branch
string
required
The default branch of the repository.
- Example
- "master"
open_issues_count
int
required
- Example
- 0
is_template
boolean
Whether this repository acts as a template that can be used to generate new repositories.
- Default
- false
- Example
- true
topics
array[string]
string
has_issues
boolean
required
Whether issues are enabled.
- Default
- true
- Example
- true
has_projects
boolean
required
Whether projects are enabled.
- Default
- true
- Example
- true
has_wiki
boolean
required
Whether the wiki is enabled.
- Default
- true
- Example
- true
has_pages
boolean
required
has_downloads
boolean
required
Whether downloads are enabled.
- Default
- true
- Example
- true
has_discussions
boolean
Whether discussions are enabled.
- Default
- false
- Example
- true
archived
boolean
required
Whether the repository is archived.
- Default
- false
disabled
boolean
required
Returns whether or not this repository disabled.
visibility
string
The repository visibility: public, private, or internal.
- Default
- "public"
pushed_at
string or null
date-time
required
- Example
- "2011-01-26T19:06:43Z"
created_at
string or null
date-time
required
- Example
- "2011-01-26T19:01:12Z"
updated_at
string or null
date-time
required
- Example
- "2011-01-26T19:14:43Z"
allow_rebase_merge
boolean
Whether to allow rebase merges for pull requests.
- Default
- true
- Example
- true
template_repository
object (template_repository) or null
id
int
node_id
string
name
string
full_name
string
owner
object (owner)
login
string
id
int
node_id
string
avatar_url
string
gravatar_id
string
url
string
html_url
string
followers_url
string
following_url
string
gists_url
string
starred_url
string
subscriptions_url
string
organizations_url
string
repos_url
string
events_url
string
received_events_url
string
type
string
site_admin
boolean
private
boolean
html_url
string
description
string
fork
boolean
url
string
archive_url
string
assignees_url
string
blobs_url
string
branches_url
string
collaborators_url
string
comments_url
string
commits_url
string
compare_url
string
contents_url
string
contributors_url
string
deployments_url
string
downloads_url
string
events_url
string
forks_url
string
git_commits_url
string
git_refs_url
string
git_tags_url
string
git_url
string
issue_comment_url
string
issue_events_url
string
issues_url
string
keys_url
string
labels_url
string
languages_url
string
merges_url
string
milestones_url
string
notifications_url
string
pulls_url
string
releases_url
string
ssh_url
string
stargazers_url
string
statuses_url
string
subscribers_url
string
subscription_url
string
tags_url
string
teams_url
string
trees_url
string
clone_url
string
mirror_url
string
hooks_url
string
svn_url
string
homepage
string
language
string
forks_count
int
stargazers_count
int
watchers_count
int
size
int
default_branch
string
open_issues_count
int
is_template
boolean
topics
array[string]
string
has_issues
boolean
has_projects
boolean
has_wiki
boolean
has_pages
boolean
has_downloads
boolean
archived
boolean
disabled
boolean
visibility
string
pushed_at
string
created_at
string
updated_at
string
permissions
object (permissions)
admin
boolean
maintain
boolean
push
boolean
triage
boolean
pull
boolean
allow_rebase_merge
boolean
temp_clone_token
string
allow_squash_merge
boolean
allow_auto_merge
boolean
delete_branch_on_merge
boolean
allow_update_branch
boolean
use_squash_pr_title_as_default
boolean
squash_merge_commit_title
string
The default value for a squash merge commit title:
PR_TITLE
- default to the pull request's title.COMMIT_OR_PR_TITLE
- default to the commit's title (if only one commit) or the pull request's title (when more than one commit).
- Enum
-
- PR_TITLE
- COMMIT_OR_PR_TITLE
squash_merge_commit_message
string
The default value for a squash merge commit message:
PR_BODY
- default to the pull request's body.COMMIT_MESSAGES
- default to the branch's commit messages.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- COMMIT_MESSAGES
- BLANK
merge_commit_title
string
The default value for a merge commit title.
PR_TITLE
- default to the pull request's title.MERGE_MESSAGE
- default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).
- Enum
-
- PR_TITLE
- MERGE_MESSAGE
merge_commit_message
string
The default value for a merge commit message.
PR_TITLE
- default to the pull request's title.PR_BODY
- default to the pull request's body.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- PR_TITLE
- BLANK
allow_merge_commit
boolean
subscribers_count
int
network_count
int
temp_clone_token
string
allow_squash_merge
boolean
Whether to allow squash merges for pull requests.
- Default
- true
- Example
- true
allow_auto_merge
boolean
Whether to allow Auto-merge to be used on pull requests.
- Default
- false
- Example
- false
delete_branch_on_merge
boolean
Whether to delete head branches when pull requests are merged
- Default
- false
- Example
- false
allow_update_branch
boolean
Whether or not a pull request head branch that is behind its base branch can always be updated even if it is not required to be up to date before merging.
- Default
- false
- Example
- false
use_squash_pr_title_as_default
boolean
deprecated
Whether a squash merge commit can use the pull request title as default. **This property has been deprecated. Please use squash_merge_commit_title
instead.
- Default
- false
squash_merge_commit_title
string
The default value for a squash merge commit title:
PR_TITLE
- default to the pull request's title.COMMIT_OR_PR_TITLE
- default to the commit's title (if only one commit) or the pull request's title (when more than one commit).
- Enum
-
- PR_TITLE
- COMMIT_OR_PR_TITLE
squash_merge_commit_message
string
The default value for a squash merge commit message:
PR_BODY
- default to the pull request's body.COMMIT_MESSAGES
- default to the branch's commit messages.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- COMMIT_MESSAGES
- BLANK
merge_commit_title
string
The default value for a merge commit title.
PR_TITLE
- default to the pull request's title.MERGE_MESSAGE
- default to the classic title for a merge message (e.g., Merge pull request #123 from branch-name).
- Enum
-
- PR_TITLE
- MERGE_MESSAGE
merge_commit_message
string
The default value for a merge commit message.
PR_TITLE
- default to the pull request's title.PR_BODY
- default to the pull request's body.BLANK
- default to a blank commit message.
- Enum
-
- PR_BODY
- PR_TITLE
- BLANK
allow_merge_commit
boolean
Whether to allow merge commits for pull requests.
- Default
- true
- Example
- true
allow_forking
boolean
Whether to allow forking this repo
web_commit_signoff_required
boolean
Whether to require contributors to sign off on web-based commits
- Default
- false
subscribers_count
int
network_count
int
open_issues
int
required
watchers
int
required
master_branch
string
starred_at
string
- Example
- "\"2020-07-09T00:17:42Z\""
anonymous_access_enabled
boolean
Whether anonymous git access is enabled for this repository
single_file
string or null
- Example
- "config.yaml"
repository_selection
string
Describe whether all repositories have been selected or there's a selection involved
- Enum
-
- all
- selected
Get a self-hosted runner for an enterprise
Gets a specific self-hosted runner configured in an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_id
int
required
Unique identifier of the self-hosted runner.
Response
Response
{
"id": 23,
"name": "MBP",
"os": "macos",
"status": "online",
"busy": true,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
},
{
"id": 21,
"name": "no-gpu",
"type": "custom"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
required
The id of the runner.
- Example
- 5
runner_group_id
int
The id of the runner group.
- Example
- 1
name
string
required
The name of the runner.
- Example
- "iMac"
os
string
required
The Operating System of the runner.
- Example
- "macos"
status
string
required
The status of the runner.
- Example
- "online"
busy
boolean
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Delete a self-hosted runner from an enterprise
Forces the removal of a self-hosted runner from an enterprise. You can use this endpoint to completely remove the runner when the machine you were using no longer exists.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_id
int
required
Unique identifier of the self-hosted runner.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
List labels for a self-hosted runner for an enterprise
Lists all labels for a self-hosted runner configured in an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_id
int
required
Unique identifier of the self-hosted runner.
Response
Response
{
"total_count": 4,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
},
{
"id": 21,
"name": "no-gpu",
"type": "custom"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
documentation_url
string
url
string
status
string
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
total_count
int
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Set custom labels for a self-hosted runner for an enterprise
Remove all previous custom labels and set the new custom labels for a specific self-hosted runner configured in an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
labels
array[string]
required
The names of the custom labels to set for the runner. You can pass an empty array to remove all custom labels.
string
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_id
int
required
Unique identifier of the self-hosted runner.
Request
{
"labels": [
"gpu",
"accelerated"
]
}
Response
Response
{
"total_count": 4,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
},
{
"id": 21,
"name": "no-gpu",
"type": "custom"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
documentation_url
string
url
string
status
string
message
string
required
documentation_url
string
required
errors
array[string]
string
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Validation failed, or the endpoint has been spammed.
{
"message": "string",
"documentation_url": "string",
"errors": [
"string"
]
}
total_count
int
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Add custom labels to a self-hosted runner for an enterprise
Add custom labels to a self-hosted runner configured in an enterprise.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
labels
array[string]
required
The names of the custom labels to add to the runner.
string
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_id
int
required
Unique identifier of the self-hosted runner.
Request
{
"labels": [
"gpu",
"accelerated"
]
}
Response
Response
{
"total_count": 4,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
},
{
"id": 21,
"name": "no-gpu",
"type": "custom"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
documentation_url
string
url
string
status
string
message
string
required
documentation_url
string
required
errors
array[string]
string
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Validation failed, or the endpoint has been spammed.
{
"message": "string",
"documentation_url": "string",
"errors": [
"string"
]
}
total_count
int
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Remove all custom labels from a self-hosted runner for an enterprise
Remove all custom labels from a self-hosted runner configured in an enterprise. Returns the remaining read-only labels from the runner.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_id
int
required
Unique identifier of the self-hosted runner.
Response
Response
{
"total_count": 3,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
documentation_url
string
url
string
status
string
message
string
required
documentation_url
string
required
errors
array[string]
string
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Validation failed, or the endpoint has been spammed.
{
"message": "string",
"documentation_url": "string",
"errors": [
"string"
]
}
total_count
int
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Remove a custom label from a self-hosted runner for an enterprise
Remove a custom label from a self-hosted runner configured in an enterprise. 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.
You must authenticate using an access token with the manage_runners:enterprise
scope to use this endpoint.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
runner_id
int
required
Unique identifier of the self-hosted runner.
name
string
required
The name of a self-hosted runner's custom label.
Response
Response
{
"total_count": 4,
"labels": [
{
"id": 5,
"name": "self-hosted",
"type": "read-only"
},
{
"id": 7,
"name": "X64",
"type": "read-only"
},
{
"id": 20,
"name": "macOS",
"type": "read-only"
},
{
"id": 21,
"name": "no-gpu",
"type": "custom"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
documentation_url
string
url
string
status
string
message
string
required
documentation_url
string
required
errors
array[string]
string
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Validation failed, or the endpoint has been spammed.
{
"message": "string",
"documentation_url": "string",
"errors": [
"string"
]
}
total_count
int
required
labels
array[object (Self hosted runner label)]
required
Self hosted runner label
object (Self hosted runner label)
A label for a self hosted runner
id
int
Unique identifier of the label.
name
string
required
Name of the label.
type
string
The type of label. Read-only labels are applied automatically when the runner is configured.
- Enum
-
- read-only
- custom
Get the audit log for an enterprise
Gets the audit log for an enterprise. To use this endpoint, you must be an enterprise admin, and you must use an access token with the read:audit_log
scope.
phrase
string
A search phrase. For more information, see Searching the audit log.
include
string
The event types to include:
web
- returns web (non-Git) events.git
- returns Git events.all
- returns both web and Git events.
The default is web
.
- Enum
-
- web
- git
- all
after
string
A cursor, as given in the Link header. If specified, the query only searches for events after this cursor.
before
string
A cursor, as given in the Link header. If specified, the query only searches for events before this cursor.
order
string
The order of audit log events. To list newest events first, specify desc
. To list oldest events first, specify asc
.
The default is desc
.
- Enum
-
- desc
- asc
page
int
Page number of the results to fetch.
- Default
- 1
per_page
int
The number of results per page (max 100).
- Default
- 30
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
[
{
"actor_ip": "88.123.45.123",
"from": "pull_requests#merge",
"device_cookie": null,
"actor": "mona-admin",
"actor_id": 7,
"repo": "octo-org/octo-repo",
"repo_id": 17,
"business": "github",
"business_id": 1,
"org": "octo-org",
"org_id": 8,
"action": "pull_request.merge",
"@timestamp": 1635940599755,
"created_at": 1635940599755,
"operation_type": "modify",
"actor_location": {
"country_code": "GB",
"country_name": "United Kingdom",
"region": "ENG",
"region_name": "England",
"city": "Louth",
"postal_code": "LN11",
"location": {
"lat": 53.4457,
"lon": 0.141
}
},
"data": {
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) ...",
"method": "POST",
"request_id": "e4dabc4d-ba16-4bca-1234-649be7ae1188",
"server_id": "5d17aab5-fd9f-abcd-a820-16bed246441b",
"request_category": "other",
"controller_action": "merge",
"url": "https://example.com/octo-org/octo-repo/pull/1/merge",
"client_id": 322299977.1635936,
"referrer": "https://example.com/octo-org/octo-repo/pull/1",
"actor_session": 1,
"pull_request_id": 1,
"category_type": "Resource Management"
}
},
{
"actor_ip": "88.123.45.123",
"from": "pull_request_review_events#create",
"device_cookie": null,
"actor": "mona-admin",
"actor_id": 7,
"business_id": 1,
"org_id": 8,
"action": "pull_request_review.submit",
"@timestamp": 1635940593079,
"created_at": 1635940593079,
"operation_type": "modify",
"actor_location": {
"country_code": "GB",
"country_name": "United Kingdom",
"region": "ENG",
"region_name": "England",
"city": "Louth",
"postal_code": "LN11",
"location": {
"lat": 53.4457,
"lon": 0.141
}
},
"data": {
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) ...",
"method": "PUT",
"request_id": "c0f63bb7-17b6-4796-940c-12345c5a581b",
"server_id": "2abc1234-f651-43e3-9696-e942ad5f8c89",
"request_category": "other",
"controller_action": "create",
"url": "https://example.com/octo-org/octo-repo/pull/1/reviews",
"client_id": 322299977.1635936,
"referrer": "https://example.com/octo-org/octo-repo/pull/1/files",
"actor_session": 1,
"spammy": false,
"pull_request_id": 1,
"body": null,
"allowed": true,
"id": 1,
"state": 40,
"issue_id": 1,
"review_id": 1,
"category_type": "Resource Management"
}
},
{
"actor_ip": "88.123.45.123",
"from": "pull_requests#create",
"device_cookie": null,
"actor": "mona",
"actor_id": 9,
"user_id": 9,
"repo": "octo-org/octo-repo",
"repo_id": 17,
"business": "github",
"business_id": 1,
"org": "octo-org",
"org_id": 8,
"action": "pull_request.create",
"@timestamp": 1635940554161,
"created_at": 1635940554161,
"operation_type": "create",
"actor_location": {
"country_code": "GB",
"country_name": "United Kingdom",
"region": "ENG",
"region_name": "England",
"city": "Louth",
"postal_code": "LN11",
"location": {
"lat": 53.4457,
"lon": 0.141
}
},
"data": {
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) ...",
"method": "POST",
"request_id": "2773abeb-477f-4ebf-a017-f8e8a206c305",
"server_id": "796e3115-4ce8-4606-8fd0-99ea57a2e12b",
"request_category": "other",
"controller_action": "create",
"url": "https://example.com/octo-org/octo-repo/pull/create?base=octo-org%3Amain&head=mona%3Apatch-1",
"client_id": 386351111.163594,
"referrer": "https://example.com/octo-org/octo-repo/compare/main...mona:patch-1",
"actor_session": 2,
"pull_request_id": 1,
"category_type": "Resource Management"
}
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
@timestamp
int
The time the audit log event occurred, given as a Unix timestamp.
action
string
The name of the action that was performed, for example user.login
or repo.create
.
active
boolean
active_was
boolean
actor
string
The actor who performed the action.
actor_id
int
The id of the actor who performed the action.
actor_location
object (actor_location)
country_name
string
data
object (data)
org_id
int
user_id
int
business_id
int
blocked_user
string
The username of the account being blocked.
business
string
config
array[object]
object
config_was
array[object]
object
content_type
string
operation_type
string
created_at
int
The time the audit log event was recorded, given as a Unix timestamp.
deploy_key_fingerprint
string
_document_id
string
A unique identifier for an audit event.
emoji
string
events
array[object]
object
events_were
array[object]
object
explanation
string
fingerprint
string
hook_id
int
limited_availability
boolean
message
string
name
string
old_user
string
openssh_public_key
string
org
string
previous_visibility
string
read_only
boolean
repo
string
The name of the repository.
repository
string
The name of the repository.
repository_public
boolean
target_login
string
team
string
transport_protocol
int
The type of protocol (for example, HTTP or SSH) used to transfer Git data.
transport_protocol_name
string
A human readable name for the protocol (for example, HTTP or SSH) used to transfer Git data.
user
string
The user that was affected by the action performed (if available).
visibility
string
The repository visibility, for example public
or private
.
Get code security and analysis features for an enterprise
Gets code security and analysis settings for the specified enterprise.
To use this endpoint, you must be an administrator of the enterprise, and you must use an access token with the admin:enterprise
scope.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Response
Response
{
"advanced_security_enabled_for_new_repositories": true,
"dependabot_alerts_enabled_for_new_repositories": true,
"secret_scanning_enabled_for_new_repositories": true,
"secret_scanning_push_protection_enabled_for_new_repositories": true,
"secret_scanning_push_protection_custom_link": "https://github.com/test-org/test-repo/blob/main/README.md"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
message
string
documentation_url
string
url
string
status
string
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
advanced_security_enabled_for_new_repositories
boolean
required
Whether GitHub advanced security is automatically enabled for new repositories and repositories transferred to this enterprise.
- Example
- false
dependabot_alerts_enabled_for_new_repositories
boolean
required
Whether Dependabot alerts are automatically enabled for new repositories and repositories transferred to this enterprise.
- Example
- false
secret_scanning_enabled_for_new_repositories
boolean
required
Whether secret scanning is automatically enabled for new repositories and repositories transferred to this enterprise.
- Example
- false
secret_scanning_push_protection_enabled_for_new_repositories
boolean
required
Whether secret scanning push protection is automatically enabled for new repositories and repositories transferred to this enterprise.
- Example
- false
secret_scanning_push_protection_custom_link
string or null
An optional URL string to display to contributors who are blocked from pushing a secret.
- Example
- "https://github.com/test-org/test-repo/blob/main/README.md"
Update code security and analysis features for an enterprise
Updates the settings for advanced security, Dependabot alerts, secret scanning, and push protection for new repositories in an enterprise.
To use this endpoint, you must be an administrator of the enterprise, and you must use an access token with the admin:enterprise
scope.
advanced_security_enabled_for_new_repositories
boolean
Whether GitHub Advanced Security is automatically enabled for new repositories. For more information, see "About GitHub Advanced Security."
dependabot_alerts_enabled_for_new_repositories
boolean
Whether Dependabot alerts are automatically enabled for new repositories. For more information, see "About Dependabot alerts."
secret_scanning_enabled_for_new_repositories
boolean
Whether secret scanning is automatically enabled for new repositories. For more information, see "About secret scanning."
secret_scanning_push_protection_enabled_for_new_repositories
boolean
Whether secret scanning push protection is automatically enabled for new repositories. For more information, see "Protecting pushes with secret scanning."
secret_scanning_push_protection_custom_link
string or null
The URL that will be displayed to contributors who are blocked from pushing a secret. For more information, see "Protecting pushes with secret scanning."
To disable this functionality, set this field to null
.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
Request
{
"advanced_security_enabled_for_new_repositories": true,
"dependabot_alerts_enabled_for_new_repositories": true,
"secret_scanning_enabled_for_new_repositories": true,
"secret_scanning_push_protection_enabled_for_new_repositories": true,
"secret_scanning_push_protection_custom_link": "https://github.com/test-org/test-repo/blob/main/README.md"
}
Response
Action started
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
message
string
documentation_url
string
url
string
status
string
The action could not be taken due to an in progress enablement, or a policy is preventing enablement
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Enable or disable a security feature
Enables or disables the specified security feature for all repositories in an enterprise.
To use this endpoint, you must be an administrator of the enterprise, and you must use an access token with the admin:enterprise
scope.
enterprise
string
required
The slug version of the enterprise name. You can also substitute this value with the enterprise id.
security_product
string
required
The security feature to enable or disable.
- Enum
-
- advanced_security
- dependabot_alerts
- secret_scanning
- secret_scanning_push_protection
enablement
string
required
The action to take.
enable_all
means to enable the specified security feature for all repositories in the enterprise.
disable_all
means to disable the specified security feature for all repositories in the enterprise.
- Enum
-
- enable_all
- disable_all
Response
Action started
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
message
string
documentation_url
string
url
string
status
string
The action could not be taken due to an in progress enablement, or a policy is preventing enablement
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Get the status of services running on all replica nodes
Gets the status of all services running on each replica node. This endpoint may take several seconds to reply.
Response
Response
{
"status": "OK",
"nodes": [
{
"hostname": "ghe-local-primary",
"status": "OK",
"services": []
},
{
"hostname": "ghe-local-replica",
"status": "OK",
"services": [
{
"status": "OK",
"name": "redis",
"details": "replication is in sync"
},
{
"status": "OK",
"name": "elasticsearch",
"details": "cluster is in sync (0 shards initializing, 0 shards unassigned)"
},
{
"status": "OK",
"name": "git",
"details": "replication is in sync"
},
{
"status": "OK",
"name": "pages",
"details": "replication is in sync"
},
{
"status": "OK",
"name": "alambic",
"details": "replication is in sync"
},
{
"status": "OK",
"name": "git-hooks",
"details": "replication is in sync"
},
{
"status": "OK",
"name": "consul",
"details": "replication is in sync"
},
{
"status": "OK",
"name": "mysql",
"details": "replication is in sync"
}
]
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
status
string
- Enum
-
- UNKNOWN
- OK
- WARNING
- CRITICAL
nodes
array[object]
object
hostname
string
hostname
status
string
- Enum
-
- UNKNOWN
- OK
- WARNING
- CRITICAL
services
array[object]
object
status
string
- Enum
-
- UNKNOWN
- OK
- WARNING
- CRITICAL
name
string
details
string
Get all GHES release version for all nodes
Gets all of the currently installed GitHub Enterprise Server release version on all available nodes. For more information, see "GitHub Enterprise Server releases."
Response
Response
[
{
"hostname": "ghe-local-primary",
"version": {
"version": "3.9.0",
"platform": "azure",
"build_id": "fc542058b5",
"build_date": "2023-05-02"
}
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
hostname
string
hostname
version
object (version)
version
string
[0-9]\.[0-9]{2}\.[0-9]
platform
string
- Enum
-
- ami
- azure
- esx
- gce
- hyperv
- kvm
build_id
string
[0-9a-f]{8}
build_date
string
date
List pre-receive hooks for an organization
List all pre-receive hooks that are enabled or testing for this organization as well as any disabled hooks that can be configured at the organization level. Globally disabled pre-receive hooks that do not allow downstream configuration are not listed.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
direction
string
The direction to sort the results by.
- Default
- "desc"
- Enum
-
- asc
- desc
sort
string
The sort order for the response collection.
- Default
- "created"
- Enum
-
- created
- updated
- name
org
string
required
The organization name. The name is not case sensitive.
Response
Response
[
{
"id": 42,
"name": "Check Commits",
"enforcement": "disabled",
"configuration_url": "https://github.example.com/api/v3/admin/pre-receive-hooks/42",
"allow_downstream_configuration": true
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
id
int
name
string
enforcement
string
configuration_url
string
allow_downstream_configuration
boolean
org
string
required
The organization name. The name is not case sensitive.
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Response
Response
{
"id": 42,
"name": "Check Commits",
"enforcement": "disabled",
"configuration_url": "https://github.example.com/api/v3/admin/pre-receive-hooks/42",
"allow_downstream_configuration": true
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
configuration_url
string
allow_downstream_configuration
boolean
Remove pre-receive hook enforcement for an organization
Removes any overrides for this hook at the org level for this org.
org
string
required
The organization name. The name is not case sensitive.
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Response
Response
{
"id": 42,
"name": "Check Commits",
"enforcement": "disabled",
"configuration_url": "https://github.example.com/api/v3/admin/pre-receive-hooks/42",
"allow_downstream_configuration": true
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
configuration_url
string
allow_downstream_configuration
boolean
Update pre-receive hook enforcement for an organization
For pre-receive hooks which are allowed to be configured at the org level, you can set enforcement
and allow_downstream_configuration
enforcement
string
The state of enforcement for the hook on this repository.
allow_downstream_configuration
boolean
Whether repositories can override enforcement.
org
string
required
The organization name. The name is not case sensitive.
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Request
{
"enforcement": "enabled",
"allow_downstream_configuration": false
}
Response
Response
{
"id": 42,
"name": "Check Commits",
"enforcement": "enabled",
"configuration_url": "https://github.example.com/api/v3/orgs/octocat/pre-receive-hooks/42",
"allow_downstream_configuration": false
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
configuration_url
string
allow_downstream_configuration
boolean
List pre-receive hooks for a repository
List all pre-receive hooks that are enabled or testing for this repository as well as any disabled hooks that are allowed to be enabled at the repository level. Pre-receive hooks that are disabled at a higher level and are not configurable will not be listed.
per_page
int
The number of results per page (max 100).
- Default
- 30
page
int
Page number of the results to fetch.
- Default
- 1
direction
string
The direction to sort the results by.
- Default
- "desc"
- Enum
-
- asc
- desc
sort
string
- Default
- "created"
- Enum
-
- created
- updated
- name
owner
string
required
The account owner of the repository. The name is not case sensitive.
repo
string
required
The name of the repository. The name is not case sensitive.
Response
Response
[
{
"id": 42,
"name": "Check Commits",
"enforcement": "disabled",
"configuration_url": "https://github.example.com/api/v3/orgs/octocat/pre-receive-hooks/42"
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
id
int
name
string
enforcement
string
configuration_url
string
Get a pre-receive hook for a repository
owner
string
required
The account owner of the repository. The name is not case sensitive.
repo
string
required
The name of the repository. The name is not case sensitive.
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Response
Response
{
"id": 42,
"name": "Check Commits",
"enforcement": "disabled",
"configuration_url": "https://github.example.com/api/v3/orgs/octocat/pre-receive-hooks/42"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
configuration_url
string
Remove pre-receive hook enforcement for a repository
Deletes any overridden enforcement on this repository for the specified hook.
Responds with effective values inherited from owner and/or global level.
owner
string
required
The account owner of the repository. The name is not case sensitive.
repo
string
required
The name of the repository. The name is not case sensitive.
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Response
Responds with effective values inherited from owner and/or global level.
{
"id": 42,
"name": "Check Commits",
"enforcement": "disabled",
"configuration_url": "https://github.example.com/api/v3/orgs/octocat/pre-receive-hooks/42"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
configuration_url
string
Update pre-receive hook enforcement for a repository
For pre-receive hooks which are allowed to be configured at the repo level, you can set enforcement
enforcement
string
The state of enforcement for the hook on this repository.
- Enum
-
- enabled
- disabled
- testing
owner
string
required
The account owner of the repository. The name is not case sensitive.
repo
string
required
The name of the repository. The name is not case sensitive.
pre_receive_hook_id
int
required
The unique identifier of the pre-receive hook.
Request
{
"enforcement": "enabled"
}
Response
Response
{
"id": 42,
"name": "Check Commits",
"enforcement": "enabled",
"configuration_url": "https://github.example.com/api/v3/repos/octocat/hello-world/pre-receive-hooks/42"
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
id
int
name
string
enforcement
string
configuration_url
string
List provisioned SCIM groups for an enterprise
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Lists provisioned SCIM groups in an enterprise.
You can improve query search time by using the excludedAttributes
query parameter with a value of members
to exclude members from the response.
filter
string
If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are externalId
, id
, and displayName
. For example, ?filter="externalId eq '9138790-10932-109120392-12321'"
.
excludedAttributes
string
Excludes the specified attribute from being returned in the results. Using this parameter can speed up response time.
- Example
- "members"
startIndex
int
i32
Used for pagination: the starting index of the first result to return when paginating through values.
- Default
- 1
- Example
- 1
count
int
i32
Used for pagination: the number of results to return per page.
- Default
- 30
- Example
- 1
Response
Success, either groups were found or not found
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:ListResponse"
],
"totalResults": 1,
"Resources": [
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"id": "927fa2c08dcb4a7fae9e",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
],
"meta": {
"resourceType": "Group",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Groups/927fa2c08dcb4a7fae9e"
}
}
],
"startIndex": 1,
"itemsPerPage": 20
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the list SCIM schemas.
- Example
- [ "urn:ietf:params:scim:api:messages:2.0:ListResponse" ]
string
- Enum
-
- urn:ietf:params:scim:api:messages:2.0:ListResponse
totalResults
int
required
Number of results found
- Example
- 1
Resources
array[object]
required
Information about each provisioned group.
object
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:Group" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:Group
- urn:ietf:params:scim:api:messages:2.0:ListResponse
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159"
displayName
string or null
A human-readable name for a security group.
- Example
- "Engineering"
members
array[object]
The security group members.
- Example
- [ { "value": "879db59-3bdf-4490-ad68-ab880a2694745", "$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745", "displayName": "User 1" }, { "value": "0db508eb-91e2-46e4-809c-30dcbda0c685", "$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685", "displayName": "User 2" } ]
object
value
string
required
The local unique identifier for the member
- Example
- "23a35c27-23d3-4c03-b4c5-6443c09e7173"
$ref
string
required
display
string
The display name associated with the member
- Example
- "Monalisa Octocat"
id
string
The internally generated id for the group object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
meta
object (meta)
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
startIndex
int
required
A starting index for the returned page
- Example
- 1
itemsPerPage
int
required
Number of objects per page
- Example
- 20
Provision a SCIM enterprise group
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Creates a SCIM group for an enterprise.
If members are included as part of the group provisioning payload, they will be created as external group members. It is up to a provider to store a mapping between the externalId
and id
of each user.
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:Group" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:Group
externalId
string
required
A unique identifier for the resource as defined by the provisioning client.
- Example
- "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159"
displayName
string
required
A human-readable name for a security group.
- Example
- "Engineering"
members
array[object]
required
The group members.
object
value
string
required
The local unique identifier for the member
- Example
- "23a35c27-23d3-4c03-b4c5-6443c09e7173"
displayName
string
required
The display name associated with the member
- Example
- "Monalisa Octocat"
Request
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering"
}
Response
Group has been created
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"id": "abcd27f8-a9aa-11ea-8221-f59b2be9cccc",
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
],
"meta": {
"resourceType": "Group",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Groups/927fa2c08dcb4a7fae9e"
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Duplicate record detected
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:Group" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:Group
- urn:ietf:params:scim:api:messages:2.0:ListResponse
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159"
displayName
string or null
A human-readable name for a security group.
- Example
- "Engineering"
members
array[object]
The security group members.
- Example
- [ { "value": "879db59-3bdf-4490-ad68-ab880a2694745", "$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745", "displayName": "User 1" }, { "value": "0db508eb-91e2-46e4-809c-30dcbda0c685", "$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685", "displayName": "User 2" } ]
object
value
string
required
The local unique identifier for the member
- Example
- "23a35c27-23d3-4c03-b4c5-6443c09e7173"
$ref
string
required
display
string
The display name associated with the member
- Example
- "Monalisa Octocat"
id
string
The internally generated id for the group object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
meta
object (meta)
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
Get SCIM provisioning information for an enterprise group
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Gets information about a SCIM group.
excludedAttributes
string
Excludes the specified attribute from being returned in the results. Using this parameter can speed up response time.
- Example
- "members"
scim_group_id
string
required
A unique identifier of the SCIM group.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
Response
Success, a group was found
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"id": "abcd27f8-a9aa-11ea-8221-f59b2be9cccc",
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
],
"meta": {
"resourceType": "Group",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Groups/927fa2c08dcb4a7fae9e"
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:Group" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:Group
- urn:ietf:params:scim:api:messages:2.0:ListResponse
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159"
displayName
string or null
A human-readable name for a security group.
- Example
- "Engineering"
members
array[object]
The security group members.
- Example
- [ { "value": "879db59-3bdf-4490-ad68-ab880a2694745", "$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745", "displayName": "User 1" }, { "value": "0db508eb-91e2-46e4-809c-30dcbda0c685", "$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685", "displayName": "User 2" } ]
object
value
string
required
The local unique identifier for the member
- Example
- "23a35c27-23d3-4c03-b4c5-6443c09e7173"
$ref
string
required
display
string
The display name associated with the member
- Example
- "Monalisa Octocat"
id
string
The internally generated id for the group object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
meta
object (meta)
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
Set SCIM information for a provisioned enterprise group
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Replaces an existing provisioned group’s information.
You must provide all the information required for the group as if you were provisioning it for the first time. Any existing group information that you don't provide will be removed, including group membership. If you want to only update a specific attribute, use the Update an attribute for a SCIM enterprise group endpoint instead.
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:Group" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:Group
externalId
string
required
A unique identifier for the resource as defined by the provisioning client.
- Example
- "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159"
displayName
string
required
A human-readable name for a security group.
- Example
- "Engineering"
members
array[object]
required
The group members.
object
value
string
required
The local unique identifier for the member
- Example
- "23a35c27-23d3-4c03-b4c5-6443c09e7173"
displayName
string
required
The display name associated with the member
- Example
- "Monalisa Octocat"
scim_group_id
string
required
A unique identifier of the SCIM group.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
Request
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering"
}
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
]
}
Response
Group was updated
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"id": "abcd27f8-a9aa-11ea-8221-f59b2be9cccc",
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
],
"meta": {
"resourceType": "Group",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Groups/927fa2c08dcb4a7fae9e"
}
}
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"id": "abcd27f8-a9aa-11ea-8221-f59b2be9cccc",
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
],
"meta": {
"resourceType": "Group",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Groups/927fa2c08dcb4a7fae9e"
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Duplicate record detected
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:Group" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:Group
- urn:ietf:params:scim:api:messages:2.0:ListResponse
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159"
displayName
string or null
A human-readable name for a security group.
- Example
- "Engineering"
members
array[object]
The security group members.
- Example
- [ { "value": "879db59-3bdf-4490-ad68-ab880a2694745", "$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745", "displayName": "User 1" }, { "value": "0db508eb-91e2-46e4-809c-30dcbda0c685", "$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685", "displayName": "User 2" } ]
object
value
string
required
The local unique identifier for the member
- Example
- "23a35c27-23d3-4c03-b4c5-6443c09e7173"
$ref
string
required
display
string
The display name associated with the member
- Example
- "Monalisa Octocat"
id
string
The internally generated id for the group object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
meta
object (meta)
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
Delete a SCIM group from an enterprise
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Deletes a SCIM group from an enterprise.
scim_group_id
string
required
A unique identifier of the SCIM group.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
Response
Group was deleted, no content
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Update an attribute for a SCIM enterprise group
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Update a provisioned group’s individual attributes.
To change a group’s values, you must provide a specific Operations JSON format that contains at least one of the add, remove, or replace operations. For examples and more information on the SCIM operations format, see the SCIM specification. Update can also be used to add group memberships.
Group memberships can be sent one at a time or in batches for faster performance. Note: The memberships are referenced through a local user id
, and the user will need to be created before they are referenced here.
Operations
array[object]
required
patch operations list
object
op
string
required
- Enum
-
- add
- replace
- remove
path
string
value
string
Corresponding 'value' of that field specified by 'path'
schemas
array[string]
required
string
- Enum
-
- urn:ietf:params:scim:api:messages:2.0:PatchOp
scim_group_id
string
required
A unique identifier of the SCIM group.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
Request
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:PatchOp"
],
"Operations": [
{
"op": "replace",
"path": "displayName",
"value": "Employees"
}
]
}
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:PatchOp"
],
"Operations": [
{
"op": "add",
"path": "members",
"value": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685"
}
]
}
]
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Success, group was updated
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"id": "abcd27f8-a9aa-11ea-8221-f59b2be9cccc",
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
],
"meta": {
"resourceType": "Group",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Groups/927fa2c08dcb4a7fae9e"
}
}
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:Group"
],
"id": "abcd27f8-a9aa-11ea-8221-f59b2be9cccc",
"externalId": "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159",
"displayName": "Engineering",
"members": [
{
"value": "879db59-3bdf-4490-ad68-ab880a2694745",
"$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745",
"displayName": "User 1"
},
{
"value": "0db508eb-91e2-46e4-809c-30dcbda0c685",
"$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685",
"displayName": "User 2"
}
],
"meta": {
"resourceType": "Group",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Groups/927fa2c08dcb4a7fae9e"
}
}
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Duplicate record detected
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:Group" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:Group
- urn:ietf:params:scim:api:messages:2.0:ListResponse
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "8aa1a0c0-c4c3-4bc0-b4a5-2ef676900159"
displayName
string or null
A human-readable name for a security group.
- Example
- "Engineering"
members
array[object]
The security group members.
- Example
- [ { "value": "879db59-3bdf-4490-ad68-ab880a2694745", "$+ref": "https://api.github.localhost/scim/v2/Users/879db59-3bdf-4490-ad68-ab880a2694745", "displayName": "User 1" }, { "value": "0db508eb-91e2-46e4-809c-30dcbda0c685", "$+ref": "https://api.github.localhost/scim/v2/Users/0db508eb-91e2-46e4-809c-30dcbda0c685", "displayName": "User 2" } ]
object
value
string
required
The local unique identifier for the member
- Example
- "23a35c27-23d3-4c03-b4c5-6443c09e7173"
$ref
string
required
display
string
The display name associated with the member
- Example
- "Monalisa Octocat"
id
string
The internally generated id for the group object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
meta
object (meta)
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
List SCIM provisioned identities for an enterprise
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Lists provisioned SCIM enterprise members.
When a user with a SCIM-provisioned external identity is removed from an enterprise through a patch
with active
flag set to false
, the account's metadata is preserved to allow the user to re-join the enterprise in the future. However, the user's account will be suspended and the user will not be able to sign-in. In order to permanently suspend the users account with no ability to re-join the enterprise in the future, use the delete
request. Users that were not permanently deleted will be visible in the returned results.
You can improve query search time by using the excludedAttributes
query parameter with a value of groups
to exclude groups from the response.
filter
string
If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are userName
, externalId
, id
, and displayName
. For example, ?filter="externalId eq '9138790-10932-109120392-12321'"
.
excludedAttributes
string
Excludes the specified attribute from being returned in the results. Using this parameter can speed up response time.
- Example
- "members"
startIndex
int
i32
Used for pagination: the starting index of the first result to return when paginating through values.
- Default
- 1
- Example
- 1
count
int
i32
Used for pagination: the number of results to return per page.
- Default
- 30
- Example
- 1
Response
Success, either users were found or not found
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:ListResponse"
],
"totalResults": 1,
"Resources": [
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"externalId": "E012345",
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
]
}
],
"startIndex": 1,
"itemsPerPage": 20
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the list SCIM schemas.
- Example
- [ "urn:ietf:params:scim:api:messages:2.0:ListResponse" ]
string
- Enum
-
- urn:ietf:params:scim:api:messages:2.0:ListResponse
totalResults
int
required
Number of results found
- Example
- 1
Resources
array[object]
required
Information about each provisioned account.
object
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:User" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:User
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "E012345"
active
boolean
required
Whether the user active in the IdP.
- Example
- true
userName
string
The username for the user.
- Example
- "E012345"
name
object (name)
formatted
string
The full name, including all middle names, titles, and suffixes as appropriate, formatted for display.
- Example
- "Ms. Mona Lisa Octocat"
familyName
string
The family name of the user.
- Example
- "Octocat"
givenName
string
The given name of the user.
- Example
- "Mona"
middleName
string
The middle name(s) of the user.
- Example
- "Lisa"
displayName
string or null
A human-readable name for the user.
- Example
- "Mona Lisa"
emails
array[object]
required
The emails for the user.
object
value
string
required
The email address.
- Example
- "mlisa@example.com"
type
string
The type of email address.
- Example
- "work"
primary
boolean
Whether this email address is the primary address.
- Example
- true
roles
array[object]
The roles assigned to the user.
object
display
string
type
string
value
string
required
The role value representing a user role in GitHub.
- Enum
-
- User
- user
- 27d9891d-2c17-4f45-a262-781a0e55c80a
- Restricted User
- restricted_user
- 1ebc4a02-e56c-43a6-92a5-02ee09b90824
- Enterprise Owner
- enterprise_owner
- 981df190-8801-4618-a08a-d91f6206c954
- ba4987ab-a1c3-412a-b58c-360fc407cb10
- Billing Manager
- billing_manager
- 0e338b8c-cc7f-498a-928d-ea3470d7e7e3
- e6be2762-e4ad-4108-b72d-1bbe884a0f91
- Example
- "user"
primary
boolean
Is the role a primary role for the user.
- Example
- false
id
string
required
The internally generated id for the user object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
groups
array[object]
Provisioned SCIM groups that the user is a member of.
object
value
string
$ref
string
display
string
meta
object (meta)
required
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
startIndex
int
required
A starting index for the returned page
- Example
- 1
itemsPerPage
int
required
Number of objects per page
- Example
- 20
Provision a SCIM enterprise user
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Creates an external identity for a new SCIM enterprise user.
SCIM does not authenticate users, it only provisions them. The authentication of users is done by SAML. However, when SCIM is enabled, all users need to be provisioned through SCIM before a user can sign in through SAML. The matching of a user to a SCIM provisioned user is done when the SAML assertion is consumed. The user will be matched on SAML response NameID
to SCIM userName
.
When converting existing enterprise to use SCIM, the user handle (userName
) from the SCIM payload will be used to match the provisioned user to an already existing user in the enterprise. Since the new identity record is created for newly provisioned users the matching for those records is done using a user's handle. Currently the matching will be performed to all of the users no matter if they were SAML JIT provisioned or created as local users.
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:User" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:User
externalId
string
required
A unique identifier for the resource as defined by the provisioning client.
- Example
- "E012345"
active
boolean
required
Whether the user active in the IdP.
- Example
- true
userName
string
required
The username for the user.
- Example
- "E012345"
name
object (name)
formatted
string
The full name, including all middle names, titles, and suffixes as appropriate, formatted for display.
- Example
- "Ms. Mona Lisa Octocat"
familyName
string
required
The family name of the user.
- Example
- "Octocat"
givenName
string
required
The given name of the user.
- Example
- "Mona"
middleName
string
The middle name(s) of the user.
- Example
- "Lisa"
displayName
string
required
A human-readable name for the user.
- Example
- "Mona Lisa"
emails
array[object]
required
The emails for the user.
object
value
string
required
The email address.
- Example
- "mlisa@example.com"
type
string
required
The type of email address.
- Example
- "work"
primary
boolean
required
Whether this email address is the primary address.
- Example
- true
roles
array[object]
The roles assigned to the user.
object
display
string
type
string
value
string
required
The role value representing a user role in GitHub.
- Enum
-
- User
- user
- 27d9891d-2c17-4f45-a262-781a0e55c80a
- Restricted User
- restricted_user
- 1ebc4a02-e56c-43a6-92a5-02ee09b90824
- Enterprise Owner
- enterprise_owner
- 981df190-8801-4618-a08a-d91f6206c954
- ba4987ab-a1c3-412a-b58c-360fc407cb10
- Billing Manager
- billing_manager
- 0e338b8c-cc7f-498a-928d-ea3470d7e7e3
- e6be2762-e4ad-4108-b72d-1bbe884a0f91
- Example
- "user"
primary
boolean
Is the role a primary role for the user.
- Example
- false
Request
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
]
}
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "Enterprise Owner",
"primary": false
}
]
}
Response
User has been created
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
],
"meta": {
"resourceType": "User",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Users/7fce0092-d52e-4f76-b727-3955bd72c939"
}
}
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
],
"meta": {
"resourceType": "User",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Users/7fce0092-d52e-4f76-b727-3955bd72c939"
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Duplicate record detected
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:User" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:User
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "E012345"
active
boolean
required
Whether the user active in the IdP.
- Example
- true
userName
string
The username for the user.
- Example
- "E012345"
name
object (name)
formatted
string
The full name, including all middle names, titles, and suffixes as appropriate, formatted for display.
- Example
- "Ms. Mona Lisa Octocat"
familyName
string
The family name of the user.
- Example
- "Octocat"
givenName
string
The given name of the user.
- Example
- "Mona"
middleName
string
The middle name(s) of the user.
- Example
- "Lisa"
displayName
string or null
A human-readable name for the user.
- Example
- "Mona Lisa"
emails
array[object]
required
The emails for the user.
object
value
string
required
The email address.
- Example
- "mlisa@example.com"
type
string
The type of email address.
- Example
- "work"
primary
boolean
Whether this email address is the primary address.
- Example
- true
roles
array[object]
The roles assigned to the user.
object
display
string
type
string
value
string
required
The role value representing a user role in GitHub.
- Enum
-
- User
- user
- 27d9891d-2c17-4f45-a262-781a0e55c80a
- Restricted User
- restricted_user
- 1ebc4a02-e56c-43a6-92a5-02ee09b90824
- Enterprise Owner
- enterprise_owner
- 981df190-8801-4618-a08a-d91f6206c954
- ba4987ab-a1c3-412a-b58c-360fc407cb10
- Billing Manager
- billing_manager
- 0e338b8c-cc7f-498a-928d-ea3470d7e7e3
- e6be2762-e4ad-4108-b72d-1bbe884a0f91
- Example
- "user"
primary
boolean
Is the role a primary role for the user.
- Example
- false
id
string
required
The internally generated id for the user object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
groups
array[object]
Provisioned SCIM groups that the user is a member of.
object
value
string
$ref
string
display
string
meta
object (meta)
required
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
Get SCIM provisioning information for an enterprise user
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Gets information about a SCIM user.
scim_user_id
string
required
The unique identifier of the SCIM user.
Response
Success, a user was found
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
],
"meta": {
"resourceType": "User",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Users/7fce0092-d52e-4f76-b727-3955bd72c939"
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:User" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:User
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "E012345"
active
boolean
required
Whether the user active in the IdP.
- Example
- true
userName
string
The username for the user.
- Example
- "E012345"
name
object (name)
formatted
string
The full name, including all middle names, titles, and suffixes as appropriate, formatted for display.
- Example
- "Ms. Mona Lisa Octocat"
familyName
string
The family name of the user.
- Example
- "Octocat"
givenName
string
The given name of the user.
- Example
- "Mona"
middleName
string
The middle name(s) of the user.
- Example
- "Lisa"
displayName
string or null
A human-readable name for the user.
- Example
- "Mona Lisa"
emails
array[object]
required
The emails for the user.
object
value
string
required
The email address.
- Example
- "mlisa@example.com"
type
string
The type of email address.
- Example
- "work"
primary
boolean
Whether this email address is the primary address.
- Example
- true
roles
array[object]
The roles assigned to the user.
object
display
string
type
string
value
string
required
The role value representing a user role in GitHub.
- Enum
-
- User
- user
- 27d9891d-2c17-4f45-a262-781a0e55c80a
- Restricted User
- restricted_user
- 1ebc4a02-e56c-43a6-92a5-02ee09b90824
- Enterprise Owner
- enterprise_owner
- 981df190-8801-4618-a08a-d91f6206c954
- ba4987ab-a1c3-412a-b58c-360fc407cb10
- Billing Manager
- billing_manager
- 0e338b8c-cc7f-498a-928d-ea3470d7e7e3
- e6be2762-e4ad-4108-b72d-1bbe884a0f91
- Example
- "user"
primary
boolean
Is the role a primary role for the user.
- Example
- false
id
string
required
The internally generated id for the user object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
groups
array[object]
Provisioned SCIM groups that the user is a member of.
object
value
string
$ref
string
display
string
meta
object (meta)
required
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
Set SCIM information for a provisioned enterprise user
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Replaces an existing provisioned user's information.
You must provide all the information required for the user as if you were provisioning them for the first time. Any existing user information that you don't provide will be removed. If you want to only update a specific attribute, use the Update an attribute for a SCIM user endpoint instead.
Warning: Setting active: false
will suspend a user and obfuscate the user handle and user email. Since the implementation is a generic SCIM implementation and does not differentiate yet between different IdP providers, for Okta, the user GDPR data will not be purged and the credentials will not be removed.
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:User" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:User
externalId
string
required
A unique identifier for the resource as defined by the provisioning client.
- Example
- "E012345"
active
boolean
required
Whether the user active in the IdP.
- Example
- true
userName
string
required
The username for the user.
- Example
- "E012345"
name
object (name)
formatted
string
The full name, including all middle names, titles, and suffixes as appropriate, formatted for display.
- Example
- "Ms. Mona Lisa Octocat"
familyName
string
required
The family name of the user.
- Example
- "Octocat"
givenName
string
required
The given name of the user.
- Example
- "Mona"
middleName
string
The middle name(s) of the user.
- Example
- "Lisa"
displayName
string
required
A human-readable name for the user.
- Example
- "Mona Lisa"
emails
array[object]
required
The emails for the user.
object
value
string
required
The email address.
- Example
- "mlisa@example.com"
type
string
required
The type of email address.
- Example
- "work"
primary
boolean
required
Whether this email address is the primary address.
- Example
- true
roles
array[object]
The roles assigned to the user.
object
display
string
type
string
value
string
required
The role value representing a user role in GitHub.
- Enum
-
- User
- user
- 27d9891d-2c17-4f45-a262-781a0e55c80a
- Restricted User
- restricted_user
- 1ebc4a02-e56c-43a6-92a5-02ee09b90824
- Enterprise Owner
- enterprise_owner
- 981df190-8801-4618-a08a-d91f6206c954
- ba4987ab-a1c3-412a-b58c-360fc407cb10
- Billing Manager
- billing_manager
- 0e338b8c-cc7f-498a-928d-ea3470d7e7e3
- e6be2762-e4ad-4108-b72d-1bbe884a0f91
- Example
- "user"
primary
boolean
Is the role a primary role for the user.
- Example
- false
scim_user_id
string
required
The unique identifier of the SCIM user.
Request
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
]
}
Response
User was updated
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
],
"meta": {
"resourceType": "User",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Users/7fce0092-d52e-4f76-b727-3955bd72c939"
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Duplicate record detected
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:User" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:User
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "E012345"
active
boolean
required
Whether the user active in the IdP.
- Example
- true
userName
string
The username for the user.
- Example
- "E012345"
name
object (name)
formatted
string
The full name, including all middle names, titles, and suffixes as appropriate, formatted for display.
- Example
- "Ms. Mona Lisa Octocat"
familyName
string
The family name of the user.
- Example
- "Octocat"
givenName
string
The given name of the user.
- Example
- "Mona"
middleName
string
The middle name(s) of the user.
- Example
- "Lisa"
displayName
string or null
A human-readable name for the user.
- Example
- "Mona Lisa"
emails
array[object]
required
The emails for the user.
object
value
string
required
The email address.
- Example
- "mlisa@example.com"
type
string
The type of email address.
- Example
- "work"
primary
boolean
Whether this email address is the primary address.
- Example
- true
roles
array[object]
The roles assigned to the user.
object
display
string
type
string
value
string
required
The role value representing a user role in GitHub.
- Enum
-
- User
- user
- 27d9891d-2c17-4f45-a262-781a0e55c80a
- Restricted User
- restricted_user
- 1ebc4a02-e56c-43a6-92a5-02ee09b90824
- Enterprise Owner
- enterprise_owner
- 981df190-8801-4618-a08a-d91f6206c954
- ba4987ab-a1c3-412a-b58c-360fc407cb10
- Billing Manager
- billing_manager
- 0e338b8c-cc7f-498a-928d-ea3470d7e7e3
- e6be2762-e4ad-4108-b72d-1bbe884a0f91
- Example
- "user"
primary
boolean
Is the role a primary role for the user.
- Example
- false
id
string
required
The internally generated id for the user object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
groups
array[object]
Provisioned SCIM groups that the user is a member of.
object
value
string
$ref
string
display
string
meta
object (meta)
required
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
Delete a SCIM user from an enterprise
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Permanently suspends a SCIM user from an enterprise, removes all data for the user, obfuscates the login, email, and display name of the user, removes all external-identity SCIM attributes, and deletes the emails, avatar, PATs, SSH keys, OAuth authorizations credentials, GPG keys, and SAML mappings for the user. You will not be able to undo this action.
scim_user_id
string
required
The unique identifier of the SCIM user.
Response
User was deleted, no content
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Update an attribute for a SCIM enterprise user
Note: The SCIM API endpoints for enterprise accounts are currently in private beta and are subject to change.
Update a provisioned user's individual attributes.
To change a user's values, you must provide a specific Operations
JSON format that contains at least one of the add
, remove
, or replace
operations. For examples and more information on the SCIM operations format, see the SCIM specification.
Note: Complicated SCIM path
selectors that include filters are not supported. For example, a path
selector defined as "path": "emails[type eq \"work\"]"
will not work.
Warning: Setting active: false
will suspend a user and obfuscate the user handle and user email. Since the implementation is a generic SCIM implementation and does not differentiate yet between different IdP providers, for Okta, the user GDPR data will not be purged and the credentials will not be removed.
{
"Operations":[{
"op":"replace",
"value":{
"active":false
}
}]
}
Operations
array[object]
required
patch operations list
object
op
string
required
- Enum
-
- add
- replace
- remove
path
string
value
string
Corresponding 'value' of that field specified by 'path'
schemas
array[string]
required
string
- Enum
-
- urn:ietf:params:scim:api:messages:2.0:PatchOp
scim_user_id
string
required
The unique identifier of the SCIM user.
Request
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:PatchOp"
],
"Operations": [
{
"op": "replace",
"path": "emails[type eq 'work'].value",
"value": "updatedEmail@microsoft.com"
},
{
"op": "replace",
"path": "name.familyName",
"value": "updatedFamilyName"
}
]
}
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:PatchOp"
],
"Operations": [
{
"op": "replace",
"path": "userName",
"value": "5b50642d-79fc-4410-9e90-4c077cdd1a59@testuser.com"
},
{
"op": "replace",
"path": "displayName",
"value": "Monalisa Octocat"
}
]
}
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:PatchOp"
],
"Operations": [
{
"op": "replace",
"path": "active",
"value": false
}
]
}
Response
Success, user was updated
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
],
"meta": {
"resourceType": "User",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Users/7fce0092-d52e-4f76-b727-3955bd72c939"
}
}
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
],
"meta": {
"resourceType": "User",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Users/7fce0092-d52e-4f76-b727-3955bd72c939"
}
}
{
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:User"
],
"id": "7fce0092-d52e-4f76-b727-3955bd72c939",
"externalId": "E012345",
"active": true,
"userName": "E012345",
"name": {
"formatted": "Ms. Mona Lisa Octocat",
"familyName": "Octocat",
"givenName": "Mona",
"middleName": "Lisa"
},
"displayName": "Mona Lisa",
"emails": [
{
"value": "mlisa@example.com",
"type": "work",
"primary": true
}
],
"roles": [
{
"value": "User",
"primary": false
}
],
"meta": {
"resourceType": "User",
"created": "2012-03-27T19:59:26.000Z",
"lastModified": "2018-03-27T19:59:26.000Z",
"location": "https://api.github.localhost/scim/v2/Users/7fce0092-d52e-4f76-b727-3955bd72c939"
}
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
No schema
No schema
message
string
documentation_url
string
url
string
status
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
message
string or null
documentation_url
string or null
detail
string or null
status
int
scimType
string or null
schemas
array[string]
string
Bad request
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Authorization failure
Empty response
Permission denied
Empty response
Resource not found
{
"message": "string",
"documentation_url": "string",
"url": "string",
"status": "string"
}
Duplicate record detected
Empty response
Too many requests
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
Internal server error
{
"message": "string",
"documentation_url": "string",
"detail": "string",
"status": 123,
"scimType": "string",
"schemas": [
"string"
]
}
schemas
array[string]
required
The URIs that are used to indicate the namespaces of the SCIM schemas.
- Example
- [ "urn:ietf:params:scim:schemas:core:2.0:User" ]
string
- Enum
-
- urn:ietf:params:scim:schemas:core:2.0:User
externalId
string or null
A unique identifier for the resource as defined by the provisioning client.
- Example
- "E012345"
active
boolean
required
Whether the user active in the IdP.
- Example
- true
userName
string
The username for the user.
- Example
- "E012345"
name
object (name)
formatted
string
The full name, including all middle names, titles, and suffixes as appropriate, formatted for display.
- Example
- "Ms. Mona Lisa Octocat"
familyName
string
The family name of the user.
- Example
- "Octocat"
givenName
string
The given name of the user.
- Example
- "Mona"
middleName
string
The middle name(s) of the user.
- Example
- "Lisa"
displayName
string or null
A human-readable name for the user.
- Example
- "Mona Lisa"
emails
array[object]
required
The emails for the user.
object
value
string
required
The email address.
- Example
- "mlisa@example.com"
type
string
The type of email address.
- Example
- "work"
primary
boolean
Whether this email address is the primary address.
- Example
- true
roles
array[object]
The roles assigned to the user.
object
display
string
type
string
value
string
required
The role value representing a user role in GitHub.
- Enum
-
- User
- user
- 27d9891d-2c17-4f45-a262-781a0e55c80a
- Restricted User
- restricted_user
- 1ebc4a02-e56c-43a6-92a5-02ee09b90824
- Enterprise Owner
- enterprise_owner
- 981df190-8801-4618-a08a-d91f6206c954
- ba4987ab-a1c3-412a-b58c-360fc407cb10
- Billing Manager
- billing_manager
- 0e338b8c-cc7f-498a-928d-ea3470d7e7e3
- e6be2762-e4ad-4108-b72d-1bbe884a0f91
- Example
- "user"
primary
boolean
Is the role a primary role for the user.
- Example
- false
id
string
required
The internally generated id for the user object.
- Example
- "7fce0092-d52e-4f76-b727-3955bd72c939"
groups
array[object]
Provisioned SCIM groups that the user is a member of.
object
value
string
$ref
string
display
string
meta
object (meta)
required
The metadata associated with the creation/updates to the user.
resourceType
string
required
A type of a resource
- Enum
-
- User
- Group
- Example
- "User"
created
string
A date and time when the user was created.
- Example
- "2022-03-27T19:59:26.000Z"
lastModified
string
A data and time when the user was last modified.
- Example
- "2022-03-27T19:59:26.000Z"
location
string
A URL location of an object
Get the configuration status
This endpoint allows you to check the status of the most recent configuration process:
Note that you may need to wait several seconds after you start a process before you can check its status.
The different statuses are:
Response
Response
{
"status": "running",
"progress": [
{
"status": "DONE",
"key": "Appliance core components"
},
{
"status": "DONE",
"key": "GitHub utilities"
},
{
"status": "DONE",
"key": "GitHub applications"
},
{
"status": "CONFIGURING",
"key": "GitHub services"
},
{
"status": "PENDING",
"key": "Reloading appliance services"
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
status
string
progress
array[object]
object
status
string
required
key
string
required
Start a configuration process
This endpoint allows you to start a configuration process at any time for your updated settings to take effect:
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Response
Response
{
"status": "scheduled",
"scheduled_time": "Tuesday, January 22 at 15:34 -0800",
"connection_services": [
{
"name": "git operations",
"number": 0
},
{
"name": "mysql queries",
"number": 233
},
{
"name": "aqueduct jobs",
"number": 34
},
{
"name": "resque jobs",
"number": 54
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
status
string
scheduled_time
string
connection_services
array[object]
object
name
string
required
number
int
required
Enable or disable maintenance mode
Note: The request body for this operation must be submitted as application/x-www-form-urlencoded
data. You can submit a parameter value as a string, or you can use a tool such as curl
to submit a parameter value as the contents of a text file. For more information, see the curl
documentation.
maintenance
string
required
A JSON string with the attributes enabled
and when
.
The possible values for enabled
are true
and false
. When it's false
, the attribute when
is ignored and the maintenance mode is turned off. when
defines the time period when the maintenance was enabled.
The possible values for when
are now
or any date parseable by mojombo/chronic.
Request
{
"maintenance": "{\"enabled\":true, \"when\":\"now\"}"
}
Response
Response
{
"status": "scheduled",
"scheduled_time": "Tuesday, January 22 at 15:34 -0800",
"connection_services": [
{
"name": "git operations",
"number": 0
},
{
"name": "mysql queries",
"number": 233
},
{
"name": "aqueduct jobs",
"number": 34
},
{
"name": "resque jobs",
"number": 54
}
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
status
string
scheduled_time
string
connection_services
array[object]
object
name
string
required
number
int
required
Get settings
Gets the settings for your instance. To change settings, see the Set settings endpoint.
Note: You cannot retrieve the management console password with the Enterprise administration API.
Response
Response
{
"enterprise": {
"private_mode": false,
"public_pages": false,
"subdomain_isolation": true,
"signup_enabled": false,
"github_hostname": "ghe.local",
"identicons_host": "dotcom",
"http_proxy": null,
"auth_mode": "default",
"expire_sessions": false,
"admin_password": null,
"configuration_id": 1401777404,
"configuration_run_count": 4,
"avatar": {
"enabled": false,
"uri": ""
},
"customer": {
"name": "GitHub",
"email": "stannis@themannis.biz",
"uuid": "af6cac80-e4e1-012e-d822-1231380e52e9",
"secret_key_data": "-----BEGIN PGP PRIVATE KEY BLOCK-----\nVersion: GnuPG v1.4.10 (GNU/Linux)\n\nlQcYBE5TCgsBEACk4yHpUcapplebaumBMXYMiLF+nCQ0lxpx...\n-----END PGP PRIVATE KEY BLOCK-----\n",
"public_key_data": "-----BEGIN PGP PUBLIC KEY BLOCK-----\nVersion: GnuPG v1.4.10 (GNU/Linux)\n\nmI0ETqzZYgEEALSe6snowdenXyqvLfSQ34HWD6C7....\n-----END PGP PUBLIC KEY BLOCK-----\n"
},
"license": {
"seats": 0,
"evaluation": false,
"perpetual": false,
"unlimited_seating": true,
"support_key": "ssh-rsa AAAAB3N....",
"ssh_allowed": true,
"cluster_support": false,
"expire_at": "2016-04-27T00:00:00-07:00"
},
"github_ssl": {
"enabled": false,
"cert": null,
"key": null
},
"ldap": {
"host": null,
"port": 0,
"base": [],
"uid": null,
"bind_dn": null,
"password": null,
"method": "Plain",
"search_strategy": "detect",
"user_groups": [],
"admin_group": null,
"virtual_attribute_enabled": false,
"recursive_group_search": false,
"posix_support": true,
"user_sync_emails": false,
"user_sync_keys": false,
"user_sync_interval": 4,
"team_sync_interval": 4,
"sync_enabled": false,
"reconciliation": {
"user": null,
"org": null
},
"profile": {
"uid": "uid",
"name": null,
"mail": null,
"key": null
}
},
"cas": {
"url": null
},
"saml": {
"sso_url": null,
"certificate": null,
"certificate_path": null,
"issuer": null,
"idp_initiated_sso": false,
"disable_admin_demote": false
},
"github_oauth": {
"client_id": "12313412",
"client_secret": "kj123131132",
"organization_name": "Homestar Runners",
"organization_team": "homestarrunners/characters"
},
"smtp": {
"enabled": true,
"address": "smtp.example.com",
"authentication": "plain",
"port": "1234",
"domain": "blah",
"username": "foo",
"user_name": "mr_foo",
"enable_starttls_auto": true,
"password": "bar",
"discard-to-noreply-address": true,
"support_address": "enterprise@github.com",
"support_address_type": "email",
"noreply_address": "noreply@github.com"
},
"ntp": {
"primary_server": "0.pool.ntp.org",
"secondary_server": "1.pool.ntp.org"
},
"timezone": null,
"snmp": {
"enabled": false,
"community": ""
},
"syslog": {
"enabled": false,
"server": null,
"protocol_name": "udp"
},
"assets": null,
"pages": {
"enabled": true
},
"collectd": {
"enabled": false,
"server": null,
"port": 0,
"encryption": null,
"username": null,
"password": null
},
"mapping": {
"enabled": true,
"tileserver": null,
"basemap": "company.map-qsz2zrvs",
"token": null
},
"load_balancer": null
},
"run_list": [
"recipe[enterprise-configure]"
]
}
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
enterprise
object (enterprise)
private_mode
boolean
public_pages
boolean
subdomain_isolation
boolean
signup_enabled
boolean
github_hostname
string
identicons_host
string
http_proxy
string or null
auth_mode
string
expire_sessions
boolean
admin_password
string or null
configuration_id
int
configuration_run_count
int
avatar
object (avatar)
enabled
boolean
uri
string
customer
object (customer)
name
string
string
uuid
string
secret_key_data
string
public_key_data
string
license
object (license)
seats
int
evaluation
boolean
perpetual
boolean
unlimited_seating
boolean
support_key
string
ssh_allowed
boolean
cluster_support
boolean
expire_at
string
github_ssl
object (github_ssl)
enabled
boolean
cert
string or null
key
string or null
ldap
object (ldap)
host
string or null
port
int
base
array[]
uid
string or null
bind_dn
string or null
password
string or null
method
string
search_strategy
string
user_groups
array[]
admin_group
string or null
virtual_attribute_enabled
boolean
recursive_group_search
boolean
posix_support
boolean
user_sync_emails
boolean
user_sync_keys
boolean
user_sync_interval
int
team_sync_interval
int
sync_enabled
boolean
reconciliation
object (reconciliation)
user
string or null
org
string or null
profile
object (profile)
uid
string
name
string or null
string or null
key
string or null
cas
object (cas)
url
string or null
saml
object (saml)
sso_url
string or null
certificate
string or null
certificate_path
string or null
issuer
string or null
idp_initiated_sso
boolean
disable_admin_demote
boolean
github_oauth
object (github_oauth)
client_id
string
client_secret
string
organization_name
string
organization_team
string
smtp
object (smtp)
enabled
boolean
address
string
authentication
string
port
string
domain
string
username
string
user_name
string
enable_starttls_auto
boolean
password
string
discard-to-noreply-address
boolean
support_address
string
support_address_type
string
noreply_address
string
ntp
object (ntp)
primary_server
string
secondary_server
string
timezone
string or null
snmp
object (snmp)
enabled
boolean
community
string
syslog
object (syslog)
enabled
boolean
server
string or null
protocol_name
string
assets
string or null
pages
object (pages)
enabled
boolean
collectd
object (collectd)
enabled
boolean
server
string or null
port
int
encryption
string or null
username
string or null
password
string or null
mapping
object (mapping)
enabled
boolean
tileserver
string or null
basemap
string
token
string or null
load_balancer
string or null
run_list
array[string]
string
Set settings
Applies settings on your instance. For a list of the available settings, see the Get settings endpoint.
Notes:
- The request body for this operation must be submitted as
application/x-www-form-urlencoded
data. You can submit a parameter value as a string, or you can use a tool such ascurl
to submit a parameter value as the contents of a text file. For more information, see thecurl
documentation. - You cannot set the management console password with the Enterprise administration API. Use the
ghe-set-password
utility to change the management console password. For more information, see "Command-line utilities."
settings
string
required
A JSON string with the new settings. Note that you only need to pass the specific settings you want to modify. For a list of the available settings, see the Get settings endpoint.
Request
{
"settings": "{ \"enterprise\": { \"public_pages\": true }}"
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Response
Response
[
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
},
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
},
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
key
string
pretty-print
string
Add an authorized SSH key
Note: The request body for this operation must be submitted as application/x-www-form-urlencoded
data. You can submit a parameter value as a string, or you can use a tool such as curl
to submit a parameter value as the contents of a text file. For more information, see the curl
documentation.
authorized_key
string
required
The public SSH key.
Request
{
"authorized_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQCssTL/Vtu/ODLTj0VtZoRAbvf7uiv5997GyDq0MoAZUjb5jmA5wYe2/wF6sFuhiZTnZoF1ZtCHunPp0hM/GHrn6VySBhNncx14YO8FPt1CIhEeRMSEjUK9cY3xAbS365oXY8vnUHJsS9+1tr/2bx/+4NJfcUt/Ezf1OR/0LStQXw=="
}
Response
Response
[
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
},
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
},
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
key
string
pretty-print
string
Remove an authorized SSH key
Note: The request body for this operation must be submitted as application/x-www-form-urlencoded
data. You can submit a parameter value as a string, or you can use a tool such as curl
to submit a parameter value as the contents of a text file. For more information, see the curl
documentation.
authorized_key
string
required
The public SSH key.
Request
{
"authorized_key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQCssTL/Vtu/ODLTj0VtZoRAbvf7uiv5997GyDq0MoAZUjb5jmA5wYe2/wF6sFuhiZTnZoF1ZtCHunPp0hM/GHrn6VySBhNncx14YO8FPt1CIhEeRMSEjUK9cY3xAbS365oXY8vnUHJsS9+1tr/2bx/+4NJfcUt/Ezf1OR/0LStQXw=="
}
Response
Response
[
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
},
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
},
{
"key": "ssh-rsa AAAAB3NzaC1yc2EAAAAB...",
"pretty-print": "ssh-rsa 01:14:0f:f2:0f:e2:fe:e8:f4:72:62:af:75:f7:1a:88:3e:04:92:64"
}
]
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
array[object]
- Content Type
- application/json
object
key
string
pretty-print
string
Create a GitHub license
When you boot a GitHub instance for the first time, you can use the following endpoint to upload a license.
Note that you need to POST
to /setup/api/configure
to start the actual configuration process.
When using this endpoint, your GitHub instance must have a password set. This can be accomplished two ways:
- If you're working directly with the API before accessing the web interface, you must pass in the password parameter to set your password.
- If you set up your instance via the web interface before accessing the API, your calls to this endpoint do not need the password parameter.
Note: The request body for this operation must be submitted as multipart/form-data
data. You can can reference the license file by prefixing the filename with the @
symbol using curl
. For more information, see the curl
documentation.
license
string
required
The content of your .ghl license file.
password
string
You must provide a password only if you are uploading your license for the first time. If you previously set a password through the web interface, you don't need this parameter.
settings
string
An optional JSON string containing the installation settings. For a list of the available settings, see the Get settings endpoint.
Request
{
"license": "@enterprise.ghl",
"password": "secret"
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Upgrade a license
This API upgrades your license and also triggers the configuration process.
Note: The request body for this operation must be submitted as multipart/form-data
data. You can can reference the license file by prefixing the filename with the @
symbol using curl
. For more information, see the curl
documentation.
license
string
The content of your new .ghl license file.
Request
{
"license": "@enterprise.ghl"
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Promote a user to be a site administrator
Note that you'll need to set Content-Length
to zero when calling out to this endpoint. For more information, see "HTTP verbs."
username
string
required
The handle for the GitHub user account.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Demote a site administrator
You can demote any user account except your own.
username
string
required
The handle for the GitHub user account.
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Suspend a user
If your GitHub instance uses LDAP Sync with Active Directory LDAP servers, Active Directory LDAP-authenticated users cannot be suspended through this API. If you attempt to suspend an Active Directory LDAP-authenticated user through this API, it will return a 403
response.
You can suspend any user account except your own.
Note that, if you choose not to pass any parameters, you'll need to set Content-Length
to zero when calling out to this endpoint. For more information, see "HTTP verbs."
reason
string
The reason the user is being suspended. This message will be logged in the audit log. If you don't provide a reason
, it will default to "Suspended via API by SITE_ADMINISTRATOR", where SITE_ADMINISTRATOR is the person who performed the action.
username
string
required
The handle for the GitHub user account.
Request
{
"reason": "Suspended during leave of absence."
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Unsuspend a user
If your GitHub instance uses LDAP Sync with Active Directory LDAP servers, this API is disabled and will return a 403
response. Active Directory LDAP-authenticated users cannot be unsuspended using the API.
reason
string
The reason the user is being unsuspended. This message will be logged in the audit log. If you don't provide a reason
, it will default to "Unsuspended via API by SITE_ADMINISTRATOR", where SITE_ADMINISTRATOR is the person who performed the action.
username
string
required
The handle for the GitHub user account.
Request
{
"reason": "Unsuspended after leave of absence."
}
Response
Response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
Empty response
No schema
Was this page helpful?