Rate this page:

VICall

Interface that may be used for call operations like answer, reject, hang up and mid-call operations like hold, start/stop video and others.

Methods

addDelegate:

Copy URL
addDelegate:(delegate: 

id<VICallDelegate>

):

void

Adds a call delegate to handle the call events.

Parameters

Returns

  • type:

    void

answerWithSettings:

Copy URL
answerWithSettings:(settings: 

VICallSettings *

):

void

Answers an incoming call.

Parameters

  • settings:

    VICallSettings *

    Call settings with additional call parameters, such as the preferred video codec, custom data, extra headers etc.

Returns

  • type:

    void

duration

Copy URL
duration(): 

NSTimeInterval

Gets a call's duration.

Returns

  • type:

    NSTimeInterval

hangupWithHeaders:

Copy URL
hangupWithHeaders:(headers: 

nullable NSDictionary *

):

void

Terminates a call. Call should be either established or dialing.

Parameters

  • headers:

    nullable NSDictionary *

    Optional set of headers to be sent with the message. Names must begin with "X-" to be processed by the SDK

Returns

  • type:

    void

issueLevelForType:

Copy URL
issueLevelForType:(type: 

VIQualityIssueType

):

VIQualityIssueLevel

Gets the current level of the specific quality issue.

Parameters

qualityIssues

Copy URL
qualityIssues(): 

NSArray<VIQualityIssueType> *

Gets all quality issues types.

Returns

rejectWithMode:headers:

Copy URL
rejectWithMode:headers:(mode: 

VIRejectMode

,
headers:

nullable NSDictionary *

):

void

Rejects an incoming call.

Parameters

  • Call rejection mode

  • headers:

    nullable NSDictionary *

    Optional set of headers to be sent with the message. Names must begin with "X-" to be processed by the SDK

Returns

  • type:

    void

removeDelegate:

Copy URL
removeDelegate:(delegate: 

id<VICallDelegate>

):

void

Removes the previously added delegate.

Parameters

Returns

  • type:

    void

sendDTMF:

Copy URL
sendDTMF:(dtmf: 

NSString *

):

BOOL

Sends a DTMF within a call.

Parameters

  • dtmf:

    NSString *

    DTMFs

Returns

  • type:

    BOOL

sendInfo:mimeType:headers:

Copy URL
sendInfo:mimeType:headers:(body: 

NSString *

,
mimeType:

NSString *

,
headers:

nullable NSDictionary *

):

void

Sends an INFO message within a call.

Parameters

  • body:

    NSString *

    Custom string data

  • mimeType:

    NSString *

    MIME type of info

  • headers:

    nullable NSDictionary *

    Optional set of headers to be sent with the message. Names must begin with "X-" to be processed by the SDK

Returns

  • type:

    void

sendMessage:

Copy URL
sendMessage:(message: 

NSString *

):

void

Sends a message within a call.

Implemented atop of SIP INFO for communication between the call endpoint and the Voximplant Cloud, and is separated from Voximplant messaging API.

Parameters

  • message:

    NSString *

    Message text

Returns

  • type:

    void

setHold:completion:

Copy URL
setHold:completion:(hold: 

BOOL

,
completion:

nullable VICompletionBlock

):

void

Holds or unholds a call.

Hold functionality is not supported in conference calls. In case of a conference call it returns VICallErrorCodeIncorrectOperation via the completion block.

Parameters

  • hold:

    BOOL

    Whether to hold or unhold the call

  • completion:

    nullable VICompletionBlock

    Completion block to handle the result of the operation

Returns

  • type:

    void

setSendVideo:completion:

Copy URL
setSendVideo:completion:(video: 

BOOL

,
completion:

nullable VICompletionBlock

):

void

Starts or stops sending video to the call.

Starting the version 2.34.3 the API behaves the same way for conference and video calls.

For the version 2.34.2 and below for the conference video call mutes or un-mutes sending video (video stream in the 'muted' state still consumes a small bandwidth).

Parameters

  • video:

    BOOL

    Whether to send the video to the call

  • completion:

    nullable VICompletionBlock

    Completion block to handle the result of the operation

Returns

  • type:

    void

start

Copy URL
start(): 

void

Starts an outgoing call.

Returns

  • type:

    void

startInAppScreenSharing:

Copy URL
startInAppScreenSharing:(completion: 

nullable VICompletionBlock

):

void

Starts in-app screen sharing.

Note that before recording actually starts, the user may be prompted with UI to confirm recording. Captures screen only inside the application. Simulator is not supported.

Use [VICall setSendVideo:completion:] method with "sendVideo" parameter "YES" value to return to the default capture mode (camera or custom camera mode). Use [VICall setSendVideo:completion:] method with "sendVideo" parameter "NO" value to stop screen capturing.

Video of the screen is sent in HD quality (720p).

Parameters

  • completion:

    nullable VICompletionBlock

    Completion block to handle the result of the operation

Returns

  • type:

    void

startReceiveVideoWithCompletion:

Copy URL
startReceiveVideoWithCompletion:(completion: 

nullable VICompletionBlock

):

void

Starts receiving video if receiving video has not been enabled before. Stopping receiving video during the call is not supported.

Parameters

  • completion:

    nullable VICompletionBlock

    Completion block to handle the result of operation

Returns

  • type:

    void

Props

callId

Copy URL
callId: 

Call's ID.

Returns

  • type:

    NSString *

callKitUUID

Copy URL
callKitUUID: 

CallKit UUID that may be used to match an incoming call with a push notification received before.

Always nil for outgoing calls on VICall instance creation.

For outgoing calls it is recommended to set CXStartCallAction.callUUID value to this property on handling CXStartCallAction

Returns

  • type:

    NSUUID *

endpoints

Copy URL
endpoints: 

Array of the endpoints associated with a call.

Returns

localVideoStreams

Copy URL
localVideoStreams: 

Local video streams associated with the call.

Returns

qualityIssueDelegate

Copy URL
qualityIssueDelegate: 

Sets VIQualityIssueDelegate to monitor issues that affect the call quality.

Returns

sendAudio

Copy URL
sendAudio: 

Whether to transfer audio from the microphone into a call.

Setting this property enables or disables audio transfer.

Returns

  • type:

    BOOL

videoEnabled

Copy URL
videoEnabled: 

Whether video is enabled in a call.

Returns

  • type:

    BOOL

videoSource

Copy URL
videoSource: 

Video source currently used in the call.

Default value:

Must be set before using [VICall start] and [VICall answerWithSettings:] if needed.

Returns