api-design-guide

api-design-guide is a skill for Claude Code, Codex from The-AI-Directory-Company/agents-and-skills. It costs 40 tokens per session (1,397 once invoked), scanned A, original, MIT.

A guide for planning REST and GraphQL APIs, which let other software request and change data. It covers resource names, HTTP methods, versioning, pagination, errors, authentication, and rate limits.

In plain words
What is it for?
Use it to create an API specification for internal services, mobile apps, web applications, or third-party developers.
Why use it?
It helps teams avoid inconsistent endpoints and breaking changes that make an API difficult for applications to use.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to create an API specification for internal services, mobile apps, web applications, or third-party developers.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/the-ai-directory-company/agents-and-skills/api-design-guide
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.

Any agent
npx skills add The-AI-Directory-Company/agents-and-skills --skill api-design-guide
Clone the repo
git clone --depth 1 https://github.com/The-AI-Directory-Company/agents-and-skills

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-guide

README.md
[![agentmods](https://agentmods.dev/badge/skills/the-ai-directory-company/agents-and-skills/api-design-guide/github.svg)](https://agentmods.dev/skills/the-ai-directory-company/agents-and-skills/api-design-guide)
Your own site
<a href="https://agentmods.dev/skills/the-ai-directory-company/agents-and-skills/api-design-guide"><img src="https://agentmods.dev/badge/skills/the-ai-directory-company/agents-and-skills/api-design-guide/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for api-design-guide

Your own site · 80×15
<a href="https://agentmods.dev/skills/the-ai-directory-company/agents-and-skills/api-design-guide"><img src="https://agentmods.dev/badge/skills/the-ai-directory-company/agents-and-skills/api-design-guide.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,397 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00040 $0.01397
Opus 5 $0.00020 $0.00698
Sonnet 5 $0.00008 $0.00279
Haiku 4.5 $0.00004 $0.00140

Measured 8d ago against content hash 486c56212cce, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

api-design-guide 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 8d 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.

skills/api-design-guide/SKILL.md · 130 lines

How it starts

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

API Design Guide

Before you start

Gather the following from the user:

  1. What resources does the API expose? (Users, orders, products, etc.)
  2. Who are the consumers? (Internal services, third-party developers, mobile apps, SPAs)
  3. REST, GraphQL, or both? Default to REST for CRUD-heavy services, GraphQL for query-heavy frontends.
  4. Auth requirements? (API keys, OAuth 2.0, JWT, session-based)
  5. Expected traffic volume? (Drives rate limiting and pagination decisions)
  6. Versioning constraints? (Breaking changes expected? Public vs. internal?)

If the user says "design an API for X" without specifics, push back: "What operations do consumers need to perform? What data do they send and receive?"

API design template

1. Resource Naming

Use plural nouns for collections. Resources are things, not actions.

Good: /users, /orders, /order-items Bad: /getUsers, /createOrder, /user_list, /OrderItem

  • Lowercase with hyphens for multi-word resources (/order-items, not /orderItems)
  • Nouns only — never verbs in the URL path
  • Nest to express ownership: /users/{id}/orders — limit nesting to two levels

2. HTTP Methods

Method Purpose Idempotent Success Code
GET Read resource(s) Yes 200
POST Create resource No 201
PUT Full replace Yes 200
PATCH Partial update No 200
DELETE Remove resource Yes 204

Use POST for actions that don't map to CRUD: POST /orders/{id}/cancel.

3. Request/Response Formats

Always use JSON. Wrap collection responses — never return a bare array:

{
  "data": [{ "id": "usr_01", "name": "Alice" }],
  "meta": { "total": 142, "page": 1, "per_page": 20 }
}

4. Error Handling

Return a consistent error envelope on every failure:

{
  "error": {
    "code": "VALIDATION_ERROR",
    "message": "Email address is invalid.",
    "details": [{ "field": "email", "reason": "Must be a valid email address." }],
    "request_id": "req_abc123"
  }
}

Read the full file on GitHub · 130 lines

Files

What ships with it

7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 8d ago First seen · 130 lines · 40 tokens per session scan A 486c56212cce

Subscribe to this mod's changes

api-design-guide is a skill published in the GitHub repository The-AI-Directory-Company/agents-and-skills (2 stars, last pushed 5mo ago), licensed MIT. It adds 40 tokens to every session and 1,397 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-09-03.

Related

Other skills, from other repositories

email-systems

Transactional email (Resend, SendGrid, SES), templates (React Email, MJML), deliverability (SPF/DKIM/DMARC), and inboxing best practices. Use when building email infrastructure, designing templates, or troubleshooting deliverability.

travisjneuman/.claude · 55 tokens

event-driven-architecture

Kafka, RabbitMQ, SQS/SNS, event sourcing, CQRS, saga patterns, dead letter queues, and idempotency. Use when designing asynchronous systems, implementing message-driven workflows, or building event streaming pipelines.

travisjneuman/.claude · 50 tokens

graphql-expert

GraphQL API design and implementation. Use when building GraphQL APIs, designing schemas, implementing resolvers, or optimizing GraphQL performance.

travisjneuman/.claude · 31 tokens

devex-sdk-design

Developer experience (DX) engineering, SDK design patterns, API ergonomics, CLI tooling design, documentation-driven development, and developer onboarding. Use when designing SDKs, improving API ergonomics, building developer tools, or creating developer documentation.

travisjneuman/.claude · 52 tokens

edge-computing

Edge computing with Cloudflare Workers, Deno Deploy, Bun, Vercel Edge Functions, AWS Lambda@Edge, and edge databases (Turso, D1, DynamoDB Global Tables). Use when building low-latency edge applications, edge-side rendering, or globally distributed compute.

travisjneuman/.claude · 63 tokens

hunt-auth-bypass

Hunting skill for auth bypass vulnerabilities. Built from 4 public bug bounty reports. Use when hunting auth bypass on any target.

adriannoes/awesome-agentic-ai · 31 tokens