Update thread labels
cooper_update_threadUse this when every message in a conversation should gain or lose the same labels, including marking the thread read. Requires auth. Works on a paused inbox. Inputs: inbox_id (required; inbox id, username, or email), thread_id (required), add_labels (optional strings), remove_labels (optional strings). The change is applied to every message in the thread. read and unread can be changed. Other system labels (inbox, sent, untrusted, auth_failed, owner, and SPF/DKIM/DMARC results) cannot. Returns the thread plus messages_updated. Unknown thread returns HTTP 404 thread_not_found. Invalid labels return invalid_label, protected_label, or label_conflict.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| inbox_id | Yes | Inbox id (inb_…), username, or full email address owned by this key | |
| thread_id | Yes | Thread id (thr_…) whose messages should change labels | |
| add_labels | No | Labels to add on every message. read and unread are allowed. System labels are not. | |
| remove_labels | No | Labels to remove from every message. Pass ["unread"] to mark the thread read. |