Class: Conference

Conference

Conference

A conference is a type of Conversation that may require privilege to join
Conference may only be created if your enterprise has the conference feature enabled on the Apizee platform

Extends

Methods


<static> getAvailableEvents()

Returns available events for this class

Returns:
Type
Array.<string>

allowEntry(contact)

Allow entry to contact in waiting room as moderator

Parameters:
Name Type Description
contact Contact
Returns:
Type
Void

asyncGetCloudConversationId(conversation, options)

Parameters:
Name Type Description
conversation Conversation
options object

token session

Inherited From:
Returns:
Type
Promise.<integer>

cancelJoin()

Cancels an ongoing join request.

Overrides:

checkAccess(options)

Returns the access status of the conference represented by this one.

Parameters:
Name Type Description
options Object

Optional data.

Inherited From:
Returns:
Type
Promise.<ConferenceAccessStatus>

close(options)

Moderator only : closes this conversations forcing every participant to leave

Parameters:
Name Type Description
options object
Returns:
Type
Promise.<void>

denyEntry()

Deny entry to contact in waiting room as moderator

Properties:
Name Type Description
contact Contact
Returns:
Type
Void

destroy()

Cleans up all local resources attached to this one.

Overrides:

enablePointerSharing(enabled)

Enables or disables pointer sharing for this one.

Parameters:
Name Type Description
enabled boolean

true to enable, false to disable.

Inherited From:
Overrides:
Returns:
Type
Promise

fetchMediaList(session, options)

Fetches media specific to this conversation

Parameters:
Name Type Description
session Session
options object
Inherited From:
Returns:

mediaList

Type
Promise.<object>

fetchMessageHistory(session, options)

Loads message history for this conversation

Parameters:
Name Type Description
session Session
options Object
Inherited From:
Returns:
Type
Promise.<Array.<ConversationMessage>>

getAvailableMediaList()

Returns information for media streams available in the conversation

Inherited From:
Deprecated:
  • Yes
Returns:

contact list

Type
Array.<StreamInfo>

getAvailableStreamList()

Returns information for media streams available in the conversation

Inherited From:
Returns:

contact list

Type
Array.<StreamInfo>

getCloudConversationId()

Returns Apizee cloud conversation id for this conversation, will be set to null if conversation is not joined

Inherited From:
Returns:
Type
string

getContacts()

Returns contact list for conversation

Inherited From:
Returns:

contact list

Type
Object.<string, Contact>

getConversationCall(stream)

Returns the conversation call handle for a given stream.

Parameters:
Name Type Description
stream Stream

A stream, result of preceding publish or subscribe call.

Inherited From:
Returns:

A conversation call handle on success, null otherwise.

Type
ConversationCall

getData()

Returns conversation persistent data

Inherited From:
Returns:

data

Type
Object

getFriendlyName()

Returns this conference's name as it is displayed on Apizee Cloud

Returns:
Type
string

getInstanceId()

Returns instance id for this conversation, will be set to null if conversation is not joined

Returns:
Type
string

getModerator()

Get conversation moderator

Returns:

moderator or null if no moderator or moderator unknown

Type
Contact

getName()

Returns this conversation's room name

Inherited From:
Returns:
Type
string

getRole()

Returns UserAgent's role for this conversation, will be set to null if conversation is not joined

Returns:
Type
string

getStatus()

Returns conversation status

Inherited From:
Returns:
Type
Symbol

getWaitingRoomContacts()

Returns contacts in the waiting room, returns empty if conversation is not joined or user is not a moderator

Inherited From:
Returns:

contact list

Type
Object.<string, Contact>

isJoined()

Checks if the conversation is joined

Inherited From:
Returns:
Type
boolean

isPublishedStream(stream)

Does the stream is currently published in conversation

Parameters:
Name Type Description
stream Stream

Stream for which you want to know the publish status

Inherited From:
Returns:
Type
boolean

join(options)

Connects to a conference if not it is not already joined, additional parameters may be
required if the conference is private (JoinOptions)

Parameters:
Name Type Description
options JoinOptions

Optional data

Overrides:
Returns:

When joining is successful.

Type
Promise.<void>

leave()

Leaves conversation
The user will automatically stop publishing its streams to the conversation and stop subscribing to streams from the conversation.
The user will no longer receive events from the conversation
The user will no longer see who's within the conversation

Inherited From:
Returns:
Type
void

publish(stream, options)

Publish stream to conversation
The stream will be able to be subscribed by other contacts within the conversation

Parameters:
Name Type Description
stream Stream

Stream to publish

options Object

Publish options.

Properties
Name Type Description
qos Object

QoS preferences.

Properties
Name Type Description
videoMinQuality String

Defines minimum video quality (one of excellent, good, medium or bad).

videoForbidInactive Boolean

Forbids video disabling.

Inherited From:
Returns:

Published stream in promise.

Type
Promise.<Stream>

pushData(data, options)

Pushes data to this one.

