List organization members
List all users who are members of an organization. If the authenticated user is also a member of this organization then both concealed and public members will be returned.
Query Parameters
Filter members returned in the list. Can be one of:
* 2fa_disabled - Members without two-factor authentication enabled. Available for organization owners.
* all - All members the authenticated user can see.
Allowed values:2fa_disabledall
Default:all
Filter members returned by their role. Can be one of:
* all - All members of the organization, regardless of role.
* admin - Organization owners.
* member - Non-owner organization members.
Allowed values:alladminmember
Default:all
Results per page (max 100)
Default:30
Page number of the results to fetch.
Default:1
Path Parameters
Response
application/json
Response
Response
Simple User
Example:octocat
Example:1
Example:MDQ6VXNlcjE=
Example:https://github.com/images/error/octocat_happy.gif
Example:41d064eb2195891e12d0413f63227ea7
Example:https://api.github.com/users/octocat
Example:https://github.com/octocat
Example:https://api.github.com/users/octocat/followers
Example:https://api.github.com/users/octocat/following{/other_user}
Example:https://api.github.com/users/octocat/gists{/gist_id}
Example:https://api.github.com/users/octocat/starred{/owner}{/repo}
Example:https://api.github.com/users/octocat/subscriptions
Example:https://api.github.com/users/octocat/orgs
Example:https://api.github.com/users/octocat/repos
Example:https://api.github.com/users/octocat/events{/privacy}
Example:https://api.github.com/users/octocat/received_events
Example:User
Example:"2020-07-09T00:17:55Z"
Path Parameters
Query Parameters
Check organization membership for a user
Check if a user is, publicly or privately, a member of the organization.
Path Parameters
Response
Response
Response if requester is an organization member and user is a member
Path Parameters
Remove an organization member
Removing a user from this list will remove them from all teams and they will no longer have any access to the organization’s repositories.
Path Parameters
Response
Response
Response
Path Parameters
Get organization membership for a user
In order to get a user’s membership with an organization, the authenticated user must be an organization member. The state parameter in the response can be used to identify the user’s membership status.
Path Parameters
Response
application/json
Response
Response
Org Membership
Org Membership
Example:https://api.github.com/orgs/octocat/memberships/defunkt
The state of the member in the organization. The pending state indicates the user has not yet accepted an invitation.
Allowed values:activepending
Example:active
The user’s membership type in the organization.
Allowed values:adminmemberbilling_manager
Example:admin
Example:https://api.github.com/orgs/octocat
Organization Simple
Show Child Parameters
Simple User
Show Child Parameters
Show Child Parameters
Path Parameters
Set organization membership for a user
Only authenticated organization owners can add a member to the organization or update the member’s role.
-
If the authenticated user is adding a member to the organization, the invited user will receive an email inviting them to the organization. The user’s membership status will be
pendinguntil they accept the invitation. -
Authenticated users can update a user’s membership by passing the
roleparameter. If the authenticated user changes a member’s role toadmin, the affected user will receive an email notifying them that they’ve been made an organization owner. If the authenticated user changes an owner’s role tomember, no email will be sent.
Rate limits
To prevent abuse, the authenticated user is limited to 50 organization invitations per 24 hour period. If the organization is more than one month old or on a paid plan, the limit is 500 invitations per 24 hour period.
Path Parameters
Body
application/json
Body
The role to give the user in the organization. Can be one of:
* admin - The user will become an owner of the organization.
* member - The user will become a non-owner member of the organization.
Allowed values:adminmember
Default:member
Response
application/json
Response
Response
Org Membership
Org Membership
Example:https://api.github.com/orgs/octocat/memberships/defunkt
The state of the member in the organization. The pending state indicates the user has not yet accepted an invitation.
Allowed values:activepending
Example:active
The user’s membership type in the organization.
Allowed values:adminmemberbilling_manager
Example:admin
Example:https://api.github.com/orgs/octocat
Organization Simple
Show Child Parameters
Simple User