Skip to content

Teams is missing "permissions" field #1863

@derekjobst

Description

@derekjobst

It appears the Repositories.ListTeams(Docs) API call returns a field permissions on each team which includes the more detailed set of permissions with triage/maintain.

A similar field is currently populated on User when calling Repositories.ListCollaborators([Docs].(https://docs.github.com/en/rest/reference/repos#list-repository-collaborators))

Example

Tested on Github Enterprise v3.0.6
https://<github-host>/api/v3/repos/test-org/test-repo/teams

[
  {
    "name": "Example Team",
    "id": 99,
    "node_id": "...",
    "slug": "example-team",
    "description": "",
    "privacy": "closed",
    "url": "...",
    "html_url": "...",
    "members_url": "...",
    "repositories_url": "...",
    "permission": "push",
    "permissions": {
      "pull": false,
      "triage": false,
      "push": false,
      "maintain": true,
      "admin": false
    },
    "parent": null
  },
]

Docs

This endpoint appears to be the same in Enterprise 3.0 and Github.com.

Proposal

Add a Permissions field identical to what exists on User to the Team type.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions