Wire MultiMail's REST API as Claude tool calls. Send, read, and approve emails with structured inputs, gated oversight modes, and a complete audit trail below the model layer.
The Anthropic SDK exposes Claude's tool use interface as a first-class API primitive. You define tools as JSON schemas, Claude decides when to call them, and your application executes the calls and feeds results back. This loop maps directly onto email operations: send_email, check_inbox, read_email, reply_email, and get_thread all fit naturally as tool definitions.
What the SDK does not provide is enforcement policy. When Claude calls send_email, nothing in the SDK validates the recipient, checks whether a human approved the send, or records the decision for audit. MultiMail adds those controls below the model layer — as a REST API your tool executor calls — so Claude's email capability is governed regardless of what the model decides.
The integration is additive. You keep your existing messages loop, system prompt, and tool definitions. MultiMail replaces the outbound email call inside your tool executor with one that enforces the oversight_mode you configured for that agent mailbox.
Claude decides when to send email. MultiMail enforces who it can send to, whether a human must approve, and what gets logged. These controls live in the API layer, not in the system prompt, so they cannot be overridden by prompt injection or model drift.
Configure gated_send so every outbound send waits for human approval, or switch to autonomous once the agent has earned trust. The same agent code runs in all modes — only the mailbox configuration changes.
MultiMail's REST endpoints accept the same JSON fields you define in Claude's tool input_schema. No translation layer needed — the object Claude generates goes directly into the request body.
check_inbox and read_email return structured JSON that fits cleanly as tool_result content. Claude can parse subject, sender, body, and thread_id without custom parsing logic in your application.
Every send_email, reply_email, and decide_email call is logged with the originating agent, timestamp, recipients, and approval state. Required for SOC 2 and GDPR Article 5 accountability obligations.
No code, no dashboard. Paste this to your AI agent — it connects MultiMail, creates an inbox, and builds the flow for you.
Add the Anthropic TypeScript SDK to your project.
Create a mailbox for your agent and set the oversight mode. Use gated_send to require human approval on all outbound sends while reads remain autonomous.
Register MultiMail endpoints as Anthropic tool definitions. The input_schema properties map directly to the JSON fields each endpoint accepts.
When stop_reason is 'tool_use', dispatch each tool_use block to the matching MultiMail endpoint and push the results back as tool_result blocks.
Email infrastructure built for AI agents. Verifiable identity, graduated oversight, and a hosted MCP server. Formally verified in Lean 4.