Skip to main content
Glama
langmail-mcp

langmail-mcp

Official
by langmail

Archive emails

archive_emails

Moves selected emails from Inbox to Archive while preserving read state and flags; pass message or thread IDs to clear inbox clutter without deleting.

Instructions

Archive one or more messages: remove them from the Inbox and file them in the Archive mailbox. Use this when the user says archive, clear, or "get this out of my inbox". Read state and flags (to-do, starred) are untouched (use mark_emails for those), and re-running it on the same ids is harmless. Takes message ids from search_emails or get_thread; pass all of a thread's ids to archive the conversation. To file into a specific folder use move_emails; to delete use trash_emails. Reports how many messages were archived and lists any id the server refused.

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": {
      "ids": "<ids>"
    },
    "name": "archive_emails"
  }
}

Input Schema

NameRequiredDescriptionDefault
idsYesMessage ids to act on (1–50), as returned by search_emails or get_thread. To act on a whole conversation, pass every id get_thread lists.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

Beyond the annotations it discloses that read state and to-do/starred flags are left untouched and that re-running on the same ids is harmless, plus what the call reports back (count archived, refused ids). One mild tension: the 're-running is harmless' claim sits awkwardly beside idempotentHint=false, though 'harmless' is about not causing damage (consistent with destructiveHint=false) rather than strict idempotence. It does not mention any permission or quota requirements.

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

Conciseness4/5

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

Front-loaded with verb and effect, then triggers, then exclusions, then return behavior — a logical order with no filler. It is slightly redundant in restating the 'pass all of a thread's ids' rule that the schema description already carries.

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 single-parameter mutation tool with no output schema, the description covers effect, triggers, non-effects on flags, repeat-call behavior, sibling alternatives, and the shape of the response. An agent has everything needed to select and invoke it correctly.

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% and the ids parameter already documents the 1–50 range and the get_thread pattern, so the schema does the heavy lifting. The description reinforces the thread semantics ('pass all of a thread's ids to archive the conversation'), but adds little syntax or format detail beyond what is already in the 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 first sentence gives a specific verb ('Archive') plus the exact effect ('remove them from the Inbox and file them in the Archive mailbox'), which is more precise than the name alone. It is immediately distinguishable from move_emails, trash_emails and mark_emails, which are named.

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

Usage Guidelines5/5

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

It supplies concrete user triggers ('archive, clear, or "get this out of my inbox"') and explicitly routes adjacent intents elsewhere: mark_emails for read/flag state, move_emails for a specific folder, trash_emails for deletion. Both when-to-use and when-not-to-use are stated, with the alternative named for each.

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