List updated and deleted messages in a room. Use lastUpdate to retrieve changes made after a specific date. To limit the results to messages originally sent at or after a specific date, use fromTs together with lastUpdate.
You can also paginate updated or deleted messages with the next, previous, and type parameters. This endpoint replaces the deprecated loadMissedMessages method, which is scheduled for removal in Rocket.Chat 9.0.0.
Changelog
| Version | Description |
|---|---|
| 8.8.0 | Added the fromTs parameter. |
| 1.0.0 | Added |
The authToken of the authenticated user.
The userId of the authenticated user.
The room ID.
The date and time after which message updates and deletions should be returned.
The inclusive date and time boundary for the original message timestamp. Only messages originally sent at or after this date are considered. You must use this parameter together with lastUpdate.
The cursor returned in result.cursor.next to retrieve the next page. Use either next or previous.
The cursor returned in result.cursor.previous to retrieve the previous page. Use either next or previous.
The message change type to retrieve when using cursor pagination. This parameter is required with next or previous.
OK
{
"result": {
"updated": [
{
"_id": "ak3WdaLbf4P7ZW3wQ",
"rid": "5qW6ssMFyzWjJev69",
"u": {
"_id": "FWfHnJmcudrCagGDX",
"username": "555192857993",
"name": "555192857993"
},
"msg": "teste",
"ts": "2021-09-24T19:19:47.911Z",
"_updatedAt": "2021-09-24T19:19:48.048Z",
"alias": "mauricio pretto",
"token": "do554ryecscmfrrxyxpvm",
"unread": true,
"urls": [],
"mentions": [],
"channels": [],
"md": [
{
"type": "PARAGRAPH",
"value": [
{
"type": "PLAIN_TEXT",
"value": "teste"
}
]
}
]
},
{
"_id": "2ttrNPABcCKbsbEtB",
"t": "livechat-started",
"msg": "",
"groupable": false,
"ts": "2021-09-24T19:19:46.523Z",
"u": {
"_id": "FWfHnJmcudrCagGDX",
"username": "555192857993",
"name": "555192857993"
},
"rid": "5qW6ssMFyzWjJev69",
"unread": true,
"_updatedAt": "2021-09-24T19:19:46.691Z",
"urls": [],
"mentions": [],
"channels": []
}
],
"deleted": []
},
"success": true
}Bad Request
{
"success": false,
"error": "The required \"roomId\" query param is missing [error-param-required]",
"errorType": "error-param-required"
}{
"success": false,
"error": "The \"type\" or \"lastUpdate\" parameters must be provided [error-param-required]",
"errorType": "error-param-required"
}{
"success": false,
"error": "The \"lastUpdate\" query parameter must be a valid date [error-lastUpdate-param-invalid]",
"errorType": "error-lastUpdate-param-invalid"
}{
"success": false,
"error": "The \"fromTs\" parameter can only be used together with \"lastUpdate\" [error-fromTs-requires-lastUpdate]",
"errorType": "error-fromTs-requires-lastUpdate"
}Unauthorized
{
"status": "error",
"message": "You must be logged in to do this."
}