# Mail Send

Send emails to one or more recipients. The API processes requests asynchronously and returns a `202` response that includes an `operationId` you can use to track send status.

## Send to a single recipient

Send an email to a single recipient:

```bash
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        }
    ],
    "content": {
        "subject": "Your subject line",
        "html": "<p>Your message content in HTML format.</p>",
        "text": "Your message content in plain text."
    }
}' \
-u $TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN
```

**Response (202 Accepted)**:

```json
{
    "operationId": "comms_operation_01h9krwprkeee8fzqspvwy6nq8",
    "operationLocation": "https://comms.twilio.com/v1/Emails/Operations/comms_operation_01h9krwprkeee8fzqspvwy6nq8"
}
```

## Send to multiple recipients

Send the same email to multiple recipients:

```bash
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        },
        {
            "address": "jane.smith@example.com",
            "name": "Jane Smith"
        }
    ],
    "content": {
        "subject": "Your subject line",
        "html": "<p>Your message content in HTML format.</p>",
        "text": "Your message content in plain text."
    }
}' \
-u $TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN
```

## Personalization with variables

Use Liquid templating to personalize emails for each recipient:

```bash
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "jane.doe@example.com",
            "variables": {
                "firstName": "Jane",
                "lastName": "Doe"
            }
        },
        {
            "address": "john.doe@example.com",
            "variables": {
                "firstName": "John",
                "lastName": "Doe"
            }
        }
    ],
    "content": {
        "subject": "Hello {{ firstName }}",
        "html": "<html><body>Hey {{ firstName | default: '\''there'\'' }} {{ lastName }}, your order is ready.</body></html>",
        "text": "Hey {{ firstName | default: '\''there'\'' }} {{ lastName }}, your order is ready."
    }
}' \
-u $TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN
```

## Schedule an email

Schedule an email to be sent at a future time. Provide a `sendAt` value in [RFC 3339](https://www.rfc-editor.org/rfc/rfc3339) format. You can schedule emails up to 7 days in advance.

```bash
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "support@example.com",
        "name": "Support Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        }
    ],
    "content": {
        "subject": "Scheduled Reminder",
        "html": "<html><body>This is your scheduled reminder.</body></html>"
    },
    "schedule": {
        "sendAt": ["2026-12-15T14:15:22Z"]
    }
}' \
-u $TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN
```

## Custom headers

Add custom headers to your emails for tracking and categorization:

```bash
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "marketing@example.com",
        "name": "Marketing Team"
    },
    "to": [
        {
            "address": "customer@example.com",
            "name": "Customer"
        }
    ],
    "content": {
        "subject": "Special Offer",
        "html": "<html><body><h1>Exclusive Deal!</h1></body></html>",
        "text": "Exclusive Deal!",
        "headers": {
            "X-Campaign-ID": "CAMPAIGN-2026-Q1",
            "X-Customer-Segment": "premium",
            "X-Priority": "high"
        }
    }
}' \
-u $TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN
```

**Note**: You can't override these headers: `x-sg-id`, `x-sg-eid`, `received`, `dkim-signature`, `Content-Type`, `Content-Transfer-Encoding`, `To`, `From`, `Subject`, `Reply-To`, `CC`, `BCC`.

## Tags for tracking

Add custom metadata tags to emails for filtering and tracking:

```bash
curl -X POST 'https://comms.twilio.com/v1/Emails' \
-H 'Content-Type: application/json' \
-d '{
    "from": {
        "address": "newsletter@example.com",
        "name": "Newsletter Team"
    },
    "to": [
        {
            "address": "john.doe@example.com",
            "name": "John Doe"
        }
    ],
    "content": {
        "subject": "January Newsletter",
        "html": "<html><body><h1>Newsletter</h1></body></html>"
    },
    "tags": {
        "campaign": "monthlyNewsletter",
        "edition": "january_2026"
    }
}' \
-u $TWILIO_ACCOUNT_SID:$TWILIO_AUTH_TOKEN
```

For more details on tag constraints, see [Tags](/docs/email/api/overview#tags).
