Skip to main content
Glama

unlabel_message

Idempotent

Remove labels from Gmail messages by ID or name to archive, mark read, or unstar. Reversible, supports up to 100 messages per call.

Instructions

Remove labels from a message (or from a list of messages). Labels: system IDs (INBOX, UNREAD, STARRED, IMPORTANT, CATEGORY_*) or user label IDs (list_labels), or their exact names. Archive = unlabel INBOX; mark read = unlabel UNREAD; star = label STARRED. Trash: trash_*; spam, sent and drafts: never. Reversible, no confirmation needed; at most 100 items per call.

Args: messageId: message ID, or a list of IDs. labelIds: labels to remove (IDs or names).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "messageId": "<messageId>",
      "labelIds": "<labelIds>"
    },
    "name": "unlabel_message"
  }
}

Input Schema

NameRequiredDescriptionDefault
labelIdsYes
messageIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.12.3
    • changedOutput schema / (root)
      Previous value: -{
      -  "properties": {
      -    "result": {
      -      "title": "Result",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "result"
      -  ],
      -  "title": "unlabel_messageOutput",
      -  "type": "object"
      -}New value: +null
  2. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations, the description discloses that the operation is reversible, requires no confirmation, and is capped at 100 items per call. It also specifies labels that should never be used here, which is exactly the kind of behavioral context an agent needs before invoking a mutation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense and front-loaded: purpose first, then label semantics and operational constraints. Every sentence carries actionable information, with no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-parameter mutation tool with no output schema, the description covers what the tool does, accepted label forms, common action mappings, prohibited labels, reversibility, and batch limits. An agent has enough information to call it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description carries the burden and explains that messageId accepts a single ID or a list, and labelIds accepts system IDs, user label IDs, or exact names. It could add format examples, but it substantially compensates for the bare schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource: remove labels from a message or a list of messages. It also distinguishes the scope by explicitly supporting batches and clarifying the label types involved, so an agent can identify the operation without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives useful when-to-use semantics, mapping common actions such as archive to unlabel INBOX, mark read to unlabel UNREAD, and star to label STARRED. It also rules out spam, sent, and drafts and states a 100-item limit, but it does not explicitly name sibling alternatives like label_message or unlabel_thread.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.