> ## Documentation Index
> Fetch the complete documentation index at: https://dokumentation.websale.de/llms.txt
> Use this file to discover all available pages before exploring further.

# messages - Event-driven emails

> The messages node configures custom, event-driven emails sent to shop managers, suppliers or manufacturers — triggered via template conditions and IDs.

export const KonfigDeeplink = ({node}) => <>
    You can open this setting directly in the Admin Interface via the following link:{" "}
    <code>{`https://<shop-domain>/admin/config/${node}`}</code>{" "}
    (<a href="/en/admin-interface/konfigurations-deeplinks">Deeplink overview</a>)
  </>;

The `messages` node is used to configure custom email notifications that are automatically triggered as soon as certain events or states occur in the shop.

In addition to the system emails sent by default (e.g. order confirmation, shipping information or low-stock warning), individual emails can be defined here that are sent specifically to certain recipient groups — for example shop managers, suppliers or manufacturers.

**Important:** not the email itself is integrated in the template, but the trigger for its dispatch.

In the template the condition is checked via the template engine (e.g. "no search results found"). If it is met, the matching message is triggered for dispatch via its ID (e.g. `order_confirmation`).

This function makes it possible to map shop-specific events that are relevant for the operation or logistics of a particular shop.

New emails can currently only be created via the [REST API configuration](/en/schnittstellen/admin-interface-api/api-referenz-konfiguration).

***

## `messages*` - Basic structure

The basic structure of the `messages` node is shown below:

```json theme={"theme":{"light":"github-light","dark":"github-dark"},"languages":{"custom":["/languages/websale.json"]}}
{
  "messages": {
    "emails": {...}
  }
}
```

#### Parameter description

| **Parameter** | **Description**                        |
| ------------- | -------------------------------------- |
| `emails`      | Configures system emails for the shop. |

***

## `messages.emails` - Event-driven emails

Configures system emails for the shop. Each configuration can be addressed via a unique ID and the template can be maintained differently per subshop.

<KonfigDeeplink node="messages.emails" />

#### Example configuration `messages.emails.additionalMail`

```json theme={"theme":{"light":"github-light","dark":"github-dark"},"languages":{"custom":["/languages/websale.json"]}}
{
  "id": "order_confirmation",
  "sender": "shop@example.com",
  "subject": "Bestellbestätigung",
  "recipient": "customer@example.com",
  "template": "order_confirmation.htm"
}
```

#### Parameter overview

| **Parameter** | **Type** | **Description**                                                                                                                                                              |
| ------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `id`          | `string` | Unique identifier of the email configuration (e.g. `order_confirmation`).<br />Freely selectable. <br />The ID is used by the template to find the associated configuration. |
| `recipient`   | `string` | Recipient address of the email.                                                                                                                                              |
| `sender`      | `string` | Sender address of the email.                                                                                                                                                 |
| `subject`     | `string` | Subject line of the email.                                                                                                                                                   |
| `template`    | `string` | Path / name of the email template to be used (e.g. `order_confirmation.htm`).                                                                                                |
