Join a meeting for any user

View as Markdown

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 }

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

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

let 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"

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) {

    }
}