Pagination broken: searchJiraIssuesUsingJql never returns nextPageToken or pagination metadata
Summary
The searchJiraIssuesUsingJql tool never returns pagination fields (nextPageToken, nextCursor, isLast) in its response,
making it impossible to paginate beyond the first page of results.
The totalCount field in the response reflects the number of results on the current page (equal to maxResults),
not the total number of matching issues, which makes it unusable for detecting whether more pages exist.
Environment
- MCP endpoint:
https://mcp.atlassian.com/v1/mcp
- Tool:
searchJiraIssuesUsingJql
- Client: Claude Code (claude-code CLI)
- Date observed: March 20, 2026
- Jira Cloud instance: Confirmed on at least one production Jira Cloud tenant
Expected behavior (per MCP pagination spec)
Per the MCP Pagination specification,
servers should return a nextCursor field (or in the Atlassian MCP's case, nextPageToken) when more results exist.
Clients treat a missing cursor as the end of results.
The tool's input schema accepts a nextPageToken parameter,
and the skills documentation in this repo
instructs agents to "use nextPageToken from results" for pagination.
This confirms pagination was designed to work.
Actual behavior
The response envelope only contains three keys:
{
"issues": {
"totalCount": 20,
"nodes": [ ... ],
"webUrl": "https://..."
}
}
-
No nextPageToken, nextCursor, or isLast field is returned, regardless of whether more results exist.
-
totalCount equals maxResults (or the number of nodes if fewer results exist), not the true total matching the JQL query.
-
Attempting to pass a value for the nextPageToken input parameter returns an error:
{"errorMessages": ["The provided next page token is invalid or expired."], "errors": {}}
Reproduction steps
-
Connect to the Atlassian MCP server
-
Call searchJiraIssuesUsingJql with a JQL query that matches more results than maxResults:
{
"cloudId": "<your-cloud-id>",
"jql": "project = <PROJECT> AND fixVersion = \"<version>\"",
"fields": ["key", "summary"],
"maxResults": 5
}
-
Observe the response:
totalCount equals 5 (matches maxResults, not the true total)
- No
nextPageToken or isLast field is present
- Only
nodes, totalCount, and webUrl keys exist
-
Repeat with maxResults: 20 and maxResults: 100 on the same query:
totalCount changes to 20 and 100 respectively, always matching maxResults
- No pagination metadata is ever returned
-
Try passing nextPageToken: "5" or any value:
- Returns error: "The provided next page token is invalid or expired."
Impact
- Any JQL query returning more results than
maxResults (max 100) silently drops results with no indication that more exist.
- Agents following the documented pagination pattern (
nextPageToken from results) will always see a missing token and conclude pagination is complete after the first page.
- There is no workaround within the MCP tool itself. The only mitigation is to use JQL
ORDER BY key ASC with AND key > "LAST-KEY" to manually paginate, but this is fragile and undocumented.
Likely root cause
This issue aligns with widely reported pagination problems in Atlassian's newer
/rest/api/3/search/jql endpoint, which replaced the deprecated /rest/api/2/search endpoint.
The newer endpoint has known issues with nextPageToken handling:
- Tokens that return the first page in an infinite loop
- Tokens returned as "expired" immediately
isLast never returning true
- Pagination fields missing entirely from responses
The MCP server appears to be using this newer endpoint but not receiving
(or not forwarding) the pagination fields from the underlying API response.
Community references
These Atlassian Community threads document the same underlying API pagination issues:
Suggested fix
- Return
nextPageToken (or nextCursor per the MCP spec) in the response when more results exist.
- Return the true
totalCount of matching issues, not the count of the current page.
- If the underlying Jira API is not providing reliable pagination tokens, consider falling back to the deprecated
/rest/api/2/search endpoint which uses offset-based pagination (startAt + total) reliably, or implement server-side cursor management.
Pagination broken:
searchJiraIssuesUsingJqlnever returnsnextPageTokenor pagination metadataSummary
The
searchJiraIssuesUsingJqltool never returns pagination fields (nextPageToken,nextCursor,isLast) in its response,making it impossible to paginate beyond the first page of results.
The
totalCountfield in the response reflects the number of results on the current page (equal tomaxResults),not the total number of matching issues, which makes it unusable for detecting whether more pages exist.
Environment
https://mcp.atlassian.com/v1/mcpsearchJiraIssuesUsingJqlExpected behavior (per MCP pagination spec)
Per the MCP Pagination specification,
servers should return a
nextCursorfield (or in the Atlassian MCP's case,nextPageToken) when more results exist.Clients treat a missing cursor as the end of results.
The tool's input schema accepts a
nextPageTokenparameter,and the skills documentation in this repo
instructs agents to "use
nextPageTokenfrom results" for pagination.This confirms pagination was designed to work.
Actual behavior
The response envelope only contains three keys:
{ "issues": { "totalCount": 20, "nodes": [ ... ], "webUrl": "https://..." } }No
nextPageToken,nextCursor, orisLastfield is returned, regardless of whether more results exist.totalCountequalsmaxResults(or the number of nodes if fewer results exist), not the true total matching the JQL query.Attempting to pass a value for the
nextPageTokeninput parameter returns an error:{"errorMessages": ["The provided next page token is invalid or expired."], "errors": {}}Reproduction steps
Connect to the Atlassian MCP server
Call
searchJiraIssuesUsingJqlwith a JQL query that matches more results thanmaxResults:{ "cloudId": "<your-cloud-id>", "jql": "project = <PROJECT> AND fixVersion = \"<version>\"", "fields": ["key", "summary"], "maxResults": 5 }Observe the response:
totalCountequals 5 (matchesmaxResults, not the true total)nextPageTokenorisLastfield is presentnodes,totalCount, andwebUrlkeys existRepeat with
maxResults: 20andmaxResults: 100on the same query:totalCountchanges to 20 and 100 respectively, always matchingmaxResultsTry passing
nextPageToken: "5"or any value:Impact
maxResults(max 100) silently drops results with no indication that more exist.nextPageTokenfrom results) will always see a missing token and conclude pagination is complete after the first page.ORDER BY key ASCwithAND key > "LAST-KEY"to manually paginate, but this is fragile and undocumented.Likely root cause
This issue aligns with widely reported pagination problems in Atlassian's newer
/rest/api/3/search/jqlendpoint, which replaced the deprecated/rest/api/2/searchendpoint.The newer endpoint has known issues with
nextPageTokenhandling:isLastnever returningtrueThe MCP server appears to be using this newer endpoint but not receiving
(or not forwarding) the pagination fields from the underlying API response.
Community references
These Atlassian Community threads document the same underlying API pagination issues:
Suggested fix
nextPageToken(ornextCursorper the MCP spec) in the response when more results exist.totalCountof matching issues, not the count of the current page./rest/api/2/searchendpoint which uses offset-based pagination (startAt+total) reliably, or implement server-side cursor management.