Integrations
PagerDuty
Official · StableBuilt-innpm: @loop-engine/adapter-pagerduty
What it does
PagerDuty incidents can trigger Loop Engine workflows, turning urgent alerts into governed and attributable response loops. The adapter maps incident events to loop signals, starts a loop per incident, and keeps human decisions in-policy.
Use case
PagerDuty fires a SEV-2 database incident:
- Loop Engine starts
incident-responseloop - On-call engineer acknowledges (human-only guard)
- Runbook automation executes
- Loop closes and emits learning signal
Quick setup
-
Install
1npm install @loop-engine/adapter-pagerduty -
Configure webhook endpoint
1POST https:"cmt">//your-app.example.com/hooks/pagerduty -
Wire a
PagerDutyNotifier(Events v2 key)1import { PagerDutyNotifier } from "@loop-engine/adapter-pagerduty";23const notifier = new PagerDutyNotifier({4 integrationKey: process.env.PAGERDUTY_INTEGRATION_KEY!5});6void notifier; -
Define incident loop
1loopId: incident-response2initialState: triage3states:4 - stateId: triage5 transitions:6 - signalId: acknowledge_incident7 toState: executing
Configuration reference
| Option | Type | Default | Description |
|---|---|---|---|
| webhookSecret | string | required | PagerDuty webhook signing secret |
| incidentLoopId | string | required | Loop definition ID to start on incident |
| severityMap | object | — | Map PagerDuty severity to loop signals |
Troubleshooting
- Webhook signature invalid — Ensure
webhookSecretmatches PagerDuty integration settings. - Loop not starting — Verify
incidentLoopIdis registered in runtime.