Parameters:
Name Type Description
data PushDataFileDescriptor | PushDataBufferDescriptor

data - Descriptor of the data to transfer.

options PushDataOptions
Inherited From:
Returns:
Type
Promise.<CloudMediaInfo>

pushMedia(media, options)

Pushes media specific to this conversation

Parameters:
Name Type Description
media string

dataURI media

options object
Inherited From:
Returns:

cloud media info in promise

Type
Promise.<CloudMediaInfo>

sendCustomEvent(event, content)

Sends a custom data event to everyone in the conversation

Parameters:
Name Type Description
event string

event key

content Object
Inherited From:
Returns:
Type
Void

sendData(data, options)

Sends data message to contacts in conversation

Parameters:
Name Type Description
data Object

data to send

options Object
Inherited From:
Returns:
Type
Void

sendInvitation(contact, options)

Invites a contact to this conversation

Parameters:
Name Type Description
contact Contact

to invite

options Object
Properties
Name Type Description
expirationTime number

Time for an invite to expire after being sent

Overrides:
Returns:
Type
SentInvitation

sendJoinRequest(session)

(re)Sends join request to moderator, if in waiting room

Parameters:
Name Type Description
session Session

connected session (optional)

Returns:
Type
Void

sendMessage(message, options)

Sends string message to contacts in conversation

Parameters:
Name Type Description
message String

message to send

options Object

options

Inherited From:
Returns:
  • Promise with message uuid.
Type
Promise.<number>

sendPointerLocation(source, x, y, data)

Sends a given pointer location to every other participant.

Parameters:
Name Type Description
source object

The display source identifier.

x number

The X coordinate of the mouse pointer in source coordinates.

y number

The Y coordinate of the mouse pointer in source coordinates.

data object

Optional data to send with.

Inherited From:

sendRawData(data, options)

Sends raw data message to contacts in conversation, for backwards compatibility purposes
Equivalent to Session.sendRawData() but to send to everyone in the conversation

Parameters:
Name Type Description
data Object

data to send

options Object
Inherited From:
Returns:
Type
Void

setData(data)

Sets conversation persistent data (cloud user only)

Parameters:
Name Type Description
data Object
Inherited From:
Returns:
Type
Promise.<void>

startNewWhiteboardSession()

Starts a new whiteboard session for this conversation and notifies contacts in conversation

Properties:
Name Type Description
canvasId string

Identifier of the canvas to use for whiteboard

cursorColor string

User cursor color, sets the user cursor color that will be seen by other participants. Set to '#000000' to have a black cursor. Default value is invisible

Inherited From:
Returns:
Type
Void

startRecording(options)

Starts recording the conversation represented by this one.

Parameters:
Name Type Description
options Object

Recording preferences.

Properties
Name Type Description
audioOnly boolean

Whether to record only audio.

videoOnly boolean

Whether to record only video.

customIdInFilename string

This string will be added to the name of the final file.

data object

User data.

Inherited From:
Returns:
Type
Promise.<RecordingInfo>

stopNewWhiteboardSession()

Stops whiteboard session for this conversation and notifies contacts in conversation

Inherited From:
Returns:
Type
Void

stopRecording()

Stops recording.

Inherited From:
Returns:
Type
Promise

subscribeToStream(streamId, options)

Subscribes to a stream.

The subscription will automatically stop if the contact publishing the stream unpublishes it.

The Conversation#streamAdded event will be fired when the stream becomes available.
The Conversation#streamRemoved event will be fired when the stream is no longer available.
The Conversation#hangup event will be fired the subscription is terminated.

Note that multiple Conversation#streamAdded and Conversation#streamRemoved events might be
fired in case failure correction.

Parameters:
Name Type Description
streamId String

Identifies the stream to subscribe to.

options SubscribeOptions
Inherited From:
Returns:
Type
Promise

unpublish(stream, options)

Unpublishes currently published stream to conversation
If other users within the conversation subscribed to this stream, it will be stopped on their side

Parameters:
Name Type Description
stream Stream

Stream to unpublish

options Object
Inherited From:
Returns:
Type
Void

unsubscribeToStream(streamId)

Unsubscribes from a conversation's stream
The stream will be stopped on the user's side

Parameters:
Name Type Description
streamId String
Inherited From:
Returns:
Type
Void

updateData()

Forces conversation persistent data update

Overrides:
Returns:

data in promise

Type
Promise.<Object>

updateSubscribedStream(streamId, options)

Updates the call configuration for a given subscribed stream.

Parameters:
Name Type Description
streamId String

Stream identifier.

options SubscribeOptions

New call configuration.

Inherited From:
Returns:

When it is done.

Type
Promise

Events


audioAmplitudeUpdate

Fired when the audio amplitude change happened on conversation stream (indicating user speaking or not)

Type: object
Properties:
Name Type Description
callId string
descriptor descriptor
Inherited From:

availableStreamsUpdated

Fired when available streams in conversation have been updated

Type: Array.<StreamInfo>
Inherited From:

