tencent cloud

Feedback

Android&iOS&Flutter

Last updated: 2024-06-17 17:41:52
    This article introduces the use of the group call feature, such as initiating a group call and joining a group call.

    Expected outcome

    TUICallKit supports group calls. The expected outcome is shown in the figure below.
    Initiate a group call
    Receive a group call request
    Accept group call requests
    
    
    
    
    
    
    
    
    

    Create groupID

    Before using the group call feature, you need to create a group first and initiate a group call in an existing group.
    Method one: Create a group by calling the Chat API, see Chat Group Management.
    Method two: Create a group manually through the console, see Console group management.

    Group call

    Initiate a group call

    Launch a group call using the groupCall API.
    Android(Kotlin)
    Android(Java)
    iOS(Swift)
    iOS(Objective-C)
    Flutter(Dart)
    import com.tencent.qcloud.tuikit.tuicallengine.TUICallDefine import com.tencent.qcloud.tuikit.tuicallkit.TUICallKit
    
    TUICallKit.createInstance(context).groupCall("12345678", Arrays.asList("jane", "mike", "tommy"), TUICallDefine.MediaType.Video)
    import com.tencent.qcloud.tuikit.tuicallengine.TUICallDefine; import com.tencent.qcloud.tuikit.tuicallkit.TUICallKit;
    
    TUICallKit.createInstance(context).groupCall("12345678", Arrays.asList("jane", "mike", "tommy"),TUICallDefine.MediaType.Video);
    import TUICallKit_Swift
    import TUICallEngine
    
    TUICallKit.createInstance().groupCall(groupId: "12345678",
    userIdList: ["denny", "mike", "tommy"],
    callMediaType: .video)
    #import <TUICallKit_Swift/TUICallKit_Swift-Swift.h>
    #import <TUICallEngine/TUICallEngine.h>
    
    [[TUICallKit createInstance] groupCallWithGroupId:@"12345678"
    userIdList:@[@"denny", @"mike", @"tommy"]
    callMediaType:TUICallMediaTypeVideo];
    import 'package:tencent_calls_uikit/tencent_calls_uikit.dart';
    
    void groupCall() {
    TUICallKit.instance.groupCall('0001', ['denny', 'mike', 'tommy'], TUICallMediaType.video);
    }

    Join a group call

    Actively join an existing audio and video call in the group by calling the joinInGroupCall API.
    Android(Kotlin)
    Android(Java)
    iOS(Swift)
    iOS(Objective-C)
    Flutter(Dart)
    import com.tencent.qcloud.tuikit.TUICommonDefine
    import com.tencent.qcloud.tuikit.tuicallengine.TUICallDefine import com.tencent.qcloud.tuikit.tuicallkit.TUICallKit
    
    var roomId = TUICommonDefine.RoomId()
    roomId.intRoomId = 123321
    var groupId = "12345678"
    TUICallKit.createInstance(context).joinInGroupCall(roomId, groupId, TUICallDefine.MediaType.Video)
    import com.tencent.qcloud.tuikit.TUICommonDefine;
    import com.tencent.qcloud.tuikit.tuicallengine.TUICallDefine; import com.tencent.qcloud.tuikit.tuicallkit.TUICallKit;
    
    TUICommonDefine.RoomId roomId = new TUICommonDefine.RoomId();
    roomId.intRoomId = 123321;
    String groupId = "12345678";
    TUICallKit.createInstance(context).joinInGroupCall(roomId, groupId, TUICallDefine.MediaType.Video);
    import TUICallKit_Swift
    import TUICallEngine
    
    let roomId = TUIRoomId()
    roomId.intRoomId = 123321
    TUICallKit.createInstance().joinInGroupCall(roomId: roomId,
    groupId: "1234567",
    callMediaType: .video)
    
    #import <TUICallKit/TUICallKit.h>
    #import <TUICallEngine/TUICallEngine.h>
    
    TUIRoomId *roomId = [[TUIRoomId alloc] init];
    roomId.intRoomId = 123321;
    [[TUICallKit createInstance] joinInGroupCallWithRoomId:roomId
    groupId:@"223344"
    callMediaType:TUICallMediaTypeVideo];
    import 'package:tencent_calls_uikit/tencent_calls_uikit.dart';
    
    void joinInGroupCall() {
    TUIRoomId roomId = TUIRoomId();
    roomId.intRoomId = 123321;
    TUICallKit.instance.joinInGroupCall(roomId, '1234567', TUICallMediaType.video);
    }
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support