Browse SDKs · Flutter
SDKsFlutter

Set the conversation message receive option

Set message reception and notification behavior for one conversation with the OpenIM Flutter SDK.

Copy
await OpenIM.iMManager.conversationManager.setConversation(
  conversationID,
  ConversationReq(recvMsgOpt: ReceiveMessageOpt.notNotify),
);
ConstantValueMeaning
ReceiveMessageOpt.receive0Receive messages normally and allow notifications.
ReceiveMessageOpt.notReceive1Do not receive messages from this conversation or notify the user.
ReceiveMessageOpt.notNotify2Receive messages from this conversation without notifying the user.

For the account-level default, see Set the global message receive option. After the Future succeeds, merge the conversation by conversationID through onConversationChanged. For the complete listener, see Retrieve the conversation list.