Skip to content

Every 5 minutes

Get an email when a PagerDuty incident changes

When an incident is triggered, acknowledged or resolved, you get the update with its service and urgency.

Runs
Every 5 minutes
Apps
PagerDuty
AI
Not needed
Access
read

Send this to your assistant

Create a ClickRuntime automation: every 5 minutes, check PagerDuty and email me whenever an incident is triggered, acknowledged or resolved, with the service, title, urgency and who is assigned.

Paste it into your assistant. It tells you what it will send or change before it runs live.

First time? Adding ClickRuntime to your assistant takes about two minutes.

Why use it

Why teams use this automation

Not everyone who needs to know about a PagerDuty incident is on the escalation policy. A support lead wants to be aware that an outage was declared before customers start writing in, and an engineering manager wants to know when it resolved. Without a message, they learn it from a customer, from a chat thread that scrolled away or from someone asking whether anything is wrong.

Every five minutes, incidents changed since the previous run are listed from PagerDuty and their statuses are compared with what was seen last time. When an incident is newly triggered or newly resolved you get an email naming it, its service and its new status. An incident that has not changed stays quiet, so the inbox is not refilled with repeats.

People often use it for stakeholders who should be informed but never paged, such as customer success, account managers or a VP who wants a heads-up.

What you get out of it

  • Stakeholders hear it from you first

    When support knows an incident started before a customer complains, replies are prepared and a status update goes out sooner. Being early is the difference between informing customers and apologizing to them.

  • Resolution notices close the loop

    A second email when the incident resolves tells everyone the issue is over. People stop refreshing dashboards and asking in chat whether it is fixed, which saves time during and after the event.

  • No pager access needed

    Interested people receive an email instead of being added to rotations or paid seats. You keep the escalation policy limited to responders while still widening awareness across the company. That keeps costs and clutter down for everyone.

  • Only real changes produce mail

    Because statuses are compared against the previous check, an incident sitting unchanged for hours does not mail you again. The messages that arrive are about something new, so they get read.

  • A timeline you can reconstruct

    Each email carries a timestamp from when it was sent. After an incident, the sequence of triggered and resolved messages gives a rough timeline for a review without digging through logs.

How it works

What happens, step by step

  1. Every five minutes ClickRuntime checks PagerDuty for incidents created or changed since its last check.

  2. It compares each incident's status with what it saw last time, so you only hear about real changes.

  3. When an incident is triggered, acknowledged or resolved, you get an email with its title, service, urgency and who it is assigned to.

Before it runs live

  • Connect PagerDuty

What you get

RunsEvery 5 minutes
Get an email when a PagerDuty incident changestoday, 9:00Succeeded
Email · PagerDuty[acknowledged] Checkout error rate above 5% Service: checkout-api · Urgency: high · Assigned: Alex Kim

Build your own

Need it to work differently?

This template is a starting point. Copy the prompt and change it, or describe a different automation from scratch, with your own conditions, more apps or an AI step. Your assistant writes it, tests it and runs it on ClickRuntime.
  • Your own rules

    Conditions, thresholds, filters and exceptions, written the way you'd explain them to a colleague.

  • Any number of apps

    One automation can read from one app and update several others. Over 248 apps are ready, and anything with an API works too.

  • AI where it helps

    Summaries, classification, extraction and drafts use ClickRuntime's built-in AI, with no extra key.

  • On a schedule or on each event

    Runs as often as every 5 minutes, or the moment an app sends an event, and keeps track of what it already handled.

Changes you can ask for

  • Act only on the items that match your own rules, and skip the rest
  • Add an AI step, for example to summarize, sort or draft a reply
  • Add another app, for example also send it to Slack
  • Combine it with other PagerDuty steps into one automation

Under the hood

The code that runs this automation

This is the Python script that runs each time the automation starts. Your AI assistant writes it for you when you send the prompt, and you allow each step in your assistant. To change how the automation works, describe the change to your assistant and it updates the script for you. For every function it can use, see the script reference.
get_alerted_on_new_or_changed_incidents.pyexample
from datetime import datetime, timedelta, timezone
from clickruntime import on_trigger, credentials, http, notify, state, report_fetched

PD = "https://api.pagerduty.com"

def pd(path, **params):
    resp = http.get(f"{PD}{path}", params=params, headers={"Authorization": f"Token token={credentials.secret('PAGERDUTY_API_KEY')}",
                    "Accept": "application/json"})
    resp.raise_for_status()
    return resp.json()

@on_trigger
def run(event):
    since = (datetime.now(timezone.utc) - timedelta(days=2)).isoformat()
    incidents = pd("/incidents", since=since, limit=100)["incidents"]
    known = state.get("statuses") or {}
    changed = [i for i in incidents if known.get(i["id"]) != i["status"]]
    report_fetched(len(changed))
    if not changed:
        return {"changed": 0}
    for i in changed:
        who = ", ".join(a["assignee"]["summary"] for a in i.get("assignments", [])) or "unassigned"
        notify.email_me(f"[{i['status']}] {i['title']}", f"Service: {i['service']['summary']}\nUrgency: {i['urgency']}\n"
                        f"Assigned: {who}\n{i['html_url']}")
        known[i["id"]] = i["status"]
    state.set("statuses", {i["id"]: known[i["id"]] for i in incidents if i["id"] in known})
    return {"changed": len(changed)}

FAQ

Common questions

How soon after an incident starts do I get the email?
It checks on a five minute cycle, so the email arrives within about five minutes of PagerDuty recording the change. That is fast enough for awareness, but it is not a replacement for paging the person who must respond.
Will I get an email for the acknowledged status as well?
The alert is about new and resolved incidents. If you also want to hear about acknowledgment, your AI assistant can add it, though it means more email on busy days, so most people leave it off.
Can it cover only the services I care about?
Yes. PagerDuty lets you list incidents by service, so you can limit the emails to the services your team owns. That keeps a payments lead from receiving every unrelated incident across the company. It is a simple filter.
What permissions does it need?
read. Nothing else in your accounts is used.
Does it need AI?
No. It runs without AI, so it doesn't use your plan's AI allowance.
How many runs does it use?
One run each time it checks. Checks that find nothing new and stop right away aren't counted.
Can I change how it works?
Yes. Describe the change to your AI assistant, for example a different schedule, channel or filter. It updates the automation, tests it and tells you what changed.

Set up “Get an email when a PagerDuty incident changes” from your assistant

Copy the prompt above, or connect your assistant first. Free plan, no credit card.