kickGroupMember

Introduction

Remove or kick some members out of the group.

All the members of the group,including self, will receive the OnMemberKicked callback, after members have been removed or kicked.

AVChatRoom: Do not supports kick members, as it has no restrictions for entering the room, but you can mute a member by muteGroupMember.

Work Group: Only group owner and APP administrators can kick members.

Public Group: Only group owner, group administrators and APP administrators can kick members.

Parameter details

Parameter name Parameter type Required Description
groupID string yes The group ID.
memberList string[] yes The list of members that to be kicked or removed.

Returned template

V2TimCallback

{
    code : number
    desc : string
}

Return value details

name type description
code number Request result: Error codes. 0 means success.
desc string The description of the error. It will be empty if success.

Code example

import { TencentImSDKPlugin } from 'react-native-tim-js';


const kickGroupMemberRes = await TencentImSDKPlugin.v2TIMManager
    .getGroupManager()
    .kickGroupMember(
        'groupID',
        [],
        'reason'
    );
if (kickGroupMemberRes.code === 0) {

}

results matching ""

    No results matching ""