SDKsFlutterEnterprise
Retrieve conversations in a group
Retrieve conversations in a Flutter conversation group by page.
Use getConversationGroupInfoWithConversations() to retrieve a conversation group together with one page of its current conversation details.
final page = await OpenIM.iMManager.conversationGroupManager
.getConversationGroupInfoWithConversations(
req: GetConversationGroupInfoWithConversationsReq(
groupID: conversationGroupID,
pagination: RequestPagination(pageNumber: 1, showNumber: 20),
),
);
renderConversationGroup(page.group, page.conversationElems ?? const []);In this request, groupID means conversationGroupID. pageNumber starts at 1, and showNumber is the page size.
Result
The response provides nullable group, the current page in conversationElems, and isEnd. The Flutter model does not contain the WASM response's conversationTotal; use isEnd to determine when pagination is complete.
This query does not trigger the group listener. If changes occur while paging, query again after loading to reconcile the snapshot.
Was this page helpful?