maxResults not working in REST API

rich leblanc March 2, 2014

I set maxResults=1000 in myrequest:

requests.get('http://jira.xxxxxxxx.com/rest/api/2/search?jql=%s&startAt=%s&maxResults=1000' % (jql, start_issue), auth=('user', 'password'))

but it always returns 50 issues no matter what I set it to. Any ideas why it's not working? When I do a search in the Jira gui when you start typing a keyword a popup appears with suggestions based on what you typed so far but nothing ever shows up for maxResults. does that mean that keyword is not available in my Jira instance?

1 answer

0 votes
Luther Hargrove
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 2, 2014

The maximum allowable value is dictated by the JIRA property 'jira.search.views.max.limit'. If you specify a value that is higher than this number, your search results will be truncated.

This can be set in the 'jira-config.properties' file.

rich leblanc March 2, 2014

Where is that file located so I can check it? nvm found it:

https://confluence.atlassian.com/display/JIRAKB/How+to+edit+the+jira-config.properties+file

rich leblanc March 4, 2014

My Jira admin told me he set jira.search.views.max.limit = -1 too "get rid of search limit according to documentation". I don't see that anywhere in docs. Is that a legit value to set it to?

Jira-Admins December 27, 2016

Hi rich,

 

Did setting to -1 worked?

 

Thanks

Sarath S

Mei Ying Phuah August 27, 2017

HI, is it same for vba coding by just adding -1 then it will exceed the limit?

Suggest an answer

Log in or Sign up to answer