Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 21:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Bitbucket API get/update all users with access to repository

Tran Tien dung
Contributor
August 14, 2019

Hi everyone,
is there any way to list all users who have access in particular repository. Beside that, I also want to update or add privilege of user in repository.
For example: In repository A, If I found user1 and user2 have admin right, I will update them to write permission.

Thanks.

 

1 answer

0 votes
Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 16, 2019

Hi Tran,

You can achieve something similar using the v1 Cloud REST API. Note that mos of the v1 endpoints are deprecated, but some of them are still in use as they don't have yet a replacement in v2. You won't be able to achieve results on a user-by-user basis, though, but you can get this information for groups, and then add or remove users from those groups accordingly.

This deprecation happened in April 2019, most of these permission endpoints have been removed or the verb only allowing GET. Further information about which endpoints are deprecated along with if or what they’re replaced with can be found at Deprecation notice - Bitbucket Cloud REST API version 1 is deprecated effective 30 June 2018. For an explanation of why this happened you can read Migration guide for major changes to Bitbucket Cloud REST APIs to improve user privacy.

I hope that helps you!

Best regards,

Ana

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events