Sending a chat message
As mentioned in introduction, there are 3 types of chat messages - text messages, images, and files. There is a method in meeting.chat to send a message of each type.
Send a text message
To send a text message, the meeting.chat.sendTextMessage() method can be used. This accepts a string message and sends it to the room.
final message = "Is this the real life?";
meeting.chat.sendTextMessage(message);
Send an image
You can send an image with the help of meeting.chat.sendImageMessage() which
sends it to the participants in the meeting. It takes a string filePath as argument.
final filePath = "file_path_of_image";
meeting.chat.sendImageMessage(filePath, (error) {
// Handle error if any
});
Send a file
You can send a file with the help of meeting.chat.sendFileMessage() which
sends it to the participants in the meeting. It takes a string filePath as argument.
final filePath = "file_path_of_pdf";
meeting.chat.sendFileMessage(filePath, (error) {
// Handle error if any
});