---
title: "inbound"
description: "Inject raw RFC 5322 messages (needs the inbound_raw permission). The `machinemail inbound` commands: arguments, flags, examples and the API routes they call."
canonical: "https://machinemail.dev/docs/cli/commands/inbound"
---

# inbound

> Inject raw RFC 5322 messages (needs the inbound_raw permission). The `machinemail inbound` commands: arguments, flags, examples and the API routes they call.

Source: https://machinemail.dev/docs/cli/commands/inbound

Inject raw RFC 5322 messages (needs the inbound\_raw permission).

| Command                       | Summary            |
| ----------------------------- | ------------------ |
| [`inbound raw`](#inbound-raw) | Inject raw message |

Every command also takes the [global flags](https://machinemail.dev/docs/cli/commands#global-flags).

## inbound raw

Inject raw message.

Stores a raw RFC 5322 message (the request body, any Content-Type, at most 40 MB) as if it had been received, once per recipient inbox in the credential’s scope. The recipient is X-Recipient, otherwise every To and Cc address.

Injected messages are marked received\_via: "raw". Their trust report never believes the authentication results they carry (headers and provider verdicts are ignored): authentication is none, so the trust level is at most unknown.

An unrestricted key (\*) does not imply inbound\_raw; it must be granted by name.

Injected mail counts toward plan limits like any other inbound mail, even when the trust layer marks it spam or quarantined (its content is yours). On the Free plan, a copy past the monthly or daily allowance (or past storage) is held: it is listed in held, not in messages, and delivered when the allowance resets or after an upgrade.

Requires the inbound\_raw permission.

```bash
machinemail inbound raw [flags]
```

#### Flags

| Field | Type | | Description |
| --- | --- | --- | --- |
| `--recipient <value>` | `string` |  | Recipient address. Defaults to the To and Cc addresses of the message. |
| `-d, --data <@file|->` | `string` |  | Request body: @file, or - for stdin. |

#### Examples

```bash
machinemail inbound raw --data @message.eml
cat message.eml | machinemail inbound raw --data -
```

#### API

- [`POST /inbound/raw`](https://machinemail.dev/docs/reference/api/inbound#inject-raw-message)
