API
ZegoUIKitPrebuiltCallInvitationService
initWithAppID
You must call this method as soon as the user login(or re-login, auto-login) to your app.
function prototype:
Untitled/// Initialization of call service /// - Parameters: /// - appID: Your appID /// - appSign: Your appSign /// - userID: User unique identification /// - userName: userName /// - config: CallInvitation personalized configuration public func initWithAppID(_ appID: UInt32, appSign: String, userID: String, userName: String, config: ZegoUIKitPrebuiltCallInvitationConfig)
1
unInit
Should be used in pairs with the
initWithAppID
api.function prototype:
Untitled/// Deinitialize call service public func unInit()
1
getPrebuiltCallVC
You can access the call page controller through this interface
function prototype:
Untitled/// Obtain the call page controller /// - Returns: ZegoUIKitPrebuiltCallVC public func getPrebuiltCallVC()-> ZegoUIKitPrebuiltCallVC?
1
setRemoteNotificationsDeviceToken
If you want to use offline invitations you must call this interface to set the token of the current device
function prototype:
Untitled/// Set the device Token to be pushed offline /// - Parameter deviceToken: device token public static func setRemoteNotificationsDeviceToken(_ deviceToken: Data)
1
endCall
You can call this interface to end the current call
function prototype:
Untitled/// End the call public func endCall()
1
setAudioOutputToSpeaker
You can route the audio to the speaker by calling this interface.
function prototype:
Untitledpublic func setAudioOutputToSpeaker(outputToSpeaker: Bool)
1
getAudioRouteType
You can use this interface to get the current audio route
function prototype:
Untitledpublic func getAudioRouteType() -> ZegoUIKitAudioOutputDevice
1
ZegoUIKitPrebuiltCallVC
addButtonToBottomMenuBar
You can add custom buttons to the bottom bar by calling this interface
function prototype:
Untitledpublic func addButtonToBottomMenuBar(_ button: UIButton)
1
addButtonToTopMenuBar
You can add custom buttons to the top bar by calling this interface
function prototype:
Untitledpublic func addButtonToTopMenuBar(_ button: UIButton)
1
finish
You can call this method to end the current call.
function prototype:
Untitledpublic func finish()
1