PagerDuty's official MCP Server
<!-- mcp-name: io.github.PagerDuty/pagerduty-mcp -->PagerDuty's local MCP (Model Context Protocol) server which provides tools to interact with your PagerDuty account, allowing you to manage incidents, services, schedules, event orchestrations, and more directly from your MCP-enabled client.
Embedded MCP Apps (Developer Experience)
Interactive React UIs for PagerDuty incident management, embedded directly in the Python MCP server for seamless IDE integration. Manage your full incident lifecycle without leaving your IDE.
Available Apps:
1. Incident Command Center π¨
Full incident lifecycle management from your IDE:
- Real-time incident feed with auto-refresh
- Deep incident details: timeline, notes, alerts, changes
- Quick actions: acknowledge, resolve, escalate
- AI-powered similar incident detection
- Alert inspection with raw data
Usage in VS Code: Ask Claude: Show me the incident command center
2. On-Call Manager π
Schedule management with override CRUD and coverage wizards:
- View current on-call rotations across schedules
- Create, edit, and delete schedule overrides
- Escalation policy management with modal-based UI
Usage in VS Code: Ask Claude: Show me the on-call manager
3. On-Call Compensation Report π°
Per-user on-call metrics with compliance tracking:
- Hours worked, incident counts, interruption rates
- Business hours vs. off-hours breakdown
- Compliance status with EU Working Time Directive limits
- Fairness/equity scoring across responders
- CSV export
Usage in VS Code: Ask Claude: Show me the oncall compensation report
4. Service Dependency Graph πΈοΈ
Interactive graph of service relationships and dependencies:
- Directed graph visualization
- Impact sidebar showing upstream/downstream services
Usage in VS Code: Ask Claude: Show me the service dependency graph
5. Onboarding Wizard π§
Step-by-step PagerDuty account setup:
- Team creation and user onboarding
- Schedule setup with timezone support
- Escalation policy and service configuration
- AIOps / alert grouping configuration
- Incident workflow setup
Usage in VS Code: Ask Claude: Open the onboarding wizard
Architecture:
- β Native VS Code integration (MCP resources)
- β Single process, no HTTP server management
- β Direct access to all PagerDuty MCP tools
- β
Simple deployment:
uv run pagerduty-mcp
See mcp-apps/README.md for development instructions and customization.
Prerequisites
-
asdf-vm installed.
-
uv installed globally.
-
A PagerDuty User API Token. To obtain a PagerDuty User API Token, follow these steps:
- Navigate to User Settings. Click on your user profile icon, then select My Profile and then User Settings.
For Freemium accounts, the permissions for generating User API tokens are limited to the user role as defined here.
- In your user settings, locate the API Access section.
- Click the Create API User Token button and follow the prompts to generate a new token.
- Copy the generated token and store it securely. You will need this token to configure the MCP server.
Use of the PagerDuty User API Token is subject to the PagerDuty Developer Agreement.
- Navigate to User Settings. Click on your user profile icon, then select My Profile and then User Settings.
Using with MCP Clients
Cursor Integration
You can configure this MCP server directly within Cursor's settings.json file, by following these steps:
-
Open Cursor settings (Cursor Settings > Tools > Add MCP, or
Cmd+,on Mac, orCtrl+,on Windows/Linux). -
Add the following configuration:
{ "mcpServers": { "pagerduty-mcp": { "type": "stdio", "command": "uvx", "args": [ "pagerduty-mcp", "--enable-write-tools" // This flag enables write operations on the MCP Server enabling you to creating incidents, schedule overrides and much more ], "env": { "PAGERDUTY_USER_API_KEY": "${input:pagerduty-api-key}" } } } }
VS Code Integration
You can configure this MCP server directly within Visual Studio Code's settings.json file, allowing VS Code to manage the server lifecycle.
-
Open VS Code settings (File > Preferences > Settings, or
Cmd+,on Mac, orCtrl+,on Windows/Linux). -
Search for "mcp" and ensure "Mcp: Enabled" is checked under Features > Chat.
-
Click "Edit in settings.json" under "Mcp > Discovery: Servers".
-
Add the following configuration:
{ "mcp": { "inputs": [ { "type": "promptString", "id": "pagerduty-api-key", "description": "PagerDuty API Key", "password": true } ], "servers": { "pagerduty-mcp": { "type": "stdio", "command": "uvx", "args": [ "pagerduty-mcp", "--enable-write-tools" // This flag enables write operations on the MCP Server enabling you to creating incidents, schedule overrides and much more ], "env": { "PAGERDUTY_USER_API_KEY": "${input:pagerduty-api-key}", "PAGERDUTY_API_HOST": "https://api.pagerduty.com" // If your PagerDuty account is located in EU update your API host to https://api.eu.pagerduty.com } } } } }
Trying it in VS Code Chat (Agent)
- Ensure MCP is enabled in VS Code settings (Features > Chat > "Mcp: Enabled").
- Configure the server as described above.
- Open the Chat view in VS Code (
View>Chat). - Make sure
Agentmode is selected. In the Chat view, you can enable or disable specific tools by clicking the π οΈ icon. - Enter a command such as
Show me the latest incidentorList my event orchestrationsto interact with your PagerDuty account through the MCP server. - You can start, stop, and manage your MCP servers using the command palette (
Cmd+Shift+P/Ctrl+Shift+P) and searching forMCP: List Servers. Ensure the server is running before sending commands. You can also try to restart the server if you encounter any issues.
Claude Desktop Integration
You can configure this MCP server to work with Claude Desktop by adding it to Claude's configuration file.
-
Locate your Claude Desktop configuration file:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
- macOS:
-
Create or edit the configuration file and add the following configuration:
{ "mcpServers": { "pagerduty-mcp": { "command": "uvx", "args": [ "pagerduty-mcp", "--enable-write-tools" ], "env": { "PAGERDUTY_USER_API_KEY": "your-pagerduty-api-key-here", "PAGERDUTY_API_HOST": "https://api.pagerduty.com" } } } } -
Replace the placeholder values:
- Replace
/path/to/your/mcp-server-directorywith the full path to the directory where you cloned the MCP server (e.g.,/Users/yourname/code/pagerduty-mcp) - Replace
your-pagerduty-api-key-herewith your actual PagerDuty User API Token - If your PagerDuty account is located in the EU, update the API host to
https://api.eu.pagerduty.com
- Replace
-
Restart Claude Desktop completely for the changes to take effect.
-
Test the integration by starting a conversation with Claude and asking something like "Show me my latest PagerDuty incidents" or "List my event orchestrations" to verify the MCP server is working.
Security Note: Unlike VS Code's secure input prompts, Claude Desktop requires you to store your API key directly in the configuration file. Ensure this file has appropriate permissions (readable only by your user account) and consider the security implications of storing credentials in plain text.
Running with Docker
The PagerDuty MCP server can be run in a Docker container, providing an isolated and portable deployment option. The Docker image uses stdio transport for MCP communication.
Prerequisites
- Docker installed
- A PagerDuty User API Token (see Prerequisites)
Quick Start
Build the Docker image:
docker build -t pagerduty-mcp:latest .Run in read-only mode (default):
docker run -i --rm \
-e PAGERDUTY_USER_API_KEY="your-api-key-here" \
pagerduty-mcp:latestRun with write tools enabled:
docker run -i --rm \
-e PAGERDUTY_USER_API_KEY="your-api-key-here" \
pagerduty-mcp:latest --enable-write-toolsFor EU region:
docker run -i --rm \
-e PAGERDUTY_USER_API_KEY="your-api-key-here" \
-e PAGERDUTY_API_HOST="https://api.eu.pagerduty.com" \
pagerduty-mcp:latestUsing with MCP Clients via Docker
To integrate the Docker container with MCP clients, you can use Docker as the command:
Claude Desktop example:
{
"mcpServers": {
"pagerduty-mcp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"PAGERDUTY_USER_API_KEY=your-api-key-here",
"pagerduty-mcp:latest"
]
}
}
}Note: The Docker container uses stdio transport, making it compatible with MCP clients that expect standard input/output communication. Ensure you build the image first using
docker build -t pagerduty-mcp:latest .
Set up locally
-
Clone the repository
-
Install
asdfpluginsasdf plugin add python asdf plugin add nodejs https://github.com/asdf-vm/asdf-nodejs.git asdf plugin add uv -
Install tool versions using
asdf:asdf install -
Create a virtual environment and install dependencies using
uv(now thatasdfhas set the correct Python anduvversions):uv sync -
Ensure
uvis available globally.The MCP server can be run from different places so you need
uvto be available globally. To do so, follow the official documentation.Tip: You may need to restart your terminal and/or VS Code for the changes to take effect.
-
Run it locally
To run your cloned PagerDuty MCP Server you need to update your configuration to use
uvinstead ofuvx."pagerduty-mcp": { "type": "stdio", "command": "uv", "args": [ "run", "--directory", "/path/to/your/mcp-server-directory", // Replace with the full path to the directory where you cloned the MCP server, e.g. "/Users/yourname/code/mcp-server", "python", "-m", "pagerduty_mcp", "--enable-write-tools" // This flag enables write operations on the MCP Server enabling you to creating incidents, schedule overrides and much more ], "env": { "PAGERDUTY_USER_API_KEY": "${input:pagerduty-api-key}", "PAGERDUTY_API_HOST": "https://api.pagerduty.com" // If your PagerDuty account is located in EU update your API host to https://api.eu.pagerduty.com } }
Configuration
The MCP server is configured via environment variables:
| Environment Variable | Required | Default | Description |
|---|---|---|---|
| `PAGERDUTY_USER |
β¦