mcp_mail: Instructions file for Codex

AGENTS.md

mcp_mail AGENTS.md is an instructions file for Codex, OpenCode from jleechanorg/mcp_mail. It costs 5,201 tokens per session, scanned D, original, MIT.

Project instructions for an MCP mail server, GitHub access, and safe file handling. They tell the coding agent how to set up hooks, credentials, and configuration.

In plain words
What is it for?
Setting up the repository, connecting to GitHub, starting the agent mail server, configuring access, and enforcing checks before commits.
Why use it?
They reduce setup mistakes and prevent accidental file or data deletion by requiring permission for irreversible actions.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions subagents; mentions Codex.

This is jleechanorg/mcp_mail's own configuration. It tells Codex and OpenCode how to work on mcp_mail itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything mcp_mail configures →

Not installable: its command points at a path on the author’s own machine, so it runs nowhere else. The line is /Users/jleechan/mcp_agent_mail.

Reuse

Borrowing it

Nothing to install: this file belongs to jleechanorg/mcp_mail. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/jleechanorg/mcp_mail/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/jleechanorg/mcp_mail

Made for: Codex, OpenCode.

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 mcp_mail AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/jleechanorg/mcp_mail/agents-md/github.svg)](https://agentmods.dev/instructions/jleechanorg/mcp_mail/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/jleechanorg/mcp_mail/agents-md"><img src="https://agentmods.dev/badge/instructions/jleechanorg/mcp_mail/agents-md/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 mcp_mail AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/jleechanorg/mcp_mail/agents-md"><img src="https://agentmods.dev/badge/instructions/jleechanorg/mcp_mail/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 5,201 This file is loaded in full into every session.
When invoked 5,201 The same file — it is already loaded in full.
Security scan D 3 findings. 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.05201 $0.05201
Opus 5.5 $0.02080 $0.02080
Sonnet 5.5 $0.01040 $0.01040
Haiku 4.5 $0.00520 $0.00520

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

Security

Grade D, and why

mcp_mail AGENTS.md scanned grade D with 3 findings 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 1mo 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.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

chmod 600 ~/.mcp_agent_mail_git_mailbox_repo/credentials.json

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

1. **Absolutely forbidden commands:** `git reset --hard`, `git clean -fd`, `rm -rf`, or any command that can delete or overwrite code/data must never be run unless the user explicitly provides the exact command and state

Makes network callslowCapability

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

curl -H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/repos/owner/repo/pulls
AGENTS.md · 336 lines

How it starts

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

RULE NUMBER 1 (NEVER EVER EVER FORGET THIS RULE!!!): YOU ARE NEVER ALLOWED TO DELETE A FILE WITHOUT EXPRESS PERMISSION FROM ME OR A DIRECT COMMAND FROM ME. EVEN A NEW FILE THAT YOU YOURSELF CREATED, SUCH AS A TEST CODE FILE. YOU HAVE A HORRIBLE TRACK RECORD OF DELETING CRITICALLY IMPORTANT FILES OR OTHERWISE THROWING AWAY TONS OF EXPENSIVE WORK THAT I THEN NEED TO PAY TO REPRODUCE. AS A RESULT, YOU HAVE PERMANENTLY LOST ANY AND ALL RIGHTS TO DETERMINE THAT A FILE OR FOLDER SHOULD BE DELETED. YOU MUST ALWAYS ASK AND RECEIVE CLEAR, WRITTEN PERMISSION FROM ME BEFORE EVER EVEN THINKING OF DELETING A FILE OR FOLDER OF ANY KIND!!!

First step in any clone/session: run ./scripts/ensure_git_hooks.sh to force core.hooksPath=.githooks so Ruff/ty/Bandit hooks run on every commit. Re-run if hooks ever stop firing.

IRREVERSIBLE GIT & FILESYSTEM ACTIONS — DO-NOT-EVER BREAK GLASS

  1. Absolutely forbidden commands: git reset --hard, git clean -fd, rm -rf, or any command that can delete or overwrite code/data must never be run unless the user explicitly provides the exact command and states, in the same message, that they understand and want the irreversible consequences.
  2. No guessing: If there is any uncertainty about what a command might delete or overwrite, stop immediately and ask the user for specific approval. “I think it’s safe” is never acceptable.
  3. Safer alternatives first: When cleanup or rollbacks are needed, request permission to use non-destructive options (git status, git diff, git stash, copying to backups) before ever considering a destructive command.
  4. Mandatory explicit plan: Even after explicit user authorization, restate the command verbatim, list exactly what will be affected, and wait for a confirmation that your understanding is correct. Only then may you execute it—if anything remains ambiguous, refuse and escalate.
  5. Document the confirmation: When running any approved destructive command, record (in the session notes / final response) the exact user text that authorized it, the command actually run, and the execution time. If that record is absent, the operation did not happen.

Read the full file on GitHub · 336 lines

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. 1mo ago First seen · 336 lines · 5,201 tokens per session scan D da70847fce58

Subscribe to this mod's changes

mcp_mail AGENTS.md is an instructions file published in the GitHub repository jleechanorg/mcp_mail (11 stars, last pushed 2mo ago), licensed MIT. It adds 5,201 tokens to every session, about $0.0208 per session on Opus 5.5. A static security scan graded it D with 3 findings (asks for root, recursive force delete, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other instructions, from other repositories

vscode buildNext.instructions.md

Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).

microsoft/vscode · 9,649 tokens

next.js AGENTS.md

AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.

vercel/next.js · 7,384 tokens

vscode oss-third-party-notices.instructions.md

Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).

microsoft/vscode · 5,262 tokens

langchain AGENTS.md

AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.

langchain-ai/langchain · 4,680 tokens

vscode copilot-instructions.md

Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).

microsoft/vscode · 2,731 tokens

deno copilot-instructions.md

Copilot instructions for denoland/deno, covering deno development guide for github copilot, network access, high level overview, key directories and key files to understand first.

denoland/deno · 3,077 tokens