I am working on an iOS mobile app and like to get issues assigned to a particular user and i am currently using the below rest api 's,
1.https://help.myDomain.com/rest/api/2/search?jql=assignee=%@
2.https://help.myDomain.com/rest/api/2/search?jql=assignee=currentuser()
but i am only getting the issues assigned to a user only for a particular project , Can any one let me know the rest api which will get the issues from all the projects assigned to a user rather than a single project ?
Thanks
Community moderators have prevented the ability to post new answers.
https://help.myDomain.com/rest/api/2/search?jql=assignee=currentuser()
Returns issues from all project since your JQL does not include any project specific conditions.
Maybe your user is assigned only in one project and that's why you get issues from this project.
Please help me on this.
Search for JIRA Issue that the current user has the right to see.
Thanks.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Volodymyr Krupach
Thanks for answering my question , but i am using this -"https://help.myDomain.com/rest/api/2/search?jql=assignee=currentuser()" but still i am getting only the issues from a single project but the user is the team lead for several projects where he has to see issues from different projects , can you let me know how can i add JQL tothis api for getting projects as well.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ravi, Please try to put "assignee=currentuser()" into to Advanced search box (instructions if you need them https://confluence.atlassian.com/display/JIRA/Advanced+Searching). I an sure that it will show you the same results as you get through the REST. So the problem is in data. If you clearly see that the current user is Assignee in issues in different projects and can work with these issues, please try to launch reindex (JQL works upon index): https://confluence.atlassian.com/display/JIRA/Search+Indexing
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, Thanks for your time and answer, Can you please let me know why would i need to perform a re-index as all the issues shown with the API are assigned to a current user . What will change if i perform a re-index ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
JQL works on top of JIRA index. If it's broken JQL returns wrong results.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Got it thanks i got the solution to my problem , Can you let me what filter do i need to add at the end of this API "https://help.myDomain.com/rest/api/2/search?jql=assignee=currentuser()"; to get results ordered by latest date and it will solve my problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
To order by issue creation date in descending order please use following JQL: "https://help.myDomain.com/rest/api/2/search?jql=assignee=currentuser() order by createdDate desc"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Volodymyr Krupach i appreciate your help for the answer , can you put "order by createdDate desc" in rest api form please post the URL, i am unavailable to get the order right.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @ravi, It's how I put in the previous comment: https://help.myDomain.com/rest/api/2/search?jql=assignee=currentuser()%20order%20by%20createdDate%20desc
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
can i get the number of issues assigned to different uses of a particualr project, basically i want to group by the result is it feasible using JQL as i want to trigger the email for the same.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There is no "group by" in JQL. Instead you can:
1) make separate REST calls for each user:
https://help.myDomain.com/rest/api/2/search?jql=assignee=user1 AND project = DEMO
If you are not interested in issues and only in total number you can pass maxResults=0. Please check the docs:
https://docs.atlassian.com/jira/REST/cloud/#api/2/search-search
2) or get all data at once (assuming that there is no paging):
https://help.myDomain.com/rest/api/2/search?jql=project = DEMO order by assignee
and iterate through returned issues checking the assignee.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.