---
title: "Inbound routing"
description: "Receive emails at your domain and get clean JSON POSTed to your webhook."
url: https://www.unitpost.com/docs/inbound
section: Docs
updated: 2026-07-23
---
# Inbound routing

## Inbound routing

> Receive emails at your domain and get clean JSON POSTed to your webhook.

Inbound routing turns incoming email into structured data. When someone replies to your campaign or emails a custom address on your domain, we receive the raw MIME message, parse it, and POST a clean JSON payload to your webhook endpoint.

### Setup

- Enable receiving: In the dashboard under Domains, click on your verified domain and go to the Receiving tab to enable inbound routing.
- Publish MX records: Add the generated MX records to your DNS provider to route mail for this domain to us.
- Add a webhook: Create a webhook endpoint that listens for the `email.received` event.

> **Dedicated receiving domains:** We recommend using a dedicated subdomain for inbound routing (e.g. `reply.yourdomain.com`) so its MX records don't conflict with your primary corporate email (Google Workspace, Office 365).

### The payload

When an email arrives, we POST an `email.received` event containing the parsed subject, sender, recipient, and the body in both text and HTML. Attachments are extracted and made available for download via the API.

## Related

- [Install the SDK](https://www.unitpost.com/docs/install): Add the official Node, Python, or Ruby SDK — or call the API directly.
- [Quickstart](https://www.unitpost.com/docs/quickstart): Create a key, verify a domain, and send your first email.
- [Templates & variables](https://www.unitpost.com/docs/templates): Reference a saved template and pass per-recipient data.
