Skip to main content
MeetingKit is a singleton with only one instance per process. It carries only account-level and device-level capabilities: login, IM, local capture and preview, audio routing, process-side screen capture integration, the pre-call network check, and meeting queries and scheduling. All in-meeting operations and events are scoped to a room and go through a MeetingKitRoom instance created with createRoomWithDelegate:. The same account can create and enter multiple rooms at the same time, and the media and business state of each room are independent of each other.
Starting with 2.0.0, the in-meeting APIs have moved out of this class. For enterRoom:onSuccess:onFailed:, requestOpenCamera:view:onSuccess:onFailed:, sendRoomChatMessage:messageType:targetId:onSuccess:onFailed:, the adminXxx family, cloud recording, the waiting room, sub-meetings, sign-in, and similar APIs, use MeetingKitRoom instead.

Core APIs

sharedInstance()

+ (MeetingKit *)sharedInstance Creates the MeetingKit instance (singleton).

version()

- (NSString *)version Gets the MeetingKit version number.

language

@property (nonatomic, copy, nullable) NSString *language SDK language (since 2.2.0) A BCP 47 language tag such as @"zh-CN" or @"en" (forms like zh_CN are normalized to zh-CN). nil or an empty string means following the system language ([NSLocale preferredLanguages].firstObject).
  • Only affects the Accept-Language request header sent to the backend: the backend returns business error messages in that language (the message of backend codes 1000–99999)
  • Error messages produced by the SDK itself are always in English and don’t change with the language
  • Applies process-wide and isn’t reset by login / logout; we recommend setting it before login
  • Since 2.2.1, it also sets the underlying RTCEngineKit.language, so the meeting layer and the RTC layer use the same language; in 2.2.0, RTC layer requests carry no language

currentLanguage

@property (nonatomic, copy, readonly) NSString *currentLanguage The language actually in effect (since 2.2.0; read-only) Priority: language if set; otherwise the system’s preferred language; @"zh" if that can’t be obtained.

addDelegate:()

- (void)addDelegate:(id <MeetingKitDelegate>)delegate Sets the global event callback. Through MeetingKitDelegate you receive two kinds of global event notifications: audio route changes and app performance. For in-room events, implement MeetingKitRoomDelegate and pass it in when creating the room.

createRoomWithDelegate:()

- (nullable MeetingKitRoom *)createRoomWithDelegate:(nullable id<MeetingKitRoomDelegate>)delegate Creates an independent meeting room instance. Each call returns a new MeetingKitRoom instance, and instances don’t affect each other. To be in multiple rooms at the same time, call it multiple times and hold each instance separately. The instance becomes invalid after you call the room’s exitRoom:, and you need to create a new one.

getRooms()

- (NSArray<MeetingKitRoom *> *)getRooms Gets the list of meeting rooms you’re currently in. Instances that have been created but haven’t entered the meeting yet, or that have already exited, aren’t included in the result.

loginWithToken:appGroup:onSuccess:onFailed:()

- (void)loginWithToken:(NSString *)token appGroup:(NSString *)appGroup onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Login API. You need to initialize the user information first before you can enter a room and perform other operations. This API enables process-wide local log capture by default.

loginWithToken:appGroup:logConfig:onSuccess:onFailed:()

- (void)loginWithToken:(NSString *)token appGroup:(NSString *)appGroup logConfig:(SEALogConfig *)logConfig onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Logs in with a custom log configuration. You need to initialize the user information first before you can enter a room and perform other operations.

logout()

- (void)logout Logout API. Exits and destroys all room instances and releases resources, so you don’t need to call exitRoom: on each room instance.

IM APIs

enableImWithDelegate:onSuccess:onFailed:()

- (void)enableImWithDelegate:(nullable id<MeetingKitIMDelegate>)delegate onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Enables IM. Call this API to turn on the SDK’s IM service, which you can use to build features such as pre-meeting calls and notifications.

disableIm()

- (void)disableIm Disables IM. When you no longer need the IM service, disable it with this API.

Meeting APIs

getMeetingList:onFailed:()

- (void)getMeetingList:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets the meeting list.

getMoreMeetingList:onFailed:()

- (void)getMoreMeetingList:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets more of the meeting list (next page).

getHistoryMeetingList:onFailed:()

- (void)getHistoryMeetingList:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets the past meeting list.

getMoreHistoryMeetingList:onFailed:()

- (void)getMoreHistoryMeetingList:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets more of the past meeting list (next page).

getMeetingDetailsWithMeetingId:onSuccess:onFailed:()

- (void)getMeetingDetailsWithMeetingId:(NSString *)meetingId onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets meeting details.

getMeetingDetailsWithRoomNo:onSuccess:onFailed:()

- (void)getMeetingDetailsWithRoomNo:(NSString *)roomNo onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets meeting details.

getParticipantListsWithMeetingId:onSuccess:onFailed:()

- (void)getParticipantListsWithMeetingId:(NSString *)meetingId onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets the attendance records of a meeting.

