# Datadog — Pipedream Connect

> Cloud monitoring as a service

- API slug: `datadog` (use in MCP headers and tool keys)
- Auth: API key (Pipedream-managed)
- Categories: Developer Tools
- Website: https://datadog.com
- This page (HTML): https://pipedream.com/apps/datadog
- Tools: 13 actions · 1 trigger

## Connect via MCP (recommended)

- Endpoint: `https://remote.mcp.pipedream.net/v3`
- Headers: `Authorization: Bearer <token>` · `x-pd-project-id` · `x-pd-environment` · `x-pd-external-user-id` · `x-pd-app-slug: datadog`

```ts
import { Client } from "@modelcontextprotocol/sdk/client/index.js"
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js"
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const accessToken = await pd.rawAccessToken

const transport = new StreamableHTTPClientTransport(
  new URL("https://remote.mcp.pipedream.net/v3"),
  {
    requestInit: {
      headers: {
        Authorization: `Bearer ${accessToken}`,
        "x-pd-project-id": process.env.PIPEDREAM_PROJECT_ID!,
        "x-pd-environment": "production",
        "x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
        "x-pd-app-slug": "datadog",
      },
    },
  },
)

const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)

const { tools } = await mcp.listTools()

// e.g. run Get Account Info:
const result = await mcp.callTool({
  name: "datadog-get-account-info",
  arguments: {},
})
```

