1. Conduid
  2. AI
  3. datadog-server
MCP server · AI

datadog-server

MCP Server for Datadog API (Audited fork of GeLi2001/datadog-mcp-server)

Unclaimed ai
39Low

Scored 7 days ago · breakdown

About datadog-server

datadog-server is an MCP server published by git+braxtonbooth in the AI category: mCP Server for Datadog API (Audited fork of GeLi2001/datadog-mcp-server).

Install

Install
npx @braxtonbooth/datadog-mcp-server
Claude Code
claude mcp add datadog-mcp-server-gitbraxt -- npx -y @braxtonbooth/datadog-mcp-server
npx
npx -y @braxtonbooth/datadog-mcp-server

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Tools (13)

aggregate-logsPerform analytical queries and aggregations on log data. Essential for calculating metrics (count, avg, sum, etc.), grouping data by fields, and creating statistical summaries from logs. Use this when you need to analyze patterns or extract metrics from log data.

Parameters not published.

aggregate-spansPerform analytical queries and aggregations on APM span data. Calculate metrics (count, avg, p50, p99, etc.), group by dimensions (service, resource, etc.), and create statistical summaries from traces. Use this for performance analysis, latency percentiles, and error rate calculations. Rate limited to 300 requests/hour.

Parameters not published.

get-dashboardGet the complete definition of a specific Datadog dashboard by its ID. Returns all widgets, layout, and configuration details.

Parameters not published.

get-dashboardsRetrieve a list of all dashboards from Datadog. Useful for discovering available dashboards and their IDs for further exploration.

Parameters not published.

get-eventsSearch for events in Datadog within a specified time range. Events include deployments, alerts, comments, and other activities. Useful for correlating system behaviors with specific events.

Parameters not published.

get-incidentsList incidents from Datadog

Parameters not published.

get-metric-metadataRetrieve detailed metadata about a specific metric, including its type, description, unit, and other attributes. Use this to understand a metric

Parameters not published.

get-metricsList available metrics from Datadog. Optionally use the q parameter to search for specific metrics matching a pattern. Helpful for discovering metrics to use in monitors or dashboards.

Parameters not published.

get-monitorGet detailed information about a specific Datadog monitor by its ID. Use this to retrieve the complete configuration, status, and other details of a single monitor.

Parameters not published.

