Overview
Add AgentMail to any ModuleX agent or workflow. API-first email for agents and automation: create inboxes, send and receive messages, reply to and forward threads, manage drafts, and organize conversations with labels — over the AgentMail REST API (api.agentmail.to).
Authentication
API Key Authentication
Authenticate using your AgentMail API keyStep 1
Required Credentials
| Field | Description | Required | Format |
|---|---|---|---|
| AgentMail API Key | Your AgentMail API key | Yes | - |
Available Actions
send_message — Send an email message from an AgentMail inbox.
send_message — Send an email message from an AgentMail inbox.
Parameters
Response
reply_message — Reply to an existing email message in AgentMail.
reply_message — Reply to an existing email message in AgentMail.
forward_message — Forward an email message to new recipients in AgentMail.
forward_message — Forward an email message to new recipients in AgentMail.
Parameters
Response
list_messages — List messages in an inbox in AgentMail.
list_messages — List messages in an inbox in AgentMail.
get_message — Get details of a specific email message in AgentMail.
get_message — Get details of a specific email message in AgentMail.
update_message — Add or remove labels on an email message in AgentMail.
update_message — Add or remove labels on an email message in AgentMail.
list_threads — List email threads in AgentMail.
list_threads — List email threads in AgentMail.
Parameters
Response
get_thread — Get details of a specific email thread including messages in AgentMail.
get_thread — Get details of a specific email thread including messages in AgentMail.
update_thread — Add or remove labels on an email thread in AgentMail.
update_thread — Add or remove labels on an email thread in AgentMail.
delete_thread — Delete an email thread in AgentMail (moves to trash, or permanently deletes if already in trash).
delete_thread — Delete an email thread in AgentMail (moves to trash, or permanently deletes if already in trash).
create_draft — Create a new email draft in AgentMail.
create_draft — Create a new email draft in AgentMail.
Parameters
Response
list_drafts — List email drafts in an inbox in AgentMail.
list_drafts — List email drafts in an inbox in AgentMail.
get_draft — Get details of a specific email draft in AgentMail.
get_draft — Get details of a specific email draft in AgentMail.
update_draft — Update an existing email draft in AgentMail.
update_draft — Update an existing email draft in AgentMail.
Parameters
Response
delete_draft — Delete an email draft in AgentMail.
delete_draft — Delete an email draft in AgentMail.
send_draft — Send an existing email draft in AgentMail.
send_draft — Send an existing email draft in AgentMail.
create_inbox — Create a new email inbox with AgentMail.
create_inbox — Create a new email inbox with AgentMail.
list_inboxes — List all email inboxes in AgentMail.
list_inboxes — List all email inboxes in AgentMail.
get_inbox — Get details of a specific email inbox in AgentMail.
get_inbox — Get details of a specific email inbox in AgentMail.
update_inbox — Update the display name of an email inbox in AgentMail.
update_inbox — Update the display name of an email inbox in AgentMail.
Limits & Quotas
- All calls go to
https://api.agentmail.to/v0over HTTPS with a 30s client timeout. - List endpoints are paginated: pass
limitand the returnednext_page_token(viapage_token) to page through results. - Error model: non-2xx responses and timeouts are caught and
returned as
success=False+errorrather than raising. Plan for retries on the agent side based on the error string.