MCP Server

Connect AI agents and IDE assistants to your Obtrace observability data via the Model Context Protocol.

Obtrace MCP Server

The Obtrace MCP Server exposes your observability platform as a set of Model Context Protocol tools. This allows AI assistants like Claude, IDE extensions, and custom agents to query logs, traces, metrics, manage incidents, and run AI-powered analysis directly against your Obtrace data.

Why MCP?

Instead of copy-pasting log snippets or manually querying dashboards, your AI assistant can:

  • Query logs, traces, and metrics using natural language or ClickHouse SQL
  • Investigate incidents by correlating signals across services
  • Run root cause analysis powered by Obtrace AI
  • Manage dashboards and alerts without leaving the conversation
  • Browse session replays to understand user-facing issues

Capabilities at a glance

CategoryToolsAccess
Logsquery_logs, search_logs, list_log_services, log_stats, log_patternsRead
Tracesquery_traces, get_trace, search_traces, list_trace_services, list_trace_operations, trace_statsRead
Metricsquery_metrics, list_metric_names, get_metric_metadata, list_metric_label_names, list_metric_label_values, metric_statsRead
Dashboardslist_dashboards, get_dashboard, get_dashboard_panels, create_dashboard, update_dashboard, delete_dashboardRead + Write
Incidentslist_incidents, get_incident, get_incident_timeline, create_incident, update_incident, add_incident_activityRead + Write
Alertslist_alert_rules, get_alert_rule, list_alert_history, list_contact_points, create_alert_rule, update_alert_rule, delete_alert_ruleRead + Write
AIchat_to_query, root_cause_analysis, summarize, autofixRead + Write
Projectslist_projects, get_project, list_apps, list_teams, list_usersRead
Replaylist_replay_sessions, get_replay_session, get_replay_events, get_replay_errorsRead
Searchglobal_search, generate_deeplinkRead

Write tools are disabled by default and require the --enable-write flag.

Architecture

flowchart TB
    A["Claude / IDE / Agent"] -->|"MCP Protocol (stdio, SSE, or HTTP)"| B["obtrace mcp"]
    B -->|"HTTPS + Bearer token"| C["Obtrace API\n(query-gateway, control-plane, ai-service)"]

Next steps

Source code

The MCP server is open source: github.com/obtraceai/obtrace-mcp

Nesta página