Docs: [MCP guide](https://pipedream.com/docs/connect/mcp/developers.md)

## API proxy

For a Datadog endpoint with no pre-built tool, the proxy forwards your request with the connected user's credentials attached.

```bash
# The path segment is the target URL, URL-safe base64 encoded:
# https://api.example.com/v1/me

curl "https://api.pipedream.com/v1/connect/{project_id}/proxy/aHR0cHM6Ly9hcGkuZXhhbXBsZS5jb20vdjEvbWU?external_user_id={external_user_id}&account_id=apn_xxxxxxx" \
  -H "Authorization: Bearer {access_token}" \
  -H "x-pd-environment: production"
```

Docs: [API proxy guide](https://pipedream.com/docs/connect/api-proxy.md)

## SDK

```ts
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "datadog-get-account-info",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    datadog: { authProvisionId: "apn_xxxxxxx" },
  },
})
```

Docs: [Managed auth guide](https://pipedream.com/docs/connect/managed-auth/quickstart.md) · [Tools guide](https://pipedream.com/docs/connect/components.md)

## Actions (13)

### `datadog-get-account-info` — Get Account Info (Read-only)

Detect the Datadog region for the connected account. Call this FIRST before any other Datadog tool if you do not already know the region. Returns the region domain (e.g. datadoghq.com) which must be passed as the region parameter to Search Logs, Search Monitors, Get Metric Data, and all other…

Full schema: https://pipedream.com/apps/datadog/actions/get-account-info.md

### `datadog-get-account-region` — Get Account Region (Read-only)

Detect the Datadog region for the connected account by validating the API key against each regional endpoint. Use this to discover the correct region before calling other Datadog actions. See the docs

Full schema: https://pipedream.com/apps/datadog/actions/get-account-region.md

### `datadog-get-metric-data` — Get Metric Data (Read-only)

Query time-series metric data for analyzing trends and system performance. Query syntax: avg:system.cpu.user{*}, sum:requests.count{env:prod} by {host}, max:system.mem.used{service:web}. Both from and to are POSIX timestamps in seconds. Use Search Metrics first to discover available metric names…

Full schema: https://pipedream.com/apps/datadog/actions/get-metric-data.md

### `datadog-list-logs` — List Logs (Read-only)

Get a list of logs matching a filter query. Uses the GET endpoint with a higher rate limit (3600/hr vs 300/hr). See the docs

Full schema: https://pipedream.com/apps/datadog/actions/list-logs.md

### `datadog-post-metric-data` — Post Metric Data (Write)

Post custom time-series metric data points to Datadog. Data appears in dashboards, monitors, and can be queried via Get Metric Data. Points: JSON object where keys are Unix timestamps (seconds) and values are numeric, e.g. {"1640995200": 1.0}. Use Search Metrics to verify a metric name exists, or…

Full schema: https://pipedream.com/apps/datadog/actions/post-metric-data.md

### `datadog-search-dashboards` — Search Dashboards (Read-only)

List and search Datadog dashboards. Returns dashboard IDs, titles, URLs, and metadata. Dashboard URL: https://app.{region}/dashboard/{id} where region comes from Get Account Info. Use alongside Search Services to find dashboards related to a specific service. See the docs

Full schema: https://pipedream.com/apps/datadog/actions/search-dashboards.md

### `datadog-search-events` — Search Events (Read-only)

Search Datadog events: monitor state changes, deployment markers, error spikes, and infrastructure events. Filter by sources (e.g. nagios,docker), tags (e.g. env:prod,service:web), and priority (normal or low). Time range defaults to last 24h (POSIX timestamps in seconds). To investigate a monitor…

Full schema: https://pipedream.com/apps/datadog/actions/search-events.md

### `datadog-search-hosts` — Search Hosts (Read-only)

Search monitored infrastructure hosts. Filter by tag (env:production), name (host:web-01), or partial match. Sort by cpu, iowait, load, status, or apps. Host names from results can scope queries in Get Metric Data (e.g. avg:system.cpu.user{host:web-01}), filter logs in Search Logs (host:web-01), or…

Full schema: https://pipedream.com/apps/datadog/actions/search-hosts.md

### `datadog-search-incidents` — Search Incidents (Read-only)

Search Datadog incidents by state, severity, and metadata. Query syntax: state:active, state:resolved, severity:SEV-1. After finding an incident, investigate with: Search Logs for the incident time window, Get Metric Data for relevant metrics, Search Events for related monitor alerts, and Search…

Full schema: https://pipedream.com/apps/datadog/actions/search-incidents.md

### `datadog-search-logs` — Search Logs (Read-only)

Search Datadog logs matching a query with support for facets and time ranges. Uses log search syntax: service:web-app status:error, @http.status_code:>=400, boolean operators (AND, OR, NOT), and wildcards. Set from to now-1h for recent logs. Use Search Metrics to discover metric names or Search…

Full schema: https://pipedream.com/apps/datadog/actions/search-logs.md

### `datadog-search-metrics` — Search Metrics (Read-only)

Discovery tool: list available Datadog metric names, optionally filtered by host. Returns metric name strings (e.g. system.cpu.user, aws.ec2.cpuutilization) for use in Get Metric Data queries with the syntax aggregation:metric.name{tags}. Use Search Hosts to find valid host names for the host…

Full schema: https://pipedream.com/apps/datadog/actions/search-metrics.md

### `datadog-search-monitors` — Search Monitors (Read-only)

Search Datadog monitors (alerting rules) including status, thresholds, and conditions. Query syntax: tag:env:production, type:metric, status:Alert. Tags filter: comma-separated (e.g. env:prod,team:backend). After finding a monitor, use Search Events to see recent state changes, or Get Metric Data…

Full schema: https://pipedream.com/apps/datadog/actions/search-monitors.md

### `datadog-search-services` — Search Services (Read-only)

List services from Datadog's Service Catalog with ownership, metadata, and team info. Use to discover service names for filtering in Search Logs (service:my-app) or finding monitors via Search Monitors (tag:service:my-app). Returns service definitions including links, docs, and on-call. See the docs

Full schema: https://pipedream.com/apps/datadog/actions/search-services.md

## Triggers (1)

### `datadog-new-monitor-event` — New Monitor Event (Instant) (Instant)

Emit new events captured by a Datadog monitor

Full schema: https://pipedream.com/apps/datadog/triggers/new-monitor-event.md

---

- All apps: https://pipedream.com/apps — index: https://pipedream.com/llms.txt
- Pipedream docs for agents: https://pipedream.com/docs/llms.txt
