api-design

api-design is a skill for Claude Code, Codex from dunialabs/mcp-servers. It costs 45 tokens per session (3,665 once invoked), scanned A, original, MIT.

A guide for designing REST APIs, which are web interfaces that let software exchange data using standard HTTP requests.

In plain words
What is it for?
Choosing resource names, HTTP methods, status codes, authentication approaches, filtering and pagination rules, and OpenAPI documentation.
Why use it?
It helps keep API URLs, requests, responses, authentication, filtering, and pagination consistent and easier for other developers to use.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/dunialabs/mcp-servers/api-design
Any agent
npx skills add dunialabs/mcp-servers --skill api-design
Clone the repo
git clone --depth 1 https://github.com/dunialabs/mcp-servers

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for api-design

README.md
[![agentmods](https://agentmods.dev/badge/skills/dunialabs/mcp-servers/api-design.svg)](https://agentmods.dev/skills/dunialabs/mcp-servers/api-design)
Your own site
<a href="https://agentmods.dev/skills/dunialabs/mcp-servers/api-design"><img src="https://agentmods.dev/badge/skills/dunialabs/mcp-servers/api-design.svg" alt="Measured on agentmods" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,665 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00045 $0.03665
Opus 5 $0.00023 $0.01833
Sonnet 5 $0.00009 $0.00733
Haiku 4.5 $0.00005 $0.00366

Measured 4d ago against content hash 184d1d9fe434, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

api-design scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

mcp-skills/examples/skills/api-design/SKILL.md · 659 lines

How it starts

The opening of the file, as written. The whole thing — 659 lines — stays where its author put it; the contents beside it link to each section on GitHub.

API Design Best Practices

This skill provides comprehensive guidelines for designing clean, consistent, and developer-friendly RESTful APIs.

Resource Naming

URL Structure

Use nouns, not verbs:

✅ Good:
GET    /users
GET    /users/123
POST   /users
PUT    /users/123
DELETE /users/123

❌ Bad:
GET    /getUsers
POST   /createUser
POST   /updateUser/123
POST   /deleteUser/123

Naming Conventions

  1. Use plural nouns for collections:

    ✅ /users, /products, /orders
    ❌ /user, /product, /order
    
  2. Use lowercase and hyphens for multi-word resources:

    ✅ /user-profiles, /order-items
    ❌ /UserProfiles, /order_items
    
  3. Nested resources for relationships:

    ✅ /users/123/orders
    ✅ /posts/456/comments
    ✅ /products/789/reviews
    
  4. Limit nesting depth (max 2 levels):

    ✅ /users/123/orders/456
    ❌ /users/123/orders/456/items/789/details
    
    Instead use:
    ✅ /order-items/789
    

HTTP Methods

Standard CRUD Operations

Method Action Example Response
GET Retrieve GET /users 200 + list
GET Retrieve one GET /users/123 200 + resource
POST Create POST /users 201 + resource
PUT Update (full) PUT /users/123 200 + resource
PATCH Update (partial) PATCH /users/123 200 + resource
DELETE Delete DELETE /users/123 204 (no content)

When to Use Each Method

GET - Retrieve data:

GET /users?page=1&limit=10
GET /users/123
GET /users/123/orders

Response: 200 OK
{
  "id": 123,
  "name": "John Doe",
  "email": "[email protected]"
}

POST - Create new resource:

POST /users
Content-Type: application/json

{
  "name": "Jane Doe",
  "email": "[email protected]"
}

Response: 201 Created
Location: /users/124
{
  "id": 124,
  "name": "Jane Doe",
  "email": "[email protected]",
  "createdAt": "2024-01-06T10:00:00Z"
}

PUT - Replace entire resource:

PUT /users/123
Content-Type: application/json

{
  "name": "John Smith",
  "email": "[email protected]",
  "phone": "+1234567890"
}

Response: 200 OK
{
  "id": 123,
  "name": "John Smith",
  "email": "[email protected]",
  "phone": "+1234567890",
  "updatedAt": "2024-01-06T10:00:00Z"
}

Read the full file on GitHub · 659 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 659 lines · 45 tokens per session scan A 184d1d9fe434

Subscribe to this mod's changes

api-design is a skill published in the GitHub repository dunialabs/mcp-servers (7 stars, last pushed 4mo ago), licensed MIT. It adds 45 tokens to every session and 3,665 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.