Search code examples
getstream-io

How to paginate the members list of a chat channel?


I tried to paginate the members of a chat channel using the server-side authentication with this request:

POST /channels/messaging/test-channel/query

{
    "members": {
        "offset": 20,
        "limit": 10
    }
}

But it's not working, it's still returning 100 members!!


Solution

  • You also need to pass state: true in the top level.

    Otherwise, default response will sent and any related pagination will be ignored.