> ## Documentation Index
> Fetch the complete documentation index at: https://sariva.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# PagerDuty

> Optional — connect PagerDuty so alerts can escalate out of chat.

ⓘINFO

**Setup wizard → the Paging step.** Sariva pages through exactly **one** provider per install — `none`, PagerDuty or [xMatters](https://sariva.mintlify.site/prerequisites/paging/xmatters.md) — chosen in the wizard. Pick PagerDuty there and the wizard templates the routing key; this page is where you get it.

The Sariva platform pages when a registered app trips an alert threshold it opted into (consumer lag, error patterns, pod restarts, rebalances) or a CFK cluster's pod is **OOMKilled**. Without a paging provider, alerts still post to Slack / Teams but can't escalate out of the chat surface.

With PagerDuty, Sariva uses the **Events API v2**: it triggers an incident at `https://events.pagerduty.com/v2/enqueue` under a dedup key it mints per episode (`<app alias>-<alert type>` for an app alert; `<cluster alias>-<pod>-oom_killed` for a CFK pod OOMKilled page), and **resolves** that same key when the condition clears — one incident per episode, never a second one. When the app registration carries a `runbook_url` ([Register an app](https://sariva.mintlify.site/app-teams/register.md)), the incident's `links[]` has a **Runbook** link to it and `custom_details.runbook_url` repeats it; otherwise there is no link and the field is empty — Sariva never sends its internal knowledge-base paths to a page. An OOMKilled page never carries a runbook link and names no app or team; its `custom_details` describe the pod and the kill.

## What you need first

* [ ] An email address you can register a PagerDuty account with (read the gotcha first)

⚠WARNING

**PagerDuty's trial form rejects consumer email domains.** Confirmed-blocked: `gmail.com` (including `+` aliases), `yahoo.com`, `hotmail.com`, `outlook.com`, `proton.me`. The "Continue" button just silently fails — no error. If you don't have a corporate email, use one of the paths below — or use [xMatters](https://sariva.mintlify.site/prerequisites/paging/xmatters.md), whose free plan accepts a personal email.

## Pick one path (priority order)

### Path (a) — primary: corporate or custom-domain email

The supported path. If you have a corporate email, use it. If not, register a custom domain and route email through it (Cloudflare Email Routing, Google Workspace, ImprovMX) before signing up — \~30 minutes end to end.

1. Sign up at [pagerduty.com/sign-up](https://www.pagerduty.com/sign-up/) with the corporate/custom-domain email. Confirm via the verification email.
2. **Services → New Service**. Name it (e.g. `acme-platform-prod`); pick or create an Escalation Policy.
3. **Integrations → Add an integration → Events API V2**. Name it (e.g. `sariva-platform`).
4. Capture the **integration key** (32-char hex) → goes into secrets as `PAGERDUTY_ROUTING_KEY`.
5. Smoke-test:

   ```bash theme={null}
   curl -X POST https://events.pagerduty.com/v2/enqueue \
     -H 'Content-Type: application/json' \
     -d '{
       "routing_key": "<your-32-char-integration-key>",
       "event_action": "trigger",
       "payload": {
         "summary": "Sariva setup smoke test — please ignore",
         "severity": "info",
         "source": "sariva-customer-setup"
       }
     }'
   ```

   Expect `{"status":"success", ...}` and a new incident in PD. Resolve it manually before continuing.

### Path (b) — PagerDuty Developer signup

If the trial form rejects your email and you can't register a custom domain: sign up at [developer.pagerduty.com](https://developer.pagerduty.com/). The developer tier generally accepts personal-email domains the trial rejects. From account creation on, the steps are identical to path (a) from step 2. Same `events.pagerduty.com/v2/enqueue` endpoint; no code change.

### Path (c) — use xMatters instead

If neither works, [xMatters](https://sariva.mintlify.site/prerequisites/paging/xmatters.md) is a supported provider with a free plan and no email-domain restriction. One provider per install — pick it in the wizard instead of PagerDuty.

⚠WARNING

**Don't use temp-email services.** PD's recovery, MFA reset, and billing flows all rely on a working inbox at the registered address. If the temp inbox is gone when you need recovery, you lose access.

## Configure the Sariva platform

The wizard writes this for you when you pick PagerDuty. Hand-authored `values.yaml` shape (Kubernetes paths):

```yaml theme={null}
paging:
  provider: pagerduty
  pagerduty:
    existingSecret: sariva-platform-extras
    routingKeySecretKey: PAGERDUTY_ROUTING_KEY
```

The integration key itself goes in as `PAGERDUTY_ROUTING_KEY` — into `setup-secret.sh` on the Kubernetes paths, or the `.env` line on the [VM path](https://sariva.mintlify.site/deploy/vm-docker-cc.md#5-fill-the-env) (where the wizard also writes `PAGING_PROVIDER=pagerduty`). **Never** in `values.yaml` or `customer_config.yaml`. One provider per install: in `values.yaml` a block for a provider that is not selected is rejected; on the VM path only the selected provider's `.env` lines are read and any others are ignored.

## Test

```bash theme={null}
sariva validate paging
#   → PagerDuty: sending a test alert to events.pagerduty.com …
#   ✓ Paging                 test alert sariva-validate-20261014T150102Z triggered and resolved (both 202 Accepted)
```

The test incident resolves itself. Distinct failures: `credentials rejected` (the key is not an Events API V2 integration key), `rate-limited` (HTTP 429 — retry in a minute), `unreachable` (allow `events.pagerduty.com:443` from the install). `sariva validate all` only checks the configuration and never sends an alert.

## Limits

* **One incident per episode.** A re-fire (the condition got materially worse) is a new trigger on the same dedup key, which PagerDuty folds into the open incident; the recovery resolves it.
* **A resolve that is not accepted is retried.** Any resolve PagerDuty does not accept — rejected, rate-limited or unreachable — is retried on later checks, up to 10 attempts in total, then dropped with a `paging_resolve_abandoned` log line. A resolve is only sent to the provider that accepted the trigger.
* **A trigger that fails is not retried** — including a rate-limit `429`. The chat alert still posts, but that episode has no incident, so there is nothing to resolve when it clears. The failure is logged as `paging_trigger_failed`.

## Return to the deployment path

> [card] [Back to the AWS EKS path](https://sariva.mintlify.site/deploy/aws-eks-cc.md)
>
> Paging is optional. After you capture the routing key, return to your deployment path and continue with the next card.

> [card] [Back to the VM path](https://sariva.mintlify.site/deploy/vm-docker-cc.md)
>
> Running on a Linux VM? Put the routing key in `.env` and continue the VM checklist.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.