IntegrationsPagerDuty

PagerDuty Integration

Integrate BugBrain with PagerDuty to immediately alert on-call teams about critical test failures.

Features

  • Alert on critical failures — Trigger PagerDuty incidents automatically
  • Severity-based routing — Critical bugs → PagerDuty, others → Slack
  • Incident deduplication — Prevent alert fatigue with 30-min window
  • On-call escalation — Auto-escalate unacknowledged alerts
  • Incident resolve — Auto-resolve when test passes
  • Pro plan required

Setup

  1. Get PagerDuty API Key

    • PagerDuty → Integrations → API Access → Create Token
    • Copy token (will need this)
  2. Connect to BugBrain

    • Settings → Integrations → PagerDuty
    • Paste API key and select Service
    • Configure alert rules
  3. Set Alert Threshold

    • Alert on “Critical” failures only
    • Or include “High” severity failures
    • Test with sample incident

Alert Rules

ConditionActionEscalation
Critical test failureCreate high-urgency incidentEscalate if unack’d after 15m
High test failureCreate medium-urgency incidentEscalate if unack’d after 30m
Multiple failures (5+)Create high-urgency incidentPage on-call lead

Alert Payload

PagerDuty Incident Created:

Title: 🔴 CRITICAL: Payment checkout flow failing
Service: BugBrain - Production Tests
Severity: Critical
Urgency: High

Description:
Test: Complete Payment Flow
Failure: Form submission timeout
Evidence: Screenshot, network logs
Execution: https://app.bugbrain.tech/executions/exec_abc123

Deduplication

  • Time window: 30 minutes
  • Match criteria: Same test + same failure type
  • Action: Updates incident rather than creating new one
  • Note: Adds comment about recurring failure

Auto-Resolve

When test passes again:

  1. BugBrain detects all tests passing
  2. Finds related PagerDuty incident
  3. Adds resolution note with fix commit
  4. Resolves incident automatically
  5. Notifies on-call team

Integration with Slack

Use together with Slack integration:

🔴 CRITICAL: Payment flow failing
🔔 PagerDuty incident created: INC-12345
⏰ On-call engineer notified

Troubleshooting

  • Incidents not creating — Verify PagerDuty API token permissions
  • Wrong service selected — Check Service selection in Integrations
  • Alert fatigue — Increase deduplication window to 60 minutes
  • Incidents not resolving — Ensure auto-resolve is enabled in settings