-
Notifications
You must be signed in to change notification settings - Fork 0
Standard initialization
Note : this article is only about integrating the voxeet-ios-sdk
into your app. If you are using UI components, please head to the UXKit
.
Before any use of the SDK into your project, please head to the developer portal to create your account or login and retrieve your api keys.
The consumer key and the consumer secret will let you use the SDK and to bring Video and Audio features to your users.
Enable background mode (go to your target settings -> 'Capabilities' -> 'Background Modes')
- Turn on 'Audio, AirPlay and Picture in Picture'
- Turn on 'Voice over IP'
If you want to support CallKit (receiving incoming call when application is killed) with VoIP push notification, enable 'Push Notifications' (you will need to upload your VoIP push certificate to the Voxeet developer portal).
Add those permissions right into your app's Info.plist
file:
- NSMicrophoneUsageDescription
- NSCameraUsageDescription
Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks.
You can install Carthage with Homebrew using the following command:
$ brew update
$ brew install carthage
To integrate VoxeetSDK into your Xcode project using Carthage, specify it in your Cartfile
:
github "voxeet/voxeet-ios-sdk" ~> 1.0
Run carthage update
to build the frameworks and drag VoxeetSDK.framework
and WebRTC.framework
into your Xcode project. More information at https://github.com/Carthage/Carthage#if-youre-building-for-ios-tvos-or-watchos.
Download the lastest release zip:
VoxeetSDK: https://github.com/voxeet/voxeet-ios-sdk/releases
Unzip and drag and drop frameworks into your project, select 'Copy items if needed' with the right target. Then in the general tab of your target, add the VoxeetConferenceKit.framework
, VoxeetSDK.framework
and WebRTC.framework
into 'Embedded Binaries'.
The SDK as 2 main initialization mode. We will focus on the fastest one but an other article will guide into our OAuth feature.
To finish the SDK initialization, you simply need to use the initialize
singleton method available in the VoxeetSDK
class.
VoxeetSDK.shared.initialize(consumerKey: "YOUR_CONSUMER_KEY", consumerSecret: "YOUR_CONSUMER_SECRET")
When User's information is created alongside the SDK use, those information are only set in memory (the classes only hold in-memory information)
The SDK let you connect an user using directly using the open
method from the session
service.
let user = VTUser(externalID: "1234", name: "Username", avatarURL: "https://voxeet.com/logo.jpg")
VoxeetSDK.shared.session.open(user: user) { error in }
Disconnecting users will unregister push notifications and currently connected WebSockets to the servers dedicated to the Voxeet functionnalities.
The SDK let you disconnect an user using directly the close
method from the session
service.
VoxeetSDK.shared.session.close { error in }
And that's it, from this point, any SDK methods will be available and ready to go.
copyright Voxeet 2019
-
Initialization
-
Managing Conference
-
Sharing
-
Advanced