Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
Next:
badges earned

Your Points Tracker
Challenges
Leaderboard
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Recognition
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Kudos
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Access Permission using Jira Rest API

Hello All,

I am new to jira.

I need to access particular user permission using user key as we don't have account id for users.

Kindly let me know the uri for accessing user permission and to check whether that user is admin or not??

Thanks in advance

Pallavi Deore

 

2 answers

0 votes
Nir Haimov Community Leader May 31, 2021

Hi @Pallavi Deore 

Follow the API documentation, everything you need regarding API is there:

https://docs.atlassian.com/software/jira/docs/api/REST/8.13.0/#api/2-getPermissions

Hi @Nir Haimov 

I went through above documents which is helpful for fetching login user permission...

It response successfully for login user but for other user how I can fetch all permission using username, key, name or email address.

Even I tried using below url 

/rest/api/2/user/permission/search?username=pallavi

But not able to fetch permission of user pallavi.

Kindly suggest me urls for fetching particular user permission and to check that user is admin or not?

Thanks...

Nir Haimov Community Leader Jun 01, 2021

Hi @Pallavi Deore 

it works like that:

/rest/api/2/user?username=user@company.com
0 votes
Daniel Ebers Community Leader Jun 05, 2021

Hi @Pallavi Deore

like Nir stated you can do a REST API call (using Jira server) like

https://jira.example.org/rest/api/2/user?username=johndoe

You will get (when doing the call while being logged in with administrator permissions) details like the username, the mail address, the full name, the time zone set for the user, the amount of groups the user is in.

However, it does not say anything about permissions. When wanting to know if the user is admin or not (I assume you mean member in jira-administrators) you still could do a REST API call like:

https://jira.example.org/rest/api/2/group/member?groupname=jira-administrators&includeInactiveUsers=false

Regards,
Daniel

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you