I am using the JIRA filter's search URL and using the UrlFetchApp in Google Apps Scripts to retreive the JSON. However, my filter has more than 50 items and I see the maxResults always set to 50. I tried passing in maxResults as an option to the fetch but I still end up with only 50. Can I do something to the filter to get more than 50 items?
I found a simple fix. At the end of the search URL I was using I just added "&maxResults=1000" and it changed it.
Hi Ben Wozniak,
That's great to see your faced issue similar to mine. Could you please share my how to add "&maxResults=1000" into you search URL?
I tried it and it still showing 50 rows returned.
My code below, can you please help me if possible to modify below
var jql = "?jql=issuetype in (subTaskIssueTypes(), Enhancement, Epic, Feature, 'Product Backlog Item', Story, Task, Bug) AND Labels = 2018 ORDER BY Rank ASC";
var resultJQL ="&maxResults=1000";
var httpResponse = UrlFetchApp.fetch(baseURL + jql + resultJQL, fetchArgs);
Thanks,
Vinh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I added into my JIRA query &startAt=0&maxResults=100 and it works!
JIRA have a limitation to get return result only 100 rows to improve performance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am using pagination and it is working fine. What sucks is that getting only 100 hundred results at a time take hours to finish grabbing the whole list of issues. Is there a way to configure Jira Cloud in other to get more than 100 results per page?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, Sergio Lage.
Could you please share me how to add pagination into the search URL?
Is that should be &page=1? But I have tried it. It doesn't work.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Like,
First of all, you need to code a loop using the data load editor.
Use startAt as a variable and increment it on every page request you do to grab a set of maxResults at each request.
Execute the loop until you get all requests you want to.
If you are fine with data load editor and its debugging tool, it won't be a problem.
I hope this helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, Sergio Lage.
The answer that you provided helps me a lot.
Thanks very much.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you link to the rest api that you are using and maybe I'll be able to just look it up for you? https://docs.atlassian.com/jira/REST/latest/
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm not using an API, I'm just using google scripts' UrlFetchApp to retrieve from the search URL then I am parsing the JSON. I was wondering if maybe I could edit the maxResults in the JIRA filter itself, or if there is a parameter I can pass in to change the maxResults.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If pagination is not allowed by the resource then you should probably raise a bug. :(
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think that JIRA has an upper limit of 50 inbuilt statically into it. I think that you will just have to paginate the API yourself to get all of the results.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.