mail-operations

mail-operations is a skill for Claude Code from desirecore/market. It costs 151 tokens per session (7,745 once invoked), scanned A, original, MIT.

A procedure for working with Gmail, Outlook, and IMAP email accounts through a local service.

In plain words
What is it for?
Use it to read, search, send, and reply to email; manage labels and drafts; download attachments; or set up automated email handling.
Why use it?
It brings different mailbox types behind one interface, reducing the need to handle each provider separately.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter.

Good fit Use it to read, search, send, and reply to email; manage labels and drafts; download attachments; or set up automated email handling.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/desirecore/market/mail-operations
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add desirecore/market --skill mail-operations
Clone the repo
git clone --depth 1 https://github.com/desirecore/market

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for mail-operations

README.md
[![agentmods](https://agentmods.dev/badge/skills/desirecore/market/mail-operations/github.svg)](https://agentmods.dev/skills/desirecore/market/mail-operations)
Your own site
<a href="https://agentmods.dev/skills/desirecore/market/mail-operations"><img src="https://agentmods.dev/badge/skills/desirecore/market/mail-operations/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for mail-operations

Your own site · 80×15
<a href="https://agentmods.dev/skills/desirecore/market/mail-operations"><img src="https://agentmods.dev/badge/skills/desirecore/market/mail-operations.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 151 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 7,745 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00151 $0.07745
Opus 5.5 $0.00060 $0.03098
Sonnet 5.5 $0.00030 $0.01549
Haiku 4.5 $0.00015 $0.00775

Measured 17d ago against content hash ff5839b3f315, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

mail-operations scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 17d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

- **Do not connect to the port directly**: do not `curl` `https://127.0.0.1:62000`. The port is allocated dynamically starting at 62000 (when several DesireCore instances run, 62000 may belong to another instance), and i
skills/mail-operations/SKILL.md · 476 lines

How it starts

The opening of the file, as written. The whole thing — 476 lines — stays where its author put it; the contents beside it link to each section on GitHub.

mail-operations Skill

L0: One-line Summary

Send and receive email, search, manage labels, and run automation rules via a local REST API; supports Gmail / Outlook / IMAP.

L1: Overview and Use Cases

Capability

mail-operations is a Procedural Skill that operates email systems through DesireCore's local REST API (called via the built-in MailOperations tool). It supports three mailbox types—Gmail (OAuth2), Outlook (MSAL), and IMAP/SMTP (QQ, 163, Yahoo, etc.)—covering send/receive, search, label management, attachment download, draft management, and automation rules.

Use Cases

  • The user wants to view the inbox, send, or reply to email
  • The user wants to search for specific emails or manage email labels/categories
  • The user wants to download attachments or manage drafts
  • The user wants to set up auto-reply rules or trigger an Agent to handle email

Core Value

  • Unified interface: three mailbox types are operated through a unified API, lowering complexity
  • Local and secure: all operations go through the local API; no need to expose credentials
  • Smart integration: supports automation rules and Agent-based email handling

L2: Detailed Specification

How to Access the Email Service

Users can reach the email management interface via:

  1. Click the third icon (folder icon) in the left navigation rail to open the Resource Explorer
  2. On the Resource Explorer home page, find and click the "Emails" card to enter email management

If a user doesn't know how to open the email page, guide them through the steps above. They can also click "Open Resource Explorer" from the top-right corner of the chat interface, then select the Emails card.


API Basics

  • How to call: use the built-in MailOperations tool. Its parameters are path (a relative path starting with /api/, with query parameters appended directly to it), method (default GET), body (a JSON object), and save_to (only for attachment downloads, see section 6). The tool locates the local Mail Service and attaches the access credential automatically; the Agent neither needs nor can supply a token.
  • Path form: the endpoints below omit the /api prefix; add it when calling. For example, /imap/messages?email=me%40example.com&limit=20 becomes path: "/api/imap/messages?email=me%40example.com&limit=20". The only exception is the health check /ping (no /api).
  • Do not connect to the port directly: do not curl https://127.0.0.1:62000. The port is allocated dynamically starting at 62000 (when several DesireCore instances run, 62000 may belong to another instance), and in strict capability mode direct requests without the credential always return 401.
  • Parameter location: GET / DELETE parameters always go in the query string; for POST / PUT follow the tables below. The email of endpoints such as messages/fetch, mark as read/unread, Outlook single-message operations, and IMAP draft send must be in the query string; putting it in the body returns 400 Missing email parameter. For /sync, both provider and email must be in the query string: provider in the body returns 400 Invalid provider, and email alone in the body raises no parameter error but the sync does not take effect.
  • Content-Type: application/json (set automatically by the tool when body is passed)
  • Response format: success {"code": 1, "msg": "Success", "result": ...}, failure {"code": 0, "msg": "error message"}; some errors also carry a stable error code field error (e.g. smtp_unverified)

Read the full file on GitHub · 476 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 17d ago Changed · +9 lines ff5839b3f315
  2. 24d ago Changed · +41 lines 5641ed24576c
  3. 1mo ago Changed · +1 lines e697a19b4abc
  4. 1mo ago First seen · 425 lines · 151 tokens per session scan A fdc44f9e9cac

Subscribe to this mod's changes

mail-operations is a skill published in the GitHub repository desirecore/market (2 stars, last pushed 2d ago), licensed MIT. It adds 151 tokens to every session and 7,745 once invoked, about $0.0006 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.