@@ -69,10 +69,14 @@ type User struct {
6969 // See: search.go and https://docs.github.com/rest/search?apiVersion=2022-11-28#text-match-metadata
7070 TextMatches []* TextMatch `json:"text_matches,omitempty"`
7171
72- // Permissions and RoleName identify the permissions and role that a user has on a given
73- // repository. These are only populated when calling Repositories.ListCollaborators.
72+ // Permissions identify the permissions that a user has on a given
73+ // repository.
74+ // This is only populated when calling [RepositoriesService.ListCollaborators].
7475 Permissions * RepositoryPermissions `json:"permissions,omitempty"`
75- RoleName * string `json:"role_name,omitempty"`
76+
77+ // RoleName identifies the role that a user has on a given repository.
78+ // This is only populated when calling [RepositoriesService.ListCollaborators].
79+ RoleName * string `json:"role_name,omitempty"`
7680
7781 // Assignment identifies how a user was assigned to an organization role. Its
7882 // possible values are: "direct", "indirect", "mixed". This is only populated when
@@ -81,6 +85,20 @@ type User struct {
8185 // InheritedFrom identifies the team that a user inherited their organization role
8286 // from. This is only populated when calling the ListUsersAssignedToOrgRole method.
8387 InheritedFrom []* Team `json:"inherited_from,omitempty"`
88+
89+ // Role identifies the role that a user has on a given team.
90+ // Its possible values are: "member", "maintainer".
91+ // This is only populated when calling the
92+ // [TeamsService.ListTeamMembersBySlug] or [TeamsService.ListTeamMembersByID]
93+ // methods.
94+ Role * string `json:"role,omitempty"`
95+
96+ // Inherited identifies whether a user inherited their team role from a child
97+ // team.
98+ // This is only populated when calling the
99+ // [TeamsService.ListTeamMembersBySlug] or [TeamsService.ListTeamMembersByID]
100+ // methods.
101+ Inherited * bool `json:"inherited,omitempty"`
84102}
85103
86104func (u User ) String () string {
0 commit comments