Get Projects list from a Filter query

(have tried to search a similar question but didn't find)

I have a JQL filter (by id) - how is it possible to read a list of associated projects, if a filter covers a lot of them? i.e. a filter result will contain issues with keys belonging to different projects. Iterating over all issues in a search result doesn't work, unfortunately, because it might take a lot of time (up to minutes or even hours in case of a large amount of issues in a filter).

REST API (link) doesn't seem to answer this question - there is a lot of endpoints about filters, but I have found nothing which would help to read associated projects. Does anyone know any undocumented features in this api? :) Or maybe it is possible to use some aggregation functions for same purpose? or call a filter via web interface?

Another way: to get projects not by just a filter, but by Agile Board. It is a kind of a workaround, but acceptable one in our case. The problem is that a documented REST endpoint "agile/1.0/board/{boardId}/project" (link) returns "404 null for uri" even for my jira with Agile plugged in (a former Greenhopper functionality), my own filter, my own board, my own several projects i've mentioned in the filter query. Thus, I believe permissions should be all ok. Could anyone give an idea why this call doesn't work?

Thank you.

1 answer

0 votes
Gaston Valente Community Champion Jul 11, 2017

Hi,

I don't know if exists another way but you can try to

  1. Query for the filter
  2. Query for the projects
  3. Loop through the filter and capture the issue key or project id to match to the correct project
  4. Return the projects included in the result of 1

 

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 25, 2018 in Jira

Atlassian Research Workshop opportunity on Sep. 28th in Austin, TX

We're looking for participants for a workshop at Atlassian! We need Jira admins who have interesting custom workflows, issue views, or boards. Think you have a story to sha...

456 views 7 5
Join discussion

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you