Move a message thread

You can move message threads:

Message threads located in the UNREAD folder are marked as unread in the interface.

Message threads located in the IMPORTANT folder are marked as important in the interface.

To add to a folder

To add a message thread to one or more folders, send a POST request to the resource message-threads/thread ID>/add-to-folders.

POST api/v1/message-threads/<thread ID>/add-to-folders
Host: https://sandbox.toloka.yandex.ru
Authorization: OAuth <OAuth token>
Content-Type: application/JSON

{
  "folders": ["UNREAD", "IMPORTANT"]
}
Request parameters

Parameter

Description

Data type

folders The folders to which you want to add the message thread. Array

Remove from a folder

To remove a message thread from one or more folders, send a POST request to the resource message-threads/<thread ID>/remove-from-folders.

When a recipient replies to a message thread, the thread is automatically removed from the UNREAD folder.

POST api/v1/message-threads/<thread ID>/remove-from-folders
Host: https://sandbox.toloka.yandex.ru
Authorization: OAuth <OAuth token>
Content-Type: application/JSON

{
  "folders": ["UNREAD", "IMPORTANT"]
}
Request parameters

Parameter

Description

Data type

folders Folders from which you want to delete the message thread. Array