Mention
To Mention user along with a message in a group, you can use mentionedUsersIds param provided to all kinds of messages such as Text, Image, video.
Text message#
To send your text message, you need to pass the TextMessage object as an argument to the parameter in the sendTextMessage() method.
- Java
- Kotlin
| Argument | Type | Description |
|---|---|---|
| MESSAGE_PARAMS | TextMessage | Object to hold the parameters of the text message |
| CALLBACK | SendMessageCallback | callback to observe the action status |
Image message#
To send your image message, you need to pass the FileMessage object as an argument to the parameter in the sendFileMessage() method.
- Java
- Kotlin
| Argument | Type | Description |
|---|---|---|
| MESSAGE_PARAMS | FileMessage | Object to hold the parameters of the image message |
| CALLBACK | SendMessageCallback | callback to observe the action status |
Note : In ChatManager
.setMediaFolderNameshould be defined to set your own local path to store app media files.
caution
If Image attachment feature unavailable for your plan then it will throw 403 exception.
Image message with url#
To send your image message, you need to pass the FileMessage object as an argument to the parameter in the sendFileMessage() method.
- Java
- Kotlin
| Argument | Type | Description |
|---|---|---|
| MESSAGE_PARAMS | FileMessage | Object to hold the parameters of the image message |
| CALLBACK | SendMessageCallback | callback to observe the action status |
caution
If Image attachment feature unavailable for your plan then it will throw 403 exception.
Video message#
To send your video message, you need to pass the FileMessage object as an argument to the parameter in the sendFileMessage() method.
- Java
- Kotlin
| Argument | Type | Description |
|---|---|---|
| MESSAGE_PARAMS | FileMessage | Object to hold the parameters of the video message |
| CALLBACK | SendMessageCallback | callback to observe the action status |
Note : In ChatManager
.setMediaFolderNameshould be defined to set your own local path to store app media files.
caution
If Video attachment feature unavailable for your plan then it will throw 403 exception.
Video message with url#
To send your video message, you need to pass the FileMessage object as an argument to the parameter in the sendFileMessage() method.
- Java
- Kotlin
| Argument | Type | Description |
|---|---|---|
| MESSAGE_PARAMS | FileMessage | Object to hold the parameters of the video message |
| CALLBACK | SendMessageCallback | callback to observe the action status |
caution
If Video attachment feature unavailable for your plan then it will throw 403 exception.
Send Reply message#
To send reply message to the original message, you need to pass the additional parameter original message-id in replyMessageId.TextMessage object as an argument to the parameter in the sendTextMessage() method.
- Java
- Kotlin
| Argument | Type | Description |
|---|---|---|
| MESSAGE_PARAMS | TextMessage | Object to hold the parameters of the text message |
| CALLBACK | SendMessageCallback | callback to observe the action status |
Receive Message#
To receive a mentioned related message from another user in a group, you must implement the messageListener function. Itβs a function that will be triggered whenever you receive a new message or related event in the chat.
- java
- Kotlin
info
To learn more on message listener callbacks, see the MessageEventsCallbacks.