Creating an inbox gives your AI agent its own email address. You can create inboxes on the default @agentmail.to domain or on your own custom domain.
The inbox now has a unique email address (e.g., randomname@agentmail.to) and can send and receive emails immediately.
You can specify a username, domain, and display name:
Using a custom domain requires a verified domain. See the Creating Custom Domains guide to set one up. If you don’t specify a domain, AgentMail uses the default @agentmail.to domain.
If your agent creates inboxes programmatically (e.g., on startup), use clientId to prevent duplicates. If an inbox with the same clientId already exists, AgentMail returns the existing inbox instead of creating a new one:
Once the inbox is created, you can send an email:
Always provide both text and html when sending emails. This ensures readability across all email clients and improves deliverability.
Now that you have an inbox, explore what you can do with it: