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

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

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

Can I Get the Group of the assignee of a specific Issue?

Hello,
I'm hitting this api to get all issues for those 3 groups: HR, DEV and Engineering.

https://test.atlassian.net/rest/api/2/search

"jql":"(assignee in membersOf('HR') OR assignee in membersOf('DEV') OR assignee in membersOf('Engineering')) AND created >= 2020-11-26 AND created < 2020-11-27 OR updated >= 2020-11-26 AND updated < 2020-11-27 ORDER BY created DESC".

But in the responce i can't get the Group of witch the assignee is in.
for example I want to know that the assigned member of this issue is in DEV for example.

But this field does not seem to be present.

should i add something to the expand field  "expand":["changelog"] ?

 

Thank you.

2 answers

2 accepted

0 votes
Answer accepted

Group memberships of a user are not issue data.

You'll need to read the user and use another call to question the groups they belong to.

0 votes
Answer accepted

Hi @Jawad Zakhour 

As @Nic Brough _Adaptavist_ mentioned above you need to make another call to get that information in your code.

Try this end point.

/rest/api/3/user?accountId=ACCOUNTID&expand=groups

Here is the curl command to test it quickly.

curl -i -X GET \
-H "Authorization:Basic ACCESSTOKEN" \
'https://JIRAURL/rest/api/3/user?accountId=ACCOUNTID&expand=groups' 

Just replace the ACCESSTOKEN, JIRAURL and the ACCOUNTID.

I hope it helps.

Ravi

Thank you a lot

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
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