---
title: Datadog
slug: datadog
docTags: 
createdAt: 2023-04-26T09:22:21.000Z
---

# Purpose

Echoes can connect to your Datadog account and monitor your incidents lifecycle in order to produce some metrics such as the [Mean time to recovery](docId\:lGfIZtDECxM2tQ2KurlIp).

# Installation

Datadog integration is done through the [integrations settings](https://app.echoeshq.com/admin/integrations). The installation will guide you into generating an organization’s API key and an Application key.&#x20;

For the Application Key we encourage to create a [Service Account ](https://docs.datadoghq.com/account_management/org_settings/service_accounts/)as [key holder](https://docs.datadoghq.com/account_management/api-app-keys/#transferring-keys).

Make sure to select the appropriate [site](https://docs.datadoghq.com/getting_started/site/#access-the-datadog-site).

::Image[]{alt="Datadog connection" src="https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/iz95S6Q3xXWEYDfkeYgI6_screenshot-2023-04-26-at-112836.png" size="60" width="1240" height="1484" caption="Datadog connection" position="center" showCaption="true"}

Once the connection is made you will be invited to select the Datadog Organization on which to install Echoes

::Image[]{src="https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/D5Y8CN0q4geYH86ypN5Am_screenshot-2023-04-26-at-114249.png" size="60" width="1392" height="614" caption="Datadog organization selection " position="center" showCaption="true"}

Echoes will then install a webhook integration on the selected Datadog organization.

## Required permissions

It is advised to create a custom [role](https://docs.datadoghq.com/account_management/rbac/?tab=datadogapplication#custom-roles) specific to Echoes and associate the role to the user the Application Key has been issued for.

![Echoes custom role](https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/fF6kfz-GgPTYJbBuB1CxM_screenshot-2023-04-28-at-103007.png "Echoes custom role")

The following permissions are required for Echoes to interact with Datadog:

- **Integration Manage**

::Image[****]{src="https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/7CQCtQk93rxXmpUt9aaLI_screenshot-2023-04-28-at-103320.png" size="84" width="2082" height="212" position="center" showCaption="false"}

- **Service Catalog Read**

::Image[****]{src="https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/8yYM6bPTxVPMgjzz8Uw4l_screenshot-2023-04-28-at-103441.png" size="84" width="2094" height="92" position="center" showCaption="false"}

# Setting up your Datadog incident notification rule

The next step is to setup an [incident notification rule](https://docs.datadoghq.com/monitors/incident_management/incident_settings/#rules) in order to send incidents' events to Echoes through the webhook previously set during the installation.

The destination to be selected is `Echoes_webhook`&#x20;

![](https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/faMy_MK_qAsjXVv8dliSq_screenshot-2023-04-26-at-115115.png "Configure the rule")

Configure the events to be sent if `State` is to change or `Echoes TeamID` (Optional).

::Image[]{alt="Webhook triggers" src="https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/UGpKsOmpBXEfdCMRYfG-h_screenshot-2023-04-28-at-102518.png" size="60" width="1052" height="180" caption="Webhook triggers" position="center" showCaption="true"}

## Reference an Echoes team as owner of a Service (Optional)

A service may represent an application, a component, to open incidents against.

In order to associate a Service suffering an incident to a team in Echoes, the property `Echoes TeamID` is to be added to the [incident's property fields ](https://docs.datadoghq.com/monitors/incident_management/incident_settings/#property-fields)as a [custom field](https://docs.datadoghq.com/monitors/incident_management/incident_settings/#custom-property-fields-and-required-fields). This field is not mandatory.

![Add custom field](https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/yxQnk0zgipPL4UdoQHEze_screenshot-2023-04-28-at-101818.png "Add custom field")

It is to be defined as a `Text Area` and a `User Input`

![Custom field attributes](https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/fhiIEq3Z5bRt-W1UUodY0_screenshot-2023-04-28-at-102044.png "Custom field attributes")

The team ID value itself can then be set via the incident attributes on the incident page

::Image[]{alt="Echoes Team ID" src="https://api.archbee.com/api/optimize/cnN9HGi_h1eJLSFAvJkF4/HhfUpQmGZg7zBw9fMZGIz_screenshot-2023-04-28-at-102245.png" size="40" width="680" height="368" caption="Echoes Team ID" position="center" showCaption="true"}

### How to get the correct team ID from Echoes?

The team IDs can be found by using our [Teams API](https://echoeshq.stoplight.io/docs/public-api/y2guczxftfojc-teams).
