Update conversation state
/api/v1/ext/conversations/{contact_id}/state
Mark a conversation read or unread, star or unstar it, archive or restore it, pause or resume the AI.
Send any of the four flags; the rest are left as they are. is_unread: false marks the conversation read (the unread count drops to 0); is_unread: true marks it unread the way the inbox does — one unread, and the chat is marked unread in Messages on the workspace's Advanced-Mode Mac too. Archiving hides the conversation from the inbox's main list (it is still returned with archived=1) and never deletes messages. is_ai_paused is the same as sending it on *Update contact*: the AI agent stops replying to this contact until it is resumed, and Contact Updated automations hear about it. A contact with neither a phone number nor an email has no conversation, so read / star / archive answer 400 for it; the AI flag still works.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| contact_id | path | number | yes | The contact id. |
| is_unread | body | boolean | no | false = mark read, true = mark unread. |
| is_starred | body | boolean | no | Star / unstar. |
| is_archived | body | boolean | no | Archive / restore. |
| is_ai_paused | body | boolean | no | Pause / resume the AI agent for this contact. |
Responses
| Status | When |
|---|---|
200 | OK — the state afterwards |
400 | No flag, a non-boolean, or a contact with no phone or email |
401 | Missing or invalid token |
403 | Missing scope |
404 | Contact does not exist or is not owned by the installer (same response for both) |
curl -X PATCH "https://backend.mysmsgateway.app/api/v1/ext/conversations/{contact_id}/state" \
-H "Authorization: Bearer <ACCESS_TOKEN>" \
-H "Content-Type: application/json" \
-d '{
"is_unread": false,
"is_starred": true
}'{
"success": true,
"message": "Conversation updated",
"data": {
"contact_id": 1234,
"workspace_id": 7,
"thread": "+61412345678",
"unread_count": 0,
"is_read": true,
"is_unread": false,
"is_starred": true,
"is_archived": false,
"last_read_at": "2026-11-04T03:10:00.000Z",
"archived_at": null,
"is_ai_paused": false,
"dnd": {
"outbound": {
"all": false,
"channels": []
},
"inbound": {
"all": false,
"channels": []
}
}
}
}The contact id.
« Get conversation state
List groups »
