MCP workflow
Build an incident timeline with observability tools
Correlate Sentry errors, Grafana dashboards, and Kubernetes state to assemble a timeline while keeping remediation human-controlled.
The problem
During an incident, context is spread across error tracking, dashboards, and cluster state. An agent can gather and correlate that evidence faster than a human, but it must not be allowed to restart workloads or change infrastructure without approval.
Why these components
Each server contributes a specific capability. The workflow is the contract between them.
Inspect issues, events, traces, and project context from Sentry through MCP.
Issue lookup · Event details · Stack tracesstdioGrafana MCP ServerQuery dashboards, datasources, and alerts through a Grafana MCP connection.
Dashboard search · Datasource queries · Alert inspectionstdioKubernetes MCP ServerInspect and operate Kubernetes clusters with scoped kubeconfig access.
List resources · Read logs · Inspect eventsPrerequisites
- Read-only project access in Sentry and viewer access in Grafana.
- A kubeconfig context restricted to the affected namespace with get/list/log permissions.
- An incident channel and a human incident commander.
Step-by-step
Establish the time window and symptoms
Record the first alert time, affected service, and user-visible symptom. Ask the agent to restate the window before querying anything.
Verify: The window, service, and symptom are written down and shared.
Pull error evidence
Query Sentry for new issues and event counts in the window. Capture the first occurrence, release, and representative stack trace. Do not assume the loudest error is the root cause.
Verify: Each error claim includes an event time and project.
Correlate infrastructure signals
Check Grafana dashboards and Kubernetes events for the same window. Look for deploy times, resource saturation, restarts, and dependency failures.
Verify: The timeline distinguishes correlation from proven causation.
Assemble a source-linked timeline
Write the timeline in chronological order with links or query identifiers for each entry. Mark unknowns explicitly and avoid speculative root causes presented as fact.
Verify: Every timeline item has a timestamp and evidence reference.
Propose, then require approval for remediation
List mitigation options, their expected impact, and rollback steps. Human responders choose and execute changes; the agent should not hold write-capable cluster credentials during the investigation.
Verify: No remediation was executed without an explicit human approval.
Generate a configuration for this workflow
Choose the client you use. The generator will preload 3 componentsand produce that client's documented format. Review every placeholder before saving.
The workflow does not imply that all components support the same transports in every client. The generator validates each entry and reports incompatibilities.
Permissions and security
- Use read-only credentials for the investigation. Do not grant pod delete, deploy, or infrastructure-write permissions.
- Sentry events, logs, and dashboards may contain customer data and secrets; share only what the incident requires.
- The agent's output is a timeline and hypothesis, not an authoritative root-cause report.
Expected outcome
A chronological incident timeline with source references, a list of open questions, and mitigation options for human responders.
Sources & evidence
- github.com/getsentry/toolkitRepository · checked Oct 23, 2026 · documented
The Sentry MCP documentation describes issue and event inspection tools used for error evidence.
- github.com/grafana/mcp-grafanaRepository · checked Oct 23, 2026 · documented
The Grafana MCP documentation describes dashboard and datasource query tools.