GET
/orgs/{org}/organization-roles/{role_id}Get an organization role
Gets an organization role that is available to this organization. For more information on organization roles, see "Using organization roles."
To use this endpoint, the authenticated user must be one of:
- An administrator for the organization.
- An organization member (or a member of a team) assigned a custom organization role that includes the View organization roles (
read_organization_custom_org_role) permission. For more information, see "Permissions for organization access."
OAuth app tokens and personal access tokens (classic) need the admin:org scope to use this endpoint.
- RetriesRetries up to 2×, 500ms backoff, 30s timeout.
orgstringrequired
The organization name. The name is not case sensitive.
role_idintegerrequired
The unique identifier of the role.
200Response
idintegerrequired
The unique identifier of the role.
namestringrequired
The name of the role.
descriptionstringoptional
A short description about who this role is for or what permissions it grants.
base_rolestringoptional
The system role from which this role inherits permissions.
sourcestringoptional
Source answers the question, "where did this role come from?"
permissionsarray<string>required
A list of permissions included in this role.
organizationobjectrequired
A GitHub user.
created_atstringrequired
The date and time the role was created.
updated_atstringrequired
The date and time the role was last updated.
404Resource not found
messagestringoptional
documentation_urlstringoptional
urlstringoptional
statusstringoptional
422Validation failed, or the endpoint has been spammed.
messagestringrequired
documentation_urlstringrequired
errorsarray<object>optional
Error handling
A 404 is returned: Resource not found. A 422 is returned: Validation failed, or the endpoint has been spammed.