Skip to content

GitHub: Teams schemas

8 GitHub schemas with complete fields and constraints.

← Teams operations · All schemas

Check team permissions for a repository — response body — Team Repository

FieldTypePresenceDescription and constraints
$objectRootA team's access to a repository.
allow_auto_mergebooleanOptionalWhether to allow Auto-merge to be used on pull requests.
Default: false
allow_forkingbooleanOptionalWhether to allow forking this repo
Default: false
allow_merge_commitbooleanOptionalWhether to allow merge commits for pull requests.
Default: true
allow_rebase_mergebooleanOptionalWhether to allow rebase merges for pull requests.
Default: true
allow_squash_mergebooleanOptionalWhether to allow squash merges for pull requests.
Default: true
archive_urlstringRequired within parent
archivedbooleanRequired within parentWhether the repository is archived.
Default: false
assignees_urlstringRequired within parent
blobs_urlstringRequired within parent
branches_urlstringRequired within parent
clone_urlstringRequired within parent
collaborators_urlstringRequired within parent
comments_urlstringRequired within parent
commits_urlstringRequired within parent
compare_urlstringRequired within parent
contents_urlstringRequired within parent
contributors_urlstringRequired within parentFormat: uri
created_atJSONRequired within parent
created_at (anyOf 1)stringAlternativeFormat: date-time
created_at (anyOf 2)nullAlternative
default_branchstringRequired within parentThe default branch of the repository.
delete_branch_on_mergebooleanOptionalWhether to delete head branches when pull requests are merged
Default: false
deployments_urlstringRequired within parentFormat: uri
descriptionJSONRequired within parent
description (anyOf 1)stringAlternative
description (anyOf 2)nullAlternative
disabledbooleanRequired within parentReturns whether or not this repository disabled.
downloads_urlstringRequired within parentFormat: uri
events_urlstringRequired within parentFormat: uri
forkbooleanRequired within parent
forksJSONRequired within parent
forks (anyOf 1)integerAlternative
forks (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
forks_countJSONRequired within parent
forks_count (anyOf 1)integerAlternative
forks_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
forks_urlstringRequired within parentFormat: uri
full_namestringRequired within parent
git_commits_urlstringRequired within parent
git_refs_urlstringRequired within parent
git_tags_urlstringRequired within parent
git_urlstringRequired within parent
has_issuesbooleanRequired within parentWhether issues are enabled.
Default: true
has_pagesbooleanRequired within parent
has_projectsbooleanRequired within parentWhether projects are enabled.
Default: true
has_wikibooleanRequired within parentWhether the wiki is enabled.
Default: true
homepageJSONRequired within parent
homepage (anyOf 1)stringAlternativeFormat: uri
homepage (anyOf 2)nullAlternative
hooks_urlstringRequired within parentFormat: uri
html_urlstringRequired within parentFormat: uri
idJSONRequired within parent
id (anyOf 1)integerAlternativeUnique identifier of the repository
id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
is_templatebooleanOptionalWhether this repository acts as a template that can be used to generate new repositories.
Default: false
issue_comment_urlstringRequired within parent
issue_events_urlstringRequired within parent
issues_urlstringRequired within parent
keys_urlstringRequired within parent
labels_urlstringRequired within parent
languageJSONRequired within parent
language (anyOf 1)stringAlternative
language (anyOf 2)nullAlternative
languages_urlstringRequired within parentFormat: uri
licenseModelRequired within parentExpand Create a fork — response body — license
master_branchstringOptional
merges_urlstringRequired within parentFormat: uri
milestones_urlstringRequired within parent
mirror_urlJSONRequired within parent
mirror_url (anyOf 1)stringAlternativeFormat: uri
mirror_url (anyOf 2)nullAlternative
namestringRequired within parentThe name of the repository.
network_countJSONOptional
network_count (anyOf 1)integerAlternative
network_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
node_idstringRequired within parent
notifications_urlstringRequired within parent
open_issuesJSONRequired within parent
open_issues (anyOf 1)integerAlternative
open_issues (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
open_issues_countJSONRequired within parent
open_issues_count (anyOf 1)integerAlternative
open_issues_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
ownerModelRequired within parentExpand Get an issue — response body — user
permissionsobjectOptional
permissions.adminbooleanRequired within parent
permissions.maintainbooleanOptional
permissions.pullbooleanRequired within parent
permissions.pushbooleanRequired within parent
permissions.triagebooleanOptional
privatebooleanRequired within parentWhether the repository is private or public.
Default: false
pulls_urlstringRequired within parent
pushed_atJSONRequired within parent
pushed_at (anyOf 1)stringAlternativeFormat: date-time
pushed_at (anyOf 2)nullAlternative
releases_urlstringRequired within parent
role_namestringOptional
sizeJSONRequired within parent
size (anyOf 1)integerAlternative
size (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
ssh_urlstringRequired within parent
stargazers_countJSONRequired within parent
stargazers_count (anyOf 1)integerAlternative
stargazers_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
stargazers_urlstringRequired within parentFormat: uri
statuses_urlstringRequired within parent
subscribers_countJSONOptional
subscribers_count (anyOf 1)integerAlternative
subscribers_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
subscribers_urlstringRequired within parentFormat: uri
subscription_urlstringRequired within parentFormat: uri
svn_urlstringRequired within parentFormat: uri
tags_urlstringRequired within parentFormat: uri
teams_urlstringRequired within parentFormat: uri
temp_clone_tokenstringOptionalWhen present and non-empty, a temporary credential for read-only Git access to this repository.
It expires five minutes after generation and cannot be used to push changes.
Treat this value as sensitive and avoid recording it in logs.
topicsarrayOptional
topics[]stringEach item
trees_urlstringRequired within parent
updated_atJSONRequired within parent
updated_at (anyOf 1)stringAlternativeFormat: date-time
updated_at (anyOf 2)nullAlternative
urlstringRequired within parentFormat: uri
visibilitystringOptionalThe repository visibility: public, private, or internal.
Default: public
watchersJSONRequired within parent
watchers (anyOf 1)integerAlternative
watchers (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
watchers_countJSONRequired within parent
watchers_count (anyOf 1)integerAlternative
watchers_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
web_commit_signoff_requiredbooleanOptionalWhether to require contributors to sign off on web-based commits
Default: false

Referenced models: Create a fork — response body — license, Get an issue — response body — user

Create a team — response body

FieldTypePresenceDescription and constraints
$objectRootGroups of organization members that gives permissions on specified repositories.
created_atstringRequired within parentFormat: date-time
descriptionJSONRequired within parent
description (anyOf 1)stringAlternative
description (anyOf 2)nullAlternative
enterprise_idJSONOptional
enterprise_id (anyOf 1)integerAlternativeUnique identifier of the enterprise to which this team belongs
enterprise_id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
html_urlstringRequired within parentFormat: uri
idJSONRequired within parent
id (anyOf 1)integerAlternativeUnique identifier of the team
id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
ldap_dnstringOptionalThe [distinguished name](https://www.ldap.com/ldap-dns-and-rdns) (DN) of the LDAP entry to map to a team.
members_countJSONRequired within parent
members_count (anyOf 1)integerAlternative
members_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
members_urlstringRequired within parent
namestringRequired within parentName of the team
node_idstringRequired within parent
notification_settingstringOptionalThe notification setting the team has set
Known values: notifications_enabled, notifications_disabled
organizationModelRequired within parentExpand Create a team — response body — organization
organization_idJSONOptional
organization_id (anyOf 1)integerAlternativeUnique identifier of the organization to which this team belongs
organization_id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
parentModelOptionalExpand Create a team — response body — parent
permissionstringRequired within parentPermission that the team will have for its repositories
privacystringOptionalThe level of privacy this team should have
Known values: closed, secret
repos_countJSONRequired within parent
repos_count (anyOf 1)integerAlternative
repos_count (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
repositories_urlstringRequired within parentFormat: uri
slugstringRequired within parent
typestringRequired within parentThe ownership type of the team
Known values: enterprise, organization
updated_atstringRequired within parentFormat: date-time
urlstringRequired within parentURL for the team
Format: uri

Referenced models: Create a team — response body — parent, Create a team — response body — organization

Create a team — response body — organization

FieldTypePresenceDescription and constraints
$objectRootTeam Organization
archived_atJSONRequired within parent
archived_at (anyOf 1)stringAlternativeFormat: date-time
archived_at (anyOf 2)nullAlternative
avatar_urlstringRequired within parent
billing_emailJSONOptional
billing_email (anyOf 1)stringAlternativeFormat: email
billing_email (anyOf 2)nullAlternative
blogJSONOptional
blog (anyOf 1)stringAlternativeFormat: uri
blog (anyOf 2)nullAlternative
collaboratorsJSONOptional
collaborators (anyOf 1)JSONAlternative
collaborators (anyOf 1) (anyOf 1)integerAlternative
collaborators (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
collaborators (anyOf 2)nullAlternative
companyJSONOptional
company (anyOf 1)stringAlternative
company (anyOf 2)nullAlternative
created_atstringRequired within parentFormat: date-time
default_repository_permissionJSONOptional
default_repository_permission (anyOf 1)stringAlternative
default_repository_permission (anyOf 2)nullAlternative
descriptionJSONRequired within parent
description (anyOf 1)stringAlternative
description (anyOf 2)nullAlternative
disk_usageJSONOptional
disk_usage (anyOf 1)JSONAlternative
disk_usage (anyOf 1) (anyOf 1)integerAlternative
disk_usage (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
disk_usage (anyOf 2)nullAlternative
emailJSONOptional
email (anyOf 1)stringAlternativeFormat: email
email (anyOf 2)nullAlternative
events_urlstringRequired within parentFormat: uri
followersJSONRequired within parent
followers (anyOf 1)integerAlternative
followers (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
followingJSONRequired within parent
following (anyOf 1)integerAlternative
following (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
has_organization_projectsbooleanRequired within parent
has_repository_projectsbooleanRequired within parent
hooks_urlstringRequired within parent
html_urlstringRequired within parentFormat: uri
idJSONRequired within parent
id (anyOf 1)integerAlternative
id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
is_verifiedbooleanOptional
issues_urlstringRequired within parent
locationJSONOptional
location (anyOf 1)stringAlternative
location (anyOf 2)nullAlternative
loginstringRequired within parent
members_allowed_repository_creation_typestringOptional
members_can_create_internal_repositoriesbooleanOptional
members_can_create_pagesbooleanOptional
members_can_create_private_pagesbooleanOptional
members_can_create_private_repositoriesbooleanOptional
members_can_create_public_pagesbooleanOptional
members_can_create_public_repositoriesbooleanOptional
members_can_create_repositoriesJSONOptional
members_can_create_repositories (anyOf 1)booleanAlternative
members_can_create_repositories (anyOf 2)nullAlternative
members_can_fork_private_repositoriesJSONOptional
members_can_fork_private_repositories (anyOf 1)booleanAlternative
members_can_fork_private_repositories (anyOf 2)nullAlternative
members_urlstringRequired within parent
namestringOptional
node_idstringRequired within parent
owned_private_reposJSONOptional
owned_private_repos (anyOf 1)integerAlternative
owned_private_repos (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
planModelOptionalExpand Get an organization — response body — plan
private_gistsJSONOptional
private_gists (anyOf 1)JSONAlternative
private_gists (anyOf 1) (anyOf 1)integerAlternative
private_gists (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
private_gists (anyOf 2)nullAlternative
public_gistsJSONRequired within parent
public_gists (anyOf 1)integerAlternative
public_gists (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
public_members_urlstringRequired within parent
public_reposJSONRequired within parent
public_repos (anyOf 1)integerAlternative
public_repos (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
repos_urlstringRequired within parentFormat: uri
total_private_reposJSONOptional
total_private_repos (anyOf 1)integerAlternative
total_private_repos (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
twitter_usernameJSONOptional
twitter_username (anyOf 1)stringAlternative
twitter_username (anyOf 2)nullAlternative
two_factor_requirement_enabledJSONOptional
two_factor_requirement_enabled (anyOf 1)booleanAlternative
two_factor_requirement_enabled (anyOf 2)nullAlternative
typestringRequired within parent
updated_atstringRequired within parentFormat: date-time
urlstringRequired within parentFormat: uri
web_commit_signoff_requiredbooleanOptional

Referenced models: Get an organization — response body — plan

Create a team — response body — parent

FieldTypePresenceDescription and constraints
$JSONRoot
$ (anyOf 1)ModelAlternativeExpand Create a team — response body — parent / type: enterprise, organization
$ (anyOf 2)nullAlternative

Referenced models: Create a team — response body — parent / type: enterprise, organization

Create a team — response body — parent / type: enterprise, organization

FieldTypePresenceDescription and constraints
$objectRootGroups of organization members that gives permissions on specified repositories.
descriptionJSONRequired within parent
description (anyOf 1)stringAlternativeDescription of the team
description (anyOf 2)nullAlternative
enterprise_idJSONOptional
enterprise_id (anyOf 1)integerAlternativeUnique identifier of the enterprise to which this team belongs
enterprise_id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
html_urlstringRequired within parentFormat: uri
idJSONRequired within parent
id (anyOf 1)integerAlternativeUnique identifier of the team
id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
ldap_dnstringOptionalDistinguished Name (DN) that team maps to within LDAP environment
members_urlstringRequired within parent
namestringRequired within parentName of the team
node_idstringRequired within parent
notification_settingstringOptionalThe notification setting the team has set
organization_idJSONOptional
organization_id (anyOf 1)integerAlternativeUnique identifier of the organization to which this team belongs
organization_id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
permissionstringRequired within parentPermission that the team will have for its repositories
privacystringOptionalThe level of privacy this team should have
repositories_urlstringRequired within parentFormat: uri
slugstringRequired within parent
typestringRequired within parentThe ownership type of the team
Known values: enterprise, organization
urlstringRequired within parentURL for the team
Format: uri

Get team membership for a user — response body

FieldTypePresenceDescription and constraints
$objectRootTeam Membership
rolestringRequired within parentThe role of the user in the team.
Known values: member, maintainer
Default: member
statestringRequired within parentThe state of the user's membership in the team.
Known values: active, pending
urlstringRequired within parentFormat: uri

List team members — response body — item

FieldTypePresenceDescription and constraints
$objectRootA user that is a member of a team, including their role on the team and whether the membership is inherited from a child team.
avatar_urlstringRequired within parentFormat: uri
emailJSONOptional
email (anyOf 1)stringAlternative
email (anyOf 2)nullAlternative
events_urlstringRequired within parent
followers_urlstringRequired within parentFormat: uri
following_urlstringRequired within parent
gists_urlstringRequired within parent
gravatar_idJSONRequired within parent
gravatar_id (anyOf 1)stringAlternative
gravatar_id (anyOf 2)nullAlternative
html_urlstringRequired within parentFormat: uri
idJSONRequired within parent
id (anyOf 1)integerAlternativeFormat: int64
id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
inheritedbooleanOptionalWhether the user is a member of the team only through a child team. `true` means the membership is inherited from a child team; `false` means the user is a direct (immediate) member of the team. Only present on the `List team members` endpoint, and only when the feature is enabled for the organization.
loginstringRequired within parent
nameJSONOptional
name (anyOf 1)stringAlternative
name (anyOf 2)nullAlternative
node_idstringRequired within parent
organizations_urlstringRequired within parentFormat: uri
received_events_urlstringRequired within parentFormat: uri
repos_urlstringRequired within parentFormat: uri
rolestringOptionalThe member's role on the team. Only present on the `List team members` endpoint, and only when the feature is enabled for the organization.
Known values: member, maintainer
site_adminbooleanRequired within parent
starred_atstringOptional
starred_urlstringRequired within parent
subscriptions_urlstringRequired within parentFormat: uri
typestringRequired within parent
urlstringRequired within parentFormat: uri
user_view_typestringOptional

List teams — response body — item

FieldTypePresenceDescription and constraints
$objectRootGroups of organization members that gives permissions on specified repositories.
access_sourcestringOptionalHow the team's access to the repository was granted. This property is only
present when the team is returned in a repository context, such as
`GET /repos/{owner}/{repo}/teams`.
Known values: direct, organization, enterprise
descriptionJSONRequired within parent
description (anyOf 1)stringAlternative
description (anyOf 2)nullAlternative
enterprise_idJSONOptional
enterprise_id (anyOf 1)integerAlternativeUnique identifier of the enterprise to which this team belongs
enterprise_id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
html_urlstringRequired within parentFormat: uri
idJSONRequired within parent
id (anyOf 1)integerAlternative
id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
members_urlstringRequired within parent
namestringRequired within parent
node_idstringRequired within parent
notification_settingstringOptional
organization_idJSONOptional
organization_id (anyOf 1)integerAlternativeUnique identifier of the organization to which this team belongs
organization_id (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
parentModelRequired within parentExpand Create a team — response body — parent
permissionstringRequired within parent
permissionsobjectOptional
permissions.adminbooleanRequired within parent
permissions.maintainbooleanRequired within parent
permissions.pullbooleanRequired within parent
permissions.pushbooleanRequired within parent
permissions.triagebooleanRequired within parent
privacystringOptional
repositories_urlstringRequired within parentFormat: uri
slugstringRequired within parent
typestringRequired within parentThe ownership type of the team
Known values: enterprise, organization
urlstringRequired within parentFormat: uri

Referenced models: Create a team — response body — parent

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand which product and documentation features are useful.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

You can change these choices at any time from Cookie settings.