I am currently working on iOS app and want to show all the issues reported by me and i am currently using the below rest api -
https://help.myDomain.com/rest/api/2/search?jql=reporter=myName+order+by+createdDate&startAt=0&maxResults=50
but it returns all the issues that are reported by me , Now i only want to show first 10 issues in the app and then when the user scrolls down it should load the next batch of issues on the app , How can i do it ? Do i need to add any filters for the above api ? Please let me know
Use the startAt and maxResults values as appropriate. I wanted to give sample links but the spam filter is not allowing it.
You can have startAt = 0 and maxResults = 10 for the first call. startAt = 10 and maxResults = 10 for the next 10 results and so on.
Precisely the correct way to do it. We do it in all our scripts.
Okay thanks and adding to that can i add something like "/page?limit=5" which confluences uses for pagination ? does JIRA support the same "page" filter like confluence or should i go ahead with the above answer startAt & maxResults ?
@Jobin Kuruvilla [Go2Group] Can you please help me with the above question ? thanks
Also, if you are running these commands from curl, try url encoding your string. For example = is %3D & is %26. It helped get my tests working.
This helped me to understand better how pagination is used.
https://community.atlassian.com/t5/Answers-Developer-Questions/How-do-I-get-all-the-issues-while-using-REST-API-for-a-JQL/qaq-p/472399
Hope it's useful.
It looks like you're new here. Sign in or register to get started.