No results for ""
EXPAND ALL
  • Home
  • API docs

GIVE DOCS FEEDBACK

Using the Datadog events integration

Read time: 4 minutes
Last edited: May 03, 2024
The Datadog events integration is a Pro and Enterprise feature

The Datadog events integration is available to customers on a Pro or Enterprise plan. To learn more, read about our pricing. To upgrade your plan, contact Sales.

Overview

This topic explains how to configure and use the LaunchDarkly Datadog events integration.

The Datadog integration lets you set up Datadog Events to receive any activity from LaunchDarkly. When something changes, such as a feature flag updates or a new account member is added to LaunchDarkly, LaunchDarkly sends an event to Datadog. Use this integration to correlate and understand how changes to your features in LaunchDarkly impact your app and infrastructure metrics.

Prerequisites

To connect Datadog to LaunchDarkly, you need an API Key from Datadog.

To generate an API Key:

  1. In Datadog, visit the API keys page.

  2. Click New Key. The "New API Key" modal appears. in the "API Keys" section.

  3. Give your API Key a human-readable name and click Create Key.

The Datadog "New API Key" modal configured with a sample name.
The Datadog "New API Key" modal configured with a sample name.
  1. Click Copy Key to copy the API Key to your clipboard. You will need it to set up the Datadog integration in LaunchDarkly.

Set up the Datadog integration

After you create an API Key in Datadog, you can set up the integration in LaunchDarkly.

To set up the Datadog integration:

  1. Navigate to the Integrations page and find "Datadog."
  2. Click Add integration. The "Create Datadog configuration" panel appears.
  3. (Optional) Give your integration a human-readable Name.
  4. Enter the Datadog API Key into the Datadog API key field. You created this API Key in the Prerequisites section.
  5. (Optional) Select your Datadog host URL. Contact Support for assistance if you have a private Datadog instance.
  6. (Optional) Check the Hide member details checkbox to exclude member names and emails from the events you send to Datadog.
Member details will not be surfaced

When Hide member details is checked, member-specific events will not be sent to Datadog.

  1. (Optional) Configure a custom policy to control which events LaunchDarkly sends to Datadog. To learn more, read Filter the events you send to Datadog.
  2. After reading the Integration Terms and Conditions, check the I have read and agree to the Integration Terms and Conditions checkbox.
  3. Click Save configuration.

The new integration appears on the Integrations page. It is switched On by default. Events from LaunchDarkly now appear in your Datadog dashboard.

Events may not appear immediately

It may take time for changes made in LaunchDarkly to propagate and appear in the Datadog events dashboard depending on Datadog's polling intervals.

To learn how to confirm that you are using the correct Datadog API key, read the related article in the LaunchDarkly Customer Knowledge Base.

Filter the events you send to Datadog

By default, LaunchDarkly sends events to Datadog for changes made to any project, environment, feature flag, and more. If you have a more limited use case for using the integration, or you wish to restrict which data you send to Datadog, you can filter which events LaunchDarkly sends.

To filter events, write a policy using the same syntax as our custom roles feature to filter the events sent to Datadog.

For more information about writing policies, read Policies in custom roles.

For example, if you only want to receive an event when a change is made to one of the feature flags in your testing environment, you can add the following policy to your events stream:

[
{
"effect": "allow",
"actions": ["*"],
"resources": ["proj/*:env/your-test-environment:flag/*"]
}
]

To add a custom filter:

  1. Navigate to the Integrations page and find the integration you wish to modify.
  2. Click Edit integration configuration. The "Edit Datadog configuration" panel appears.
The configuration overflow menu with the "Edit integration configuration" option called out.
The configuration overflow menu with the "Edit integration configuration" option called out.
  1. Click Advanced editor. The Advanced editor appears.
  2. Enter your custom policy.
The "Edit Datadog configuration" panel with the Advanced editor open and a policy inside it.
The "Edit Datadog configuration" panel with the Advanced editor open and a policy inside it.
  1. Click Save configuration.
  2. Verify that LaunchDarkly is sending a customized set of events by viewing the events in your Datadog dashboard.

Disable the Datadog integration

If you wish to disable the Datadog integration, there are two methods to do so:

  • Disable the integration to pause the flow of events to Datadog, but leaves the connection between Datadog and LaunchDarkly intact.
  • Delete the integration to cease all event export and break the connection between Datadog and LaunchDarkly.

To temporarily disable the Datadog integration:

  1. Navigate to the Integrations page.
  2. Find the Datadog integration you wish to disable.
  3. Click the Edit integration configuration button. The "Edit Datadog configuration" panel appears.
  4. Toggle to turn the integration Off.

To permanently delete the Datadog integration:

  1. Navigate to the Integrations page.
  2. Find the integration you wish to modify and click Edit integration configuration. The "Edit Datadog configuration" panel appears.
  3. Click Delete in the "Delete configuration" section. A confirmation dialog appears.
  4. Click Delete to confirm.