team_slug parameter
Check team permissions for a project
Checks whether a team has read
, write
, or admin
permissions for an organization project. The response includes projects inherited from a parent team.
Note: You can also specify a team by org_id
and team_id
using the route GET /organizations/{org_id}/team/{team_id}/projects/{project_id}
.
Path Parameters
Response
application/json
Response
Response
Team Project
A team’s access to a project.
Simple User
Show Child Parameters
The organization permission for this project. Only present when owner is an organization.
Whether the project is private or not. Only present when owner is an organization.
Show Child Parameters
Path Parameters
Add or update team project permissions
Adds an organization project to a team. To add a project to a team or update the team’s permission on a project, the authenticated user must have admin
permissions for the project. The project and team must be part of the same organization.
Note: You can also specify a team by org_id
and team_id
using the route PUT /organizations/{org_id}/team/{team_id}/projects/{project_id}
.
Path Parameters
team_slug parameter
Body
application/json
Body
The permission to grant to the team for this project. Can be one of:
* read
- team members can read, but not write to or administer this project.
* write
- team members can read and write, but not administer this project.
* admin
- team members can read, write and administer this project.
Default: the team’s permission
attribute will be used to determine what permission to grant the team on this project. 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.”
Allowed values:readwriteadmin
Response
Response
Response
Path Parameters
Body
Remove a project from a team
Removes an organization project from a team. An organization owner or a team maintainer can remove any project from the team. To remove a project from a team as an organization member, the authenticated user must have read
access to both the team and project, or admin
access to the team or project. This endpoint removes the project from the team, but does not delete the project.
Note: You can also specify a team by org_id
and team_id
using the route DELETE /organizations/{org_id}/team/{team_id}/projects/{project_id}
.
Path Parameters
team_slug parameter
Response
204
Response
Response
Path Parameters
List team repositories
Lists a team’s repositories visible to the authenticated user.
Note: You can also specify a team by org_id
and team_id
using the route GET /organizations/{org_id}/team/{team_id}/repos
.
Query Parameters
Results per page (max 100)
Default:30
Page number of the results to fetch.
Default:1
Path Parameters
team_slug parameter
Response
200 application/json
Response
Response
Minimal Repository
Example:1296269
Example:MDEwOlJlcG9zaXRvcnkxMjk2MjY5
Example:Hello-World
Example:octocat/Hello-World
Simple User
Show Child Parameters
Example:https://github.com/octocat/Hello-World
Example:This your first repo!
Example:https://api.github.com/repos/octocat/Hello-World
Example:http://api.github.com/repos/octocat/Hello-World/{archive_format}{/ref}
Example:http://api.github.com/repos/octocat/Hello-World/assignees{/user}
Example:http://api.github.com/repos/octocat/Hello-World/git/blobs{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/branches{/branch}
Example:http://api.github.com/repos/octocat/Hello-World/collaborators{/collaborator}
Example:http://api.github.com/repos/octocat/Hello-World/comments{/number}
Example:http://api.github.com/repos/octocat/Hello-World/commits{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/compare/{base}...{head}
Example:http://api.github.com/repos/octocat/Hello-World/contents/{+path}
Example:http://api.github.com/repos/octocat/Hello-World/contributors
Example:http://api.github.com/repos/octocat/Hello-World/deployments
Example:http://api.github.com/repos/octocat/Hello-World/downloads
Example:http://api.github.com/repos/octocat/Hello-World/events
Example:http://api.github.com/repos/octocat/Hello-World/forks
Example:http://api.github.com/repos/octocat/Hello-World/git/commits{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/git/refs{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/git/tags{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/issues/comments{/number}
Example:http://api.github.com/repos/octocat/Hello-World/issues/events{/number}
Example:http://api.github.com/repos/octocat/Hello-World/issues{/number}
Example:http://api.github.com/repos/octocat/Hello-World/keys{/key_id}
Example:http://api.github.com/repos/octocat/Hello-World/labels{/name}
Example:http://api.github.com/repos/octocat/Hello-World/languages
Example:http://api.github.com/repos/octocat/Hello-World/merges
Example:http://api.github.com/repos/octocat/Hello-World/milestones{/number}
Example:http://api.github.com/repos/octocat/Hello-World/notifications{?since,all,participating}
Example:http://api.github.com/repos/octocat/Hello-World/pulls{/number}
Example:http://api.github.com/repos/octocat/Hello-World/releases{/id}
Example:http://api.github.com/repos/octocat/Hello-World/stargazers
Example:http://api.github.com/repos/octocat/Hello-World/statuses/{sha}
Example:http://api.github.com/repos/octocat/Hello-World/subscribers
Example:http://api.github.com/repos/octocat/Hello-World/subscription
Example:http://api.github.com/repos/octocat/Hello-World/tags
Example:http://api.github.com/repos/octocat/Hello-World/teams
Example:http://api.github.com/repos/octocat/Hello-World/git/trees{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/hooks
Example:2011-01-26T19:06:43Z
Example:2011-01-26T19:01:12Z
Example:2011-01-26T19:14:43Z
Show Child Parameters
A git repository
Show Child Parameters
Code Of Conduct
Show Child Parameters
Show Child Parameters
Example:0
Example:0
Example:0
Path Parameters
Query Parameters
Check team permissions for a repository
Checks whether a team has admin
, push
, maintain
, triage
, or pull
permission for a repository. Repositories inherited through a parent team will also be checked.
You can also get information about the specified repository, including what permissions the team grants on it, by passing the following custom media type via the application/vnd.github.v3.repository+json
accept header.
If a team doesn’t have permission for the repository, you will receive a 404 Not Found
response status.
Note: You can also specify a team by org_id
and team_id
using the route GET /organizations/{org_id}/team/{team_id}/repos/{owner}/{repo}
.
Path Parameters
team_slug parameter
Response
application/json
Response
Alternative response with repository permissions
Team Repository
A team’s access to a repository.
Unique identifier of the repository
Example:42
Example:MDEwOlJlcG9zaXRvcnkxMjk2MjY5
The name of the repository.
Example:Team Environment
Example:octocat/Hello-World
License Simple
Show Child Parameters
Show Child Parameters
Simple User
Show Child Parameters
Whether the repository is private or public.
Default:false
Example:https://github.com/octocat/Hello-World
Example:This your first repo!
Example:https://api.github.com/repos/octocat/Hello-World
Example:http://api.github.com/repos/octocat/Hello-World/{archive_format}{/ref}
Example:http://api.github.com/repos/octocat/Hello-World/assignees{/user}
Example:http://api.github.com/repos/octocat/Hello-World/git/blobs{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/branches{/branch}
Example:http://api.github.com/repos/octocat/Hello-World/collaborators{/collaborator}
Example:http://api.github.com/repos/octocat/Hello-World/comments{/number}
Example:http://api.github.com/repos/octocat/Hello-World/commits{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/compare/{base}...{head}
Example:http://api.github.com/repos/octocat/Hello-World/contents/{+path}
Example:http://api.github.com/repos/octocat/Hello-World/contributors
Example:http://api.github.com/repos/octocat/Hello-World/deployments
Example:http://api.github.com/repos/octocat/Hello-World/downloads
Example:http://api.github.com/repos/octocat/Hello-World/events
Example:http://api.github.com/repos/octocat/Hello-World/forks
Example:http://api.github.com/repos/octocat/Hello-World/git/commits{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/git/refs{/sha}
Example:http://api.github.com/repos/octocat/Hello-World/git/tags{/sha}
Example:git:github.com/octocat/Hello-World.git
Example:http://api.github.com/repos/octocat/Hello-World/issues/comments{/number}
Example:http://api.github.com/repos/octocat/Hello-World/issues/events{/number}
Example:http://api.github.com/repos/octocat/Hello-World/issues{/number}
Example:http://api.github.com/repos/octocat/Hello-World/keys{/key_id}
Example:http://api.github.com/repos/octocat/Hello-World/labels{/name}
Example:http://api.github.com/repos/octocat/Hello-World/languages
Example:http://api.github.com/repos/octocat/Hello-World/merges
Example:http://api.github.com/repos/octocat/Hello-World/milestones{/number}
Example:http://api.github.com/repos/octocat/Hello-World/notifications{?since,all,participating}
Example:http://api.github.com/repos/octocat/Hello-World/pulls{/number}
Example:http://api.github.com/repos/octocat/Hello-World/releases{/id}
Example:git@github.com:octocat/Hello-World.git
Example:http://api.github.com/repos/octocat/Hello-World/stargazers
Example:http://api.github.com/repos/octocat/Hello-World/statuses/{sha}
Example:http://api.github.com/repos/octocat/Hello-World/subscribers
Example:http://api.github.com/repos/octocat/Hello-World/subscription
Example:http://api.github.com/repos/octocat/Hello-World/tags
Example:http://api.github.com/repos/octocat/Hello-World/teams
Example:http://api.github.com/repos/octocat/Hello-World/git/trees{/sha}
Example:https://github.com/octocat/Hello-World.git
Example:git:git.example.com/octocat/Hello-World
Example:http://api.github.com/repos/octocat/Hello-World/hooks
Example:https://svn.github.com/octocat/Hello-World
Example:https://github.com
Example:9
Example:80
Example:80
Example:108
The default branch of the repository.
Example:master
Example:0
Whether this repository acts as a template that can be used to generate new repositories.
Default:false
Example:true
Whether issues are enabled.
Default:true
Example:true
Whether projects are enabled.
Default:true
Example:true
Whether the wiki is enabled.
Default:true
Example:true
Whether downloads are enabled.
Default:true
Example:true
Whether the repository is archived.
Default:false
Returns whether or not this repository disabled.
The repository visibility: public, private, or internal.
Default:public
Example:2011-01-26T19:06:43Z
Example:2011-01-26T19:01:12Z
Example:2011-01-26T19:14:43Z
Whether to allow rebase merges for pull requests.
Default:true
Example:true
A git repository
Show Child Parameters
Whether to allow squash merges for pull requests.
Default:true
Example:true
Whether to delete head branches when pull requests are merged
Default:false
Example:false
Whether to allow merge commits for pull requests.
Default:true
Example:true
Whether to allow forking this repo
Default:false
Example:false