Skip to main content
Glama

Modify Gmail Message Labels

modify_gmail_message_labels
Destructive

Modify Gmail message labels by adding or removing label IDs. Archive a message 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.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
user_google_emailYesThe user's Google email address. Required.
message_idYesThe ID of the message to modify.
add_label_idsNoList of label IDs to add to the message.
remove_label_idsNoList of label IDs to remove from the message.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Annotations already convey destructive and non-idempotent behavior. The description adds value by explaining how to achieve archive (remove INBOX) and delete (add TRASH), which provides behavioral context beyond the binary annotations.

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 three sentences, front-loading the main purpose and then providing two key use-cases. No redundant information, every sentence is essential.

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?

Given the tool has 4 parameters, 100% schema coverage, and an output schema (not shown), the description covers the main use cases. However, it does not mention what happens if both add and remove lists are empty, or error handling, but these are minor omissions.

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

Parameters3/5

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

Schema coverage is 100%, so all parameters are documented. The description does not add extra meaning beyond the schema; it only reiterates examples. A baseline score of 3 is appropriate since the schema already handles parameter semantics adequately.

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 clearly states 'Adds or removes labels from a Gmail message', providing a specific verb and resource. It also gives concrete examples (archiving by removing INBOX, deleting by adding TRASH), which distinguishes it from sibling tools like list_gmail_labels or get_gmail_message_content.

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 gives practical examples of when to use the tool for archiving and deleting, but it does not explicitly mention when to use batch_modify_gmail_message_labels instead, nor does it outline scenarios where this tool is not appropriate.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/theolefort-cyber/mcpworkspace'

If you have feedback or need assistance with the MCP directory API, please join our Discord server