Send email from Discord bots without losing oversight

Wire Discord slash commands and interactions to MultiMail's approval queue so every bot-triggered email send goes through the right gate before delivery.


Discord bots have become a standard interface for internal team workflows — support queues, moderation actions, member onboarding, and outreach requests all flow through bot commands. When those commands need to trigger outbound email, the gap between "bot says send" and "email actually delivered" is where mistakes happen.

MultiMail sits between your Discord bot and your email infrastructure. A slash command fires, the bot calls MultiMail's REST API, and depending on your oversight mode, the message either queues for human approval or sends immediately with a notification. Either way, you get a full audit trail of who triggered what and when.

This pattern is common in community management tools, support bots, and internal tooling where a Discord interaction is the user-facing trigger but the actual effect — an email to a customer, a partner, or a mailing list — needs to be controlled and traceable.

Built for Discord developers

Approval queue for chat-triggered sends

Discord commands make email outreach dangerously easy. MultiMail's gated_send mode holds every bot-triggered send in a review queue. A human approves or rejects via the MultiMail dashboard or API before any message leaves your domain.

Recipient verification before delivery

MultiMail checks recipients against your contact list and domain policy before queuing a send. A typo in a Discord command won't result in email to an unintended address.

Audit trail tied to Discord interactions

Every send, approval, and rejection is logged with the originating interaction ID. You can trace any email back to the exact Discord command that triggered it, including the user, channel, and timestamp.

Inbox reads without credential sharing

Discord bots can query MultiMail inboxes via the REST API without needing direct IMAP or SMTP credentials. The bot gets read access scoped to specific mailboxes with no path to credential leakage.

Webhook callbacks to Discord channels

MultiMail can post delivery confirmations, bounce alerts, and approval requests back to specific Discord channels via webhooks, closing the loop without requiring the bot to poll.


Try it with your agent

No code, no dashboard. Paste this to your AI agent — it connects MultiMail, creates an inbox, and builds the flow for you.

1. Read https://multimail.dev/llms.txt, connect the MultiMail MCP server, create a free inbox for this Discord agent, and set up a verified sending domain. Keep MultiMail in gated_send oversight mode so I must approve every send before delivery. 2. In my Discord app, use Discord's real application commands and interaction handling: add slash commands for checking the inbox, drafting a reply, and sending an email. Use Discord interaction responses, modals, and message components where appropriate for collecting recipients, subject, body, and approval decisions. 3. Wire those Discord commands to MultiMail MCP capabilities only: inbox checking reads the agent inbox, draft-reply composes an email draft, and send prepares the email for gated_send review. Do not send directly from Discord without passing through MultiMail oversight. 4. Add an approval flow in Discord: when a bot-triggered email is ready, post a private review interaction showing recipient, subject, and body, with clear approve and reject actions. Approval should release the gated_send item; rejection should stop it. 5. Send one test email from the verified sender to a developer-controlled address, confirm it appears in the gated_send review step before delivery, approve it from Discord, then verify delivery and leave gated_send enabled for all future bot-triggered sends.

Step by step

1

Create a MultiMail mailbox and get your API key

Sign up at multimail.dev and create a mailbox (e.g., a support agent on a @multimail.dev address, or a local address on your own verified domain). Copy your API key from the dashboard — it starts with mm_live_ for production or mm_test_ for test mode. Creating a mailbox requires an admin-scope key.

2

Install discord.js and register your slash commands

Install the Discord library and register the slash commands your bot will expose. Use the Discord Developer Portal to create an application and bot token.

3

Wire the interaction handler to MultiMail

In your bot's interactionCreate handler, send from a mailbox whose oversight mode is gated_send. The sender is the mailbox in the path plus the bearer key — there is no `from` field.

4

Set up a webhook listener to close the loop

Register a webhook via POST /v1/webhooks (or in the MultiMail dashboard under Settings > Webhooks). Point it at your bot's HTTP endpoint. When an email is received, delivered, or bounces, MultiMail will POST an event that your bot can relay back to the originating Discord channel.


Common questions

Can I use MultiMail to send emails from a Discord bot without any human approval?
Yes. Set the mailbox's oversight mode to 'autonomous' or 'monitored' (it is a per-mailbox setting, not a per-send parameter). With 'autonomous', emails send immediately with no approval step. With 'monitored', emails send immediately but a copy is surfaced to a human observer. For most bots handling outbound email to external recipients, 'gated_send' is the safer default.
How do I prevent Discord users from sending email to arbitrary addresses?
Use MultiMail's recipient allowlist feature to restrict the 'to' field to a set of verified addresses or domains. Any send attempt to an address outside the allowlist will be rejected with a 403 before it enters the approval queue. Configure the allowlist in the MultiMail dashboard under mailbox settings.
Does MultiMail support Discord webhooks directly, or do I need a separate server?
MultiMail emits webhooks to any HTTPS endpoint you register. You need a small HTTP listener to receive them — a Cloudflare Worker, a Vercel function, or a Node.js server all work. The listener receives the event payload and can then post to Discord using a Discord webhook URL or the bot's channel.send() method.
Can I read emails from a MultiMail inbox and display them in Discord?
Yes. Use GET /v1/mailboxes/{mailbox_id}/emails to fetch recent messages and GET /v1/mailboxes/{mailbox_id}/emails/{email_id} to retrieve the full body of a specific message. Both are standard REST calls your Discord bot can make in an interaction handler. Be mindful of Discord's message length limits (2000 characters) — truncate or summarize long email bodies before posting.
How do I associate a Discord user with an email action in the audit log?
Keep your own mapping: record the API key (or mailbox) used per Discord interaction on your side, and correlate it against MultiMail's audit log (GET /v1/audit-log), which records every send, approval, and rejection with timestamp and the acting key. Use a dedicated mailbox or key per workflow so the MultiMail-side trail is unambiguous, then join it to your Discord interaction log for a full trace from interaction to delivery.
What happens if an approved email bounces after a Discord-triggered send?
MultiMail emits an email.bounced webhook event. Register a webhook handler that forwards the bounce notification back to the Discord channel where the original command was issued. Include the email_id from the event payload in the notification so the team can correlate it with the approval they reviewed.

Explore more

The only agent email with a verifiable sender

Email infrastructure built for AI agents. Verifiable identity, graduated oversight, and a hosted MCP server. Formally verified in Lean 4.