Opsgenie MCP Server
Provides tools for interacting with Opsgenie's alert management API, enabling users to create, search, retrieve, acknowledge, close, snooze, and add notes to alerts.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Opsgenie MCP Server Create a P1 alert for the Backend Team: Database connection failed"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Opsgenie MCP Server
A Model Context Protocol (MCP) server for integrating with Opsgenie's alert management system. This server allows you to manage Opsgenie alerts through any MCP-compatible client like Claude Desktop.
Features
This MCP server provides comprehensive Opsgenie integration with the following tools:
create_alert: Create new alerts in Opsgenie
list_alerts: List and search alerts with filtering options
get_alert: Get detailed information about a specific alert
acknowledge_alert: Acknowledge alerts
close_alert: Close resolved alerts
snooze_alert: Snooze alerts for a specified time period
unacknowledge_alert: Remove acknowledgment from alerts
add_note_to_alert: Add notes to existing alerts
Related MCP server: servicenow-mcp-server
Quick Start
Prerequisites
Node.js 18+
Opsgenie API key (Get one here)
Installation
Download or clone this server:
git clone https://github.com/HainanZhao/mcp-opsgenie.git
cd mcp-opsgenieSet up the project:
npm run setupConfigure your API key:
# Edit .env and add your OPSGENIE_API_KEYTest your setup:
npm testAvailable Commands
npm run setup # Install dependencies, build, and create .env
npm run build # Build TypeScript to JavaScript
npm run dev # Start development server with auto-reload
npm test # Run tests to validate setup
npm start # Start the MCP server
npm run clean # Remove build artifactsConfiguration
Environment Variables
Create a .env file with your Opsgenie API key:
OPSGENIE_API_KEY=your_opsgenie_api_key_hereMCP Client Configuration
Add this server to your MCP client configuration. For Claude Desktop, add to your config file:
{
"mcpServers": {
"opsgenie": {
"command": "/path/to/mcp-opsgenie/dist/index.js",
"env": {
"OPSGENIE_API_KEY": "your_api_key_here"
}
}
}
}Alternative using npm/npx (if installed globally):
{
"mcpServers": {
"opsgenie": {
"command": "npx",
"args": ["mcp-opsgenie"],
"env": {
"OPSGENIE_API_KEY": "your_api_key_here"
}
}
}
}Claude Desktop config locations:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.json
Usage Examples
Creating an Alert
Ask your MCP client to create an alert:
"Create a P1 alert in Opsgenie with message 'Database connection failed' for the Backend Team"
Or provide specific details:
Message: "Database connection failed"
Priority: P1 (Critical)
Teams: Backend Team
Tags: database, production, critical
Description: Detailed problem description
Managing Alerts
List alerts: "Show me all open P1 alerts"
Get alert details: "Get details for alert ID abc123"
Acknowledge: "Acknowledge alert abc123 with note 'Investigating'"
Close alert: "Close alert abc123 with note 'Issue resolved'"
Snooze: "Snooze alert abc123 until 2024-12-25 10:00 AM"
Searching Alerts
Use Opsgenie's powerful query syntax:
"List alerts with status open and priority P1"
"Show me alerts tagged with 'database' from the last 24 hours"
"Find all unacknowledged alerts for the Backend Team"
API Reference
Alert Priorities
P1: Critical - Immediate action required
P2: High - Quick response needed
P3: Medium - Normal priority (default)
P4: Low - Can be addressed during business hours
P5: Informational - For awareness
Search Query Examples
status:open- Open alerts onlypriority:P1- P1 priority alertstag:production- Alerts with "production" tagteam:"Backend Team"- Alerts for specific teamcreatedAt>"2024-01-01"- Alerts after a datestatus:open AND priority:P1- Combine conditions
Troubleshooting
Common Issues
"Authentication failed"
Verify your API key is correct in the
.envfileEnsure the API key has necessary permissions in Opsgenie
"Cannot find module"
Run
npm installto install dependenciesMake sure you've run
npm run buildto compile TypeScript
"No alerts found"
Check if you have alerts in your Opsgenie account
Verify your search query syntax
Try listing without filters first
Getting Help
Check the examples documentation for detailed usage patterns
Review your Opsgenie API permissions
Ensure network connectivity to
api.opsgenie.com
What You Can Do
With this MCP server, you can:
✅ Create alerts with full customization (priority, teams, tags, etc.)
✅ Search and filter alerts using Opsgenie's query language
✅ Manage alert lifecycle (acknowledge, close, snooze)
✅ Add notes and collaborate on incident resolution
✅ Integrate with any MCP-compatible AI assistant
✅ Automate alert management through natural language
Security Notes
Keep your API key secure and never commit it to version control
Use environment variables for configuration
Consider using API keys with minimal required permissions
The server only makes outbound connections to Opsgenie's API
Contributing
See CONTRIBUTING.md for development setup and contribution guidelines.
License
MIT License - see LICENSE file for details.
Available Tools
8 toolsopsgenie_acknowledge_alertC
Acknowledge an alert
Inputs: identifier (required), note, user, source, +1 more.
opsgenie_add_note_to_alertC
Add a note to an alert
Inputs: note (required), identifier (required), user, source, +1 more.
opsgenie_close_alertC
Close an alert
Inputs: identifier (required), note, user, source, +1 more.
opsgenie_create_alertC
Create a new alert in Opsgenie
Inputs: message (required), tags, alias, teams, +4 more.
opsgenie_get_alertC
Get details of a specific alert
Inputs: identifier (required), identifierType.
opsgenie_list_alertsC
List alerts from Opsgenie
Inputs: sort, limit, order, query, +2 more.
opsgenie_snooze_alertB
Snooze an alert for a specified time
Inputs: endTime (required), identifier (required), note, user, +2 more.
opsgenie_unacknowledge_alertC
Remove acknowledgment from an alert
Inputs: identifier (required), note, user, source, +1 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 8 tools
Each tool maps to a distinct lifecycle action on a single resource (alert): create, list, get, snooze, acknowledge, unacknowledge, close, add note. The only near-pair, acknowledge vs. unacknowledge, is explicitly named as inverse operations, so selection is unambiguous.
All eight tools follow the same pattern: opsgenie_ prefix plus verb_noun (create_alert, snooze_alert, list_alerts, get_alert, add_note_to_alert). The only variance is singular/plural noun (get_alert vs list_alerts), which is a natural and readable convention.
Eight tools is well-scoped for an alert-management server, with each tool covering a distinct state transition or read operation. No tool feels redundant or padding the surface.
The alert lifecycle is essentially fully covered: create, read, list, acknowledge/unacknowledge, snooze, close, and annotate. Minor gaps remain around reassigning/ownership, updating alert fields (priority, description, tags), and deleting alerts, which agents may need.
Maintenance
Related MCP Connectors
Manage uptime monitors, incidents and status pages from any MCP client.
Manage uptime monitors and incidents and search logs, metrics and traces from an AI assistant.
PagerDuty's official hosted MCP server: incidents, on-call, services, schedules and more.
Manage incidents and on-call: list/create/update incidents, who is on call, on-call overrides.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables comprehensive Opsgenie alert management including listing, creating, acknowledging, and closing alerts, as well as managing alert notes, logs, and custom properties through natural language.937 npmMIT
- AlicenseAqualityDmaintenanceEnables natural language interaction with ServiceNow instances for managing incidents, changes, CMDB, service catalog, users, groups, and knowledge base via MCP.4151 npm1MIT
- AlicenseNot gradedqualityDmaintenanceMCP server for the Splunk On-Call (VictorOps) API providing comprehensive incident management, on-call schedules, team administration, and alert reporting through natural language.2,047 PyPIMIT
- AlicenseNot gradedqualityDmaintenanceEnables management of Atlassian Statuspage incidents, components, and subscribers through natural language.MIT