getMoreParticipantListsWithMeetingId:onSuccess:onFailed:()

- (void)getMoreParticipantListsWithMeetingId:(NSString *)meetingId onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets more attendance records (next page).

requestCancelMeetingWithMeetingId:onSuccess:onFailed:()

- (void)requestCancelMeetingWithMeetingId:(NSString *)meetingId onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Requests to cancel a meeting.

createRoom:onSuccess:onFailed:()

- (void)createRoom:(SEAMeetingParam *)params onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Creates a room.

updateRoom:onSuccess:onFailed:()

- (void)updateRoom:(SEAMeetingParam *)params onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Updates room data.

Resource APIs

Available since 2.4.0. Files don’t pass through the SDK: first call presignedPutObject:meetingId:ext:onSuccess:onFailed: to get a signed upload URL and upload with your own HTTP PUT; store and send only the resource key key, and when you need to download, call presignedGetObjectWithResKey:resId:onSuccess:onFailed: to get a fresh download URL.

presignedPutObject:meetingId:ext:onSuccess:onFailed:()

- (void)presignedPutObject:(SEAResourceType)type meetingId:(NSString *)meetingId ext:(NSString *)ext onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Presigned upload: requests an upload URL from the meeting layer for uploading directly to storage. After you get the result:
  • Upload the file bytes to url with an HTTP PUT, with the header Content-Type: application/octet-stream (not a multipart form).
  • Store and send key in your business logic, not url: the upload URL is signed and expires in about 2 hours.
  • Sending a chat file: after a successful upload, call sendRoomChatMessage:messageType:targetId:onSuccess:onFailed:() with SEAMessageTypeFile, and use the JSON string {"key":"<key>","name":"original file name","size":"1.20MB"} as the message, which interoperates with other platforms.
Example
The example builds message by string concatenation only to show the fields. In real code, generate it with NSJSONSerialization so that characters such as quotes in the file name don’t break the JSON.

presignedGetObjectWithResKey:resId:onSuccess:onFailed:()

- (void)presignedGetObjectWithResKey:(nullable NSString *)resKey resId:(nullable NSString *)resId onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Presigned download: exchanges a resource key for a temporary download URL. The download URL is signed and expires in about 2 hours. Request a new one before each download and don’t cache it.

Pre-call network check APIs

Available since 2.3.0; requires RTCEngineKit >= 3.3.0. Call it before joining: it doesn’t require entering a room or connecting to RTC. The check logic is the same as SRTC’s networkCheck:onItem:completion:: items are checked in the fixed order permission → connectivity → mtu → dns → server; when everything is normal it finishes within about 5 seconds, and takes at most about 10 seconds. The meeting layer adds a meeting_api subcheck (whether the meeting API is reachable) to the server item, and uses its own SEANetworkCheckXxx types.

networkCheck:onItem:completion:()

- (SEAError)networkCheck:(nullable SEANetworkCheckParams *)params onItem:(nullable SEANetworkCheckItemBlock)onItem completion:(nullable SEANetworkCheckCompletionBlock)completion Starts the pre-call network check. Return value Example
The meeting_api subcheck of server
  • It runs in parallel with the RTC checks and doesn’t add to the total time; any HTTP response counts as reachable.
  • If the meeting API is unreachable, server is fail with reason meeting_api_unreachable; if server has already failed because of an RTC subcheck, the RTC reason is kept.
  • When not logged in, the meeting API address isn’t available, so meeting_api is skipped with reason server_info_unavailable, which doesn’t affect the overall status.
  • The other items’ checks and reason codes are the same as SRTC’s; see SRTC iOS Types.

cancelNetworkCheck()

- (void)cancelNetworkCheck Cancels the pre-call network check. After cancellation, onItem is no longer called and completion finishes with SEAErrorUserCancelled (103026). You can start a new check right away. Logging out also cancels a running check.

User APIs

getAgentList:keyword:onSuccess:onFailed:()

- (void)getAgentList:(NSArray <NSNumber *> *)typesList keyword:(nullable NSString *)keyword onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets the device list.

getMoreAgentList:keyword:onSuccess:onFailed:()

- (void)getMoreAgentList:(NSArray <NSNumber *> *)typesList keyword:(nullable NSString *)keyword onSuccess:(nullable SEASuccessBlock)onSuccess onFailed:(nullable SEAFailedBlock)onFailed Gets more of the device list (next page).

Local capture APIs

startLocalPreview:view:()

- (RTCEngineError)startLocalPreview:(BOOL)frontCamera view:(VIEW_CLASS *)view Starts the local camera preview. Available since 2.6.0. Can be called before entering a meeting (outside a meeting, for example on the waiting room or waiting-for-host page). It only captures and previews locally and doesn’t publish to the meeting. Call stopLocalPreview() before entering; after entering, the room’s requestOpenCamera turns the camera on again and publishes it. Return value: RTCEngineErrorCameraNoAuthorized (103231) if camera permission isn’t granted.

