# api-patterns

This skill guides API style choices and covers response structure, versioning, and pagination. Use it when planning an API.

- skill · `type=skill` · Claude Code · 491 installs
- Author: davila7
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/davila7/claude-code-templates/tree/HEAD/cli-tool/components/skills/development/api-patterns
- Updated: 2026-10-24
- HTML: https://affpapa.org/en/nevibecode/skills/api-patterns

## What it does

The skill helps weigh REST, GraphQL, and tRPC against the project context. Its topic files cover response formats, version strategies, pagination, authentication, rate limits, documentation, and security checks. It also prompts the agent to consider who will consume the API before settling on an approach.

The material is split into focused files, so the skill directs attention to the sections relevant to the current request. Recommendations therefore depend on the API question at hand. A Python script checks API endpoints: run it with `python scripts/api_validator.py <project_path>`. The skill can use Read, Write, Edit, Glob, and Grep.

## Install

### Claude Code (native platform)

1. **claude-code-templates**
```bash
npx claude-code-templates@latest --skill development/api-patterns
```

2. **Skills CLI (Vercel)**
```bash
npx skills add davila7/claude-code-templates --skill api-patterns -a claude-code
```

3. **Manually: put the files in place**
- File: `~/.claude/skills/api-patterns/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/api-patterns/

### Codex

**Manually: put the files in place**
- File: `.agents/skills/api-patterns/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

**Manually: put the files in place**
- File: `.cursor/skills/api-patterns/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install davila7/claude-code-templates api-patterns
```

2. **Manually: put the files in place**
- File: `.github/skills/api-patterns/SKILL.md`

### Gemini CLI

**Platform CLI**
```bash
gemini skills install https://github.com/davila7/claude-code-templates --path cli-tool/components/skills/development/api-patterns
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/api-patterns/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/davila7/claude-code-templates/tree/HEAD/cli-tool/components/skills/development/api-patterns

## When to use it
- choose an API style for a project
- define consistent response and error formats
- plan API versioning
- select a pagination approach
- validate project API endpoints

## Example prompts
- Help me choose REST, GraphQL, or tRPC for this project.
- Design response and error formats with pagination for my REST API.
- Check this project's endpoints with `python scripts/api_validator.py <project_path>`.

## Similar
- [mcp-builder](https://affpapa.org/en/nevibecode/skills/mcp-builder.md) — skill · 130949 installs
- [claude-api](https://affpapa.org/en/nevibecode/skills/claude-api.md) — skill · 74198 installs
- [lark-im](https://affpapa.org/en/nevibecode/skills/lark-im.md) — skill · 472900 installs
- [lark-event](https://affpapa.org/en/nevibecode/skills/lark-event.md) — skill · 466800 installs
- [caveman-discover](https://affpapa.org/en/nevibecode/skills/caveman-discover.md) — skill · 104400 installs
- [migration](https://affpapa.org/en/nevibecode/skills/migration.md) — skill · 103900 installs

From the same set: [davila7/claude-code-templates](https://affpapa.org/en/nevibecode/by/davila7/claude-code-templates.md) — 495 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
