SDKsAndroid
Create a reply message
Use createQuoteMessage to reply while quoting an existing message.
Construct a reply message referencing a previous message in the conversation. Provide the reply text and the original Message object being quoted; receiving clients display the reply alongside a preview bubble of the referenced message.
Code example
String replyText = "Understood, I will handle it shortly.";
Message message = OpenIMClient.getInstance().messageManager.createQuoteMessage(
replyText,
quotedMessage
);Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
text | String | Yes | Text content of the reply message. |
quotedMessage | Message | Yes | The complete historical Message object being referenced. |
Return value
Returns the created Message object with contentType set to MessageType.QUOTE.
State changes after the call
- Local initialization: Initializes the local
Messagestructure without sending data to the server. - Transmission: Call Send a message to deliver the quote-reply message to a single user or group.
Was this page helpful?