Save or clear the authenticated user's message draft for a room or an existing thread. The user must have a subscription to the room.
To save a room draft, omit tmid. To save a thread draft, provide the ID of the thread's main message in tmid. Send an empty draft to clear the corresponding room or thread draft. The draft cannot exceed the workspace's Message_MaxAllowedSize setting.
Changelog
| Version | Description |
|---|---|
| 8.8.0 | Added the optional tmid parameter to save thread drafts |
| 8.5.0 | Added |
The authToken of the authenticated user.
The userId of the authenticated user.
{
"rid": "GENERAL",
"draft": "Remember to share the report"
}{
"rid": "GENERAL",
"draft": "I will check this and reply",
"tmid": "7aDSXtjMA3KPLxLjt"
}{
"rid": "GENERAL",
"draft": "",
"tmid": "7aDSXtjMA3KPLxLjt"
}The room ID.
The draft text. Send an empty string to clear the draft.
The ID of the thread's main message. Omit this parameter to save or clear the main room draft.
OK
{
"success": true
}Bad Request
{
"success": false,
"error": "Invalid subscription [error-invalid-subscription]",
"errorType": "error-invalid-subscription"
}{
"success": false,
"error": "error-message-size-exceeded"
}Unauthorized
{
"status": "error",
"message": "You must be logged in to do this."
}