AI-powered on-call assistant for Microsoft ICM β from incident triage to R2D generation
Features β’ Quick Start β’ Skills β’ Architecture β’ Commands
| Feature | Description |
|---|---|
| π Incident Investigation | Query ICM incidents, get AI summaries, find similar incidents, check customer impact |
| π R2D Generation | Auto-generate Ready-to-Dispatch work items in Azure DevOps from ICM incidents |
| π¬ Kusto Investigation | 3-phase Kusto pipeline: ApiQoSEvent β ContextActivity β DisksBI |
| π ICM Crawler | Puppeteer-based crawler for authored summaries & discussion entries (data the API doesn't expose) |
| π οΈ 23+ ICM MCP Tools | Full access to incidents, teams, on-call schedules, customer impact via MCP protocol |
| π§© Extensible Skills | Add new incident types by creating a skill markdown file β no code changes needed |
| π ADO Integration | Create/update Azure DevOps work items via REST API with HTML formatting |
| π₯ Team & Contact Lookup | Find on-call engineers, search teams, lookup contacts by alias |
- β Node.js v18+ (Download)
- β Azure CLI installed and logged in (Install Guide)
- β Microsoft Edge (for ICM Crawler and Kusto Web queries)
- β ICM Access via your Microsoft account
- β VPN connected (for Kusto cluster access)
git clone https://github.com/zhanrz88-sudo/oncallspecialist.git
cd oncallspecialist
npm run setup# Login to Azure for ICM API access
az login --scope api://icmmcpapi-prod/mcp.tools
# Login to Azure for ADO access (if using R2D generation)
az loginThe ICM crawler and Kusto queries use Edge with a persistent profile. On first use, a browser window opens for interactive login. After that, everything runs headlessly.
# Direct CLI
node oncall-agent/oncall-agent.js incident 123456789
# Or install for GitHub Copilot CLI
npm run install-copilotSkills are markdown-defined workflows that the agent executes step-by-step. Each skill is a self-contained playbook for a specific on-call task.
| Skill | Trigger | What It Does |
|---|---|---|
| Triage Incident | "triage incident <id>" | Parallel investigation: incident details, impact, similar incidents, mitigation hints |
| Auto Mitigate | "mitigate incident <id>" | Match incident to known patterns, suggest fix, provide TSG links |
| Generate R2D | "generate R2D for <id>" | Full pipeline: ICM β Crawler β Kusto β R2D template β ADO work item |
| DES Weak Association | "break DES association" | Specialized R2D for DES deletion blocked by stale storage account references |
- Create
skills/skill-r2d-<name>.mdfollowing the existing template format - Define the 8 R2D questions with pre-filled answers for that incident type
- Register it in
skills/skill-generate-r2d.mdβ Sub-Skills Registry table - The agent will auto-match it based on incident patterns
oncall-specialist/
βββ oncall-agent/ # CLI agent + ICM client library
β βββ oncall-agent.js # Main CLI (incident, oncall, kusto, etc.)
β βββ icm-client.js # Reusable ICM API client
β βββ *.md # Agent instructions + skill files
βββ icm-mcp-server/ # MCP server for GitHub Copilot integration
β βββ index.js # MCP protocol server (23+ tools)
β βββ icm-crawler.js # Puppeteer-based ICM portal crawler
β βββ kusto-web-query.js # Kusto Web Explorer query runner
β βββ kusto-query.js # Kusto SDK query runner
βββ skills/ # Skill definitions (shareable)
β βββ skill-generate-r2d.md
β βββ skill-r2d-break-des-storage-association.md
β βββ skill-triage-incident.md
β βββ skill-auto-mitigate.md
βββ docs/ # TSG documents
β βββ tsg-refresh-encryption-scopes.md
β βββ tsg-constructing-blob-uri.md
β βββ ...
βββ package.json # Root package with setup scripts
ICM Incident ID
β
ββββΊ ICM API (23 MCP tools) βββΊ title, severity, subscription, region
ββββΊ ICM Crawler (Puppeteer) βββΊ authored summary, discussion entries
β
βΌ
Kusto 3-Phase Pipeline
ββββΊ Phase 1: DiskManagerApiQoSEvent βββΊ failed DELETEs, correlation IDs
ββββΊ Phase 2: DiskManagerContextActivity βββΊ root cause, blocking storage account
ββββΊ Phase 3: DisksBI/StorageAccount βββΊ validate DES β storage association
β
βΌ
Sub-Skill Match (pattern-based)
ββββΊ DES weak association template
ββββΊ Snapshot stale reference template
ββββΊ (extensible β add your own)
β
βΌ
R2D Template Engine
ββββΊ 8-question HTML description
ββββΊ Iteration path auto-calculation
ββββΊ Acceptance criteria
β
βΌ
Azure DevOps REST API
ββββΊ Create/Update PBI with tags, area path, assignment
# Incident operations
node oncall-agent/oncall-agent.js incident <id> # Get incident details + AI summary
node oncall-agent/oncall-agent.js impact <id> # Customer impact
node oncall-agent/oncall-agent.js find-similar <id> # Smart similar incident search
node oncall-agent/oncall-agent.js mitigate <id> # Mitigation hints
# Team & contact
node oncall-agent/oncall-agent.js oncall "Disk Service" # Who is on-call
node oncall-agent/oncall-agent.js team "Disk Service" # Search teams
node oncall-agent/oncall-agent.js contact <alias> # Lookup person
# Kusto queries
node oncall-agent/oncall-agent.js kusto disks Disks "<KQL>"
node oncall-agent/oncall-agent.js kusto disksbi DisksBI "<KQL>"
node oncall-agent/oncall-agent.js kusto-tables disks Disks
node oncall-agent/oncall-agent.js kusto-schema disks Disks <table># Full crawl (authored summary + discussion entries)
node icm-mcp-server/icm-crawler.js <incidentId>
# Summary only
node icm-mcp-server/icm-crawler.js <incidentId> --summary-onlynode icm-mcp-server/kusto-web-query.js https://disks.kusto.windows.net Disks "<KQL query>"Add to your Copilot custom instructions to enable the agent:
You have access to an On-Call Specialist Agent.
Run commands via: node <path>/oncall-agent/oncall-agent.js <command> [args]
See oncall-agent/oncall-specialist.instructions.md for the full instruction template.
| Team | ICM Public ID | Team ID |
|---|---|---|
| Disk Service | AZURERT\DiskService | 28322 |
| Alias | URL | Database |
|---|---|---|
| disks | https://disks.kusto.windows.net | Disks |
| disksbi | https://disksbi.kusto.windows.net | DisksBI |
- New Skills: Create a
skill-*.mdinskills/following the existing format - New TSGs: Add
tsg-*.mdindocs/ - New Commands: Extend
oncall-agent/oncall-agent.js - Bug Fixes: PRs welcome!
MIT License β see LICENSE for details.
Made with β€οΈ for the Microsoft on-call engineering community