> ## Documentation Index
> Fetch the complete documentation index at: https://docs.modulex.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Resend Integration for AI Agents & Workflows

> Send transactional and marketing emails, retrieve email status, manage contacts, and view domains with Resend.

{/* Self-hosted logo — build-time vendored from modulex.json / Iconify (see scripts/lib/logo.js). */}

<img src="https://mintcdn.com/modulexaillc/df8MOr-hXotYLTh5/logos/placeholder.svg?fit=max&auto=format&n=df8MOr-hXotYLTh5&q=85&s=a4046f9cd6d738c81259050e9833913c" alt="Resend logo" width="72" height="72" data-path="logos/placeholder.svg" />

## Overview

Add **Resend** to any ModuleX agent or workflow. Send transactional and marketing emails, retrieve email status, manage contacts, and view domains via the Resend REST API (`api.resend.com`).

<Info>
  **Categories**: Communication · Email · Email Marketing · **Auth**: API Key · **Actions**: 8
</Info>

## Authentication

### API Key Authentication

Authenticate using your Resend API key

<Steps>
  <Step title="Step 1">
    Go to [https://resend.com](https://resend.com) and sign up or log in
  </Step>

  <Step title="Step 2">
    Navigate to the 'API Keys' section in the dashboard
  </Step>

  <Step title="Step 3">
    Create a new API key (it starts with 're\_')
  </Step>

  <Step title="Step 4">
    Paste the API key below
  </Step>
</Steps>

#### Required Credentials

| Field          | Description                                  | Required | Format                         |
| -------------- | -------------------------------------------- | -------- | ------------------------------ |
| Resend API Key | Your Resend API key from resend.com/api-keys | Yes      | `re_xxxxxxxxxxxxxxxxxxxxxxxxx` |

## Available Actions

<AccordionGroup>
  <Accordion title="send — Send an email using your Resend API key and from address.">
    ### Parameters

    <ResponseField name="from_address" type="string" required>
      Email address to send from (e.g. "[sender@example.com](mailto:sender@example.com)" or "Sender Name \<[sender@example.com](mailto:sender@example.com)>")
    </ResponseField>

    <ResponseField name="to" type="string" required>
      Recipient email address (e.g. "[recipient@example.com](mailto:recipient@example.com)" or "Recipient Name \<[recipient@example.com](mailto:recipient@example.com)>")
    </ResponseField>

    <ResponseField name="subject" type="string" required>
      Email subject line
    </ResponseField>

    <ResponseField name="body" type="string" required>
      Email body content (plain text or HTML based on content\_type)
    </ResponseField>

    <ResponseField name="content_type" type="string">
      Content type for the body: "text" for plain text or "html" (Default: `text`)
    </ResponseField>

    <ResponseField name="cc" type="string">
      Carbon copy recipient email address
    </ResponseField>

    <ResponseField name="bcc" type="string">
      Blind carbon copy recipient email address
    </ResponseField>

    <ResponseField name="reply_to" type="string">
      Reply-to email address
    </ResponseField>

    <ResponseField name="scheduled_at" type="string">
      Schedule email to be sent later in ISO 8601 format
    </ResponseField>

    <ResponseField name="tags" type="string">
      Comma-separated key:value pairs for email tags (e.g. "category:welcome,type:onboarding")
    </ResponseField>

    ### Response

    ```json theme={null}
    {
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Id"
        },
        "to": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "To"
        },
        "subject": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Subject"
        },
        "body": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Body"
        }
      },
      "required": [
        "success"
      ],
      "title": "SendOutput",
      "type": "object"
    }
    ```
  </Accordion>

  <Accordion title="get_email — Retrieve details of a previously sent email by its ID.">
    ### Parameters

    <ResponseField name="email_id" type="string" required>
      The ID of the email to retrieve
    </ResponseField>

    ### Response

    ```json theme={null}
    {
      "$defs": {
        "EmailTag": {
          "additionalProperties": false,
          "description": "A single tag name/value pair attached to an email.",
          "properties": {
            "name": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Name"
            },
            "value": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Value"
            }
          },
          "title": "EmailTag",
          "type": "object"
        }
      },
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Id"
        },
        "sender": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Sender"
        },
        "to": {
          "items": {
            "type": "string"
          },
          "title": "To",
          "type": "array"
        },
        "subject": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Subject"
        },
        "html": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Html"
        },
        "text": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Text"
        },
        "cc": {
          "items": {
            "type": "string"
          },
          "title": "Cc",
          "type": "array"
        },
        "bcc": {
          "items": {
            "type": "string"
          },
          "title": "Bcc",
          "type": "array"
        },
        "reply_to": {
          "items": {
            "type": "string"
          },
          "title": "Reply To",
          "type": "array"
        },
        "last_event": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Last Event"
        },
        "created_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Created At"
        },
        "scheduled_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Scheduled At"
        },
        "tags": {
          "items": {
            "$ref": "#/$defs/EmailTag"
          },
          "title": "Tags",
          "type": "array"
        }
      },
      "required": [
        "success"
      ],
      "title": "GetEmailOutput",
      "type": "object"
    }
    ```
  </Accordion>

  <Accordion title="create_contact — Create a new contact in Resend.">
    ### Parameters

    <ResponseField name="email" type="string" required>
      Email address of the contact
    </ResponseField>

    <ResponseField name="first_name" type="string">
      First name of the contact
    </ResponseField>

    <ResponseField name="last_name" type="string">
      Last name of the contact
    </ResponseField>

    <ResponseField name="unsubscribed" type="boolean">
      Whether the contact is unsubscribed from all broadcasts
    </ResponseField>

    ### Response

    ```json theme={null}
    {
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Id"
        }
      },
      "required": [
        "success"
      ],
      "title": "CreateContactOutput",
      "type": "object"
    }
    ```
  </Accordion>

  <Accordion title="list_contacts — List all contacts in Resend.">
    ### Response

    ```json theme={null}
    {
      "$defs": {
        "ContactItem": {
          "additionalProperties": false,
          "description": "A single contact row in ``list_contacts``.",
          "properties": {
            "id": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Id"
            },
            "email": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Email"
            },
            "first_name": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "First Name"
            },
            "last_name": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Last Name"
            },
            "created_at": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Created At"
            },
            "unsubscribed": {
              "anyOf": [
                {
                  "type": "boolean"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Unsubscribed"
            }
          },
          "title": "ContactItem",
          "type": "object"
        }
      },
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "contacts": {
          "items": {
            "$ref": "#/$defs/ContactItem"
          },
          "title": "Contacts",
          "type": "array"
        },
        "has_more": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Has More"
        }
      },
      "required": [
        "success"
      ],
      "title": "ListContactsOutput",
      "type": "object"
    }
    ```
  </Accordion>

  <Accordion title="get_contact — Retrieve details of a contact by ID or email.">
    ### Parameters

    <ResponseField name="contact_id" type="string" required>
      The contact ID or email address to retrieve
    </ResponseField>

    ### Response

    ```json theme={null}
    {
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Id"
        },
        "email": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Email"
        },
        "first_name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "First Name"
        },
        "last_name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Last Name"
        },
        "created_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Created At"
        },
        "unsubscribed": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Unsubscribed"
        }
      },
      "required": [
        "success"
      ],
      "title": "GetContactOutput",
      "type": "object"
    }
    ```
  </Accordion>

  <Accordion title="update_contact — Update an existing contact in Resend.">
    ### Parameters

    <ResponseField name="contact_id" type="string" required>
      The contact ID or email address to update
    </ResponseField>

    <ResponseField name="first_name" type="string">
      Updated first name
    </ResponseField>

    <ResponseField name="last_name" type="string">
      Updated last name
    </ResponseField>

    <ResponseField name="unsubscribed" type="boolean">
      Whether the contact should be unsubscribed from all broadcasts
    </ResponseField>

    ### Response

    ```json theme={null}
    {
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Id"
        }
      },
      "required": [
        "success"
      ],
      "title": "UpdateContactOutput",
      "type": "object"
    }
    ```
  </Accordion>

  <Accordion title="delete_contact — Delete a contact from Resend by ID or email.">
    ### Parameters

    <ResponseField name="contact_id" type="string" required>
      The contact ID or email address to delete
    </ResponseField>

    ### Response

    ```json theme={null}
    {
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Id"
        },
        "deleted": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Deleted"
        }
      },
      "required": [
        "success"
      ],
      "title": "DeleteContactOutput",
      "type": "object"
    }
    ```
  </Accordion>

  <Accordion title="list_domains — List all domains in your Resend account.">
    ### Response

    ```json theme={null}
    {
      "$defs": {
        "DomainItem": {
          "additionalProperties": false,
          "description": "A single domain row in ``list_domains``.",
          "properties": {
            "id": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Id"
            },
            "name": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Name"
            },
            "status": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Status"
            },
            "region": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Region"
            },
            "created_at": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "default": null,
              "title": "Created At"
            }
          },
          "title": "DomainItem",
          "type": "object"
        }
      },
      "additionalProperties": false,
      "properties": {
        "success": {
          "title": "Success",
          "type": "boolean"
        },
        "error": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Error"
        },
        "domains": {
          "items": {
            "$ref": "#/$defs/DomainItem"
          },
          "title": "Domains",
          "type": "array"
        },
        "has_more": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Has More"
        }
      },
      "required": [
        "success"
      ],
      "title": "ListDomainsOutput",
      "type": "object"
    }
    ```
  </Accordion>
</AccordionGroup>

## Limits & Quotas

* **Rate limit**: 2 requests/second by default (Resend account level).
* **Scheduling**: emails can be scheduled up to 30 days ahead via
  `scheduled_at` (ISO 8601 timestamp).
* **Error model**: non-2xx responses and timeouts are caught and
  returned as `success=False` + `error` rather than raising. Plan for
  retries on the agent side based on the error string.

## Related integrations

<CardGroup cols={3}>
  <Card title="AgentMail" href="/integrations/tools/agentmail" />

  <Card title="Gmail" href="/integrations/tools/gmail" />

  <Card title="Mailgun" href="/integrations/tools/mailgun" />
</CardGroup>

## Links

* [Resend](https://resend.com)
