---
title: "Email API | Prontuno"
description: "Send receipts, password resets, and account alerts with a single HTTP request. The same integration works for your first email and your millionth."
canonical: https://prontuno.com/features/email-api/
---

# Transactional email, built into your application.

**Email API · REST · JSON**

Send receipts, password resets, and account alerts with a single HTTP request. The same integration works for your first email and your millionth.

[Request access](https://app.prontuno.com/get-started/) · [Read the send email reference](https://prontuno.com/api-reference/emails/send-email/)

## Send an email

### Example request and response

`POST /v1/emails`

```json
{
  "from": "receipts@example.com",
  "to": "ada@example.com",
  "subject": "Your receipt",
  "html": "<p>Thanks for your order.</p>"
}
```

`202 Accepted`

```json
{
  "emails": [{
    "id": "email_01kxwz4bfhe00rr3ww02remnap",
    "status": "queued"
  }]
}
```

Accepted requests return an email ID you can use to inspect delivery.

## Everything you need to send and track email

The API suits applications you write yourself: your code sends each message and can follow what happened to it, without running mail servers.

### Send one or many

Create a single email, or submit up to 1,000 emails in one batch request.

### Manage domains and suppressions

Add sending domains and manage the addresses you should not send to, from the same API.

### Look up any message

Check an email’s status and see when it was sent, delivered, bounced, or rejected.

## Built for integrations that retry

Networks fail and background jobs run twice. The API is designed so that retrying a request is safe and every error can be handled in code.

### Idempotent sends

A request sent with an Idempotency-Key header is accepted once. Repeating it within 24 hours returns the original response instead of sending again.

### Batches of up to 1,000

Every email in a batch is validated before any is accepted, so one invalid item cannot leave a batch half-sent.

### Attachments and headers

Emails can carry file attachments, inline images referenced by Content-ID, and custom headers, in requests of up to 15 MB.

### Errors your code can act on

Every error includes a code, the field that caused it, whether a retry can succeed, and a suggested next action.

### Send an email examples

#### cURL

```shell
curl https://api.prontuno.net/v1/emails \
  -H "Authorization: Bearer $PRONTUNO_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: order-1042-receipt" \
  -d '{
    "from": "receipts@example.com",
    "to": "ada@example.com",
    "subject": "Your receipt",
    "html": "<p>Thanks for your order.</p>"
  }'
```

#### Node.js

```js
const response = await fetch('https://api.prontuno.net/v1/emails', {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.PRONTUNO_API_KEY}`,
    'Content-Type': 'application/json',
    'Idempotency-Key': 'order-1042-receipt',
  },
  body: JSON.stringify({
    from: 'receipts@example.com',
    to: 'ada@example.com',
    subject: 'Your receipt',
    html: '<p>Thanks for your order.</p>',
  }),
});

const { emails } = await response.json();
```

#### Python

```python
import os
import requests

response = requests.post(
    "https://api.prontuno.net/v1/emails",
    headers={
        "Authorization": f"Bearer {os.environ['PRONTUNO_API_KEY']}",
        "Idempotency-Key": "order-1042-receipt",
    },
    json={
        "from": "receipts@example.com",
        "to": "ada@example.com",
        "subject": "Your receipt",
        "html": "<p>Thanks for your order.</p>",
    },
)

emails = response.json()["emails"]
```

#### Laravel

```php
use Illuminate\Support\Facades\Http;

$response = Http::withToken(config('services.prontuno.key'))
    ->withHeaders(['Idempotency-Key' => 'order-1042-receipt'])
    ->post('https://api.prontuno.net/v1/emails', [
        'from' => 'receipts@example.com',
        'to' => 'ada@example.com',
        'subject' => 'Your receipt',
        'html' => '<p>Thanks for your order.</p>',
    ]);

$emails = $response->json('emails');
```

## Send your first email

1. Request access and verify a sending domain.
2. Create an API key with sending access.
3. Send an email and check its delivery status.

[Read the send email reference](https://prontuno.com/api-reference/emails/send-email/)

## Explore more of Prontuno

- [Webhooks](https://prontuno.com/features/webhooks/) — Get delivery events in real time.
- [SMTP relay](https://prontuno.com/features/smtp-relay/) — Connect existing apps over SMTP.
- [Domain authentication](https://prontuno.com/features/domain-authentication/) — Set up SPF, DKIM, and DMARC.
- [Dedicated IP](https://prontuno.com/features/dedicated-ip/) — An IP reserved for your team.

## Request access

Ready to send with Prontuno? Request access and tell us about your sending needs. Applications are reviewed within 24 hours.

[Request access](https://app.prontuno.com/get-started/)
