Skip to main content
Glama
tom275275

Google Workspace MCP Server

by tom275275

modify_gmail_message_labels

Manage Gmail message labels by adding or removing label IDs. Archive an email by removing the INBOX label, or delete it by adding the TRASH label.

Instructions

Adds or removes labels from a Gmail message. To archive an email, remove the INBOX label. To delete an email, add the TRASH label.

Args: user_google_email (str): The user's Google email address. Required. message_id (str): The ID of the message to modify. add_label_ids (Optional[List[str]]): List of label IDs to add to the message. remove_label_ids (Optional[List[str]]): List of label IDs to remove from the message.

Returns: str: Confirmation message of the label changes applied to the message.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
message_idYes
add_label_idsNo
remove_label_idsNo
user_google_emailYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.14.3

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It explains the core side-effect behavior, including that removing INBOX archives and adding TRASH deletes, and it states the return type. It does not disclose edge-case behavior, such as what happens if the same label ID is passed in both add and remove lists, but the main behavioral traits are covered.

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 well-structured and front-loaded: a one-sentence purpose, two practical usage examples, then a compact Args section and a Return statement. No sentences are wasted, and the structure makes it easy to scan.

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

Completeness4/5

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

The description covers purpose, usage examples, all parameters, and return value, which is nearly complete for a simple four-parameter tool. It could be improved by referencing the sibling batch tool and noting that label IDs come from list_gmail_labels, but these gaps are minor given the tool's simplicity.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must fully document parameters, and it does. It explains user_google_email (required), message_id, add_label_ids, and remove_label_ids with their types and roles. This goes well beyond the bare input schema, giving an agent enough information to invoke the tool correctly.

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

Purpose4/5

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

The description clearly states a specific verb and resource: 'Adds or removes labels from a Gmail message.' It is easy to understand what the tool does. However, it does not explicitly distinguish itself from the sibling tool batch_modify_gmail_message_labels, which performs the same label-modification operation on multiple messages.

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?

The description provides clear usage context with concrete examples: 'To archive an email, remove the INBOX label. To delete an email, add the TRASH label.' This helps an agent know common scenarios. However, it does not mention when to prefer this tool over batch_modify_gmail_message_labels or other alternatives, so exclusion guidance is missing.

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

Deploy Server

Other Tools