iOS SDK Overview
The EnableX iOS SDK integrates EnableX RTC sessions with your Native iOS applications. The SDK consists of APIs required to communicate with EnableX Signalling and Media servers and to listen to event-based notifications during a session.
Download iOS SDK v3.0.5
Released: August 21, 2024. v2.3.2+ are compatible with iOS 13 and above.
Download iOS WebRTC SDK
Released: May 8, 2023Note:
- iOS SDK v2.3.3 is compatible with iOS 12 or above
- iOS SDK v3.0.0 and above are built using SWIFT.
- Limitation of EnableX iOS SDK (Swift)
- If your Application is built using Objective-C and you are using EnableX iOS SDK (Swift), you can't publish Canvas Stream. Therefore, all features that needs initiation of Canvas Stream, e.g. Annotation, Whiteboard etc.; will not work. However, your Application still can receive Canvas Stream and related features.
- All other SDK Methods will work as excepted in this case.
- On the other hand, if your Application is built using Swift and your are using EnableX iOS SDK (Swift), all features will will work as expected.
- EnableX iOS SDK (Swift) will require
Socket.IO-Client-Swift v16.1.0
Library.
Getting Started
The EnxRTCiOS directory contains the EnxRTCiOS iOS SDK framework. Add this framework to your project. The EnxRTCiOS iOS SDK is supported on iOS 12 and later versions and XCode 9 and later versions.
- Install CocoaPods. For installation instructions, see this web page.
- Open the terminal.
- Go to the project directory and run
pod init
. - To integrate EnxRTCiOS with your Xcode project using CocoaPods, specify EnxRTCiOS as the pod name.
- After adding all the required libraries in PodFile, go to the terminal and run
pod Install
. - Reopen your project in Xcode using the new .xcworkspace file.
Note: The EnablexWebRTC framework is also installed when the EnxRTCiOS framework is installed through the pod. To use EnableX iOS SDK, you must use Socket.IO-Client-Swift(15.0.0) in your project with these pod names:
pod 'Socket.IO-Client-Swift', '~> 16.1.0'
.
Errors and Exceptions
When an SDK method call encounters an issue and fails, a JSON object containing the details of the error is returned through callback. Below is an example of this JSON object.
{"errorCode": Number,"msg": "String","desc": "String"}
The parameters added in this example are described below.
Parameter Name | Type | Description |
---|---|---|
errorCode | Number | Returns an error code depending on the error encountered. |
msg | String | Returns an error message depending on the error encountered. |
desc | String | Optional. Returns explanation of the error encountered. |
SDK Methods
The SDK provides several methods for implementing different features and functionalities. For more information, see List of SDK Methods.
Media Devices
The SDK provides several methods to access device cameras and microphones that can be used to create media streams to publish into the video rooms. For more information, see Get Media Devices.
Stream Configuration
The SDK supports local and remote streams. For more information, see:
Room Configuration
The SDK supports the following room configurations:
In-session Communication
The SDK provides several methods for managing in-session communication including chat, custom signalling, file sharing, screen sharing, canvas streaming, annotations, and live transcription. For more information, see In-Session Communication.
Session Management
The SDK provides several methods for managing different aspects of video sessions including recording a session, watermarking a recorded file, live recording with UI, muting or unmuting a room or a participant, forcing room entry restrictions, disconnecting a user from a session, extending or concluding a session, switching participant roles, RTMP live streaming, HLS streaming, pinning or unpinning a user, spotlighting a user, and switching the room mode. For more information, see Session Management.
Breakout Room
The SDK provides several methods for implementing breakout rooms. For more information, see Breakout Room.
Floor Access Control in Lecture Mode
Participants can request for floor access in the Lecture mode. The SDK provides different methods to implement floor access. For more information, see Floor Access Control in Lecture Mode.
Live Statistics
The SDK provides several methods to obtain live statistics of local, remote, canvas streaming, and screen sharing during a session. For more information, see Live Statistics.
Utilities
The SDK provides several methods for managing different aspects of video sessions through different utilities. For more information, see Utilities.