---
title: "List workspaces for user"
method: GET
path: "/workspaces"
tags: ["Workspaces"]
deprecated: true
---

# List workspaces for user

`GET /workspaces`

> **Deprecated.**

**This endpoint is deprecated. Please use the
[supported alternative](/cloud/bitbucket/rest/api-group-workspaces/#api-user-workspaces-get).**

Returns a list of workspaces accessible by the authenticated user.

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

* `q=slug="bbworkspace1"` or `q=is_private=true`
* `sort=created_on`

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

**The `collaborator` role is being removed from the Bitbucket Cloud API. For more information,
see the [deprecation announcement](/cloud/bitbucket/deprecation-notice-collaborator-role/).**

## Query parameters

- `role` 'owner' | 'collaborator' | 'member'
- `q` string
- `sort` string

## Response `200`

The list of workspaces accessible by the authenticated user.

- PaginatedWorkspaces — A paginated list of workspaces.
  - `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` Workspace[]
    - `type` string, required
    - `links` object
      - `avatar` 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
      - `members` object — A link to a resource related to this object.
        - `href` string, uri
        - `name` string
      - `owners` object — A link to a resource related to this object.
        - `href` string, uri
        - `name` string
      - `projects` object — A link to a resource related to this object.
        - `href` string, uri
        - `name` string
      - `repositories` object — A link to a resource related to this object.
        - `href` string, uri
        - `name` string
      - `snippets` object — A link to a resource related to this object.
        - `href` string, uri
        - `name` string
      - `self` object — A link to a resource related to this object.
        - `href` string, uri
        - `name` string
    - `uuid` string — The workspace's immutable id.
    - `name` string — The name of the workspace.
    - `slug` string — The short label that identifies this workspace.
    - `is_private` boolean — Indicates whether the workspace is publicly accessible, or whether it is private to the members and consequently only visible to members.
    - `is_privacy_enforced` boolean — Indicates whether the workspace enforces private content, or whether it allows public content.
    - `forking_mode` 'allow_forks' | 'internal_only' — Controls the rules for forking repositories within this workspace. * **allow_forks**: unrestricted forking * **internal_only**: prevents forking of private repositories outside the workspace or to public repositories
    - `created_on` string, date-time
    - `updated_on` string, date-time

## Other responses

- `401` — The request wasn't authenticated.

---

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