# Content

!!! info
    This page was generated by extracting information from a JSON Schema
    data file for the API.  It may be missing some information, or otherwise
    suggest approximate or placeholder values based on information in the
    schema file; this is due to limitations on how that data is extracted
    from the underlying Rust code and into the JSON Schema, and then again
    from there and into these docs.

The message content.
Can either be a fully formed MIME message, or a json
object describing the MIME structure that should be created.


Can be one of the following shapes of data:

## Option 1
A complete MIME message string

This is a string value.

## Option 2
Describe the MIME structure to be created

This is an object value, with the following properties:


  * `amp_html_body` - optional nullable `string`. If set, will be used to create a text/x-amp-html part.
    This is available {{since('2026.03.04-bb93ecb1', inline=True)}}

  * `attachments` - optional array of [Attachment](Attachment.md). Optional list of attachments.

  * `from` - optional nullable [FromHeader](FromHeader.md). 

  * `headers` - optional `object`. Optional map of headers to include in the message.
    This is a map of header name to header value

  * `html_body` - optional nullable `string`. If set, will be used to create a text/html part

  * `reply_to` - optional nullable [FromHeader](FromHeader.md). 

  * `subject` - optional nullable `string`. Set the Subject: header

  * `text_body` - optional nullable `string`. If set, will be used to create a text/plain part

### Examples
```json
"From: user@example.com\nSubject: Hello\n\nHello there"
```
```json
{
  "amp_html_body": "<!doctype html><html amp4email>...</html>",
  "attachments": [
    {
      "base64": true,
      "content_id": "my-image",
      "content_type": "image/gif",
      "data": "R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",
      "file_name": "pixel.gif"
    }
  ],
  "from": {
    "email": "sales@sender-example.com",
    "name": "Sales"
  },
  "headers": {
    "X-Tenant": "MyTenant"
  },
  "html_body": "<p>This is the <b>HTML</b> part</p>",
  "reply_to": {
    "email": "sales@sender-example.com",
    "name": "Sales"
  },
  "subject": "string",
  "text_body": "This is the plain text part"
}
```
