Hi, I am trying to use the JIRA Software REST API (https://docs.atlassian.com/jira-software/REST/cloud/) to get all boards relevant to a project.
Therefore I tried to use the /rest/agile/1.0/board
endpoint with a projectKeyOrId
query parameter but unfortunately this only returns the boards where the project is directly referenced in the jql. At least that is what I understood from the description of the query parameter:
Filters results to boards that are relevant to a project. Relevance means that the jql filter defined in board contains a reference to a project.
So since I need a list of all boards where the project is visible it seems I am forced to fetch all boards, and then use the /rest/agile/1.0/board/{boardId}/project
endpoint to fetch all projects for each board and look for a match.
So this brings me to my question.
This endpoint is really slow. I am guessing it is because it has to evaluate the board’s jql against all projects (and there are a lot of projects), and some of the boards have more than 200 projects which means that with pagination I have to fetch 5 times to get all the projects.
The API says that I should be able to use maxResults
query parameter to increase the number of returned projects from the default 50, but if I set it to more than 50 I still only get 50 per request.
Is this intended that maxResults
is limited to 50 for this endpoint, or am I doing something wrong? The returned data per project is minimal so I don’t see a reason why they would set the limit so low.
Also if any of you know an easier way to get all boards for a project, please let me know.