gmail-draft-from-markdown

gmail-draft-from-markdown is a skill for Claude Code from jtsternberg/claude-plugins. It costs 48 tokens per session (4,146 once invoked), scanned A, original, MIT.

A tool that turns a local Markdown file into an HTML-formatted Gmail draft and can attach local files or continue an existing email thread. Markdown is a plain-text way to format documents.

In plain words
What is it for?
Use it to create Gmail drafts from notes, add attachments, or prepare a reply to an existing message, then review and send it in Gmail.
Why use it?
It prepares a reviewable email draft without sending anything automatically, leaving the final decision with the user.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: mentions Claude Code; mentions Codex.

Installs and runs on its own, but its text points at files inside its plugin — anything it tells you to read at a ${CLAUDE_PLUGIN_ROOT} path is only there once the plugin is installed. Installing the plugin gets both.

Part of the gws plugin — 7 skills shipped together

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.

agentmods
npx agentmods add skills/jtsternberg/claude-plugins/gmail-draft-from-markdown
Any agent
npx skills add jtsternberg/claude-plugins --skill gmail-draft-from-markdown
Clone the repo
git clone --depth 1 https://github.com/jtsternberg/claude-plugins

Made for: Claude Code.

Or install gws, the plugin that ships this one along with the rest of its 7 skills.

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 gmail-draft-from-markdown

README.md
[![agentmods](https://agentmods.dev/badge/skills/jtsternberg/claude-plugins/gmail-draft-from-markdown.svg)](https://agentmods.dev/skills/jtsternberg/claude-plugins/gmail-draft-from-markdown)
Your own site
<a href="https://agentmods.dev/skills/jtsternberg/claude-plugins/gmail-draft-from-markdown"><img src="https://agentmods.dev/badge/skills/jtsternberg/claude-plugins/gmail-draft-from-markdown.svg" alt="Measured on agentmods" height="20"></a>
Per session 48 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,146 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00048 $0.04146
Opus 5 $0.00024 $0.02073
Sonnet 5 $0.00010 $0.00829
Haiku 4.5 $0.00005 $0.00415

Measured 5d ago against content hash a6dc2d7c8912, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

gmail-draft-from-markdown scanned grade A with 0 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 5d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/build-message.py, scripts/clean.sh, scripts/draft.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/gws/skills/gmail-draft-from-markdown/SKILL.md · 345 lines

How it starts

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

Gmail Draft from Markdown

Take a local markdown file, convert it to HTML, and save it as a Gmail draft (never sent). Returns a clickable Gmail drafts URL so the user can review and send from the Gmail UI.

Default is --draft, always. Thoughtful emails (coaching follow-ups, client notes, anything personal) need human review before they go out. This skill will never send an email directly.

Prerequisites

# Codex: this path resolves under Claude Code; substitute the directory containing this plugin.
PLUGIN_ROOT="${CLAUDE_PLUGIN_ROOT}"
bash "$PLUGIN_ROOT/scripts/auth-preflight.sh"

Also requires a markdown→HTML converter. The script prefers marked (npm i -g marked) and falls back to pandoc. It errors with a clear message if neither is installed.

Task

Run the entrypoint script, passing all arguments through:

# Codex: this path resolves under Claude Code; substitute the directory containing this SKILL.md.
SKILL_DIR="${CLAUDE_SKILL_DIR}"
bash "$SKILL_DIR/scripts/draft.sh" $ARGUMENTS

If no arguments were provided, ask the user for the markdown file path and recipient (email or name). Subject is optional — the script derives it from a Subject: ... line at the top of the markdown if present.

Arguments

Arg Required Notes
<markdown-file> yes Path to a local .md file.
<recipient> yes Email address, or a name to look up via Gmail search.
--subject "..." no Overrides the Subject: line in the markdown.
--cc EMAIL no Comma-separated.
--bcc EMAIL no Comma-separated.
--from EMAIL no Send-as alias (defaults to active account).
--reply-to MESSAGE_ID no Thread the draft onto that message's conversation (see Threading).
--thread THREAD_ID no Attach the draft to a threadId directly, no header lookup. Prefer --reply-to.
--attach PATH no Attach a local file. Repeatable; composes with every other flag.

Read the full file on GitHub · 345 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. 5d ago First seen · 345 lines · 48 tokens per session scan A a6dc2d7c8912

Subscribe to this mod's changes

gmail-draft-from-markdown is a skill published in the GitHub repository jtsternberg/claude-plugins (5 stars, last pushed yesterday), licensed MIT. It adds 48 tokens to every session and 4,146 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.