sre-pagerduty-opsgenie
Skill4 starsChanged 25 days agoMITView on GitHub
Use for on-call, incident and handoff tasks in PagerDuty or Opsgenie: who is on call, open incidents/alerts, escalation policies, timelines, capped page counts. Writes need approval.
- Reads credentials
In this repository84 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .github/copilot-instructions.mdCopilot instructions
- .cursor/rules/sre-safety-gates.mdcCursor rule
- sre-awsSkill
- sre-azureSkill
- sre-capacity-planningSkill
- sre-change-safetySkill
- sre-chaos-engineeringSkill
- sre-cloud-cost-reviewSkill
- sre-database-triageSkill
- sre-datadogSkill
- sre-dependency-mappingSkill
- sre-diagnosticsSkill
- sre-dr-backup-testSkill
- sre-dynatraceSkill
- sre-emudhra-ca-checkSkill
- sre-engineerSkill
- sre-expiry-auditSkill
- sre-gcpSkill
- sre-incident-commandSkill
- sre-incident-communicationSkill
- sre-k8s-safe-remediationSkill
- sre-k8s-triageSkill
- sre-k8s-upgrade-autopilotSkill
- sre-message-queue-triageSkill
- sre-migration-safetySkill
- sre-observability-cost-cutterSkill
- sre-observability-query-cookbookSkill
- sre-oncall-auditSkill
- sre-oncall-handoffSkill
- sre-php2shell-checkSkill
- sre-postmortem-templatesSkill
- sre-production-readinessSkill
- sre-prometheus-grafanaSkill
- sre-remediation-actionsSkill
- sre-runbook-templatesSkill
- sre-safety-gatesSkill
- sre-security-incident-triageSkill
- sre-service-mesh-triageSkill
- sre-slo-alertingSkill
- sre-slo-burn-rate-rulesSkill
- sre-terraformSkill
- sre-toil-reviewSkill
- sre-awsSkill
- sre-azureSkill
- sre-capacity-planningSkill
- sre-change-safetySkill
- sre-chaos-engineeringSkill
- sre-cloud-cost-reviewSkill
- sre-database-triageSkill
- sre-datadogSkill
- sre-dependency-mappingSkill
- sre-diagnosticsSkill
- sre-dr-backup-testSkill
- sre-dynatraceSkill
- sre-emudhra-ca-checkSkill
- sre-engineerSkill
- sre-expiry-auditSkill
- sre-gcpSkill
- sre-incident-commandSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 4 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 12
Wait for explicit human approval before any prod-changing command, MCP write tool, or external post.
- Distinctive: line 23
Never create test incidents on real services: Use a sandbox service / escalation policy.
- Very specific: line 41
Use the bundled GET-only scripts.
- Distinctive: line 52
Every script exits 2 with nothing on stdout when the key is missing, the region is wrong, the API is unreachable or it returns an HTTP …
- Distinctive: line 66
If neither the MCP server nor the API keys are available, output the commands for the human and stop.
≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
PagerDuty and Opsgenie
Safety gates (REQUIRED)
- Read-only diagnosis first.
- Propose each change with risk (low/med/high) and reversibility.
- Wait for explicit human approval before any prod-changing command, MCP write tool, or external post.
- Act only as approved, verify, and stop and escalate if anything gets worse.
Full rules: sre-safety-gates. Read-only MCP setup: sre-safety-gates/references/mcp.md.
Process skills: sre-incident-command, sre-oncall-handoff, sre-oncall-audit, sre-toil-review, sre-postmortem-templates. MCP setup detail: references/mcp-setup.md.
Rules
- Confirm account and region before any write (US vs EU; which subdomain).
- Never echo tokens or use
curl -v(it prints auth headers). Use env vars. - Never create test incidents on real services. Use a sandbox service / escalation policy.
Writes needing approval
Acknowledge, resolve, reassign, add note, add responders, start incident workflow, create incident / trigger page, schedule overrides, status-page posts, team or service changes (create/update/delete), Opsgenie acknowledge/close/assign.
PagerDuty
MCP
- Hosted MCP
https://mcp.pagerduty.com/mcp(EU:https://mcp.eu.pagerduty.com/mcp) exposes read and write tools, e.g.manage_incidents(create/update/add_note/add_responders/start_workflow),manage_schedules(create_override),manage_status_pages,manage_teams(delete). It has no tool filtering: restrict it with a scoped OAuth client or a read-only user, and add Claude Code deny rules (sre-safety-gates/references/mcp.md). Source: https://support.pagerduty.com/main/docs/pagerduty-mcp-server - Auth: OAuth or header
Authorization: Token token=<api-key>. No Dynamic Client Registration, so Claude Code OAuth needs a fixedclientIdandcallbackPort. - Archived local server (deprecated): package
pagerduty-mcp, runuvx pagerduty-mcp, envPAGERDUTY_USER_API_KEY; read-only unless--enable-write-tools.
REST (read-only)
Env (one set for scripts and snippets): PD_API_KEY (read-only REST key), PD_REGION=us|eu, OG_API_KEY, OG_REGION=us|eu, PD_ROUTING_KEY (Events API only). Hosts and auth: references/regions-and-auth.md.
Use the bundled GET-only scripts. They send keys over stdin, retry HTTP 429, and cap pagination at MAX_PAGES (default 20 pages of 100):
bash scripts/pd_oncall.sh # who is on call now
bash scripts/pd_incidents.sh --status triggered --status acknowledged # open incidents (table)
bash scripts/pd_incidents.sh --since <ISO8601> --until <ISO8601> --json > "$W/pages.jsonl" && grep -c . "$W/pages.jsonl" # page count; W="$(mktemp -d)"
bash scripts/pd_audit_schedules.sh --since <ISO8601> --until <ISO8601> # see sre-oncall-audit
bash scripts/og_alerts.sh --query 'status:open'
bash scripts/og_oncall.sh --schedule <schedule-name>Every script exits 2 with nothing on stdout when the key is missing, the region is wrong, the API is unreachable or it returns an HTTP error. Treat that as "data unavailable", never as nobody on call or zero incidents.
Raw REST calls (paginated, projected and capped helpers, plus marked writes): references/api-reference-pagerduty.md, references/api-reference-opsgenie.md. Run the offline tests with bash scripts/tests/run_tests.sh.
Paging (Events API v2, approval required)
Paging uses the Events API v2 with an integration routing key (PD_ROUTING_KEY, not the REST key). Always set a dedup_key; sandbox services only for tests. Details: references/events-api-v2.md.
Opsgenie
Lifecycle: end of sale 2025-06-04; end of support 2027-04-05, when access is shut off and unmigrated data is deleted. Source: https://www.atlassian.com/licensing/opsgenie. Migration plan and export: references/opsgenie-migration.md (time-bounded).
Auth Authorization: GenieKey $OG_API_KEY; OG_HOST always includes the scheme (https://api.opsgenie.com, EU https://api.eu.opsgenie.com). Acknowledge/close are writes and async (202 + requestId; check /v2/alerts/requests/<requestId>). The /v1/incidents?query= endpoint is unverified.
If neither the MCP server nor the API keys are available, output the commands for the human and stop.
Output
- On-call names, incident/alert lists with IDs and links, timelines for postmortems, paginated page counts for handoff/toil
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

