mark chat as read
This commit is contained in:
@@ -287,13 +287,15 @@ async function markAsRead(token: string, loginName: string, appPassword: string)
|
||||
}
|
||||
|
||||
try {
|
||||
await axios.delete(
|
||||
await axios.post(
|
||||
`${baseUrl}/ocs/v2.php/apps/spreed/api/v1/chat/${encodeURIComponent(token)}/read`,
|
||||
{ lastReadMessage: null },
|
||||
{
|
||||
headers: {
|
||||
'Authorization': `Basic ${Buffer.from(loginName + ':' + appPassword).toString('base64')}`,
|
||||
'OCS-APIRequest': 'true',
|
||||
'Accept': 'application/json',
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
},
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user