Ashish · field notes
All notes
← back to the system map
LiveInfrastructure1 min read

Programmatic email send

The mail connector could only draft, so I built the narrow piece of plumbing that actually sends.

The Gmail MCP connector is draft-only. It can search, read, label, and create drafts, but it can't send or trash. So the agents that needed to actually dispatch mail (payroll checks out to GMs, vendor emails) were stuck one step short of acting.

How it works

A small Python SMTP sender authenticates as my own address over smtp.gmail.com, using a Google app password pulled from 1Password at runtime. Never the login password, and never printed. It sets real To and Cc headers, sends to arbitrary recipients, and the sends auto-save to my Gmail Sent folder. I wrapped it in reusable helpers so any agent can fire a recipient-aware HTML email.

It's live and confirmed. It's a deliberately boring bridge, but without it half the agents could only draft, not act. That gap between draft and send is the whole difference between a suggestion and a done task.

Got an idea? Tell me →More field notes