From afdocs
AI-Friendly Operational Procedures Standard. Use when documenting deployments, rollbacks, backups, restores, scaling, maintenance, migrations, or patching procedures.
How this skill is triggered — by the user, by Claude, or both
Slash command
/afdocs:afopsThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Use this skill to document operational procedures that are fail-safe, composable, and executable by humans or AI agents.
Use this skill to document operational procedures that are fail-safe, composable, and executable by humans or AI agents.
docs/
runbook.md ← index of all procedures (AFADS required)
procedures/
deploy.md ← one file per procedure
rollback.md
backup.md
restore.md
scale.md
...
procedures.yaml ← procedure registry
| Type | Description |
|---|---|
deploy | Deploy or upgrade a component |
rollback | Revert a deployment or change |
backup | Create a backup of data or state |
restore | Restore from a backup |
maintenance | Planned maintenance task (cert rotation, etc.) |
scale | Scale a component up or down |
migrate | Migrate data or configuration |
patch | Apply a security or bug fix patch |
---
procedure_id: deploy-api-service
name: Deploy API Service
type: deploy
component_id: api-service # AFADS component_id
scope: [staging, prod]
criticality: high # low | medium | high | critical
owner: platform-team
last_reviewed: 2026-02-06
requires_approval: true
estimated_duration: 15-30min
depends_on_procedures: [backup-api-db] # optional: must run first
rollback_procedure_id: rollback-api-service # optional
change_window: any # any | maintenance-only | business-hours
notification_channels: ["#prod-ops"] # optional
---
Every procedure MUST include these sections in order:
## Purpose
One to three sentences: what this does and when to use it.
## Prerequisites
### Access Requirements
- kubectl access to cluster: prod
- Helm >= 3.14
### Dependencies
- Procedure `backup-api-db` must complete first
### Approval
- Requires sign-off from: on-call lead
## Pre-flight Checks
1. Verify cluster is healthy: `kubectl get nodes`
**Expected:** All nodes `Ready`
**Abort if:** Any node `NotReady`
## Steps
### Step 1: <title>
**Abort if:** <condition>
**Time limit:** <duration>
**Rollback:** <how to undo this step>
1. <action>
```bash
<command>
Expected: If unexpected:
...
curl https://api.example.com/health
Expected: HTTP 200helm rollback api-service
| Condition | Action | Escalate to | Response time |
|---|---|---|---|
| Step fails after retry | Page on-call | #incident-channel | 15 min |
| Data loss suspected | Stop all changes | Engineering lead | Immediate |
## Procedure Registry (procedures.yaml)
```yaml
procedures:
- procedure_id: deploy-api-service
name: Deploy API Service
type: deploy
component_id: api-service
path: docs/procedures/deploy.md
criticality: high
scope: [staging, prod]
owner: platform-team
last_reviewed: 2026-02-06
procedure_id, don't duplicate stepscomponent_id MUST match an AFADS componentverification_procedure_idprocedure_idhttps://github.com/securitymonster/afdocs/blob/main/OPS-STANDARD.md
npx claudepluginhub securitymonster/afdocs --plugin afdocsGenerates structured operational runbooks for services, incidents, or deployments with prerequisites, step-by-step procedures, rollback steps, and escalation paths.
Generates Markdown runbooks for operational procedures with steps, prerequisites, troubleshooting, rollback, escalation, and history. Use for on-call or ops recurring tasks.
Generates operational runbooks for repeatable incident procedures that any engineer can execute under pressure. Follows Google SRE and PagerDuty best practices.