Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How get the list of repositories that the user does not have access?

ramakrishna September 24, 2019

How get the list of repositories that the user does not have access?

1 answer

0 votes
Daniel Santos
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 26, 2019

Hi @ramakrishna

You can't build this list easily, you will need to check each repository manually.
There is a feature request for an entry point to check if a given user has write access, which could be used to build such list, but this is just a feature request: [BCLOUD-8542] Determine whether authenticated user has "write" access to a repository?.

In case you think we should have a different entry point via REST for such report, please share what in your opinion would be the parameters send and returned and I'll open a feature request for you.

ramakrishna September 27, 2019

Yes, I am asking fore Rest.

Daniel Santos
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 30, 2019

Hi @ramakrishna

I had a typo in my first message.  I said "You can build this list easily" when it should be "You can't build this list easily". The best you can do is to check what repositories he has access using the workaround provided by evzijst on [BCLOUD-8542] Determine whether authenticated user has "write" access to a repository?.

GET /2.0/repositories/{username}?role=contributor

For more details on this API you can check Bitbucket API - Repositories/{username}.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events