get-monitorsFetch monitors from Datadog with optional filtering. Use groupStates to filter by monitor status (e.g.,

Parameters not published.

Show all 13 tools
get-traceRetrieve all spans for a specific trace ID. A trace represents the complete journey of a request through your distributed system. This tool fetches all spans (operations) that belong to the trace, sorted chronologically. Useful for debugging specific requests or understanding the full execution path. Rate limited to 300 requests/hour.

Parameters not published.

search-logsSearch logs in Datadog with advanced filtering options. Use filter.query for search terms (e.g.,

Parameters not published.

search-spansSearch APM spans in Datadog with filtering options. Use filter.query for search terms (e.g.,

Parameters not published.

Ask AI

✦

Ask AI about datadog-server

Powered by Claude · Grounded in docs

I know everything about datadog-server. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

  • ✓README presentThe repository ships documentation.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

4 checks have not been run yet.

README

Datadog MCP Server

Note: This is an audited fork of GeLi2001/datadog-mcp-server maintained by @braxtonbooth. Security reviewed and monitored via Dependabot.

A Model Context Protocol (MCP) server for interacting with the Datadog API.

Features

  • Monitoring: Access monitor data and configurations
  • Dashboards: Retrieve and view dashboard definitions
  • Metrics: Query available metrics and their metadata
  • Events: Search and retrieve events within timeframes
  • Logs: Search logs with advanced filtering and sorting options
  • Incidents: Access incident management data
  • APM (Traces & Spans): Search spans, aggregate span data, and retrieve complete traces
  • API Integration: Direct integration with Datadog's v1 and v2 APIs
  • Comprehensive Error Handling: Clear error messages for API and authentication issues
  • Service-Specific Endpoints: Support for different endpoints for logs and metrics

Prerequisites

  1. Node.js (version 16 or higher)
  2. Datadog account with:
    • API key - Found in Organization Settings > API Keys
    • Application key - Found in Organization Settings > Application Keys

Application Key Scopes

For improved security, you can scope your Application Key to grant only the minimum permissions required by this MCP server. By default, Application Keys inherit all permissions from the user who created them, but scoped Application Keys allow you to follow the principle of least privilege.

Required Scopes

The following scopes are required for the corresponding features:

Tool(s) Required Scope Description
get-monitors, get-monitor monitors_read Read access to monitor configurations and states
get-dashboards, get-dashboard dashboards_read Read access to dashboard definitions
get-metrics, get-metric-metadata metrics_read Read access to metrics list and metadata
get-events events_read Read access to events from the event stream
search-logs, aggregate-logs logs_read_data Read access to log data for search and aggregation
get-incidents incident_read Read access to incident management data
search-spans, aggregate-spans, get-trace apm_read Read access to APM traces and spans data

Creating a Scoped Application Key

  1. Go to Organization Settings > Application Keys
  2. Click New Key
  3. Enter a name (e.g., "MCP Server - Read Only")
  4. Under Scopes, select only the permissions you need:
    • For full functionality: monitors_read, dashboards_read, metrics_read, events_read, logs_read_data, incident_read, apm_read
    • For logs only: logs_read_data
    • For monitoring only: monitors_read, dashboards_read, metrics_read
    • For APM only: apm_read
  5. Click Create Key

Note: If you don't specify any scopes when creating an Application Key, it will have full access with all permissions of the creating user. For production use, we recommend always specifying explicit scopes.

Installation

Via npm (recommended)

npm install -g datadog-mcp-server

From Source

  1. Clone this repository
  2. Install dependencies:
    npm install
    
  3. Build the project:
    npm run build
    

Configuration

You can configure the Datadog MCP server using either environment variables or command-line arguments.

Environment Variables

Create a .env file with your Datadog credentials:

DD_API_KEY=your_api_key_here
DD_APP_KEY=your_app_key_here
DD_SITE=datadoghq.com
DD_LOGS_SITE=datadoghq.com
DD_METRICS_SITE=datadoghq.com

Note: DD_LOGS_SITE and DD_METRICS_SITE are optional and will default to the value of DD_SITE if not specified.

Command-line Arguments

Basic usage with global site setting:

datadog-mcp-server --apiKey=your_api_key --appKey=your_app_key --site=datadoghq.eu

Advanced usage with service-specific endpoints:

datadog-mcp-server --apiKey=your_api_key --appKey=your_app_key --site=datadoghq.com --logsSite=logs.datadoghq.com --metricsSite=metrics.datadoghq.com

Note: Site arguments don't need https:// - it will be added automatically.

Regional Endpoints

Different Datadog regions have different endpoints:

  • US (Default): datadoghq.com
  • EU: datadoghq.eu
  • US3 (GovCloud): ddog-gov.com
  • US5: us5.datadoghq.com
  • AP1: ap1.datadoghq.com

Usage with Claude Desktop

Add this to your claude_desktop_config.json:

{
  "mcpServers": {
    "datadog": {
      "command": "npx",
      "args": [
        "datadog-mcp-server",
        "--apiKey",
        "<YOUR_API_KEY>",
        "--appKey",
        "<YOUR_APP_KEY>",
        "--site",
        "<YOUR_DD_SITE>(e.g us5.datadoghq.com)"
      ]
    }
  }
}

For more advanced configurations with separate endpoints for logs and metrics:

{
  "mcpServers": {
    "datadog": {
      "command": "npx",
      "args": [
        "datadog-mcp-server",
        "--apiKey",
        "<YOUR_API_KEY>",
        "--appKey",
        "<YOUR_APP_KEY>",
        "--site",
        "<YOUR_DD_SITE>",
        "--logsSite",
        "<YOUR_LOGS_SITE>",
        "--metricsSite",
        "<YOUR_METRICS_SITE>"
      ]
    }
  }
}

Locations for the Claude Desktop config file:

  • MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%/Claude/claude_desktop_config.json

Usage with MCP Inspector

To use with the MCP Inspector tool:

npx @modelcontextprotocol/inspector datadog-mcp-server --apiKey=your_api_key --appKey=your_app_key

Available Tools

The server provides these MCP tools:

Monitoring & Observability

  • get-monitors: Fetch monitors with optional filtering
  • get-monitor: Get details of a specific monitor by ID
  • get-dashboards: List all dashboards
  • get-dashboard: Get a specific dashboard by ID
  • get-metrics: List available metrics
  • get-metric-metadata: Get metadata for a specific metric
  • get-events: Fetch events within a time range
  • get-incidents: List incidents with optional filtering

Logs

  • search-logs: Search logs with advanced query filtering
  • aggregate-logs: Perform analytics and aggregations on log data

APM (Application Performance Monitoring)

  • search-spans: Search APM spans with filtering by service, operation, time range, etc.
  • aggregate-spans: Aggregate span data for performance analysis (latency percentiles, error rates, etc.)
  • get-trace: Retrieve all spans for a specific trace ID to see the complete request journey

Examples

Example: Get Monitors

{
  "method": "tools/call",
  "params": {
    "name": "get-monitors",
    "arguments": {
      "groupStates": ["alert", "warn"],
      "limit": 5
    }
  }
}

Example: Get a Dashboard

{
  "method": "tools/call",
  "params": {
    "name": "get-dashboard",
    "arguments": {
      "dashboardId": "abc-def-123"
    }
  }
}

Example: Search Logs

{
  "method": "tools/call",
  "params": {
    "name": "search-logs",
    "arguments": {
      "filter": {
        "query": "service:web-app status:error",
        "from": "now-15m",
        "to": "now"
      },
      "sort": "-timestamp",
      "limit": 20
    }
  }
}

Example: Aggregate Logs

{
  "method": "tools/call",
  "params": {
    "name": "aggregate-logs",
    "arguments": {
      "filter": {
        "query": "service:web-app",
        "from": "now-1h",
        "to": "now"
      },
      "compute": [
        {
          "aggregation": "count"
        }
      ],
      "groupBy": [
        {
          "facet": "status",
          "limit": 10,
          "sort": {
            "aggregation": "count",
            "order": "desc"
          }
        }
      ]
    }
  }
}

Example: Get Incidents

{
  "method": "tools/call",
  "params": {
    "name": "get-incidents",
    "arguments": {
      "includeArchived": false,
      "query": "state:active",
      "pageSize": 10
    }
  }
}

Example: Search Spans

{
  "method": "tools/call",
  "params": {
    "name": "search-spans",
    "arguments": {
      "filter": {
        "query": "service:web-app operation_name:http.request",
        "from": "now-1h",
        "to": "now"
      },
      "sort": "timestamp",
      "limit": 100
    }
  }
}

Example: Aggregate Spans

{
  "method": "tools/call",
  "params": {
    "name": "aggregate-spans",
    "arguments": {
      "filter": {
        "query": "service:web-app",
        "from": "now-1h",
        "to": "now"
      },
      "compute": [
        {
          "aggregation": "pc99",
          "metric": "duration",
          "type": "total"
        }
      ],
      "groupBy": [
        {
          "facet": "resource_name",
          "limit": 10,
          "sort": {
            "aggregation": "pc99",
            "order": "desc",
            "type": "measure"
          }
        }
      ]
    }
  }
}

Example: Get Trace

{
  "method": "tools/call",
  "params": {
    "name": "get-trace",
    "arguments": {
      "traceId": "1234567890abcdef",
      "limit": 1000
    }
  }
}

Troubleshooting

If you encounter a 403 Forbidden error, verify that:

  1. Your API key and Application key are correct
  2. The keys have the necessary permissions to access the requested resources
  3. Your account has access to the requested data
  4. You're using the correct endpoint for your region (e.g., datadoghq.eu for EU customers)

Debugging

If you encounter issues, check Claude Desktop's MCP logs:

# On macOS
tail -n 20 -f ~/Library/Logs/Claude/mcp*.log

# On Windows
Get-Content -Path "$env:APPDATA\Claude\Logs\mcp*.log" -Tail 20 -Wait

Common issues:

  • 403 Forbidden: Authentication issue with Datadog API keys
  • API key or App key format invalid: Ensure you're using the full key strings
  • Site configuration errors: Make sure you're using the correct Datadog domain
  • Endpoint mismatches: Verify that service-specific endpoints are correctly set if you're using separate domains for logs and metrics

License

MIT

README copy captured when this server was indexed; it may lag the repository. The original is authoritative.

Questions

About datadog-server

How do I install datadog-server?

Run npx @braxtonbooth/datadog-mcp-server, then add the server to your MCP client's configuration.

Is datadog-server safe to use with an AI agent?

Its trust score is 39 out of 100 (low). It passes 1 of the 2 static security checks run so far; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is datadog-server still maintained?

Conduid hasn't recorded a commit date for this repository yet. Check the repository directly for recent activity.