Join a meeting for any user

The code on this page works with either the default UI or the custom UI.

This content applies to all user types.

Join with a meeting number

To join a meeting, retrieve a ZoomSDKMeetingService instance from ZoomSDK.

guard let meetingService = ZoomSDK.shared().getMeetingService() else { return }
ZoomSDKMeetingService *meetingService = [[ZoomSDK sharedSDK] getMeetingService];
if (!meetingService) {
    return;
}

Then, configure the ZoomSDKJoinMeetingElements.

let joinParams = ZoomSDKJoinMeetingElements()
joinParams.displayName = "DISPLAY_NAME"
joinParams.meetingNumber = 123456789
joinParams.password = "PASSWORD"
// some additional options
joinParams.userType = ZoomSDKUserType_WithoutLogin
joinParams.onBehalfToken = "ON_BEHALF_TOKEN"
joinParams.isNoAudio = false
joinParams.isNoVideo = false
ZoomSDKJoinMeetingElements *joinParams = [[ZoomSDKJoinMeetingElements alloc] init];
joinParams.displayName = @"DISPLAY_NAME";
joinParams.meetingNumber = 123456789;
joinParams.password = @"PASSWORD";
// some available options
joinParams.userType = ZoomSDKUserType_WithoutLogin;
joinParams.onBehalfToken = @"ON_BEHALF_TOKEN";
joinParams.isNoAudio = NO;
joinParams.isNoVideo = NO;

Once the options and parameters are ready, pass them to joinMeetingWithParams to join the meeting.

let result = meetingService.joinMeeting(joinParams)
ZoomSDKError result = [meetingService joinMeeting:joinParams];

Join with a vanity ID

A vanity ID is a special and personalized ID that uniquely belongs to a user.

To join a meeting with vanity ID instead of meeting number, the process is exactly the same as joining a meeting with meeting number. Just store the vanityID in ZoomSDKJoinMeetingElements instead of storing meetingNumber.

joinParams.userType = ZoomSDKUserType_WithoutLogin
joinParams.vanityID = "VANITY_ID"
joinParams.onBehalfToken = "ON_BEHALF_TOKEN" // Either onBehalfToken or ZAK must be presented
joinParams.zak = "ZAK"
joinParams.displayName = "DISPLAY_NAME"
joinParams.meetingNumber = 123456789
joinParams.password = "PASSWORD"
joinParams.userType = ZoomSDKUserType_WithoutLogin;
joinParams.vanityID = @"VANITY_ID";
joinParams.onBehalfToken = @"ON_BEHALF_TOKEN"; // Either onBehalfToken or ZAK must be presented
joinParams.zak = @"ZAK";
joinParams.displayName = @"DISPLAY_NAME";
joinParams.password = @"PASSWORD";

Join Meeting status

To know whether the join meeting action is a success or not, or to get the error message, listen to the onMeetingStatusChange callback under ZoomSDKMeetingServiceDelegate.

guard let meetingService = ZoomSDK.shared().getMeetingService() else { return }
meetingService.delegate = self
extension ViewController: ZoomSDKMeetingServiceDelegate {
    func onMeetingStatusChange(_ state: ZoomSDKMeetingStatus, meetingError error: ZoomSDKMeetingError, end reason: EndMeetingReason) {
    }
}
// In your .h file
@interface TestWindow : NSWindowController <ZoomSDKMeetingServiceDelegate> {
}
// In your .m file
ZoomSDKMeetingService *meetingService = [[ZoomSDK sharedSDK] getMeetingService];
if (!meetingService) {
    return;
}
meetingService.delegate = self;
- (void)onMeetingStatusChange:(ZoomSDKMeetingStatus)state meetingError:(ZoomSDKMeetingError)error EndReason:(EndMeetingReason)reason {
}