CommandService

The CommandService allows the application to send custom text commands to all other clients. It also emits an event to the application informing about received messages.


Events

received

received(participant: Participant, message: Object): void

Emitted when a message is received.

example

VoxeetSDK.command.on("received", (participant: Participant, message: Object) => {

});

Parameters:

NameType
participantParticipant
messageObject

Returns: void

Methods

send

send(message: string): Promise‹any›

Sends a message (basic string) to all other clients.

Parameters:

NameTypeDescription
messagestringThe message to send

Returns: Promise‹any›