---
title: Create an automated email for failed orders
slug: configured-commerce/sdk/creating-an-automated-email-for-failed-orders
docTags: 
createdAt: 2026-08-05T19:24:01.122Z
---

Optimizely \{user\["product-name"]} offers an automated email for PunchOut administrators to receive if an order request fails. This article provides the required steps to set up the automated email. The steps include changing a setting as well as editing the template.

## Update the setting

:::hint{type="info"}
**Note**
The **PunchOut\_FailedOrderRequest** setting is a uniquely applied to each website.
:::

1. Go to **Marketing** > **Communication** > **Email Templates**.
2. Locate the **PunchOut\_FailedOrderRequest** template and click **Edit**. The email template is automatically created
3. Go to **Admin Console** > **Administration** > **System** > **Settings**.
4. From the **Configuring** menu, select the desired website.
5. Select the **Order Management** finger tab.
6. In **Failed Order Email**, enter the email address. To add additional recipients, click **Add**.

## Edit the email template

To make edits to the template, go to the **Admin Console** > **Marketing** > **Communication** > **Email Templates**.

The template is pre-populated with the following information:

- **Subject line** – Failed Punchout Order Alert
- **Body** – Date/Time Received: \<created on date/time>
- **Body** – Order ID: \<Order ID from cXML>
- **Body** – Bill To: \<BillTo.Name from cXML>
- **Body** – The above document failed to be processed. See the Order Requests history for additional information

The email will be sent to the recipients according to the following conditions:

- During the processing of the cXML – if a fatal error occurs **AND** there are any addresses in the Punchout\_FailedOrderEmail setting **AND** the template exists, send out the email using the template.
- Use the **Failed Order Email** Setting to identify the recipients who receive email notification for when an order fails when processing through cXML/PunchOut.