stopLocalPreview()

- (RTCEngineError)stopLocalPreview Stops the local camera preview. Available since 2.6.0. Use it together with startLocalPreview:view:(): call it when leaving the out-of-meeting preview page or before entering a meeting. Return value: RTCEngineErrorCameraNoAuthorized (103231) if camera permission isn’t granted.

updateLocalView:()

- (void)updateLocalView:(VIEW_CLASS *)view Updates the local camera preview.

switchCamera()

- (void)switchCamera Switches between the front and rear cameras.

setLocalPreviewMirror:()

- (void)setLocalPreviewMirror:(BOOL)mirror Sets the local preview mirroring preference for the front camera. Applies only to the local preview and doesn’t affect the published data. The front camera is mirrored according to mirror, and the rear camera is never mirrored; after you switch cameras, the SDK applies the corresponding policy automatically.

currentCameraDirection()

- (SEACameraDirection)currentCameraDirection Gets the current camera direction. Returns the direction of the camera currently used for capture; see SEACameraDirection.

Audio routing APIs

switchAudioRoute:()

- (void)switchAudioRoute:(SEAAudioRoute)route Switches the audio route. Use this API to request switching between built-in audio output devices, such as the speaker and the earpiece. When a Bluetooth or wired headset is present, iOS decides which external device is used. The actual final route is whatever currentAudioRoute and the onAudioRouteChange:previousRoute:() callback in MeetingKitDelegate report.

currentAudioRoute()

- (SEAAudioRoute)currentAudioRoute Gets the system’s current actual audio route. Returns the audio route the system is actually using, such as the speaker, the earpiece, or a Bluetooth or wired headset. See SEAAudioRoute.

headphoneDeviceAvailable()

- (BOOL)headphoneDeviceAvailable Whether a wired headset is present. Returns whether a wired headset is present.

bluetoothDeviceAvailable()

- (BOOL)bluetoothDeviceAvailable Whether a Bluetooth headset is present. Returns whether a Bluetooth headset is present.

Virtual background APIs

Virtual background applies to the single shared camera capture pipeline in the process. It’s a device-level capability, and its settings apply to all rooms at once. After you switch cameras during the meeting or reconnect after a disconnect, the SDK automatically re-applies the current configuration, so you don’t need to do it yourself. For usage, see Virtual background.

installVirtualBackground:()

- (SEAError)installVirtualBackground:(nullable NSString *)modelPath Installs the virtual background component. We recommend calling it before entering the room and turning on the camera. After installation, you also need to call enabledVirtualBackground:() for it to take effect.

uninstallVirtualBackground()

- (void)uninstallVirtualBackground Uninstalls the virtual background component. Releases the inference session and related buffers.

enabledVirtualBackground:()

- (SEAError)enabledVirtualBackground:(BOOL)enabled Virtual background switch. After installation, it’s off by default and must be turned on explicitly. When off, frames pass straight through with zero overhead, and no inference runs. Calling it before the component is installed returns SEAErrorVirtualBackgroundNotInstalled (103028; SEAErrorConflict before 2.2.0).

setVirtualBackgroundBlur:()

- (void)setVirtualBackgroundBlur:(NSInteger)level Sets background blur. Mutually exclusive with setVirtualBackgroundImage:(); the later call wins.

setVirtualBackgroundImage:()

- (void)setVirtualBackgroundImage:(nullable UIImage *)image Sets background replacement. Mutually exclusive with setVirtualBackgroundBlur:(); the later call wins.

setVirtualBackgroundInferenceInterval:()

- (void)setVirtualBackgroundInferenceInterval:(NSInteger)interval Sets the segmentation inference interval. A performance tier for you to set per device model; we don’t recommend exposing it to end users.

setVirtualBackgroundMaskSync:()

- (void)setVirtualBackgroundMaskSync:(BOOL)enabled Sets mask sync. Eliminates misaligned trails when waving, at the cost of the video update rate dropping to the mask rate. When interval is 1, turning it on or off makes no difference at all; it only takes effect after you increase the inference interval.

isVirtualBackgroundEnabled()

- (BOOL)isVirtualBackgroundEnabled Gets whether virtual background is on.

Screen sharing APIs

broadcastStartedWithAppGroup:delegate:()

- (void)broadcastStartedWithAppGroup:(NSString *)appGroup delegate:(id<MeetingKitScreenDelegate>)delegate Starts screen recording in the extension and binds the delegate. Use this method in the extension’s SampleHandler. After screen capture is turned off, the SDK notifies you of the current device capture status through the meetingRoom:onScreenRecordStatus:() callback in MeetingKitRoomDelegate. Based on the status in the callback, choose whether to request to start sharing or to stop sharing.

sendSampleBuffer:withType:()

- (void)sendSampleBuffer:(CMSampleBufferRef)sampleBuffer withType:(RPSampleBufferType)sampleBufferType Sends screen capture frames from the extension. Use this method in the extension’s SampleHandler.