# PATCH /api/v1/inboxes/:id/threads/:threadId

Auth: Bearer

HTML: https://cooperemail.com/docs/reference/update-thread

## Summary

Add or remove labels on every message in the thread. Same rules as message labels: read and unread can change; other system labels cannot. Works on a paused inbox. Returns the thread and messages_updated. Unknown thread returns 404 thread_not_found.

## Request

```json
{
  "add_labels": [
    "follow-up"
  ],
  "remove_labels": [
    "unread"
  ]
}
```

## Response

The OpenAPI document does not declare a JSON response schema for this call. The summary is the contract.

## Errors

- HTTP 404 thread_not_found

The live `message` is the sentence for that code. Branch on `code`.

```json
{
  "error": {
    "type": "not_found",
    "code": "thread_not_found",
    "docs_url": "https://cooperemail.com/docs#thread_not_found"
  }
}
```

## Idempotency

This route does not document Idempotency-Key or client_id.
