Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Api Test Plan

ASecurity

Plan tests for an API endpoint or service — functional, negative, and contract. Use when asked to test an API, write API test cases, plan REST/GraphQL endpoint testing, or validate an API contract. Produces an API test plan — per-endpoint cases (status codes, schema, auth, validation, errors), boundary/negative cases, contract checks, and non-functional notes — so the API is verified beyond the happy 200.

1,330 stars
0 votes
0 copies
1 views
Added 9/3/2026
ai-agentstestinggitapisecurity

Works with

cliapi

Security Analysis

A100/100

Scanned 9/3/2026

$npx -y skills add mohitagw15856/pm-claude-skills --skill api-test-plan --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Api Test Plan?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Api Test Plan
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/mohitagw15856-api-test-plan/badge)](https://www.skillsdirectory.com/skills/mohitagw15856-api-test-plan)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: api-test-plan
description: "Plan tests for an API endpoint or service — functional, negative, and contract. Use when asked to test an API, write API test cases, plan REST/GraphQL endpoint testing, or validate an API contract. Produces an API test plan — per-endpoint cases (status codes, schema, auth, validation, errors), boundary/negative cases, contract checks, and non-functional notes — so the API is verified beyond the happy 200."
homepage: https://mohitagw15856.github.io/pm-claude-skills/skill/api-test-plan.html
metadata:
  {
    "openclaw": { "emoji": "🧪" }
  }
---

# API Test Plan Skill

APIs fail in specific, testable ways: wrong status codes, schema drift, missing auth checks, sloppy validation,
unhelpful errors. This skill plans the tests that catch them — per endpoint, across the response codes and the
error paths, with contract checks so the API keeps its promises to clients. It tests the whole behaviour, not
just the happy `200`.

## Working from a brief

Given an endpoint or an API description, **produce the test plan anyway** — infer the likely parameters,
responses, auth model, and error cases, labelling assumptions. Always include auth, validation, and negative
cases. Never hand back a question instead of a plan.

## Required Inputs

Ask for these only if they aren't already provided (else infer and label):

- **The API** — REST/GraphQL, the endpoints/operations, and what they do.
- **Contract** — request/response schemas, parameters, status codes (or an OpenAPI/spec if available).
- **Auth & rules** — the auth model (token/scopes/roles), rate limits, and validation rules.
- **Dependencies & data** — downstream services, and the data/state needed to test.

## Output Format

### API Test Plan: [API / endpoint]

**Per endpoint**, a set of cases grouped by type:

| ID | Endpoint | Case | Type | Request | Expected status | Expected body / assertion |
|---|---|---|---|---|---|---|
| API-01 | POST /orders | valid create | Functional | valid payload | 201 | body matches schema, id returned |
| API-02 | POST /orders | missing field | Validation | partial payload | 400 | error names the field |
| API-03 | POST /orders | no token | Auth | valid payload, no auth | 401 | not created |
| API-04 | POST /orders | wrong role | Authz | valid payload, wrong scope | 403 | not created |
| API-05 | GET /orders/{id} | not found | Negative | unknown id | 404 | error body |

Cover deliberately: **happy path** (correct status + schema), **validation** (missing/invalid/extra fields, types, boundaries), **auth/authz** (no token, expired, wrong scope/role), **negative** (not found, conflict, bad method), **idempotency/concurrency** where relevant, and **errors** (correct codes + helpful, consistent error bodies).

**Contract checks** — responses conform to the schema; required fields, types, and status codes match the spec; backward compatibility for existing clients.

**Non-functional notes** — rate limiting, pagination, large payloads, latency expectations, and security basics (no sensitive data leakage, proper status for unauthorised).

**Setup** — test data, environment, and any mocks/stubs for dependencies.

## Quality Checks

- [ ] Each endpoint is tested beyond 200 — error codes (4xx/5xx) and their bodies are asserted
- [ ] Auth and authorization cases are included (no token, expired, wrong scope/role)
- [ ] Validation/boundary/negative cases cover missing, invalid, and extra inputs
- [ ] Responses are checked against the schema/contract, incl. backward compatibility
- [ ] Status codes match the spec and are used correctly (e.g. 401 vs. 403, 400 vs. 422)
- [ ] Non-functional aspects (rate limits, pagination, data leakage) are noted

## Anti-Patterns

- [ ] Do not test only the happy 200 — most API bugs are in validation, auth, and error paths
- [ ] Do not ignore the response schema — a 200 with the wrong body still breaks clients
- [ ] Do not skip authz (role/scope) testing — "logged in" isn't "allowed"
- [ ] Do not assert only status codes — check the body/contract too
- [ ] Do not overlook error-body quality and correct status semantics (401 vs 403, 400 vs 404)

## Based On

API testing practice — contract/schema validation, status-code correctness, auth/authz coverage, and negative/boundary testing beyond the happy path.

Attribution

mohitagw15856mohitagw15856
View sourceSee grades on GitHubMore from mohitagw15856 →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Caveman

Terse caveman voice: answer first, fluff gone, every technical fact kept. Use for /caveman, "caveman mode", "talk like caveman", "be brief", "less tokens". Stays on until "stop caveman" or "normal mode".

1100021 votes

Hyperplan

Adversarial multi-agent planning skill. Self-orchestrates 5 hostile category members (unspecified-low, unspecified-high, deep, ultrabrain, artistry) via team-mode for ruthless cross-critique debate, distills only the defensible insights, then MANDATORILY hands the distilled insight bundle to the `plan` agent for executable plan formalization. Use when planning needs maximum rigor and surfacing of weak assumptions, blind spots, and over-engineering. Triggers: 'hyperplan', 'hpp', '/hyperplan', ...

698621 votes

Writing Skills

Create and manage Claude Code skills in HASH repository following Anthropic best practices. Use when creating new skills, modifying skill-rules.json, understanding trigger patterns, working with hooks, debugging skill activation, or implementing progressive disclosure. Covers skill structure, YAML frontmatter, trigger types (keywords, intent patterns), UserPromptSubmit hook, and the 500-line rule. Includes validation and debugging with SKILL_DEBUG. Examples include rust-error-stack, cargo-dep...

3931 votes

Mcp Code Execution

Routes multi-tool workflows through MCP servers for large datasets and pipelines. Use when Bash tool overhead is limiting throughput on data-heavy tasks.

3421 votes

catchup

Recovers the conversation and failed tool calls of a previous Codex, Amp, Claude Code, Antigravity, Cline, Copilot CLI, Cursor, DeepSeek Harness, Grok Build, Kimi, OpenCode, Pi Agent, or ZCode session. Use when the user says "catch up", "what did the last session do", "get me up to speed", "I switched agents", asks to recover/summarize a previous session before continuing, or asks to diagnose or report a catchup failure. Do NOT use for the current conversation, git history, or any non-agent log.

741 votes
View all in ai-agents →