---
title: Create an Email-Alert Trigger for DeviceHub Device Data Quality
slug: create-an-email-alert-trigger-for-devicehub-device-data-quality
docTags: 
createdAt: 2025-05-05T14:40:56.051Z
---

In this guide, you will set up an alert and a trigger for a Manufacturing Connect Edge (MC Edge) device that is generating invalid/corrupted data. Then you will simulate an error output so that an alert is triggered. When the alert is triggered, the email addresses specified in the trigger will receive an email with information about the alert.

# Before You Begin

- You will have to enable SMTP from the Manufacturing Connect Admin Console. See [Email](docId\:XG4vTwb4X3rB-Yadjzt97) to learn more.&#x20;
- If you haven't yet connected your MC Edge instance to Manufacturing Connect, see [Activate an Edge Device](docId\:M2dU1twvNe9kZ1he-r222). An MC Edge instance needs to be activated in Manufacturing Connect before it can trigger alerts.

# Step 1: Set Up an Email-Alert Trigger&#x20;

In this step you'll create an email notification alert. Next, you will create a trigger that will use the email notification alert. See [Alerts](docId:2zMaXAfW8FaxD-bhWSeP6) for additional details.

From Manufacturing Connect, navigate to **Events & Alerts** and follow the steps below.&#x20;

## Step 1a: Set Up an Email Alert

**To set up an email alert:&#x20;**

1. From the *Events & Alerts* pane, click the **Add new Action** icon. &#x20;
   The *Add new Action* dialog box appears.
   ![](https://api.archbee.com/api/optimize/SSUUxKZUk9bFTEPNn_6Zo/4kj1vGY8vFuEs7Cj6g2ha_add-new-action.png)
2. From the *Add new Action* dialog box, enter the following details:
   - **Action Template**: Select EMAIL.
   - **Action Name**: Enter an action name.&#x20;
   - **Enter email**: Enter an email address that will receive the alert.
   - **Notifications Limit**: Enter 1.&#x20;
   - **Interval**: Select *minute*.
3. Click **Add**.&#x20;
   The newly created action appears in the *Action List*.

::Image[]{src="https://api.archbee.com/api/optimize/SSUUxKZUk9bFTEPNn_6Zo/12fxB2Jd2r2gu7ixNdevB_image.png" size="80" width="1554" height="496" caption="Creating a new email alert" position="center" showCaption="true"}

## Step 1b: Set Up a Trigger

**To set up a trigger:&#x20;**

1. From the *Events & Alerts* pane, click the **Add new Trigger** icon.&#x20;
   The *New Trigger* pane appears.
   ::Image[]{src="https://api.archbee.com/api/optimize/SSUUxKZUk9bFTEPNn_6Zo/__pb4Jy2-dOl7wRIZCXqh_add-new-trigger.png" size="80" width="1329" height="568" position="center" showCaption="false"}
2. From the *New Trigger* pane, configure the following sections.&#x20;

### Trigger

- **Name**: Enter a name for the trigger.
- **Active**: Select the checkbox.
- **Dashboard**: Select the checkbox.
- **Description**: Enter a description for the trigger.

### Scope

Selec&#x74;**&#x20;Edge Device&#x20;**&#x61;nd select the appropriate MC Edge instance.&#x20;

### Source

- Selec&#x74;**&#x20;Metrics&#x20;**&#x61;s the source of the trigger.
- Click **Add&#x20;**&#x6E;ew rule.
- **Select Alert template**: Select *DH device data quality.*
  - For *Target Value, msgs/minute,* enter 1 minute.
  - For *Alert Delay, seconds,&#x20;*&#x65;nter 60 seconds.&#x20;

### Action

- **Action List**: Select the action you previously created.
- **Continuously**: Select the checkbox to send notifications continuously. &#x20;
- **Notification Period, minutes**: Enter 1.

When done, click **Save**.&#x20;
The alert trigger appears in the Trigger List.

# Step 2: Simulate a Disconnection

From your MCE, you will simulate the DeviceHub driver sending invalid/corrupted data.

**To simulate a disconnection:**

1. Log in to Manufacturing Connect Edge.&#x20;
2. From the navigation panel, navigate to **DeviceHub&#x20;**> **Tags**.
   The *Tags* pane appears.
3. Click the **Action menu** for the tag you created and select **Edit**.&#x20;
4. For the **Value Type** field, select float64.
5. For the **Formula** field, corrupt the *Formula* field by replacing the `s` in `sin` with `1` so that the final formula starts with `1in`. Then, click **Update Tag**.&#x20;

::Image[]{src="https://api.archbee.com/api/optimize/SSUUxKZUk9bFTEPNn_6Zo/SbKcMpkwo-Ei3WUF_VYVP_image.png" size="80" width="1176" height="705" caption="Corrupted Tag Formula" position="center" showCaption="true"}

# Step 3: Verify Successful Trigger and Alert

From Manufacturing Connect, you will verify the simulated error rate.

**To verify the trigger and alert:**

1. Log in to Manufacturing Connect.
   The Status Overview page displays.&#x20;
2.   From the navigation panel, navigate to **Events & Alerts&#x20;**> **Incidents**.
   The *Incidents&#x20;*&#x70;ane appears. Review that the incidents display in the list.&#x20;

The email address that was configured for the alert will also receive the respective alert email.

![](https://api.archbee.com/api/optimize/SSUUxKZUk9bFTEPNn_6Zo/3dnC_ZEFnxsoPoMlqhJRG_vqxt10uwvt7wlaldr8pekimage.png "Alert email")

