Documentation Index
Fetch the complete documentation index at: https://mezmo-9a59581a-mintlify-926f893d.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Mezmo MCP Server (Model Context Protocol)
Mezmo MCP is a remote Model Context Protocol (MCP) server that lets AI assistants and IDE chat agents interact with the Mezmo observability platform via the Model Context Protocol. Use it for streamlined observability, log analysis, and root-cause analysis in your favorite tools. Add Mezmo MCP and you can:- 🕵️ Run advanced Root-cause analysis over recent logs
- 📦 List and describe Pipelines
- 📤 Export and filter Logs with powerful query syntax
Overview
Mezmo MCP is a remote MCP server that connects AI assistants and IDE chat to Mezmo so you can run advanced root-cause analysis, discover pipelines, and export logs without hosting anything yourself. It’s built for observability use cases and works across many popular MCP clients.Available Tools & Examples
1. Log Analysis & Root Cause Detection
analyze_logs_for_root_cause_relative_time
Fetches, processes (deduplicates, clusters), and analyzes logs to determine potential root causes for incidents within a relative time range.
Use cases:
- Investigating recent incidents
- Finding root causes of system failures
- Analyzing error patterns
analyze_logs_for_root_cause_time_range
Similar to the relative time version but uses absolute time ranges.
Example:
“What caused the database connection pool to be exhausted between 10 AM and 11 AM today in the backend app?“
2. Log Deduplication
deduplicate_logs_relative_time
Removes duplicate log entries within a relative time range.
Example:
“Deduplicate the error logs from the payment service in the last 15 minutes”
deduplicate_logs_time_range
Deduplicates logs within an absolute time range.
Example:
“Remove duplicate exception logs from the web frontend between 2 PM and 3 PM yesterday”
3. Log Grouping & Aggregation
group_logs_by_field
Groups logs by a specific field and returns distribution of values with optional metric aggregation.
Use cases:
- “Which apps generate the most errors?”
- “What is the p95 latency per host?”
- “Which pods are producing the most logs?”
4. Log Visualization
get_log_histogram
Returns a time-series histogram of log volume over time.
Use cases:
- Visualizing log activity patterns
- Identifying spikes or anomalies
- Understanding when incidents occurred
5. Field Discovery
list_log_fields
Lists available structured fields that can be used in log queries.
Use cases:
- Discovering available fields for queries
- Finding field names like “app”, “host”, “level”, “namespace”, “pod”, “node”
6. Pipeline Management
list_pipelines
Lists available Mezmo v3 pipelines.
Example:
“Show me all the Mezmo pipelines”
“What pipelines are configured?”
get_pipeline
Gets details for a specific Mezmo v3 pipeline.
Parameters:
pipeline_id(required): UUID of the pipeline
7. Time Utilities
get_current_time
Returns the current server time in various formats.
Example:
“What time is it right now?”
“Get the current timestamp”
Use cases:
- Determining time ranges for log analysis
- Converting between time formats
relative_time_to_time_range
Converts relative time expressions to absolute time ranges in milliseconds.
Examples:
“Convert ‘last 5 minutes’ to an absolute time range”
“What’s the timestamp range for ‘2 hours ago’?“
8. Trace Analysis
find_trace_analysis_component
Finds active OpenTelemetry trace source components across all pipelines. Returns the component_id used by trace analysis tools like get_service_graph, get_spans, find_degraded_service_edges, list_service_latency_summaries, get_service_failure_rates, and get_service_failures.
Use cases:
- Discovering which pipelines have trace analysis available
- Getting the
component_idbefore using other trace analysis tools - Checking which OpenTelemetry trace sources are active in your account
component_id: The ID to pass to other trace analysis toolstitle: The name of the trace source componentpipeline_id: The pipeline containing this componentpipeline_title: The name of the pipeline
9. Correlated Timeline
get_correlated_timeline_relative_time
Builds a correlated timeline of logs across multiple sources within a relative time range. Groups logs by a source field (like app, host, or any custom field) to help with root cause investigation.
Use cases:
- Investigating incidents across multiple services or hosts
- Understanding the sequence of events leading to a failure
- Correlating errors across apps in a distributed system
get_correlated_timeline_time_range
Same as above, but uses absolute time ranges.
Example:
“Build a timeline of all warnings and errors between 10 AM and 11 AM today, grouped by host”
Key options
- Grouping field: Logs are grouped by
_appby default. You can also group by_host,level, or any custom field - Deduplication mode: Use
templatemode (default) to show one example per unique log pattern, ornonefor raw chronological order - Limits: Control how many logs per source and total timeline events to return
Query Syntax
Many MCP tools accept aquery parameter that filters logs. You can combine text search with fielded queries to find specific logs.
Text Search
For basic searches, provide keywords. The query matches any logs containing those terms (case-insensitive, with automatic prefix-matching):timeout matches timeout, timeouts, and timeout_error without needing a wildcard.
Fielded Search
Usefield:value syntax to search specific structured fields:
Common Fields
These fields are available in most log data:| Field | Description |
|---|---|
app | Application or service name |
host | Hostname or server identifier |
level | Log level (error, warn, info, debug) |
env | Environment (production, staging, dev) |
source | Log source identifier |
tag | Tags applied to the log |
namespace | Kubernetes namespace |
pod | Kubernetes pod name |
node | Kubernetes node name |
Nested Fields
For nested or JSON fields, use dotted paths:Numeric Comparisons
Query numeric fields using comparison operators:Field Existence
Usefield:* to match logs where a specific field is present:
The*character is only valid for field existence checks (field:*). Do not use wildcards in query terms or field values (for example,pod:vector-*orhost:prod-*). Prefix-matching is automatic, sopod:vectoralready matchesvector-gen14-abc,vector-prod-01, and similar values.
Combining Queries
Combine multiple conditions to narrow your search:Query Protection for Large Log Volumes
Mezmo MCP protects against queries that would process too much data. This keeps performance fast and ensures queries finish quickly.How It Works
When you run a tool that processes logs, Mezmo MCP checks how many entries match your query:- Confirmation prompt: If your query matches a large number of logs, the server asks you to confirm before proceeding. You can narrow your query or confirm to continue.
- Query rejection: If your query matches an extremely large number of logs, the request is rejected. Try narrowing your time range or adding more specific filters.
Affected Tools
These tools have query protection:analyze_logs_for_root_cause_relative_time/analyze_logs_for_root_cause_time_rangededuplicate_logs_relative_time/deduplicate_logs_time_rangeget_correlated_timeline_relative_time/get_correlated_timeline_time_rangeget_log_histogramgroup_logs_by_field
Tips for Working with Large Datasets
If you see a confirmation prompt or rejection:- Narrow your time range. Try “last 1 hour” instead of “last 24 hours”.
- Add filters. Use fielded search to target specific logs (for example,
app,host,level,namespace, orpod). See Query Syntax for the full list. - Confirm when appropriate. If you’ve reviewed the log count and want to proceed, confirm the prompt.
Retention Window Limits
Queries must fall within your account’s retention window. If you query logs outside this window, you’ll receive an error showing the valid time range. For example, querying logs from 6 months ago on a 7-day retention account will fail.Use relative time ranges likelast 15 minutesorlast 1 hourto ensure your queries stay within retention.
Best Practices
- Start broad for root-cause analysis
- If the query is too narrow, our RCA can’t do its thing. Cast a wide net, and if needed, specify app/service/level in subsequent queries.
- Prefer analyze_logs_for_root_cause or deduplicate_log tools for insights
- These tools deduplicate and groups similar logs for better summaries, allowing the results to fit into finite LLM context windows.
- Use relative time ranges
- Prefer values like
last_15_minutes,last_hourwhen supported. - Keep prompts simple; add filters gradually
- Add filters step by step. See Query Syntax for available fields.
- Use export_logs for raw data only
- For dashboards or offline analysis, use
export_logs; otherwise prefer RCA.
Installation
Requirements
- A Mezmo Service Key (generate one in your Mezmo dashboard under Settings > API Keys; see Mezmo docs for details)
- Node.js ≥ 18 (only needed for clients that use the
mcp-remotebridge) - One of the supported MCP clients below
- Supports remote URL? → configure it with a
urlthat points tohttps://mcp.mezmo.com/mcpand include theAuthorizationheader. - StdIO-only client? → use the
mcp-remotebridge:
Client Configurations
Cursor
Cursor natively supports remote MCP servers, so you only need a remote configuration. Install Mezmo MCP Server in Cursor Clicking the Install MCP Server badge opens Cursor and automatically adds themezmo entry to your ~/.cursor/mcp.json with a placeholder for the Service Key. After it’s created, edit the file and replace <SERVICE KEY> with your actual Mezmo service key. Restart Cursor for changes to take effect. The final configuration should look like the example below.
Windsurf
Windsurf also supports remote servers via theserverUrl field.
Trae
VS Code’s Copilot Chat or Visual Studio 2022
Zed
Gemini CLI
Claude Code
Claude Desktop
BoltAI
Windows (CMD)
Augment Code
Add a new MCP and enter:Roo Code
Roo Code supports remote URLs:ZenCoder
Amazon Q Developer CLI
Qodo Gen
JetBrains AI Assistant
Warp
OpenCode
Codex CLI
Add to~/.codex/config.toml:
workspace-write for example, add this:
codex --sandbox workspace-write or set a default mode with:
Troubleshooting
1. npx argument-escaping bug
Some clients pass command-line arguments to npx without quoting spaces. This can split the Authorization header (e.g. Bearer and the token become separate arguments) and cause authentication failures.
Work-around: store the header in an environment variable and pass it without spaces:
2. Lost connection to the Mezmo MCP server
If your client shows an error such as “server disconnected” or stops responding to MCP commands:- Disable or remove the Mezmo MCP entry in your client settings.
- Re-enable (or re-add) the same entry, or simply restart the client.
3. 401/403 authentication errors
- Verify the
Authorizationheader is present and formatted asBearer <SERVICE KEY>. - If using
npx mcp-remote, prefer the environment variable approach to avoid splitting the header. - Regenerate your Service Key in Mezmo and try again if issues persist.
Next Steps
Once your client is configured you can immediately run natural-language commands such asanalyze my logs from the last 30 minutes and determine root cause for any issues that you findlist all my pipelinesshow me details for pipeline <pipeline title>deduplicate error logs from the last 30 minutes for app "my-app-frontend"