Update Inbox Thread
update-inbox-threadPurpose: Update one thread in a Resend inbox: mark it read or unread, move it to another folder, or add and remove labels. At least one of read, folder, addLabelIds, or removeLabelIds is required.
Instructions
Purpose: Update one thread in a Resend inbox: mark it read or unread, move it to another folder, or add and remove labels. At least one of read, folder, addLabelIds, or removeLabelIds is required.
NOT for: Creating or deleting labels themselves (use create-inbox-label and remove-inbox-label), or deleting the thread (use remove-inbox-thread).
Returns: The thread's id, subject, folder, labels and read state after the update.
When to use: User asks to archive a thread, mark it read or unread, move it to spam or trash, or tag or untag it with a label. Moving a thread to trash schedules it for deletion in 30 days, the same as remove-inbox-thread. Moving a thread out of trash restores it and clears its deletion deadline. The changes apply in this order: read, folder, added labels, removed labels. They are not atomic: if a label ID is not found, the earlier changes stay applied. Get the thread ID from list-inbox-threads and the label IDs from list-inbox-labels.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| read | No | Mark every email in the thread as read (true) or unread (false). | |
| folder | No | Folder to move the thread to. Note that "sent" is not a valid destination: a thread can only be moved to inbox, archive, spam, or trash. | |
| inboxId | Yes | Inbox ID | |
| threadId | Yes | Thread ID | |
| addLabelIds | No | ID of the label to apply to this thread, or an array of up to 10 label IDs. A label ID cannot be both added and removed in the same call. Use list-inbox-labels to find label IDs. | |
| removeLabelIds | No | ID of the label to take off this thread, or an array of up to 10 label IDs. The label itself is kept, and stays on every other thread that carries it. A label ID cannot be both added and removed in the same call. Use list-inbox-labels to find label IDs. |