Post
/api/v1/subscriptions.unread
Mark messages as unread by room ID or from a message.
Changelog
Version | Description |
---|---|
0.65.0 | Added |
Header parameters
X-Auth-Token
stringRequired
The token of the authenticated user.
ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
X-User-Id
stringRequired
The user ID of the authenticated user.
ExamplerbAXPnMktTFbNpwtJ
Body parameters
Example
{
"roomId": "L6su9mxwdDkvdSaT9hvzu8z6mHFigiXy6Y"
}
Example 2
{
"firstUnreadMessage": {
"_id": "L6su9mxwdDkvdSaT9hvzu8z6mHFigiXy6Y"
}
}
AnyOf
object
object
roomId
string Required
The room ID.
object
object
firstUnreadMessage
object Required
_id
string
The message ID.
Responses
200
OK
Example 1
{
"success": true
}
object
success
boolean
400
Bad Request
Invalid Parameter
{
"success": false,
"error": "must have required property 'roomId'\n must have required property 'firstUnreadMessage'\n must match a schema in anyOf [invalid-params]",
"errorType": "invalid-params"
}
object
success
boolean
error
string
errorType
string
401
Unauthorized
Authorization Error
{
"status": "error",
"message": "You must be logged in to do this."
}
object
status
string
message
string