Get
/api/v1/livechat/messages.history/{rid}
Get the entire message history of a conversation.
Path parameters
rid
stringRequired
The room ID.
Query parameters
token
stringRequired
The visitor token.
ExampleiNKE8a6k6cjbqWhWd
ls
(date-time)
The timestamp to start loading the messages.
Example2018-09-14T13:31:33.201Z
end
(date-time)
Example2018-09-14T14:31:33.201Z
limit
number
The number of messages to load.
Example25
Responses
200
Success Example
{
"messages": [
{
"_id": "ZKWP8LfGnRHQ3ozWa",
"rid": "KuACMJ5MpN6SfAFWg",
"msg": "editing livechat message..",
"token": "iNKE8a6k6cjbqWhWd",
"alias": "Livechat Visitor",
"ls": "2018-09-14T13:31:33.201Z",
"u": {
"_id": "YgEoq2djbGdjjZnsL",
"username": "guest-4",
"name": "Livechat Visitor"
},
"mentions": [],
"channels": [],
"_updatedAt": "2018-09-14T13:31:33.222Z",
"editedAt": "2018-09-14T13:31:33.219Z",
"editedBy": {
"_id": "YgEoq2djbGdjjZnsL",
"username": "guest-4"
},
"urls": []
}
],
"unreadNotLoaded": 0,
"success": true
}
object
messages
Array of object
object
_id
string
rid
string
msg
string
token
string
alias
string
ls
string
u
object
_id
string
username
string
name
string
mentions
Array of object
object
channels
Array of object
object
_updatedAt
string
editedAt
string
editedBy
object
_id
string
username
string
urls
Array of object
object
unreadNotLoaded
integer
success
boolean
400
Bad Request
Example 1
{
"success": false,
"error": "must have required property 'token' [invalid-params]",
"errorType": "invalid-params"
}
object
success
boolean
error
string
errorType
string