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

# Sending USM Anywhere Notifications to PagerDuty

From USM Anywhere, you can send an alarm or event notification to your PagerDuty incident management console so that team members receive alerts. This facilitates communication and collaboration within the same messaging tool that your organization uses for <Tooltip tip="Incident response is a business process or plan dictating how an organization handles security incidents such as a security breach or attack.">incident response</Tooltip>. When you have this integration configured in USM Anywhere, you can create orchestration rules to automatically send these notifications when an <Tooltip tip="Any traffic or data exchange detected by LevelBlue products through a sensor or external devices such as a firewall.">event</Tooltip> or <Tooltip tip="Alarms provide notification of an event or sequence of events that require attention or investigation.">alarm</Tooltip> matches the rule criteria.

<Tip>
  **Edition:** The Notification integrations are available in the Standard and Premium editions of USM Anywhere.

  See the [Affordable pricing to fit every budget](https://cybersecurity.att.com/pricing) page for more information about the features and support provided by each of the USM Anywhere editions.
</Tip>

<AccordionGroup>
  <Accordion title="Create the PagerDuty Integration">
    PagerDuty provides a mechanism to create services that include integrations to its Events API as a way to post data from external sources into PagerDuty incidents. The service configuration determines how PagerDuty handles the incoming incident. You must first create the integration key for a PagerDuty service before you set up the configuration in USM Anywhere to send these notifications.

    <Note>
      **Note:** A PagerDuty service typically represents an application, component, or team for opening incidents. If you already have a defined service and you want to incorporate USM Anywhere notifications with it, you can simply add a new integration to that service and use the parameters outlined in the following procedure.
    </Note>

    **To create a PagerDuty service and integration for USM Anywhere**

    1. Log in to your PagerDuty account.

    2. In the top menu, select **Configuration > Services**.

    3. At the top of the page, click **Add New Service**.

    4. In the General Settings, enter a name for the new service (such as LevelBlue).

    5. In Integration Settings, set the type and name for the integration.

       * Choose **Use our API Directly** and select **Events API v2**.
       * Enter an Integration Name (such as *USM Anywhere*).

           <Frame>
             <img src="https://mintcdn.com/levelblue-5324744e/xOkkFcWcXtj_Ev_v/images/usm-anywhere/deployment-guide/notifications/pagerduty-new-service.webp?fit=max&auto=format&n=xOkkFcWcXtj_Ev_v&q=85&s=f7d8baf08dfe2eb8a2cf23f4dffb3a5c" width="776" height="652" data-path="images/usm-anywhere/deployment-guide/notifications/pagerduty-new-service.webp" />
           </Frame>

    6. Set the Incident Settings and Incident Behavior according to how you want PagerDuty to handle the incidents (notifications) from USM Anywhere.

    7. Click **Add Service**.

    8. In the Integrations tab, copy the Integration Key for the new integration.

           <Frame>
             <img src="https://mintcdn.com/levelblue-5324744e/xOkkFcWcXtj_Ev_v/images/usm-anywhere/deployment-guide/notifications/pagerduty-integration-key.webp?fit=max&auto=format&n=xOkkFcWcXtj_Ev_v&q=85&s=e01b69e1afa67fda2ad2aab74f624302" width="895" height="381" data-path="images/usm-anywhere/deployment-guide/notifications/pagerduty-integration-key.webp" />
           </Frame>

       Make sure to copy the key value to a secured location.
  </Accordion>

  <Accordion title="Configure the PagerDuty Integration in USM Anywhere">
    After you have created the PagerDuty integration and copied the key, you can configure USM Anywhere for PagerDuty notifications. After this configuration is in place, any orchestration rules set up for PagerDuty notification will send the triggered notification to the PagerDuty service for incident handling.

    **To configure the connection between PagerDuty and USM Anywhere**

    1. In the USM Anywhere web UI, go to **Settings > Notifications**.

    2. In the left navigation panel, click **PagerDuty**.

    3. In the PagerDuty integration key field, paste the key value that you copied from your PagerDuty service integration.

           <Frame>
             <img src="https://mintcdn.com/levelblue-5324744e/xOkkFcWcXtj_Ev_v/images/usm-anywhere/deployment-guide/notifications/pagerduty-config.webp?fit=max&auto=format&n=xOkkFcWcXtj_Ev_v&q=85&s=6d5eeff16b16f9c6e7b04edb4acf76fb" width="774" height="291" data-path="images/usm-anywhere/deployment-guide/notifications/pagerduty-config.webp" />
           </Frame>

    4. Click **Save Credentials**.
  </Accordion>

  <Accordion title="Add an Orchestration Rule for PagerDuty Notifications">
    Create an orchestration rule to match new alarms or events and trigger a notification to your PagerDuty service. You can use an existing alarm or event with the desired characteristics to easily set the matching conditions for the rule.

    **To create an orchestration rule to trigger a PagerDuty notification**

    1. Go to **Activity > Alarms** or **Activity > Events**.

    2. Click the alarm or event to open the details.

    3. Click **Create Rule** and select **Create Notification Rule**.

           <Frame>
             <img src="https://mintcdn.com/levelblue-5324744e/xOkkFcWcXtj_Ev_v/images/usm-anywhere/deployment-guide/notifications/alarmdetailscreaterule.webp?fit=max&auto=format&n=xOkkFcWcXtj_Ev_v&q=85&s=da7b47a01605543300784c444dfa2944" width="580" height="287" data-path="images/usm-anywhere/deployment-guide/notifications/alarmdetailscreaterule.webp" />
           </Frame>

    4. You have already suggested property values to create a matching condition, but if you want to add new property values, click **Add Condition**.

           <Note>
             **Note:** If the field is related to the name of a country, you should use the country code defined by the [ISO 3166](https://www.iso.org/iso-3166-country-codes.html).
           </Note>

           <Note>
             **Note:** The Sources or Destinations field needs to match the universally unique identifier (UUID) of the event or alarm. You can use the Source Name or Destination Name field instead.
           </Note>

           <Warning>
             **Important:** Instead of using the `equals` and `equals`, `case insensitive` operators for array fields, LevelBlue recommends the use of the `in` or `contains` operators.
           </Warning>

           <Note>
             **Note:** If you need to add a property value that maps with a property key, you need to know the mapping of the field. See [Determining the Mapping of a Field](../../user-guide/rules-management/mapping-field) for more information.
           </Note>

    5. (Optional) Click **Add Group** to group your conditions.

           <Note>
             **Note:** See [Operators in the Orchestration Rules](../../user-guide/rules-management/orchestration-rules-operators) for more information.
           </Note>

    6. In the **Occurrences** text box, enter the number of event occurrences that you want to produce a match on the conditional expression to trigger the rule.

       You can enter the number of occurrences or use the arrows to scroll the value up or down. You can enter a number between 1 and 100.

           <Note>
             **Note:** The current rule box shows you the syntax of your rule, and the rule verification box reviews that syntax before saving the rule.
           </Note>

    7. Click **Next**.

           <Frame>
             <img src="https://mintcdn.com/levelblue-5324744e/LRsr4s1iGr_CM6ff/images/usm-anywhere/user-guide/rules-management/ruleverification.webp?fit=max&auto=format&n=LRsr4s1iGr_CM6ff&q=85&s=52719fcab619098656679ab0756735fa" width="358" height="234" data-path="images/usm-anywhere/user-guide/rules-management/ruleverification.webp" />
           </Frame>

    8. Enter a name for the rule.

    9. (Optional) Enter a description for identifying this rule.

    10. For Notification Method, select the **Slack** option.

    11. Enter the Slack Alert Username.

        The username must be a valid team member for the Slack channel.

            <Frame>
              <img src="https://mintcdn.com/levelblue-5324744e/xOkkFcWcXtj_Ev_v/images/usm-anywhere/deployment-guide/notifications/slackrulesettings.webp?fit=max&auto=format&n=xOkkFcWcXtj_Ev_v&q=85&s=daf74b444798c2b81e4454c7c79a15bc" width="1604" height="302" data-path="images/usm-anywhere/deployment-guide/notifications/slackrulesettings.webp" />
            </Frame>

    12. In the **Length** text box, specify the timespan that you want to use to identify a match for multiple occurrences. Enter the number in the text box, and then use the drop-down menu to select a value of seconds, minutes, or hours.

        This duration identifies the amount of time that transpires from the beginning to the end of the occurrence. If the number of occurrences is not met within this period, the rule is not a match.

            <Note>
              **Note:** Your defined length and occurrences function together to specify the number of occurrences within a time period that will produce a match for the rule. For example, you can define a rule to trigger an <Tooltip tip="Alarms provide notification of an event or sequence of events that require attention or investigation.">alarm</Tooltip> for an <Tooltip tip="An incident-type categorization that may be a precursor to other actions or stages of an attack.">unauthorized access</Tooltip> attempt when a failed <Tooltip tip="Program to securely log into another computer over a network, execute commands in a remote machine, and move files from one machine to another through Secure Copy (SCP).">SSH</Tooltip> <Tooltip tip="Log in (verb): Process in which an individual gains access to a computer system after providing sufficient credentials to authenticate their unique identity. Login (noun): User credentials, typically a username and matching password.">login</Tooltip> occurs three times within a five-minute window.
            </Note>

    13. Click **Save**.

        The created rule displays in the list of rules. You can see it from **Settings > Rules > Orchestration Rules**. See [Orchestration Rules](../../user-guide/rules-management/orchestration-rules) for more information.

            <Warning>
              **Important:** It takes a few minutes for an orchestration rule to become active.
            </Warning>

    14. For **Notification Method**, select the **PagerDuty** option.

            <Frame>
              <img src="https://mintcdn.com/levelblue-5324744e/xOkkFcWcXtj_Ev_v/images/usm-anywhere/deployment-guide/notifications/pagerduty-rule.webp?fit=max&auto=format&n=xOkkFcWcXtj_Ev_v&q=85&s=e550be9625c31a7bcc7a5359696cc421" width="790" height="221" data-path="images/usm-anywhere/deployment-guide/notifications/pagerduty-rule.webp" />
            </Frame>

    15. At the bottom of the dialog box, set the rule condition parameters to specify the criteria for a matching alarm or event to trigger the rule.

            <Frame>
              <img src="https://mintcdn.com/levelblue-5324744e/ElsAVGG4IM3pFRzT/images/usm-anywhere/alienapps/rules-conditions.webp?fit=max&auto=format&n=ElsAVGG4IM3pFRzT&q=85&s=ed0c95231c90d03bf18126555ab587e4" width="972" height="419" data-path="images/usm-anywhere/alienapps/rules-conditions.webp" />
            </Frame>

        * This section provides suggested property/value pairs from the selected alarm or event that you can use as conditions for the rule. Click the <img src="https://mintcdn.com/levelblue-5324744e/jTImDFBjBH7kNNGB/images/central-any-app/buttons/trash-alt.svg?fit=max&auto=format&n=jTImDFBjBH7kNNGB&q=85&s=7fcb12066bec17b51a7ebd4cad626542" style={{ height: "1em", verticalAlign: "middle", display: "inline-block", margin: "0 0.25em" }} width="24" height="24" data-path="images/central-any-app/buttons/trash-alt.svg" /> icon to delete the items that you do not want to include in the matching conditions. You can also add other conditions that are not suggested.
        * If you create the rule from the Rules page, you must use the Add Condition and Add Group functions to define the property/value pairs that you want to use as conditions for the rule.
        * At the bottom of the dialog box, click **More** to display the optional multiple occurrence and window-length parameters.

            <AccordionGroup>
              <Accordion title="Conditional Expression">
                Select an operator and add one or more conditions to form the conditional expression. You can include a condition group to evaluate a subset of conditions. The Current Rule pane displays the constructed expression in standard syntax. The box displays a red border if the expression is syntactically invalid as currently specified. A valid expression is required to save the rule definition.

                Select the operator used to determine the match for multiple conditions:

                * **AND**: Match all conditions.
                * **OR**: Match any one condition.
                * **AND NOT**: Exclude items matching all conditions after the first.
                * **OR NOT**: Include all items that do not match any conditions after the first.

                Click **Add Condition** to add a condition. For each condition, specify the field name, evaluator, and value. If the evaluation returns true for the condition, it is a match.

                Click **Add Group** to add a condition group. A new group includes a condition and its own operator used to match the conditions within the group. You can nest condition groups.
              </Accordion>

              <Accordion title="Occurrences">
                Specify the number of event or alarm occurrences that produce a match on the conditional expression to trigger the rule. The default value is 1. You can enter the number of occurrences or use the arrow to scroll the value up or down.

                USM Anywhere uses this in conjunction with the Length option to specify the number of occurrences within a time period that will trigger the rule. For example, you can define a rule to trigger for an unauthorized access attempt when a failed <Tooltip tip="Program to securely log into another computer over a network, execute commands in a remote machine, and move files from one machine to another through Secure Copy (SCP).">SSH</Tooltip> login occurs three times within a five-minute window.
              </Accordion>

              <Accordion title="Length">
                Specify the length of the window to identify a match for multiple occurrences. Enter the number and choose a time unit value of seconds, minutes, or hours. This time period identifies the amount of time that transpires from the first occurrence to the last occurrence. If the number of occurrences is not met within this period, the rule does not trigger.
              </Accordion>
            </AccordionGroup>

        7. Click **Save Rule**.
  </Accordion>

  <Accordion title="Review USM Anywhere Notifications in PagerDuty">
    PagerDuty creates incidents for the service from the notifications that USM Anywhere sends. You can review and respond to these incidents from your PagerDuty incidents dashboard. When you expand the details for the incident, in the Client area, click the link to open the event or alarm in USM Anywhere.

    <Frame>
      <img src="https://mintcdn.com/levelblue-5324744e/xOkkFcWcXtj_Ev_v/images/usm-anywhere/deployment-guide/notifications/pagerduty-incident.webp?fit=max&auto=format&n=xOkkFcWcXtj_Ev_v&q=85&s=397506dfc37c281eb6156e78f4daa2d9" width="964" height="639" data-path="images/usm-anywhere/deployment-guide/notifications/pagerduty-incident.webp" />
    </Frame>
  </Accordion>
</AccordionGroup>
