A Model Context Protocol (MCP) server for interacting with the Datadog API.
npm install -g datadog-mcp-server
npm install
npm run build
You can configure the Datadog MCP server using either environment variables or command-line arguments.
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
datadog-mcp-server --apiKey=your_api_key --appKey=your_app_key --site=datadoghq.eu
Note: The site argument doesn't need https://
- it will be added automatically.
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)"
]
}
}
}
Locations for the Claude Desktop config file:
~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%/Claude/claude_desktop_config.json
To use with the MCP Inspector tool:
npx @modelcontextprotocol/inspector datadog-mcp-server --apiKey=your_api_key --appKey=your_app_key
The server provides these MCP tools:
{
"method": "tools/call",
"params": {
"name": "get-monitors",
"arguments": {
"groupStates": ["alert", "warn"],
"limit": 5
}
}
}
{
"method": "tools/call",
"params": {
"name": "get-dashboard",
"arguments": {
"dashboardId": "abc-def-123"
}
}
}
{
"method": "tools/call",
"params": {
"name": "search-logs",
"arguments": {
"filter": {
"query": "service:web-app status:error",
"from": "now-15m",
"to": "now"
},
"sort": "-timestamp",
"limit": 20
}
}
}
{
"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"
}
}
]
}
}
}
{
"method": "tools/call",
"params": {
"name": "get-incidents",
"arguments": {
"includeArchived": false,
"query": "state:active",
"pageSize": 10
}
}
}
If you encounter a 403 Forbidden error, verify that:
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:
MIT
{
"mcpServers": {
"datadog": {
"args": [
"datadog-mcp-server",
"--apiKey",
"<YOUR_API_KEY>",
"--appKey",
"<YOUR_APP_KEY>",
"--site",
"<YOUR_DD_SITE>(e.g us5.datadoghq.com)"
],
"command": "npx"
}
}
}
Seamless access to top MCP servers powering the future of AI integration.