Skip to main content

Removing members from a conversation

Through the WireApplicationManager you can remove members from a conversation. Here is an example for both on the standalone way:

note

To remove members, make sure the conversation is a group or channel, and that the app has admin permissions in the conversation.

Use Case: Remove a member from a conversation

val applicationManager = wireAppSdk.getApplicationManager()

val myConversationId = QualifiedId(
id = UUID.fromString("conversation-id"),
domain = "conversation-domain.com"
)

val myListOfMembers = listOf(
QualifiedId(
id = UUID.fromString("member-user-id"),
domain = "member-domain.com"
)
)

applicationManager.removeMembersFromConversationSuspending(
conversationId = myConversationId,
members = myListOfMembers
)