-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Low
-
Component/s: Workspace - Permissions
-
None
-
1
-
Severity 3 - Minor
-
128
Issue Summary
The Bitbucket Cloud legacy API v1 endpoint GET /1.0/group-privileges/<workspace>/<workspace>/<group> fails with a timeout (500 error) in workspaces with a large number of repositories (e.g., 1,000+).
Steps to Reproduce
- Identify a Bitbucket Cloud workspace with a large number of repositories (e.g., 1,000 - 5,000+).
- Attempt to call the group privileges endpoint for any group within that workspace:
curl -X GET https://api.bitbucket.org/1.0/group-privileges/<workspace_ID>/<workspace_ID>/<group_slug> - Observe the response time and the resulting status code.
Expected Results
The API should return a list of repository privileges for the specified group within a reasonable timeframe.
Actual Results
The request hangs and eventually returns a 500 Internal Server Error or a gateway timeout due to the backend process exceeding the allowed execution time while iterating through the repository list.
Workaround
To avoid the iteration timeout, users should use the repository-specific privileges API, which scopes the permission check to a single repository:
GET /1.0/group-privileges/<workspace>/<repo_slug>/<workspace>/<group>
While this requires multiple calls to cover all repositories, it avoids the architectural bottleneck of the workspace-wide iteration.