Clarify pagination continuation and sorting rules#253
Open
Mehrn0ush wants to merge 2 commits into
Open
Conversation
Signed-off-by: Mehrn0ush <mehrnoush.vaseghi@gmail.com>
270e6c2 to
d37ddb6
Compare
taleodor
suggested changes
Jun 11, 2026
taleodor
left a comment
Contributor
There was a problem hiding this comment.
Great points, just want to request one change to exclude pageSize from the token scope.
| This token MUST be copied verbatim from the `nextPageToken` value returned by the previous response. | ||
| Clients MUST NOT parse, construct, or modify this token. | ||
|
|
||
| The token represents continuation state for the original query, including `pageSize`, |
Contributor
There was a problem hiding this comment.
I would suggest excluding pageSize from this list, since that is not affecting results, and can be left to clients.
Author
There was a problem hiding this comment.
Thanks, that makes sense. I updated the pageToken description to remove pageSize from the continuation state. The token scope now remains limited to sorting, result-affecting filters, and path/path-parameter scope.
Signed-off-by: Mehrn0ush <mehrnoush.vaseghi@gmail.com>
taleodor
approved these changes
Jun 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR clarifies the opaque pagination contract in
spec/openapi.yamland addresses issues #249, #250, and #251.The changes define deterministic ordering rules, clarify
hasNext/nextPageTokenbehavior, and specify howpageTokeninteracts with query parameters and path-scoped resources.Changes
Deterministic pagination ordering (#249)
sortField, then byuuidas a deterministic secondary tie-breaker.uuidbecause collection revisions may share the same UUID.versionsorting semantics and explicitly state that semantic-version precedence is not implied.releaseDatevalues./componentReleasesto usesort-field-component-releaseinstead ofsort-field-component.hasNextandnextPageToken(#250)nextPageTokenfrom required pagination response fields.nextPageTokenMUST be present whenhasNextistrue.nextPageTokenMUST NOT be included whenhasNextisfalse.pageTokencontinuation semantics (#251)pageTokenis opaque and MUST be copied verbatim from a previousnextPageToken.pageToken.pageSizesortFieldsortOrderidTypeandidValueuuid400 Bad Requestfor malformed, invalid, expired, conflicting, wrong-path, or wrong-path-parameter tokens.Closes #249
Closes #250
Closes #251