---
title: "List a repository permissions for a workspace"
method: GET
path: "/workspaces/{workspace}/permissions/repositories/{repo_slug}"
tags: ["Workspaces"]
---

# List a repository permissions for a workspace

`GET /workspaces/{workspace}/permissions/repositories/{repo_slug}`

Returns an object for the repository permission of each user in the
requested repository.

Permissions returned are effective permissions: the highest level of
permission the user has. This does not distinguish between direct and
indirect (group) privileges.

Only users with admin permission for the repository may access this resource.

Permissions can be:

* `admin`
* `write`
* `read`

Results may be further [filtered or sorted](/cloud/bitbucket/rest/intro/#filtering)
by user, or permission by adding the following query string parameters:

* `q=permission>"read"`
* `sort=user.display_name`

Note that the query parameter values need to be URL escaped so that `=`
would become `%3D`.

## Query parameters

- `q` string
- `sort` string

## Response `200`

The repository permission for all users in this repository.

- PaginatedRepositoryPermissions — A paginated list of repository permissions.
  - `size` integer — Total number of objects in the response. This is an optional element that is not provided in all responses, as it can be expensive to compute.
  - `page` integer — Page number of the current results. This is an optional element that is not provided in all responses.
  - `pagelen` integer — Current number of objects on the existing page. The default value is 10 with 100 being the maximum allowed value. Individual APIs may enforce different values.
  - `next` string, uri — Link to the next page if it exists. The last page of a collection does not have this value. Use this link to navigate the result set and refrain from constructing your own URLs.
  - `previous` string, uri — Link to previous page if it exists. A collections first page does not have this value. This is an optional element that is not provided in all responses. Some result sets strictly support forward navigation and never provide previous links. Clients must anticipate that backwards navigation is not always available. Use this link to navigate the result set and refrain from constructing your own URLs.
  - `values` RepositoryPermission[]
    - `type` string, required
    - `permission` 'read' | 'write' | 'admin' | 'none'
    - `user` User — A user object.
      - `type` string, required
      - `links` object — Links related to a User.
        - `avatar` Link — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `self` Link — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `html` Link — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `repositories` Link — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
      - `created_on` string, date-time
      - `display_name` string
      - `uuid` string
      - `account_id` string — The user's Atlassian account ID.
      - `account_status` string — The status of the account. Currently the only possible value is "active", but more values may be added in the future.
      - `has_2fa_enabled` boolean
      - `nickname` string — Account name defined by the owner. Should be used instead of the "username" field. Note that "nickname" cannot be used in place of "username" in URLs and queries, as "nickname" is not guaranteed to be unique.
      - `is_staff` boolean
    - `repository` Repository — A Bitbucket repository.
      - `type` string, required
      - `links` object
        - `self` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `html` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `avatar` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `pullrequests` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `commits` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `forks` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `watchers` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `downloads` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
        - `clone` object[]
          - `href` string, uri
          - `name` string
        - `hooks` object — A link to a resource related to this object.
          - `href` string, uri
          - `name` string
      - `uuid` string — The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.
      - `full_name` string — The concatenation of the repository owner's username and the slugified name, e.g. "evzijst/interruptingcow". This is the same string used in Bitbucket URLs.
      - `is_private` boolean
      - `parent` Repository — recursive
      - `scm` 'git'
      - `owner` Account — An account object.
        - `type` string, required
        - `links` AccountLinks — Links related to an Account.
          - `avatar` Link — A link to a resource related to this object.
            - `href` string, uri
            - `name` string
        - `created_on` string, date-time
        - `display_name` string
        - `uuid` string
      - `name` string
      - `description` string
      - `created_on` string, date-time
      - `updated_on` string, date-time
      - `size` integer
      - `language` string
      - `has_issues` boolean — The issue tracker for this repository is enabled. Issue Tracker features are not supported for repositories in workspaces administered through admin.atlassian.com.
      - `has_wiki` boolean — The wiki for this repository is enabled. Wiki features are not supported for repositories in workspaces administered through admin.atlassian.com.
      - `fork_policy` 'allow_forks' | 'no_public_forks' | 'no_forks' — Controls the rules for forking this repository. * **allow_forks**: unrestricted forking * **no_public_forks**: restrict forking to private forks (forks cannot be made public later) * **no_forks**: deny all forking
      - `project` Project — A Bitbucket project. Projects are used by teams to organize repositories.
        - `type` string, required
        - `links` object
          - `html` object — A link to a resource related to this object.
            - `href` string, uri
            - `name` string
          - `avatar` object — A link to a resource related to this object.
            - `href` string, uri
            - `name` string
        - `uuid` string — The project's immutable id.
        - `key` string — The project's key.
        - `owner` Team — A team object.
          - `type` string, required
          - `links` object — Links related to a Team.
            - `avatar` Link — A link to a resource related to this object.
              - …
            - `self` Link — A link to a resource related to this object.
              - …
            - `html` Link — A link to a resource related to this object.
              - …
            - `members` Link — A link to a resource related to this object.
              - …
            - `projects` Link — A link to a resource related to this object.
              - …
            - `repositories` Link — A link to a resource related to this object.
              - …
          - `created_on` string, date-time
          - `display_name` string
          - `uuid` string
        - `name` string — The name of the project.
        - `description` string
        - `is_private` boolean — Indicates whether the project is publicly accessible, or whether it is private to the team and consequently only visible to team members. Note that private projects cannot contain public repositories.
        - `created_on` string, date-time
        - `updated_on` string, date-time
        - `has_publicly_visible_repos` boolean — Indicates whether the project contains publicly visible repositories. Note that private projects cannot contain public repositories.
      - `mainbranch` Branch — A branch object, representing a branch in a repository.
        - `type` string, required
        - `links` object
          - `self` object — A link to a resource related to this object.
            - `href` string, uri
            - `name` string
          - `commits` object — A link to a resource related to this object.
            - `href` string, uri
            - `name` string
          - `html` object — A link to a resource related to this object.
            - `href` string, uri
            - `name` string
        - `name` string — The name of the ref.
        - `target` Commit — A repository commit object.
          - `type` string, required
          - `hash` string
          - `date` string, date-time
          - `author` Author — The author of a change in a repository
            - `type` string, required
            - `raw` string — The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.
            - `user` Account — An account object.
              - …
          - `committer` Committer — The committer of a change in a repository
            - `type` string, required
            - `raw` string — The raw committer value from the repository. This may be the only value available if the committer does not match a user in Bitbucket.
            - `user` Account — An account object.
              - …
          - `message` string
          - `summary` object
            - `raw` string — The text as it was typed by a user.
            - `markup` 'markdown' | 'creole' | 'plaintext' — The type of markup language the raw content is to be interpreted in.
            - `html` string — The user's content rendered as HTML.
          - `parents` BaseCommit[]
            - `type` string, required
            - `hash` string
            - `date` string, date-time
            - `author` Author — The author of a change in a repository
              - …
            - `committer` Committer — The committer of a change in a repository
              - …
            - `message` string
            - `summary` object
              - …
            - `parents` BaseCommit[]
          - `repository` Repository — recursive
          - `participants` Participant[]
            - `type` string, required
            - `user` Account — An account object.
              - …
            - `role` 'PARTICIPANT' | 'REVIEWER'
            - `approved` boolean
            - `state` string
            - `participated_on` string, date-time — The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented.
        - `merge_strategies` string[] — Available merge strategies for pull requests targeting this branch.
        - `default_merge_strategy` string — The default merge strategy for pull requests targeting this branch.

## Other responses

- `403` — The requesting user isn't an admin of the repository.

---

[API](https://skmtc.net/atlassian/apis/bitbucket-api.md) · [All operations](https://skmtc.net/atlassian/apis/bitbucket-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/atlassian/bitbucket-api/versions/8c7911c0a910/schema)
