SigNoz
Built by Metorial, the integration platform for agentic AI.
SigNoz
A Model Context Protocol (MCP) server that provides seamless access to SigNoz observability data through AI assistants and LLMs. This server enables natural language queries for metrics, traces, logs, alerts, dashboards, and service performance data.
βββββββββββββββββββ ββββββββββββββββββββ βββββββββββββββββββ
β MCP Client βββββΆβ MCP Server βββββΆβ SigNoz API β
β (AI Assistant) β β (Go) β β (Observability)β
βββββββββββββββββββ ββββββββββββββββββββ βββββββββββββββββββ
β
βΌ
ββββββββββββββββββββ
β Tool Handlers β
β (HTTP Client) β
ββββββββββββββββββββ
Use this mcp-server with MCP-compatible clients like Claude Desktop and Cursor.
signoz-mcp-server (for example: .../signoz-mcp-server/bin/signoz-mcp-server).edit configclaude_desktop_config.json Add shown config with your signoz url, api key and path to signoz-mcp-server binary.{
"mcpServers": {
"signoz": {
"command": "/absolute/path/to/signoz-mcp-server/bin/signoz-mcp-server",
"args": [],
"env": {
"SIGNOZ_URL": "https://your-signoz-instance.com",
"SIGNOZ_API_KEY": "your-api-key-here",
"LOG_LEVEL": "info"
}
}
}
}
signoz server load in the developer console and its tools become available.Notes:
command path with your actual binary location.Option A β GUI:
+ New MCP ServerOption B β Project config file:
Create .cursor/mcp.json in your project root:
For Both options use same json struct
{
"mcpServers": {
"signoz": {
"command": "/absolute/path/to/signoz-mcp-server/bin/signoz-mcp-server",
"args": [],
"env": {
"SIGNOZ_URL": "https://your-signoz-instance.com",
"SIGNOZ_API_KEY": "your-api-key-here",
"LOG_LEVEL": "info"
}
}
}
}
Once added, restart Cursor to use the SigNoz tools.
edit configclaude_desktop_config.json Add shown config with your signoz url, api key and path to signoz-mcp-server binary.{
"mcpServers": {
"signoz": {
"url": "http://localhost:8000/mcp",
"headers": {
"Authorization": "Bearer your-api-key-here"
}
}
}
}
Note: You can pass the SigNoz API key either as:
SIGNOZ_API_KEY) when starting the server, orAuthorization header in the client configuration as shown abovesignoz server load in the developer console and its tools become available.Build and run signoz-mcp-server with envs - SIGNOZ_URL=signoz_url SIGNOZ_API_KEY=signoz_apikey TRANSPORT_MODE=http MCP_SERVER_PORT=8000 LOG_LEVEL=log_level ./signoz-mcp-server - or use docker-compose
Option A β GUI:
+ New MCP ServerOption B β Project config file:
Create .cursor/mcp.json in your project root:
For Both options use same json struct
{
"mcpServers": {
"signoz": {
"url": "http://localhost:8000/mcp",
"headers": {
"Authorization": "Bearer signoz-api-key-here"
}
}
}
}
Note: You can pass the SigNoz API key either as:
SIGNOZ_API_KEY) when starting the server, orAuthorization header in the client configuration as shown aboveNote: By default, the server logs at info level. If you need detailed debugging information, set LOG_LEVEL=debug in your environment. For production use, consider using LOG_LEVEL=warn to reduce log verbosity.
signoz-mcp-server/
βββ cmd/server/ # Main application entry point
βββ internal/
β βββ client/ # SigNoz API client
β βββ config/ # Configuration management
β βββ handler/tools/ # MCP tool implementations
β βββ logger/ # Logging utilities
β βββ mcp-server/ # MCP server core
βββ go.mod # Go module dependencies
βββ Makefile # Build automation
βββ README.md
# Clone the repository
git clone https://github.com/SigNoz/signoz-mcp-server.git
cd signoz-mcp-server
# Build the binary
make build
# Or build directly with Go
go build -o bin/signoz-mcp-server ./cmd/server/
Set the following environment variables:
export SIGNOZ_URL="https://your-signoz-instance.com"
export SIGNOZ_API_KEY="your-api-key-here"
export LOG_LEVEL="info" # Optional: debug, info, error (default: info)
In SigNoz Cloud, SIGNOZ_URL is typically - https://ingest..signoz.cloud
You can access API Key by going to Settings -> Workspace Settings -> API Key in SigNoz UI
# Run the built binary
./bin/signoz-mcp-server
internal/handler/tools/internal/client/client.goThe MCP server provides the following tools that can be used through natural language:
"Show me all available metrics"
"Search for CPU related metrics"
"List all active alerts"
"Get details for alert rule ID abc123"
"Show me the history for alert rule abc123 from the last 6 hours"
"Get logs related to alert abc456"
"List all dashboards"
"Show me the Host Metrics dashboard details"
"Create a dashboard with a specified name, optional tags, and a widget visualizing a chosen metric."
"List all services from the last 6 hours"
"What are the top operations for the paymentservice?"
"List all saved log views"
"Show me error logs for the paymentservice from the last hour"
"Search paymentservice logs for 'connection timeout' errors"
"Get error logs with FATAL severity"
"How many errors per service in the last hour?"
"What are the top error messages for the consumer service?"
"Search all logs where workflow_run_id = 'wr_123'"
"Show me logs containing 'timeout' across all services"
"Show me all available trace fields"
"Search traces for the apple service from the last hour"
"Get details for trace ID ball123"
"Check for error patterns in traces from the randomservice"
"Show me the span hierarchy for trace xyz789"
"Find traces with errors in the last 2 hours"
"Give me flow of this trace"
"What is the p99 latency for the checkout service?"
"How many errors per service in the last hour?"
"Average response time by operation for the payment-svc"
"Request rate per service in the last 30 minutes"
"Which operations have the highest p95 latency?"
signoz_list_metric_keysLists all available metric keys from SigNoz.
signoz_search_metric_by_textSearches metrics by text (uses SigNoz aggregate_attributes autocomplete).
searchText (required) - Text to search forsignoz_list_alertsLists all active alerts from SigNoz.
signoz_get_alertGets details of a specific alert rule.
ruleId (required) - Alert rule IDsignoz_list_dashboardsLists all dashboards with summaries (name, UUID, description, tags).
signoz_get_dashboardGets complete dashboard configuration.
uuid (required) - Dashboard UUIDsignoz_create_dashboardCreates a dashboard.
signoz_update_dashboardUpdates an existing dashboard.
Returns A success confirmation only. No response body is provided.
signoz_list_servicesLists all services within a time range.
timeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in nanoseconds (defaults to 6 hours ago)end (optional) - End time in nanoseconds (defaults to now)signoz_get_service_top_operationsGets top operations for a specific service.
service (required) - Service nametimeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in nanoseconds (defaults to 6 hours ago)end (optional) - End time in nanoseconds (defaults to now)tags (optional) - JSON array of tagssignoz_get_alert_historyGets alert history timeline for a specific rule.
ruleId (required) - Alert rule IDtimeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start timestamp in milliseconds (defaults to 6 hours ago)end (optional) - End timestamp in milliseconds (defaults to now)offset (optional) - Offset for pagination (default: 0)limit (optional) - Limit number of results (default: 20)order (optional) - Sort order: 'asc' or 'desc' (default: 'asc')signoz_list_log_viewsLists all saved log views from SigNoz.
signoz_get_log_viewGets full details of a specific log view by ID.
viewId (required) - Log view IDsignoz_get_logs_for_alertGets logs related to a specific alert automatically.
alertId (required) - Alert rule IDtimeRange (optional) - Time range around alert (e.g., '1h', '30m', '2h') - default: '1h'limit (optional) - Maximum number of logs to return (default: 100)signoz_get_error_logsGets logs with ERROR or FATAL severity within a time range.
timeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in milliseconds (defaults to 6 hours ago)end (optional) - End time in milliseconds (defaults to now)service (optional) - Service name to filter bylimit (optional) - Maximum number of logs to return (default: 100)signoz_search_logs_by_serviceSearches logs for a specific service within a time range.
service (required) - Service name to search logs fortimeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in milliseconds (defaults to 6 hours ago)end (optional) - End time in milliseconds (defaults to now)severity (optional) - Log severity filter (DEBUG, INFO, WARN, ERROR, FATAL)searchText (optional) - Text to search for in log bodylimit (optional) - Maximum number of logs to return (default: 100)signoz_aggregate_logsAggregate logs to provide count, average, sum, min, max, or percentiles, optionally grouped by fields. Use this for questions like "how many errors per service?", "average response time by endpoint", or "top error messages by count".
aggregation (required) - Aggregation function: count, count_distinct, avg, sum, min, max, p50, p75, p90, p95, p99, rateaggregateOn (optional) - Field to aggregate on (required for all except count and rate)groupBy (optional) - Comma-separated fields to group by (e.g., 'service.name, severity_text')filter (optional) - Filter expression using SigNoz search syntaxservice (optional) - Shortcut filter for service nameseverity (optional) - Shortcut filter for severity (DEBUG, INFO, WARN, ERROR, FATAL)orderBy (optional) - Order expression and direction (e.g., 'count() desc')limit (optional) - Maximum number of groups to return (default: 10)timeRange (optional) - Time range like '30m', '1h', '6h', '24h' (default: '1h')start / end (optional) - Start/end time in millisecondssignoz_search_logsSearch logs with flexible filtering across all services. Supports query expressions, optional service/severity filters, and body text search.
query (optional) - Filter expression using SigNoz search syntax (e.g., "service.name = 'payment-svc' AND http.status_code >= 400")service (optional) - Service name to filter byseverity (optional) - Severity filter (DEBUG, INFO, WARN, ERROR, FATAL)searchText (optional) - Text to search for in log body (uses CONTAINS matching)timeRange (optional) - Time range like '30m', '1h', '6h', '24h' (default: '1h')start / end (optional) - Start/end time in millisecondslimit (optional) - Maximum number of logs to return (default: 100)offset (optional) - Offset for pagination (default: 0)signoz_get_trace_field_valuesGets available field values for trace.
fieldName (required) - Field name to get values for (e.g., 'service.name', 'http.method')searchText (optional) - Search text to filter valuessignoz_get_logs_field_valuesGets available field values for log queries.
fieldName (required) - Field name to get values for (e.g., 'service.name')searchText (optional) - Search text to filter valuessignoz_get_metrics_field_valuesGets available field values for metric queries.
fieldName (required) - Field name to get values forsearchText (optional) - Search text to filter valuessignoz_get_trace_available_fieldsGets available field names for trace queries.
searchText (optional) - Search text to filter available fieldssignoz_get_logs_available_fieldsGets available field names for log queries.
searchText (optional) - Search text to filter available fieldssignoz_get_metrics_available_fieldsGets available field names for metric queries.
searchText (optional) - Search text to filter available fieldssignoz_search_traces_by_serviceSearches traces for a specific service.
service (required) - Service name to search traces fortimeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in milliseconds (defaults to 6 hours ago)end (optional) - End time in milliseconds (defaults to now)operation (optional) - Operation name to filter byerror (optional) - Filter by error status (true/false)minDuration (optional) - Minimum duration in nanosecondsmaxDuration (optional) - Maximum duration in nanosecondslimit (optional) - Maximum number of traces to return (default: 100)signoz_aggregate_tracesAggregate traces to gets statistics like count, average, sum, min, max, or percentiles over spans, optionally grouped by fields.
aggregation (required) - Aggregation function: count, count_distinct, avg, sum, min, max, p50, p75, p90, p95, p99, rateaggregateOn (optional) - Field to aggregate on (e.g., 'durationNano'). Required for all except count and rategroupBy (optional) - Comma-separated fields to group by (e.g., 'service.name, name')filter (optional) - Filter expression using SigNoz search syntaxservice (optional) - Shortcut filter for service nameoperation (optional) - Shortcut filter for span/operation nameerror (optional) - Shortcut filter for error spans ('true' or 'false')orderBy (optional) - Order expression and direction (e.g., 'avg(durationNano) desc')limit (optional) - Maximum number of groups to return (default: 10)timeRange (optional) - Time range like '30m', '1h', '6h', '24h' (default: '1h')start / end (optional) - Start/end time in millisecondssignoz_get_trace_detailsGets trace information including all spans and metadata.
traceId (required) - Trace ID to get details fortimeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in milliseconds (defaults to 6 hours ago)end (optional) - End time in milliseconds (defaults to now)includeSpans (optional) - Include detailed span information (true/false, default: true)signoz_get_trace_error_analysisAnalyzes error patterns in traces.
timeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in milliseconds (defaults to 6 hours ago)end (optional) - End time in milliseconds (defaults to now)service (optional) - Service name to filter bysignoz_get_trace_span_hierarchyGets trace span relationships and hierarchy.
traceId (required) - Trace ID to get span hierarchy fortimeRange (optional) - Time range like '2h', '6h', '2d', '7d'start (optional) - Start time in milliseconds (defaults to 6 hours ago)end (optional) - End time in milliseconds (defaults to now)signoz_execute_builder_queryExecutes a SigNoz Query Builder v5 query.
query (required) - Complete SigNoz Query Builder v5 JSON objectMost tools support flexible time parameters:
Use the timeRange parameter with formats:
'30m' - Last 30 minutes'2h' - Last 2 hours'6h' - Last 6 hours'2d' - Last 2 days'7d' - Last 7 daysThe timeRange parameter automatically calculates the time window from now backwards. If not specified, most tools default to the last 6 hours. You can also specify time in milliseconds and nanoseconds
All tools return JSON responses that are optimized for LLM consumption:
| Variable | Description | Required |
|---|---|---|
SIGNOZ_URL | SigNoz instance URL | Yes |
SIGNOZ_API_KEY | SigNoz API key (get from Settings β Workspace Settings β API Key in SigNoz UI) | Yes |
LOG_LEVEL | Logging level: info(default), debug, warn, error | No |
TRANSPORT_MODE | MCP transport mode: stdio(default) or http | No |
MCP_SERVER_PORT | Port for HTTP transport mode | Yes only when TRANSPORT_MODE=http |
Ensure Node.js is installed on your system. For details about the MCPB CLI, see Anthropic MCPB GitHub repository.
From the repository root, run:
make bundle
This command builds platform binaries (macOS and Windows), copies manifest and assets, installs the MCPB CLI (@anthropic-ai/mcpb), and packages everything into a Claude-compatible .mcpb bundle.
Open Claude Desktop β Settings β Developer β Edit Config -> Add bundle.mcpb
Select the generated bundle:
./bundle/bundle.mcpb
Provide your SigNoz configuration:
SIGNOZ_URL: URL of your SigNoz instanceSIGNOZ_API_KEY: API key from SigNoz UI β Settings β Workspace Settings β API KeyLOG_LEVEL: Optional (info, debug, or warn)Restart Claude Desktop and it will then automatically start the SigNoz MCP Server and register its tools.
We welcome contributions!
Made with β€οΈ for the observability community