Why Molted
How Molted's policy engine protects your agent from sending the wrong email - and why prompt-level guardrails are not enough.
Every AI agent that sends email will eventually send the wrong one. The question is what stops it.
Most email infrastructure treats agent-sent email identically to human-sent email. There is no policy layer, no decision trace, and no way to enforce rules at the infrastructure level. When something goes wrong, you find out from a bounce notification or an angry reply.
Molted is different. Every send passes through a policy pipeline on the server, more than 30 distinct block reasons across billing, quotas, warmup, compliance and recipient checks, before anything leaves.
The problem with prompt-level guardrails
In February 2026, an AI agent operating on a live Gmail inbox bulk-deleted hundreds of emails. The agent had safety instructions - "never delete emails without confirmation" - but those instructions were plain text in its system prompt. During a long session, context compaction dropped the safety instructions to fit newer messages into the context window. The guardrail disappeared, and the agent acted on its remaining instructions.
This is not a hypothetical edge case. It is the natural failure mode of prompt-level safety. Instructions that exist only as text are subject to:
- Context compaction - long-running agents routinely compress or drop older context
- Prompt injection - inbound emails can contain instructions that override system prompts
- Model updates - behavior changes across model versions can alter instruction adherence
- Multi-agent handoffs - safety context may not transfer between agents in a pipeline
Infrastructure-layer enforcement catches what prompt-layer guardrails miss because the rules execute in application code, outside the model's context window.
What the send pipeline checks
Every send (POST /v1/agent/request-send, POST /v1/send/request, a thread reply, a batch item, and the simulation endpoint) runs the same checks, in this order. The first one that fails decides the answer, and its code comes back as reason:
| Stage | What it catches | reason |
|---|---|---|
| Coordination | Another agent holds the lease on this contact (agent routes); a human took the thread over | lease_conflict, thread_taken_over (409) |
| Template | The template is missing or fails to render; a marketing send while the workspace has no physical address on file (CAN-SPAM) | template_not_found, template_render_failed, missing_physical_address |
| Billing | No plan activated yet, or the plan expired | trial_not_activated, subscription_expired |
| Quota | The workspace's monthly, daily or hourly send allowance is used up | monthly_limit_exceeded, overage_cap_exceeded, daily_limit_exceeded, hourly_limit_exceeded |
| Warmup and domain limits | A new domain's warmup cap; per-recipient-domain throttles | warmup_limit, warmup_horizon_exceeded, domain_throttled, domain_daily_limit_exceeded, domain_hourly_limit_exceeded, domain_minute_limit_exceeded |
| Account and mailbox pause | An account pause; a mailbox paused by a person or for its reputation | tenant_paused, mailbox_paused |
| Template approval | A template that requires approval and isn't approved, or fails lint | template_not_approved, template_lint_failed |
| Suppression | Recipients on a suppression list (unsubscribes, bounces, complaints, legal) | suppressed |
| Consent (opt-in) | A marketing send with no recorded consent, when the workspace requires it | no_consent |
| Engagement | Recipients who stopped engaging (5+ sends, no open, click or reply in 90 days), for a workspace with it on. Not self-serve today: no setting turns it on | disengaged |
| Active opportunity | A contact in an open deal stage (demo_scheduled, proposal, negotiation, contract_sent) | active_opportunity |
| Duplicate | The same dedupeKey was used before in this workspace | duplicate |
| Cooldown | The same recipient, template and mailbox within the workspace's cooldown (default 10 minutes, set in Workspace Settings; a reply to a message the contact sent in a thread skips it) | cooldown |
| Negative signals | Too many bounces and complaints across the workspace in 24 hours (default budget 50) | negative_signal_budget_exceeded |
| Sender | The mailbox isn't active, or its custom domain isn't verified | mailbox_not_active, sender_domain_not_verified, no_verified_domain |
A send that passes every check can still be held for a human instead of sent (status: "pending_approval"): by the mailbox's autonomy level (autonomy_level), by a risky thread (thread_risk_flagged: a reply on a thread whose inbound mail in the last 7 days was quarantined, rejected, or scored high for prompt injection, scoped to that one thread), or by the outbound content check (content_check). See Errors for every reason and what to do about it.
Every decision is recorded with its reason, and GET /v1/ops/trace/:requestId (molted trace) shows it next to the request and its delivery events, so you can audit why any send was allowed or blocked.
How Molted compares
The table below compares architectural approaches to agent email safety. It reflects publicly available documentation as of March 2026.
| Capability | Molted | Typical agent email provider |
|---|---|---|
| Send-time policy evaluation | 30+ block reasons, checked on every send | None |
| Decision records | Every send's decision and reason, with its trace | None |
| Autonomy levels | L1 (full approval), L2 (first-contact), L3 (auto) | None |
| Suppression enforcement | Global and tenant scopes (campaign scope recorded, enforced workspace-wide for now) | Basic unsubscribe |
| Engagement-based blocking | Blocks recipients who stopped engaging (not self-serve yet) | None |
| Active opportunity protection | Blocks sends to contacts in an open deal stage | None |
| Duplicate detection | Dedupe key matching | None |
| Cooldown windows | Per-workspace cooldown per recipient, template and mailbox | None |
| Per-thread injection-risk hold | Holds a reply on a thread with quarantined, rejected or high-injection-risk inbound | None |
| Negative signal budgets | Blocks sends on bounce/complaint spikes; mailboxes auto-pause on poor reputation | None |
| Multi-agent coordination | Leases, heartbeats, consensus voting | None |
| Consent/GDPR tracking | Consent records with a basis, source and jurisdiction; opt-in consent gate for marketing | None |
These are not add-ons the agent can skip: they run on the server on every send, whether the agent asks for them or not. The consent check is switched on per workspace, with requireConsentForMarketing in Workspace Settings; the engagement check can't be switched on by you yet.
Simulate it yourself
The policy engine is not a black box. You can dry-run any send against it and see exactly which rules would fire.
Try the policy engine
Enter an email address to simulate a send against the live policy engine. No email is actually sent.
Or call the endpoint directly (CLI: molted send simulate; MCP: dry_run):
curl -X POST https://mailbox.molted.email/v1/agent/simulate-send \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"recipientEmail": "test@example.com",
"templateId": "campaign-march",
"dedupeKey": "march-test"
}'templateId (default _default) and dedupeKey are optional; mailboxId, payload and threadId simulate exactly the send you plan to make.
{
"wouldAllow": false,
"reason": "cooldown",
"blockingReasons": ["cooldown"],
"cooldownExpiresAt": "2026-03-01T12:10:00Z",
"simulation": true,
"rateLimited": false,
"resolvedMailboxId": "MAILBOX_UUID",
"resolvedFromAddress": "you@agent.molted.email",
"policyContext": {
"hasDuplicate": false,
"isCooldownHit": true,
"isSuppressed": false,
"isDisengaged": false,
"hasActiveOpportunity": false,
"isTenantPaused": false,
"templateApproved": true,
"templateLintPassed": true,
"isConsentMissing": false,
"isBillingBlocked": false,
"billingPlan": "solo"
}
}blockingReasons lists every reason the send would be blocked for, in check order (reason is the first), so you can fix them all in one pass. policyContext shows the recipient-level checks (duplicate, cooldown, suppression, consent, engagement, opportunity, pause, template, billing, negative signals); quota, warmup, domain and sender problems show up in reason, blockingReasons and rateLimited. A send that would be held for a human comes back with wouldRequireApproval: true and an approvalReason. See Policy Simulation for the full API reference.
Architecture, not promises
Molted's approach is architectural. The policy engine runs in application code on the server, not in a prompt. It cannot be overridden by the model, bypassed by context compaction, or injected away by a malicious inbound email.
When your agent sends email through Molted:
- Rules are enforced - every send hits the policy pipeline, regardless of what the agent requested
- Decisions are recorded - every send's decision and reason are kept and traceable
- Autonomy is configurable - you choose how much independence the agent gets
- Reputation is protected - bounce and complaint spikes block sends, and a mailbox with poor reputation is paused, before deliverability degrades
The OWASP Top 10 for Agentic Applications (2026) lists inadequate scope limitation as a critical risk. The World Economic Forum's March 2026 report on AI agent governance recommends infrastructure-level controls. Molted implements both.
Get started
- Quickstart - send your first policy-checked email in five minutes
- Policy Simulation - dry-run sends against the engine
- Autonomy Levels - configure agent independence
- Approval Queues - human-in-the-loop review for sensitive sends