callStatsUpdate

Type: object
Properties:
Name Type Description
callId string
stats CallStats
Inherited From:

closed

Fired when conversation has been closed

Type: void
Inherited From:

contactJoined

Fired when a contact joined the conversation

Type: Contact
Inherited From:

contactJoinedWaitingRoom

Contact joined the waiting room event (moderator only)

Type: Contact
Inherited From:

contactLeft

Fired when a contact left the conversation

Type: Contact
Inherited From:

contactLeftWaitingRoom

Contact left the waiting room event (moderator only)

Type: Contact
Inherited From:

customEvent

Fired when a custom data event has been received from a contact within the conversation.

Type: object
Properties:
Name Type Description
event string

event identifier

sender Contact
content object
Inherited From:

data

Fired when data is received from a contact within the conversation

Type: object
Properties:
Name Type Description
content object

data

sender Contact
Inherited From:

disconnectionWarning

Fired when a disconnection happened on conversation stream

Type: object
Properties:
Name Type Description
streamInfo Array.<StreamInfo>

Stream information

Inherited From:

error

Fired when an error happened on conversation stream

Type: object
Properties:
Name Type Description
streamInfo Array.<StreamInfo>

Stream information

errorCode string

Code description of the error

errorInfo string

Code information about the error

descriptor object

Detailed descriptor of the error

Inherited From:

hangup

Fired when a publish or subscribe is terminated.

Type: object
Properties:
Name Type Description
from string

'local' or 'remote'.

reason string

Hangup reason.

Inherited From:

joined

Fired when conversation has been joined by the user.

Type: void
Inherited From:

left

Fired when conversation has been left by the user.

Type: void
Inherited From:

localStreamUpdated

Fired when local stream properties changed.

Type: object
Properties:
Name Type Description
callId string

callId.

streamId string

streamId.

audio boolean

whether an audio line has been negotiated and active.

audioMuted boolean

whether the audio line is muted.

video boolean

whether a video line has been negotiated and active.

videoMuted boolean

whether the video line is muted.

Inherited From:

message

Fired when a message is received from contact in the conversation

Type: object
Properties:
Name Type Description
content string

content of the message

sender Contact
time Date

receive time

Inherited From:

moderatorConnected

Fired when moderator joined the conversation

Type: object
Properties:
Name Type Description
moderator Contact
Inherited From:

newMediaAvailable

Fired when a new media is available in the conversation.

Type: object
Properties:
Name Type Description
sender Contact
media CloudMediaInfo
Inherited From:

newWhiteboardSession

Fired when a contact in the conversation starts a new whiteboard session

Type: object
Properties:
Name Type Description
sender Contact
Inherited From:

persistentDataUpdated

Fired when conversation persistent data has been updated.

Type: object
Inherited From:

pointerLocationChanged

Fired when a pointer location changed.

Type: object
Properties:
Name Type Description
sender Contact

sender.

source object

source identifier.

x number

The X coordinate of the mouse pointer in source coordinates.

y number

The Y coordinate of the mouse pointer in source coordinates.

data object

Optional data.

Inherited From:

pointerSharingEnabled

Fired when pointer sharing is enabled or disabled.

Type: object
Properties:
Name Type Description
enabled boolean

True when enabled, false when disabled.

Inherited From:

recordingAvailable

Fired when a recording is available for play or download.

Type: RecordingInfo
Inherited From:

recordingStarted

Fired when a recording started.

Type: RecordingInfo
Inherited From:

remoteStreamUpdated

Fired when remote stream properties changed.

Type: object
Properties:
Name Type Description
callId string

callId

audio boolean

whether an audio line has been negotiated and active.

audioMuted boolean

whether the audio line is muted.

video boolean

whether a video line has been negotiated and active.

videoMuted boolean

whether the video line is muted.

Inherited From:

Fired when a slow link is detected.

Type: object
Properties:
Name Type Description
callId string

callId

Inherited From:

streamAdded

Fired when a stream is received from this conversation after a subscription

Type: Stream
Inherited From:

streamListChanged

Fired when available stream list changed

Type: StreamInfo
Inherited From:

streamRemoved

Fired when stream is removed from this conversation after an unsubscription

Type: Stream
Inherited From:

transferBegun

Fired when a transfer begun (push data).

Type: object
Properties:
Name Type Description
id string

transfer id.

name string

filename.

Inherited From:

transferEnded

Fired when a transfer ended (push data).

Type: object
Properties:
Name Type Description
id string

transfer id.

name string

filename.

Inherited From:

transferProgress

Fired with progress status during a transfer (push data).

Type: object
Properties:
Name Type Description
id string

transfer id.

name string

filename.

size number

total transfered byte count.

remBytes number

remaining byte count.

percentage number

progress ratio.

Inherited From:

waitingForModeratorAcceptance

Fired when entering the waiting room of a conversation, requiring the moderator to accept before joining the room

Type: object
Properties:
Name Type Description
moderator Contact
Inherited From: