Hi,
I am looking in to self service Bitbucket access where user can see admins of the repo for all existing repos.
Is there a way to get these details either from Rest API or database query?
Thanks in advance.
Mansi
Helo! You can try this
select p.NAME as "PROJECT NAME",
p.DESCRIPTION as "PROJECT DESCRIPTION",
spp.GROUP_NAME as "GROUP WITH ADMIN RIGHTS",
u.NAME as "USER WITH ADMIN RIGHTS"
from
STASH.STA_PROJECT_PERMISSION spp
left join stash.project p
on p.ID = spp.PROJECT_ID
left join stash.sta_normal_user u
on spp.user_id = u.user_id
left join stash.cwd_user cu
on cu.lower_user_name = u.name
left join stash.cwd_membership cm
on cm.lower_parent_name = spp.GROUP_NAME
where
( length(spp.group_name) > 1 or length(spp.user_id) > 1 )
and spp.perm_id > 3
order by p.NAME;
Hi Mansi! You could get the admins, but the users wouldn't be able to see them as they don't have the permissions for that (unless you share a list with the users separately to inform them of who are the admins). This other Community thread might help you.
I've done some research and I could find this plugin that might interest you, please note that it's only available for Bitbucket Server.
Hope that helps!
Ana
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Ana,
I am looking for REST Api to get project admin list. I am writing my own application and for that I need to send approval request to admins of the project.
In Above thread, there is groovy script attached to it.
Thanks,
Mansi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm afraid I won't be able to help you with that. There might be other users that can help you with that, but alternatively you can have a look at our developers' resources for more help.
Hope that's useful!
Ana
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.