v56

latestOpenAPI 3.0.3MITraw.githubusercontent.com2026-08-011,21696712.2 MB
teams

List team members (Legacy)

[!WARNING] Endpoint closing down notice: This endpoint route is closing down and will be removed from the Teams API. We recommend migrating your existing code to use the new List team members endpoint.

Team members will include the members of child teams.

Each member includes their role on the team (member or maintainer) and an inherited flag indicating whether the membership is inherited from a child team (true) or is a direct membership (false).

get/teams/{team_id}/members

Path parameters

team_idinteger required

The unique identifier of the team.

Query parameters

role'member' | 'maintainer' | 'all'

Filters members returned by their role in the team.

per_pageinteger

The number of results per page (max 100). For more information, see "Using pagination in the REST API."

pageinteger

The page number of the results to fetch. For more information, see "Using pagination in the REST API."

Response

Response

namestring nullable
emailstring nullable
loginstring required
idinteger required
node_idstring required
avatar_urlstring uri required
gravatar_idstring nullable required
urlstring uri required
html_urlstring uri required
followers_urlstring uri required
following_urlstring required
gists_urlstring required
starred_urlstring required
subscriptions_urlstring uri required
organizations_urlstring uri required
repos_urlstring uri required
events_urlstring required
received_events_urlstring uri required
typestring required
site_adminboolean required
starred_atstring
user_view_typestring
role'member' | 'maintainer'

The member's role on the team. Only present on the List team members endpoint, and only when the feature is enabled for the organization.

inheritedboolean

Whether 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.

Example response

[
  {
    "login": "octocat",
    "id": 1,
    "node_id": "MDQ6VXNlcjE=",
    "avatar_url": "https://github.com/images/error/octocat_happy.gif",
    "gravatar_id": "41d064eb2195891e12d0413f63227ea7",
    "url": "https://api.github.com/users/octocat",
    "html_url": "https://github.com/octocat",
    "followers_url": "https://api.github.com/users/octocat/followers",
    "following_url": "https://api.github.com/users/octocat/following{/other_user}",
    "gists_url": "https://api.github.com/users/octocat/gists{/gist_id}",
    "starred_url": "https://api.github.com/users/octocat/starred{/owner}{/repo}",
    "subscriptions_url": "https://api.github.com/users/octocat/subscriptions",
    "organizations_url": "https://api.github.com/users/octocat/orgs",
    "repos_url": "https://api.github.com/users/octocat/repos",
    "events_url": "https://api.github.com/users/octocat/events{/privacy}",
    "received_events_url": "https://api.github.com/users/octocat/received_events",
    "type": "User",
    "starred_at": "\"2020-07-09T00:17:55Z\"",
    "user_view_type": "public",
    "role": "member"
  }
]