1---2name: api-security-automation3description: API security automation skill for REST, GraphQL, gRPC, and WebSocket APIs. Covers OpenAPI/AsyncAPI ingestion, authenticated fuzzing, OWASP API Top 10 (BOLA, BFLA, mass assignment, SSRF), schema diffing, GraphQL introspection abuse, JWT and OAuth misuse, rate-limit and replay testing. Use to automate API assessments with safe, scoped, evidence-backed findings.4---56# API Security Automation78## Authorization Boundary910- Require base URL, environment label (lab/staging/prod), scoped credentials, and rate ceiling.11- Avoid production write endpoints unless explicitly authorized; prefer idempotent or staging traffic.12- Strip tokens and PII from artifacts.1314## Testing Workflow15161. Ingest spec: OpenAPI, GraphQL SDL, gRPC `.proto`, Postman collection, HAR; otherwise crawl with `katana`/`hetty`.172. Build a request matrix per endpoint × role × parameter class (id, enum, nested object, file).183. Auth tests: token tampering, alg=none, kid confusion, audience swap, refresh replay, scope downgrade.194. Object-level auth: enumerate IDs across roles to detect BOLA/IDOR.205. Function-level auth: invoke admin/owner endpoints with low-privilege tokens.216. Mass assignment: inject unexpected fields; observe persisted state changes.227. Input handling: type confusion, prototype pollution, SSRF via URL params, path traversal, deserialization.238. GraphQL: introspection, alias-based rate bypass, batched queries, depth/complexity DoS.249. Rate and replay: nonce reuse, idempotency-key collisions, race conditions on state.2526## Tooling2728- `ffuf`, `wfuzz`, `nuclei` (api templates), `kiterunner`, `mitmproxy`, `hetty`, `graphql-cop`, `clairvoyance`, `jwt_tool`, `restler`, `schemathesis`.2930## Output Contract3132- `spec/`: normalized spec snapshot.33- `requests/`: replayable HAR per finding.34- `findings.jsonl`: `{endpoint, method, role, class, severity, evidence, cwe, remediation}`.35- `report.md`: business impact, top fixes, regression tests as CI hooks.