Chat / Flutter
Current version: v3
Chat Flutter v3
Chat Flutter
Chat
Flutter
Home
/
Chat
/
Flutter
/
Message

Retrieve a list of polls

Create a PollListQuery instance to retrieve a list of polls matching the specifications set by PollListQueryParams. After a list of polls is successfully retrieved, you can access the data of each polls from the result list through the polls parameter of the callback handler.

final result = await PollListQuery(
    params: PollListQueryParams(
    channelType: channel.channelType, channelUrl: channel.channelUrl),
    ).loadNext();

PollListQueryParams

Parameter nameTypeDescription

channelType

ChannelType

Specifies the type of the channel.

channelUrl

String

Specifies the URL of the channel.

limit

int

Specifies the number of results to retrieve per page. Acceptable values are 1 to 20, inclusive. (Default: 10)