v50

latestOpenAPI 3.0.3MITraw.githubusercontent.com2024-03-2585861610.1 MB
orgs

Get an organization

Gets information about an organization.

When the value of two_factor_requirement_enabled is true, the organization requires all members, billing managers, and outside collaborators to enable two-factor authentication.

To see the full details about an organization, the authenticated user must be an organization owner.

OAuth app tokens and personal access tokens (classic) need the admin:org scope to see the full details about an organization.

To see information about an organization's GitHub Enterprise Server plan, GitHub Apps need the Organization plan permission.

get/orgs/{org}

Path parameters

orgstring required

The organization name. The name is not case sensitive.

Response

Response

loginstring required
idinteger required
node_idstring required
urlstring uri required
repos_urlstring uri required
events_urlstring uri required
hooks_urlstring required
issues_urlstring required
members_urlstring required
public_members_urlstring required
avatar_urlstring required
descriptionstring nullable required
namestring
companystring
blogstring uri
locationstring
emailstring email
twitter_usernamestring nullable
is_verifiedboolean
has_organization_projectsboolean required
has_repository_projectsboolean required
public_reposinteger required
public_gistsinteger required
followersinteger required
followinginteger required
html_urlstring uri required
typestring required
total_private_reposinteger
owned_private_reposinteger
private_gistsinteger nullable
disk_usageinteger nullable
collaboratorsinteger nullable
billing_emailstring email nullable
default_repository_permissionstring nullable
members_can_create_repositoriesboolean nullable
two_factor_requirement_enabledboolean nullable
members_allowed_repository_creation_typestring
members_can_create_public_repositoriesboolean
members_can_create_private_repositoriesboolean
members_can_create_internal_repositoriesboolean
members_can_create_pagesboolean
members_can_create_public_pagesboolean
members_can_create_private_pagesboolean
members_can_fork_private_repositoriesboolean nullable
web_commit_signoff_requiredboolean
advanced_security_enabled_for_new_repositoriesboolean

Whether GitHub Advanced Security is enabled for new repositories and repositories transferred to this organization.

This field is only visible to organization owners or members of a team with the security manager role.

dependabot_alerts_enabled_for_new_repositoriesboolean

Whether GitHub Advanced Security is automatically enabled for new repositories and repositories transferred to this organization.

This field is only visible to organization owners or members of a team with the security manager role.

dependabot_security_updates_enabled_for_new_repositoriesboolean

Whether dependabot security updates are automatically enabled for new repositories and repositories transferred to this organization.

This field is only visible to organization owners or members of a team with the security manager role.

dependency_graph_enabled_for_new_repositoriesboolean

Whether dependency graph is automatically enabled for new repositories and repositories transferred to this organization.

This field is only visible to organization owners or members of a team with the security manager role.

secret_scanning_enabled_for_new_repositoriesboolean

Whether secret scanning is automatically enabled for new repositories and repositories transferred to this organization.

This field is only visible to organization owners or members of a team with the security manager role.

secret_scanning_push_protection_enabled_for_new_repositoriesboolean

Whether secret scanning push protection is automatically enabled for new repositories and repositories transferred to this organization.

This field is only visible to organization owners or members of a team with the security manager role.

secret_scanning_push_protection_custom_link_enabledboolean

Whether a custom link is shown to contributors who are blocked from pushing a secret by push protection.

secret_scanning_push_protection_custom_linkstring nullable

An optional URL string to display to contributors who are blocked from pushing a secret.

created_atstring date-time required
updated_atstring date-time required

Example 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",
  "name": "github",
  "company": "GitHub",
  "blog": "https://github.com/blog",
  "location": "San Francisco",
  "email": "octocat@github.com",
  "twitter_username": "github",
  "is_verified": true,
  "has_organization_projects": true,
  "has_repository_projects": true,
  "public_repos": 2,
  "public_gists": 1,
  "followers": 20,
  "html_url": "https://github.com/octocat",
  "type": "Organization",
  "total_private_repos": 100,
  "owned_private_repos": 100,
  "private_gists": 81,
  "disk_usage": 10000,
  "collaborators": 8,
  "billing_email": "org@example.com",
  "members_can_create_repositories": true,
  "two_factor_requirement_enabled": true,
  "members_allowed_repository_creation_type": "all",
  "members_can_create_public_repositories": true,
  "members_can_create_private_repositories": true,
  "members_can_create_internal_repositories": true,
  "members_can_create_pages": true,
  "members_can_create_public_pages": true,
  "members_can_create_private_pages": true,
  "secret_scanning_push_protection_custom_link": "https://github.com/test-org/test-repo/blob/main/README.md",
  "created_at": "2008-01-14T04:33:35Z"
}