Organizations
- Git course
- Expert
- Lesson 23/32
- 4 min
Learn organization management.
What are GitHub Organizations?
A GitHub Organization allows multiple people to manage projects under a shared structure. Organizations are used to centrally manage repositories, members, and teams.
Organization
├── Team: frontend
├── Team: backend
└── RepositoriesOrganization owners can manage member roles and repository access permissions.
Teams and members
Teams within an organization group members according to specific responsibilities. For example, the frontend team can access web interface repositories while the backend team can access server repositories.
GET /orgs/{org}/teams
GET /orgs/{org}/membersYou can list teams and organization members through the REST API. Your token must have permission to access the relevant organization data.
Practice List organization teams
Send a GET request to list the teams of the my-company organization. Specify the JSON response type expected by the GitHub API in the request header. Also print the HTTP response status code.
Starter code
# Organizasyon ekiplerini listele
# HTTP durum kodunu gösterSample solution
curl -sS -o /dev/null -w "%{http_code}
" -X GET -H "Accept: application/vnd.github+json" https://api.github.com/orgs/my-company/teamsExpected output
200
Questions and answers
Review the lesson questions together with their answers. To test yourself, solve the lesson interactively.
1 You want to organize a company's developers into teams and grant shared repository access. Which GitHub structure provides this management?
- Release
- Personal account
- Organization Correct answer
- Gist
Explanation: An Organization centrally manages members and teams, allowing shared access to repositories.
2 Complete the organization teams endpoint
GET /orgs/{org}/teams____
GET /orgs/{org}/teamsteams
Explanation: The <code>/orgs/{org}/teams</code> endpoint is used to list teams in an organization.
3 Organization management
| Term | Meaning |
|---|---|
Organization |
Shared management space |
Team |
Represents a specific task group |
Member |
User who belongs to the organization |
Owner |
Role with management permissions |