---
title: Notifications and alert destinations
source: https://docs.newrelic.com/docs/workflow-automation/setup-and-configure/create-destinations
---

This page covers two ways **Workflow Automation** integrates with notifications:

1.  **Send notifications from workflows**: Use **Slack**, **PagerDuty**, email, or **webhook** actions within your workflows to notify teams when workflows complete, fail, or require approval.
2.  **Trigger workflows from alerts**: Configure **Workflow Automation** as a destination in New Relic alerts to automatically start workflows when alert conditions are breached.

> #### ⚠️ IMPORTANT
>
> **Two different concepts:**
>
> -   **Outbound notifications**: Your workflow sends messages to **Slack**/**PagerDuty** using actions like `slack.chat.postMessage`
> -   **Inbound triggers**: New Relic alerts trigger your workflow to run, passing `issueId` automatically

## Before you begin

Before configuring notifications, ensure you have:

-   A workflow created in your account (from [template](https://docs.newrelic.com/docs/workflow-automation/create-a-workflow-automation/use-a-template) or [custom-built](https://docs.newrelic.com/docs/workflow-automation/create-a-workflow-automation/create-your-own)).
-   Credentials for your notification channel (Slack bot token, PagerDuty API key, etc.).
-   Credentials stored in [secrets manager](https://docs.newrelic.com/docs/workflow-automation/limitations-and-faq/workflow-best-practices#secure-credentials).

> #### 💡 TIP
>
> **For sending notifications from workflows**: Use the actions catalog to add notification actions directly in your workflow steps:
>
> -   **Slack**: Use [`slack.chat.postMessage`](https://docs.newrelic.com/docs/workflow-automation/setup-and-configure/actions-catalog/slack/slack-chat) for direct Slack integration
> -   **PagerDuty**: Use [PagerDuty actions](https://docs.newrelic.com/docs/workflow-automation/setup-and-configure/actions-catalog/pagerduty/pagerduty-incident) for incident management
> -   **Email**: Use [`newrelic.notification.sendEmail`](https://docs.newrelic.com/docs/workflow-automation/setup-and-configure/actions-catalog/newrelic/newrelic-notification) after setting up email destinations in [Alerts > Destinations](https://docs.newrelic.com/docs/alerts/get-notified/destinations/)

## Send notifications from workflows [#send-from-workflows]

Use these notification channels to alert your team from within your workflows. Select the right channel for your use case:

| **Channel**   | **Best for**                  | **Setup complexity**              | **Features**                                |
| ------------- | ----------------------------- | --------------------------------- | ------------------------------------------- |
| **Slack**     | Team collaboration, approvals | Easy - requires bot token         | Rich messages, reactions, threads           |
| **PagerDuty** | Incident management, on-call  | Easy - requires API key           | Escalation policies, incident tracking      |
| **Email**     | Formal notifications, reports | Easy - requires destination setup | Attachments, HTML formatting, query results |
| **Webhooks**  | Custom integrations           | Medium - requires endpoint        | Flexible payload, any system                |

## Trigger workflows from alerts [#trigger-from-alerts]

Configure Workflow Automation as a destination in New Relic alerts to automatically start workflows when alert conditions are breached. When triggered by an alert, workflows automatically receive `issueId` and `accountId` as inputs.

1.  Navigate to **[one.newrelic.com > All capabilities](https://one.newrelic.com/all-capabilities) > Alerts > Destinations**, and select **Workflow Automation**.
2.  To configure the **Workflow Automation**, enter the required information, such as the **Workflow Automation destination name** (a unique name for the** Workflow Automation**) and the **API Key**.
3.  Click **Save destination**.

    ![Image of the Workflow Automation destination page.](https://docs.newrelic.com/images/add-a-destination.webp "How to add a destination")

## Create an alert notification workflow [#create-the-notification-workflow]

After setting up **Workflow Automation** as a destination, create an alert notification workflow to define which alerts trigger your workflows.

> #### ⚠️ IMPORTANT
>
> The steps below are for configuring **alert notification workflows**. Alert notification workflows route issues to destinations, including the **Workflow Automation** destination you configured above. For complete documentation on alert workflows, see [Alert event workflows](https://docs.newrelic.com/docs/alerts/get-notified/alert-event-workflows).

1.  Go to **Alerts > Notification Workflows**, and select **+ Add a workflow**.
2.  To configure your notification workflow, on the Configure your notification workflow page, provide the required information:
    -   Enter a unique name that you will recognize.
    -   Select the **Tag**, **Policy**, and **Priority** attributes from their respective dropdowns in the **Basic** filter option to receive notifications about an alert event, or opt for the **Advanced** filter option to choose **Attributes**, **Operators**, and **Values** for more detailed alert event notifications.
    -   Click **Additional settings** to enrich your data by building [NRQL queries](https://docs.newrelic.com/docs/alerts/get-notified/alert-event-workflows#enrichments) to gather related data from across your New Relic platform. For enrichment examples, see [Workflow data enrichment](https://docs.newrelic.com/docs/alerts/get-notified/custom-variables-alert-event-workflows#enrichment-examples).
3.  To specify notification destinations, in the **Notify** section, choose the **Workflow Automation** destination you created in the previous step.
4.  (Optional) You can also add other destinations like [Slack](https://docs.newrelic.com/docs/workflow-automation/setup-and-configure/actions-catalog/slack/slack-chat#configure-slack-integration) to receive notifications alongside triggering the workflow:
    1.  Select the **Slack destination** from the drop-down list.
    2.  Choose the **Channel** from the drop-down list and check the **Receive notification updates on the channel** checkbox.
    3.  Optionally, add a custom message in the **Custom Details** section.
        We recommend sending a test notification using Send test notification.
    4.  Select **Save message**.
5.  Select **Activate workflow**.

    ![Image of how to configure a workflow](https://docs.newrelic.com/images/configure-workflow.gif "How to configure a workflow")

## What data is passed [#data-passed]

When an alert triggers your Workflow Automation:

-   **`issueId`**: Automatically passed to your workflow. Your workflow must accept this as an input parameter. As documented in [Create your own workflow](https://docs.newrelic.com/docs/workflow-automation/create-a-workflow-automation/create-your-own), the `issueId` is "provided automatically when the workflow runs from an alert."
-   **`accountId`**: Your New Relic account ID. Your workflow must accept this as a required input parameter.

Your Workflow Automation definition must declare these inputs. For example:

```yaml
workflowInputs:
  accountId:
    type: Int
  issueId:
    type: String
```

> #### ⚠️ IMPORTANT
>
> Inputs without a `defaultValue` are required and must be provided when the workflow is triggered. You can then use `issueId` to query alert details using the NerdGraph API within your workflow.

## Related topics [#related-topics]

[Slack actions](https://docs.newrelic.com/docs/workflow-automation/setup-and-configure/actions-catalog/slack/slack-chat)

Send messages and get reactions in Slack channels

[Slack integration example](https://docs.newrelic.com/docs/workflow-automation/workflow-examples/integrations/slack)

Build workflows with Slack approval gates

[Use a template](https://docs.newrelic.com/docs/workflow-automation/create-a-workflow-automation/use-a-template)

Deploy notification workflows from templates

[Workflow best practices](https://docs.newrelic.com/docs/workflow-automation/limitations-and-faq/workflow-best-practices)

Security best practices for notification credentials
