Skip to main content
Glama

Set Email Flags

mail_set_flags
Idempotent

Set read/unread and flagged status on an email by message ID, with mailbox and account auto-resolved when omitted.

Instructions

Set flagged and/or read status on an email. Mailbox and account are auto-resolved from the message ID if not provided. Use when: marking emails as read/unread, flagging important messages

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>"
    },
    "name": "mail_set_flags"
  }
}

Input Schema

NameRequiredDescriptionDefault
readNoSet read status
accountNoAccount name. If omitted, auto-resolved from the message ID.
flaggedNoSet flagged status
mailboxNoMailbox name. If omitted, auto-resolved from the message ID.
messageIdYes

Output Schema

NameRequiredDescriptionDefault
successYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4/5.0
Behavior4/5

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

Beyond the annotations, the description explains that mailbox and account are auto-resolved from the message ID when omitted, which is useful behavioral context for a write operation. It does not cover permission requirements or exactly how unspecified flags are treated, but the annotations already establish safety and idempotency.

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 short sentences with the core purpose front-loaded and no unnecessary wording. The usage examples are compact and directly useful.

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 tool has annotations, an output schema, and mostly described parameters, so the description does not need to explain return values. It covers purpose, key auto-resolution behavior, and primary use cases well enough, though it could say more about partial flag updates.

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 80%, so the schema already documents most parameter meaning. The description repeats the auto-resolution behavior for mailbox and account but adds no additional syntax or edge-case semantics for the messageId or boolean flags beyond what the schema provides.

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 states a specific verb and resource: setting flagged and/or read status on an email. It is clear what the tool does, but it does not explicitly distinguish this operation from sibling tools such as mail_move or mail_search.

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 explicit when-to-use guidance: marking emails as read/unread and flagging important messages. It does not state when not to use the tool or name alternatives, so it stops short of full routing guidance.

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