Datadog Logs MCP Server
Enables searching and retrieving logs from Datadog with customizable queries, time ranges, and result limits through the Datadog Logs API.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Datadog Logs MCP Serversearch logs from the last hour for errors in production"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Datadog Logs MCP Server
An MCP (Model Context Protocol) server for searching Datadog logs via HTTP.
Features
Search Datadog logs with customizable queries
Specify time ranges for log searches
Control result limits
Runs as an HTTP server on port 5000
Related MCP server: Datadog MCP Server
Prerequisites
Docker and Docker Compose
Datadog API Key
Datadog Application Key
Setup
Copy the example environment file and add your Datadog credentials:
cp .env.example .envEdit
.envand add your actual Datadog keys:
DD_API_KEY=your_actual_api_key
DD_APPLICATION_KEY=your_actual_application_key
PORT=4000Running with Docker Compose
Start the server:
docker-compose upThe server will be available at http://localhost:5000
To run in detached mode:
docker-compose up -dTo stop the server:
docker-compose downAPI Endpoints
SSE Connection
GET
/sse- Establish SSE connection for MCP communication
Message Endpoint
POST
/messages- Send MCP protocol messages
MCP Tool: search_logs
Search Datadog logs with the following parameters:
query(required): Log search query (e.g., "env:prd AND service:pms-connectors")from(required): Start time (e.g., "now-10m", "2024-01-01T00:00:00Z")to(required): End time (e.g., "now", "2024-01-01T01:00:00Z")limit(optional): Maximum number of logs to return (default: 10)
Example Usage
The server will search Datadog logs using the API endpoint:
POST https://api.datadoghq.com/api/v2/logs/events/searchWith the query parameters provided through the MCP tool invocation.
Development
To build locally without Docker:
npm install
npm run build
npm startEnvironment Variables
DD_API_KEY: Your Datadog API key (required)DD_APPLICATION_KEY: Your Datadog application key (required)PORT: Server port (default: 5000)
Available Tools
3 toolssearch_clickhouseC
Query Clickhouse database (currently unimplemented)
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | SQL query to execute | |
| database | No | Database name (optional) | |
| format | No | Output format (e.g., 'JSON', 'TabSeparated') | JSON |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It only mentions that the tool is 'currently unimplemented', which is confusing but doesn't describe actual behavior like error handling, performance characteristics, or what happens when queries are executed. No useful behavioral context is provided.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
While brief, the description is poorly structured and confusing. The 'currently unimplemented' note undermines the tool's purpose without explanation, making it inefficient. It fails to front-load useful information about what the tool actually does.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a database query tool with 3 parameters and no annotations or output schema, the description is incomplete. It doesn't explain what the tool returns, how results are formatted, or any limitations. The 'unimplemented' note creates ambiguity rather than providing necessary context.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already documents all three parameters thoroughly. The description adds no additional meaning about parameters beyond what's in the schema, maintaining the baseline score of 3.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states the tool's purpose as 'Query Clickhouse database', which is clear but vague. It doesn't specify what kind of queries are supported or what resources are accessed. The 'currently unimplemented' note adds confusion rather than clarifying the actual functionality.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus the sibling tools (search_cloudbeds_pms, search_logs). The description doesn't mention any prerequisites, alternatives, or specific contexts where this tool would be appropriate.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_cloudbeds_pmsC
Search Cloudbeds PMS API for reservations with rate details
| Name | Required | Description | Default |
|---|---|---|---|
| hotelId | Yes | Hotel ID to query (must be configured in HOTEL_REFRESH_TOKENS map) | |
| queryParams | No | Query parameters for the API request (e.g., reservationCheckOutFrom, reservationCheckOutTo, resultsFrom, resultsTo) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. While 'Search' implies a read operation, the description doesn't mention authentication requirements, rate limits, pagination behavior, error handling, or what 'rate details' specifically includes. For a search tool with zero annotation coverage, this leaves significant behavioral questions unanswered.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that communicates the core purpose without unnecessary words. It's appropriately sized for a search tool and front-loads the essential information - every word earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity of searching a PMS API with rate details, no annotations, no output schema, and nested query parameters, the description is insufficient. It doesn't explain what 'rate details' includes, how results are structured, whether there are limitations on date ranges or result sizes, or how to interpret the search results. The description should provide more context for effective tool use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema description coverage is 100%, so the schema already documents both parameters thoroughly. The description adds no additional parameter semantics beyond what's in the schema - it doesn't explain the format of hotelId values, provide examples of queryParams, or clarify the relationship between parameters. This meets the baseline for high schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Search') and target resource ('Cloudbeds PMS API for reservations with rate details'), providing a specific verb+resource combination. However, it doesn't differentiate from sibling tools like 'search_clickhouse' or 'search_logs' - all three appear to be search operations but for different data sources.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus the sibling tools 'search_clickhouse' or 'search_logs'. There's no mention of use cases, prerequisites, or alternatives - it simply states what the tool does without context about when it's appropriate.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_logsC
Search Datadog logs with a query and time range
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Log search query (e.g., 'env:prd AND service:pms-connectors') | |
| from | Yes | Start time for log search (e.g., 'now-10m', '2024-01-01T00:00:00Z') | |
| to | Yes | End time for log search (e.g., 'now', '2024-01-01T01:00:00Z') | |
| limit | No | Maximum number of logs to return (default: 10) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool searches logs but lacks details on permissions, rate limits, pagination, or response format. For a search tool with no annotations, this is a significant gap in transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that front-loads the core purpose without unnecessary words. Every part earns its place, making it highly concise and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no annotations and no output schema, the description is incomplete. It covers the basic action but lacks critical context like behavioral traits, return values, or usage guidelines. For a tool with 4 parameters and no structured support, this is inadequate.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with all parameters well-documented in the input schema. The description adds minimal value beyond the schema by mentioning 'query and time range', which aligns with the parameters but doesn't provide additional semantics. Baseline 3 is appropriate as the schema does the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Search') and resource ('Datadog logs'), specifying the scope with 'with a query and time range'. It distinguishes from sibling tools like 'search_clickhouse' and 'search_cloudbeds_pms' by explicitly mentioning Datadog, though it doesn't explicitly contrast them. This is clear but lacks explicit sibling differentiation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives like the sibling tools. It mentions the tool's purpose but offers no context, exclusions, or prerequisites for usage, leaving the agent without direction on tool selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
Each tool has a clearly distinct purpose targeting different data sources: Clickhouse database queries, Cloudbeds PMS API for reservations, and Datadog logs search. There is no overlap in functionality or ambiguity about which tool to use for each specific task.
All three tools follow a consistent verb_noun pattern with 'search_' prefix followed by the target resource (clickhouse, cloudbeds_pms, logs). The naming is perfectly uniform and predictable across the entire tool set.
With only 3 tools, the server feels somewhat thin for a 'Datadog Logs MCP Server' that also includes non-Datadog tools. While the tools are well-defined, the scope appears broader than just logs, and the count may be insufficient for comprehensive coverage of the implied domains.
For a server named 'Datadog Logs', having only one Datadog-specific tool (search_logs) with two unrelated tools creates significant gaps. The Clickhouse tool is unimplemented, and the Cloudbeds tool seems out of scope, leaving the core Datadog functionality incomplete and fragmented.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Open-source agent that observes and fixes your application. Query logs, traces, metrics, incidents.
Read-only access to Auralogs production logs: search logs, inspect errors, review AI analyses.
Query application logs, traces, and metrics from your AI coding assistant via Foam's MCP server.
Query any public logr profile — timelines, events, full context — plus owner-authorized writes.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables querying log data stored in SQLite databases through the Model Context Protocol, allowing natural language interactions with log analysis.
- AlicenseCqualityDmaintenanceEnables interaction with Datadog's monitoring platform to search logs, search trace spans, and perform trace span aggregation for analysis.31,106MIT
- AlicenseNot gradedqualityDmaintenanceEnables integration with Datadog APIs to monitor and retrieve information about monitors, metrics, dashboards, logs, events, and incidents through the Model Context Protocol.3,024MIT
- AlicenseNot gradedqualityDmaintenanceEnables querying and formatting Loki logs from Grafana via the Model Context Protocol. It supports LogQL queries, label retrieval, and provides results in text, JSON, or markdown formats.29MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/rezo8/columbo'
If you have feedback or need assistance with the MCP directory API, please join our Discord server