Skip to main content
Back to the PagerDuty MCP server

MCP Gateway · Claude Code

PagerDuty icon

Connect PagerDuty to Claude Code

When the pager goes off, the engineer on call is usually already in a terminal. Claude Code can pull the incident, its alerts and recent changes into the session, check whether it has happened before, and write findings back as incident notes. The Speakeasy MCP Gateway logs each PagerDuty call against the engineer who made it.

Category
Infrastructure
Tools
64
Authentication
API key
Claude Code
CLI

Behind the MCP Gateway

Run PagerDuty MCP behind the MCP Gateway

One URL for every agent, sign-in through your IdP, RBAC down to the tool, and every PagerDuty call inspected and logged.

Deploy on MCP Gateway

Set up

Add PagerDuty to Claude Code in 4 steps

  1. 01

    Add PagerDuty from the catalog

    An admin finds PagerDuty in the MCP Catalog (MCP Gateway > MCP > Catalog) and clicks Add. Speakeasy registers the vendor's server as a remote MCP server and proxies sessions to it. Nothing is copied or re-hosted.

    PagerDuty authenticates with an API key. Enter it under Upstream headers in the install dialog, or later on the server's Settings tab. The key is stored on the server, sent with every upstream request, and never reaches anyone's client configuration.

    Where MCP-scoped policies are enabled, the install offers a recommended risk policy for the new server that detects secrets and PII and inspects tool requests and responses.

  2. 02

    Choose who can use PagerDuty

    Give teams the mcp:connect scope on the PagerDuty server through team access or a role. The organization gateway works out each person's servers from their live access, so granting access adds PagerDuty to their gateway on the next call, and removing it takes it away.

  3. 03

    Connect Claude Code

    Add the organization gateway as an HTTP MCP server, then authenticate from /mcp.

    Run the command below with your organization gateway URL.

    Open /mcp in Claude Code and choose Authenticate to sign in.

    claude mcp add --transport http --scope user \
      'speakeasy' \
      'https://<organization host>/mcp/gateway/<organization slug>'
  4. 04

    Sign in and use PagerDuty from Claude Code

    The first time Claude Code connects, it opens a browser so the person can sign in to Speakeasy through your identity provider.

    From then on, PagerDuty's tools appear in Claude Code, limited to what the person's access allows, and every call lands in the gateway's tool logs.

To roll it out to a whole team, publish the server in a plugin and register the plugin marketplace in Claude Code's managed settings, so every member gets it without running the command. The device agent can also write and reapply these settings on each laptop.

Use cases

What Claude Code users do with PagerDuty

Investigate an incident from the terminal

Give Claude Code the incident ID and it reads the incident, its alerts and the change events linked to it, then lines them up with the code you have open.

get_incidentlist_alerts_from_incidentlist_incident_change_events

Check whether it happened before

Claude Code fetches past and related incidents for the current one, so you can see how a similar failure was resolved last time.

get_past_incidentsget_related_incidents

Write findings to the incident

As you narrow down the cause, Claude Code adds notes to the incident with what you checked and what you ruled out, so the next responder starts from there.

add_note_to_incident

Tools

64 tools

Each PagerDuty tool can be allowed or denied per team and role at the MCP Gateway before Claude Code sees it.

list_alert_grouping_settings

List all alert grouping settings with optional filtering.

get_alert_grouping_setting

Get details for a specific alert grouping setting.

list_alerts_from_incident

List alerts for a specific incident.

get_alert_from_incident

Get a specific alert from an incident.

list_change_events

List all change events with optional filtering.

get_change_event

Get details about a specific change event.

See all 64 tools

Control

What Speakeasy can see and stop in Claude Code

The gateway covers every client the same way. The rest depends on what Claude Code exposes to Speakeasy.

Tool logs

Gateway

Every PagerDuty call is logged with the person and the client that made it.

Access by role

Gateway

People reach only the PagerDuty tools their team or role allows.

Request and response blocking

Gateway

A risk policy scoped to PagerDuty can reject a tool request before it reaches the server, or withhold a result from Claude Code. MCP-scoped policies are enabled per organization.

Prompt and tool-call blocking

Claude Code

Agent hooks send each prompt and tool call to Speakeasy, which allows or denies it before Claude Code runs it.

User attribution

Claude Code

Claude Code's OpenTelemetry exporter ties each session to a named person. Without it, activity can't be attributed.

Budgets

Claude Code

Spend limits can block Claude Code traffic once a budget is reached.

Device agent and MDM

Claude Code

The device agent installs the marketplace, plugin and telemetry settings and reapplies them every minute. It deploys through MDM.

Anthropic inference hooks

Claude Code

On Claude Enterprise, prompts can be checked before inference with nothing installed on the device (beta).

  • Claude Code on the web doesn't use the laptop setup. It needs the device agent in a shared Anthropic-hosted environment.
  • Plugin marketplace URLs for Claude Code carry an access token, so share install snippets only through a private channel.

Questions

Frequently asked questions

Can Claude Code change incidents, or only read them?
That depends on the role. Each of the 64 PagerDuty tools can be allowed or denied per team and role at the gateway, so a role could read incidents and add notes without access to manage_incidents or delete_team.
Can Speakeasy stop a PagerDuty tool call in Claude Code?
Yes. Agent hooks send each prompt and tool call to Speakeasy, which allows or denies it before Claude Code runs it.
How do Claude Code users get PagerDuty?
An admin adds PagerDuty from the Speakeasy MCP Catalog and grants access by team or role. Add the organization gateway as an HTTP MCP server, then authenticate from /mcp. Each person then sees only the PagerDuty tools their access allows.
Are PagerDuty calls from Claude Code logged?
Yes. PagerDuty calls go through the MCP Gateway, which logs each tool call and attributes it to the person and the client that made it.

Connect more

PagerDuty in other clients

AI everywhere.

Control here.