Skip to main content
Glama
mail-mcp

mail-mcp

by honest-magic

extract_contacts

Read-only

Scan recent IMAP messages to return structured contact data—name, email, and frequency—sorted by how often each contact emails you, helping identify your most frequent senders.

Instructions

Scan recent messages via IMAP and return structured contact data (name, email, frequency) sorted by how often they email you — enables "who emails me most?" queries. Works with any IMAP provider.

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": {
      "accountId": "<accountId>"
    },
    "name": "extract_contacts"
  }
}

Input Schema

NameRequiredDescriptionDefault
countNoNumber of recent messages to scan (default: 100, max: 500)
folderNoThe folder to scan (default: INBOX)
accountIdYesThe ID of the account to use

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.4.0

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so safety is covered. The description adds that it scans via IMAP and that results are frequency-sorted, plus provider compatibility, but says nothing about cost/latency of scanning up to 500 messages or what happens when an account isn't IMAP.

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?

Two sentences, front-loaded with the operation and its return shape, then a one-clause compatibility note. No restatement of the tool name and nothing that could be cut without losing information.

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?

With no output schema, the description correctly shoulders the burden by naming the returned fields and their sort order. All three parameters are documented, though runtime expectations and non-IMAP failure behavior are absent.

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%, including the default 100 / max 500 limit and the default INBOX folder, so the schema already carries parameter meaning. The description does not add semantics (e.g., whether folder supports nested paths or how count affects runtime), so the baseline 3 applies.

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?

States a specific verb (scan messages) and a specific output (structured name/email/frequency records sorted by frequency), and the framing "who emails me most?" makes its niche clear against siblings like list_emails or search_emails. It stops short of naming or explicitly contrasting any sibling, so it lands just under the top mark.

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

Usage Guidelines3/5

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

Usage is only implied through the example query "who emails me most?" — there is no explicit when-to-use vs. when-not, and no pointer to search_emails or list_emails for raw message retrieval. "Works with any IMAP provider" is a compatibility note, not selection guidance.

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