Call feature is essential for the modern day communication. Call sdk allows users to make a audio/video call with the another sdk users.
Before making the call, make sure you have implemented the helper object.
Make a voice call#
Initiate a call by providing the callee’s user JID into the makeVoiceCall method. Once the call initiated successfully, a callStatusListener callback will be triggered and callee user call status will be received here.
Request Params#
Param | Description | Type | Required |
---|
[USER_JID ] | User JID | Array | true |
Response Params#
Arguments | Description | Type |
---|
statusCode | Status Code | Number |
message | Success/Error Message | String |
Make a video call#
Initiate a call by providing the callee’s user JID into the makeVideoCall method. Once the call initiated successfully, a callback callStatusListener will be triggered and callee user call status will be received here.
Request Params#
Param | Description | Type | Required |
---|
[USER_JID ] | User JID | Array | true |
Response Params#
Arguments | Description | Type |
---|
statusCode | Status Code | Number |
message | Success/Error Message | String |
Make a group voice call#
Initiate a call by providing the callee’s user JID & Group ID into the makeVoiceCall method. Once the call initiated successfully, a callStatusListener callback will be triggered and callee user call status will be received here.
Request Params#
Param | Description | Type | Required |
---|
[USER_JID ] | Pass User JID in array format | String | true |
GROUP_ID | Group ID | String | true |
Response Params#
Arguments | Description | Type |
---|
statusCode | Status Code | Number |
message | Success/Error Message | String |
Make a group video call#
Initiate a call by providing the callee’s user JID & Group ID into the makeVideoCall method. Once the call initiated successfully, a callback callStatusListener will be triggered and callee user call status will be received here.
Request Params#
Param | Description | Type | Required |
---|
[USER_JID ] | Pass User JID in array format | String | true |
GROUP_ID | Group ID | String | true |
Response Params#
Arguments | Description | Type |
---|
statusCode | Status Code | Number |
message | Success/Error Message | String |
Receive incoming call#
To receive an incoming call, a incomingCallListener callback should already be registered in the callee’s client app. Whenever a user make call to a user, the callee user will receive the calling data in this callback.
Response Params#
Arguments | Description |
---|
callTime | Call intiated time in timestamp format. |
callType | Describe the audio or video call. |
groupId | Contain the group ID If the call is group call. Otherwise, the value will be NULL. |
roomId | Call room ID. |
status | Status of the call(calling, ringing, connecting, connected). |
toUsers | Array of User JID of callee users. |
userJid | User JID who intiated the call |
Answer a call#
To answer a call use the answerCall method.
Response Params#
Arguments | Description | Type |
---|
statusCode | Status Code | Number |
message | Success/Error Message | String |
End a call#
To end a call use the endCall method.
Response Params#
Arguments | Description | Type |
---|
statusCode | Status Code | Number |
message | Success/Error Message | String |
Decline a call#
To decline a call use the declineCall method.
Response Params#
Arguments | Description | Type |
---|
statusCode | Status Code | Number |
message | Success/Error Message | String |