DyteChat
This is the chat module, which can be used to send and receive messages from the meeting.
- DyteChat
- .messages
 - .channels
 - .socketJoined
 - .pinned
 - .setMaxTextLimit()
 - .sendTextMessage(message)
 - .sendImageMessage(image)
 - .sendFileMessage(file)
 - .sendMessage(message, participantIds)
 - .getMessagesByUser(userId)
 - .getMessagesByType(type)
 - .pin(id)
 - .unpin(id)
 - .getMessages()
 - .createChannel()
 - .updateChannel()
 - .sendMessageToChannel(message, channelId)
 - .getChannelMembers()
 - .searchMessages()
 - .markLastReadMessage()
 
 
meeting.chat.messages
An array of chat messages.
Kind: instance property of DyteChat
meeting.chat.channels
An Array of all available channels.
Kind: instance property of DyteChat
meeting.chat.socketJoined
Returns true if the local participant has joined the meeting.
Kind: instance property of DyteChat
meeting.chat.pinned
Returns an array of pinned messages.
Kind: instance property of DyteChat
meeting.chat.setMaxTextLimit()
Set the max character limit of a text message
Kind: instance method of DyteChat
meeting.chat.sendTextMessage(message)
Sends a chat text message to the room.
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| message | The message that must be sent to the room. | 
meeting.chat.sendImageMessage(image)
Sends an image message to the meeting.
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| image | The image that is to be sent. | 
meeting.chat.sendFileMessage(file)
Sends a file to the meeting.
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| file | A File object. | 
meeting.chat.sendMessage(message, participantIds)
Sends a message to the meeting. This method can be used to send text, image,
or file messages. The message type is determined by the key 'type' in message
object.
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| message | An object including the type and content of the message. | 
| participantIds | An array including the userIds of the participants. | 
meeting.chat.getMessagesByUser(userId)
Returns an array of messages sent by a specific userId.
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| userId | The user id of the user that sent the message. | 
meeting.chat.getMessagesByType(type)
Returns an array of 'text', 'image' or 'file' messages.
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| type | 'text', 'image', or 'file'. | 
meeting.chat.pin(id)
Pins a chat message
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| id | ID of the message to be pinned | 
meeting.chat.unpin(id)
Unpins a chat message
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| id | ID of the message to be unpinned | 
meeting.chat.getMessages()
Gets chat messages in a paginated manner
Kind: instance method of DyteChat
meeting.chat.createChannel()
Creates a channel with specified name and userIds as members
Kind: instance method of DyteChat
meeting.chat.updateChannel()
Updates the channel
Kind: instance method of DyteChat
meeting.chat.sendMessageToChannel(message, channelId)
Sends a message to a channel. This method can be used to send text, image,
or file messages. The message type is determined by the key 'type' in message
object.
Kind: instance method of DyteChat
| Param | Description | 
|---|---|
| message | An object including the type and content of the message. | 
| channelId | Id of the channel where you want to send the message. | 
meeting.chat.getChannelMembers()
returns a list of members added to the channel
Kind: instance method of DyteChat
meeting.chat.searchMessages()
search messages
Kind: instance method of DyteChat
meeting.chat.markLastReadMessage()
marks last read message in a channel
Kind: instance method of DyteChat