For the complete documentation index, see llms.txt. This page is also available as Markdown.

Add a Datadog connector

Add a Datadog connector so Harness can fetch metrics and logs from Datadog for verification.

Datadog is a cloud-based monitoring and analytics platform that collects metrics, logs, and traces from applications and infrastructure. Add a Datadog connector in Harness to let your pipelines query your Datadog data. Harness can then use that data in Continuous Verification to compare application behavior before and after a deployment, helping you confirm a release is healthy or trigger a rollback.

Go to Overview for information about all monitoring and logging connectors, such as scopes and delegate selection.


What you will learn from this topic


Before you begin

  • Datadog access: A Datadog account with permission to create API keys and application keys.

  • Harness permissions: Permission to create connectors and secrets in Harness.


Add a Datadog connector

You can add a Datadog connector at the project, org, or account scope. This procedure covers the project scope, and the process is the same for org and account.

Perform the following steps to add a Datadog connector:

  1. Open your Harness project.

  2. In Project Settings, select Connectors.

  3. Click New Connector, then select Datadog under Monitoring and Logging Systems. The Datadog connector settings appear.

Overview

Configure the identity fields for the connector:

  1. In Name, enter a name for the connector. Harness generates the Id from the name.

  2. Optionally, add a Description and Tags.

  3. Click Continue.

Datadog connector overview settings

Credentials

Configure the following settings:

  1. In URL, enter the Datadog API URL. To build it, copy the protocol and domain of your Datadog URL, such as https://app.datadoghq.com/, then append api/. The trailing forward slash is mandatory. If your URL ends in v1, remove v1. The URL must match one of the following:

    • https://app.datadoghq.com/api/

    • https://us3.datadoghq.com/api/

    • https://us5.datadoghq.com/api/

    • https://app.datadoghq.eu/api/

    • https://app.ddog-gov.com/api/

  2. In Encrypted Application Key, select or create a Harness encrypted text secret that stores the Datadog application key. Go to API and Application Keys in Datadog documentation to create an application key in Datadog.

  3. In Encrypted API Key, select or create a Harness encrypted text secret that stores the Datadog API key. Go to API and Application Keys in Datadog documentation to create an API key in Datadog.

  4. Click Next.

Datadog connector credentials with the URL, application key, and API key fields

Application key scopes for Continuous Verification

When you create the Datadog application key, ensure it has at least the following scopes:

  • timeseries_query: Fetch metrics data.

  • logs_read_data: Read log data.

  • metrics_read: Read metrics metadata.

  • events_read: Read events.

  • monitors_read: Read monitor configurations.

  • dashboards_read: Read dashboard configurations.

Go to the Datadog Metrics API and Logs API documentation for details on Datadog API scopes.

Delegates Setup

Select one of the following options:

  • Use any available Delegate: Harness selects an available delegate at runtime.

  • Only use Delegates with all of the following tags: Enter the tags of the delegates Harness must use with this connector.

The Test Delegate Connectivity list shows the delegates that match your selection. To add a delegate, click Install new Delegate.

Click Save and Continue.

Datadog connector delegates setup with the delegate connectivity list

Verify Connection

Click Finish after the connection test succeeds. The connector is listed in Connectors page.


Sample YAML

The following example shows a YAML for the Datadog connector created in this topic.

YAML - Datadog connector

For the full connector YAML schema, including how to skip connector preflight checks, go to Create a connector using YAML.


Next steps

Last updated

Was this helpful?