Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarifications to pagination parameters for various APIs #3353

Merged
merged 4 commits into from
Aug 25, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion data/api/client-server/message_pagination.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ paths:
The token to start returning events from. This token can be obtained
from a `prev_batch` or `next_batch` token returned by the `/sync` endpoint,
or from an `end` token returned by a previous request to this endpoint.

Some server implementations also accept a value returned as a `start` token
by a previous request to this endpoint, but this is not required, and
clients should not rely on it.
richvdh marked this conversation as resolved.
Show resolved Hide resolved
richvdh marked this conversation as resolved.
Show resolved Hide resolved
required: true
x-example: "s345_678_333"
- in: query
Expand Down Expand Up @@ -114,7 +118,8 @@ paths:
description: |-
A list of room events. The order depends on the `dir` parameter.
For `dir=b` events will be in reverse-chronological order,
for `dir=f` in chronological order.
for `dir=f` in chronological order. (The exact definition of `chronological`
is dependent on the server implementation.)

Note that an empty `chunk` does not *necessarily* imply that no more events
are available. Clients should continue to paginate until no `end` property
Expand Down