We're using an API to search Issues on Jira, (Get issue picker suggestion).
The response is somewhat like this:
Response:
"sections":[
{
"label":"History Search",
"sub":"Showing 2 of 2 matching issues",
"id":"hs",
"issues":[
{issue_1 and details},
{issue_2 and details}
]
}
]
I want to implement Pagination for the issues i'm receiving. I tried adding startAt and maxResults value in query params, but the result does not change and gives me a non paged response.
Is there anyway I can limit my values with pagination
References:
Hello Raghav. Not all the REST API endpoints return the results in a paginated format, only those whose operation could potentially produce a very large number of results.
The /rest/api/3/issue/picker is one of the endpoints that does not return the results in paginated format, so defining the startAt and maxResults parameters has no effect. You will have to manage the results returned in your code.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes.
In the REST API documentation for that endpoint, you will see that it specifically describes using startAt and maxResults to paginate the results:
startAt
integer
The index of the first item to return in a page of results (page offset).
Default:
0
, Format:int32
maxResults
integer
The maximum number of items to return per page. To manage page size, Jira may return fewer items per page where a large number of fields are requested. The greatest number of items returned per page is achieved when requesting
id
orkey
only.Default:
50
, Format:int32
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Validate your expertise in managing Jira Service Projects for Cloud. Master configuration, optimize workflows, and manage users seamlessly. Earn global 🗺️ recognition and advance your career as a trusted Jira Service management expert.
Get Certified! ✍️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.