A workspace is where you create repositories, collaborate on your code, and organize different streams of work in your Bitbucket Cloud account. Workspaces replace the use of teams and users in API calls.
Returns an object for each workspace accessible to the caller. This object
also contains details on whether the caller has admin permissions on the workspace
("administrator" = true) or not ("administrator" = false).
Queries support filtering based on administrator permissions,
sorting or
filtering by slug. Results can
be paginated.
accountread:workspace:bitbucketstring
boolean
The list of workspaces accessible by the authenticated user.
A paginated list of workspace permissions.
1
2
3
4
curl --request GET \
--url 'https://api.bitbucket.org/2.0/user/workspaces' \
--header 'Authorization: Bearer <access_token>' \
--header 'Accept: application/json'1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
{
"pagelen": 25,
"page": 1,
"size": 1,
"values": [
{
"administrator": true,
"type": "workspace_access",
"workspace": {
"links": {
"avatar": {
"href": "https://api.bitbucket.org/workspaces/bbworkspace1/avatar/"
},
"self": {
"href": "https://api.bitbucket.org/2.0/workspaces/bbworkspace1"
}
},
"slug": "bbworkspace1",
"type": "workspace_base",
"uuid": "{470c176d-3574-44ea-bb41-89e8638bcca4}"
}
}
]
}Returns the caller's effective role; as in, the highest level of privilege the caller has for the workspace. If the calling user is a member of multiple groups with distinct roles, only the highest level is returned.
Permissions can be:
ownercreate-projectcollaborator (deprecated; see this
deprecation announcement for more details)memberaccountread:workspace:bitbucket