---
title: "Update Label Endpoint"
method: PATCH
path: "/admin/email-classifier/labels/{gmail_message_id}"
tags: ["admin-email-classifier"]
---

# Update Label Endpoint

`PATCH /admin/email-classifier/labels/{gmail_message_id}`

## Request

- Base URL: `https://stardrift.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://stardrift.ai/admin/email-classifier/labels/{gmail_message_id}`
- Auth: none declared

Partial update of a labeled email's label and/or reviewer notes.
Only fields explicitly present in the request body are touched.
403 if the email is not from the caller's inbox.

## Path parameters

- `gmail_message_id` string, required

## Request body

- LabelPatchRequest: Partial update. Fields left unset are not touched. Sending `notes` as an empty string or `null` clears the reviewer note.
  - `label` boolean, nullable
  - `notes` string, nullable

## Response `200`

Successful Response

- LabelPatchResponse
  - `gmail_message_id` string, required
  - `label` boolean, required
  - `original_label` boolean, nullable, required
  - `reviewed_at` string, date-time, nullable, required
  - `reviewer_notes` string, nullable, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/stardrift/apis/stardrift-api.md) - [All operations](https://skmtc.dev/stardrift/apis/stardrift-api/llms.txt) - [OpenAPI document](https://skmtc.dev/stardrift/apis/stardrift-api/revisions/be9ed1e6c38a?raw)
