grafana/mcp-grafana
Vedi su GitHubFeature Request: Add update_alert_group tool (acknowledge, resolve, update state)
Open
Aperta il 29 apr 2026
good first issuehelp wanted
Descrizione
Summary
The current OnCall toolset only has `list_alert_groups` and `get_alert_group`. There are no write tools to act on an alert group — making it impossible for an AI agent to close the loop on an alert without switching to the Grafana UI.
Motivation
In an AI-driven on-call workflow, the full lifecycle of an alert group is:
- Detect → `list_alert_groups` / `get_alert_group` ✅ (exists)
- Acknowledge → signal investigation started ❌ missing
- Resolve → close out once fix is confirmed ❌ missing
Without these, an agent using the MCP can investigate and triage but cannot update the alert state — defeating the purpose of agentic on-call automation. This mirrors the same gap I raised for incidents in #748.
Dependency
The underlying Go client (`grafana/amixr-api-go-client`) also lacks these methods, so this request spans two layers:
- `amixr-api-go-client`: add `AcknowledgeAlertGroup`, `UnacknowledgeAlertGroup`, `ResolveAlertGroup`, `UnresolveAlertGroup` methods
- `mcp-grafana`: add a single `update_alert_group` tool in `tools/oncall.go`
Proposed Tool
type UpdateAlertGroupParams struct {
AlertGroupID string \`json:"alertGroupId" jsonschema:"required,description=The ID of the alert group to update"\`
State string \`json:"state" jsonschema:"required,description=New state for the alert group. One of: acknowledged\\, unacknowledged\\, resolved\\, unresolved"\`
}
Should be gated behind `enableWriteTools` (same as `create_incident`).
Use Cases
- AI agent acknowledges an alert group immediately upon starting triage (signals to the team that it's being handled)
- AI agent resolves the alert group after confirming the root cause is fixed and the PR is merged
Related
- #748 — same pattern for Grafana Incidents
- `tools/oncall.go` — where the new tool would live
- `grafana/amixr-api-go-client` — Go client needs the write methods added first