incident-postmortem-writer
Writes a blameless incident postmortem document from an incident timeline or Slack thread.
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Writes a blameless incident postmortem document from an incident timeline or Slack thread.
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
Runs a systematic checklist review on any code diff or file, covering correctness, security, performance, and readability.
Writes a high-quality CLAUDE.md, .cursorrules, or .windsurfrules file that gives a coding agent the right project context, conventions, and constraints to work effectively.
Designs an eval suite for an LLM agent or pipeline including success metrics, trajectory scoring, LLM-as-judge setup, and regression test cases.
Designs a hybrid retrieval pipeline combining dense vector search and BM25 sparse search with reciprocal rank fusion, and explains when to use each configuration.
Converts a workflow description into a LangGraph node/edge graph with typed state, conditional routing, and human-in-the-loop checkpoints.
Audits an AI application for unnecessary token spend and recommends prompt caching, model routing, and token reduction techniques to cut costs.
| name | Incident Postmortem Writer |
| description | Writes a blameless incident postmortem document from an incident timeline or Slack thread. |
| category | productivity |
| tags | ["incidents","postmortem","reliability","sre","documentation"] |
| author | simplyutils |
This skill turns a raw incident timeline, Slack thread dump, or bullet-point notes into a polished, blameless postmortem document. It structures the narrative, extracts action items, identifies contributing factors (not culprits), and formats everything into a document that can be shared with the team and used to prevent future recurrences. The output follows SRE best practices for blameless postmortems.
Use this immediately after an incident is resolved, while details are fresh, to produce the postmortem document without spending hours writing it from scratch.
Copy this file to .agents/skills/incident-postmortem-writer/SKILL.md in your project root.
Then ask:
Provide:
Add the instructions below to your .cursorrules or paste them into the Cursor AI pane. Paste the incident notes.
Paste the incident notes and ask Codex to follow the instructions below to produce the postmortem.
When asked to write a postmortem, follow these steps:
Extract from the raw notes:
Construct a clean, chronological timeline. Format each entry as:
HH:MM UTC — [What happened / what was observed / what action was taken]
Don't editorialize in the timeline — just facts. Reserve analysis for the "Root Cause Analysis" section.
Identify:
Use the 5-Why technique to go beyond the surface cause. The immediate cause is rarely the real root cause.
Action items must be:
# Incident Postmortem — [Short title]
**Date**: [Date of incident]
**Severity**: [SEV1 / SEV2 / SEV3 or equivalent]
**Duration**: [HH:MM] (from first impact to full resolution)
**Status**: [Draft / Under Review / Final]
**Authors**: [Optional: team name or individuals who wrote the postmortem]
---
## Summary
[2–4 sentences. What happened, who was affected, for how long, and what the root cause was. Should be understandable by someone who wasn't involved.]
## Impact
| Metric | Value |
|--------|-------|
| Duration of impact | [e.g., 47 minutes] |
| Users affected | [e.g., ~12,000 active users, 100% of EU region] |
| Requests failed | [e.g., ~8,400 failed API requests] |
| Revenue impact | [if known] |
| Services affected | [list] |
## Timeline
| Time (UTC) | Event |
|------------|-------|
| HH:MM | [Event] |
| HH:MM | [Event] |
...
## Root Cause Analysis
### Immediate Cause
[What technically failed]
### Contributing Factors
- [Factor 1]
- [Factor 2]
### 5-Why Analysis
- Why did X fail? → [Because Y]
- Why did Y happen? → [Because Z]
...
## What Went Well
- [Thing 1]
- [Thing 2]
## What Went Poorly
- [Thing 1]
- [Thing 2]
## Action Items
| Priority | Action | Owner | Due Date |
|----------|--------|-------|----------|
| P1 | [Specific action to prevent recurrence] | [Team] | [Date] |
| P2 | [Specific action to detect faster] | [Team] | [Date] |
| P3 | [Specific action to respond better] | [Team] | [Date] |
## Lessons Learned
[2–3 sentences on the key takeaways from this incident for the organization]
Input to Agent:
"Use the Incident Postmortem Writer skill.
Incident: March 14 2026. Around 2:30am UTC, users started reporting that they couldn't log in. At 2:47am our on-call got paged (from a user report, not our own monitoring). Turned out a deploy at 2:28am had introduced a bug in the JWT validation middleware that rejected all valid tokens. We rolled back at 3:15am and everything recovered by 3:18am. About 15,000 users were affected. The deploy wasn't tested with real JWTs in staging — staging uses mock auth. Action items we know about: fix staging auth to use real JWTs, add a synthetic login monitor."
Output from Agent:
Incident Postmortem — Login Outage (JWT Validation Bug)
Date: 2026-03-14 Severity: SEV1 Duration: 50 minutes (02:28 UTC → 03:18 UTC) Status: Draft
Summary
A deployment at 02:28 UTC introduced a regression in the JWT validation middleware that caused all authenticated requests to be rejected. Users were unable to log in for approximately 50 minutes. The issue was detected via a user report (not automated monitoring) and resolved by rolling back the deployment. Approximately 15,000 active users were affected.
Impact
Metric Value Duration of impact 50 minutes Users affected ~15,000 active users Services affected Authentication service, all authenticated API endpoints Timeline
Time (UTC) Event 02:28 Deployment of auth service v2.4.1 completed 02:28 JWT validation bug introduced; all authenticated requests begin failing 02:30 First user reports of login failure (via support chat) 02:47 On-call engineer paged via user escalation 02:53 Root cause identified as JWT middleware regression 03:15 Rollback to v2.4.0 initiated 03:18 Service fully restored Root Cause Analysis
Immediate Cause
A code change in the JWT validation middleware in v2.4.1 incorrectly invalidated tokens with a valid
iat(issued-at) claim by comparing it against the wrong reference time.Contributing Factors
- Staging environment uses mock authentication; real JWT validation was not exercised before deployment
- No synthetic login monitor existed to detect authentication failures automatically
- On-call was not alerted until 19 minutes after the incident began, relying on a user report
What Went Well
- Root cause was identified quickly once investigation began (6 minutes)
- Rollback was clean and full recovery occurred within 3 minutes of rollback
Action Items
Priority Action Owner Due Date P1 Update staging environment to use real JWT validation instead of mock auth Auth team 2026-03-21 P2 Create synthetic login monitor that alerts if authentication fails Observability team 2026-03-21 P3 Add automated test that validates JWT acceptance/rejection behavior on every deploy Auth team 2026-03-28