api-design

api-design is a skill for Claude Code, Codex from medy-gribkov/arcana. It costs 89 tokens per session (3,244 once invoked), scanned A, original, Apache-2.0.

Guidance for designing REST APIs and GraphQL APIs, which are ways for software systems to exchange data. It covers URL structure, requests, errors, authentication, documentation, and GraphQL schemas.

In plain words
What is it for?
Use it when planning or reviewing API endpoints, choosing pagination or filtering, defining error responses, setting up authentication, or writing OpenAPI documentation.
Why use it?
It helps keep an API consistent and predictable as it grows, so client developers know how to use it and teams avoid making incompatible design choices.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: positional $N argument.

Good fit Use it when planning or reviewing API endpoints, choosing pagination or filtering, defining error responses, setting up authentication, or writing OpenAPI documentation.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/medy-gribkov/arcana/api-design
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 medy-gribkov/arcana --skill api-design
Clone the repo
git clone --depth 1 https://github.com/medy-gribkov/arcana

Made for: Claude Code, Codex.

Its marketplace also offers this one on its own, as the plugin api-design/plugin install api-design after adding the marketplace above.

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/medy-gribkov/arcana/api-design.svg)](https://agentmods.dev/skills/medy-gribkov/arcana/api-design)
Your own site
<a href="https://agentmods.dev/skills/medy-gribkov/arcana/api-design"><img src="https://agentmods.dev/badge/skills/medy-gribkov/arcana/api-design.svg" alt="Measured on agentmods" height="20"></a>
Per session 89 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,244 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.00089 $0.03244
Opus 5 $0.00044 $0.01622
Sonnet 5 $0.00018 $0.00649
Haiku 4.5 $0.00009 $0.00324

Measured 7d ago against content hash 4b93099a5bf7, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, 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 7d 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/SKILL.md · 407 lines

How it starts

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

You are an API architect specializing in RESTful API design, GraphQL schema design, and production-grade API patterns for scalability and developer experience.

Use this skill when

  • Designing REST or GraphQL APIs
  • Choosing pagination, filtering, or error response patterns
  • Setting up API authentication and authorization
  • Writing OpenAPI/Swagger specifications
  • Reviewing API design for consistency and best practices

REST Resource Naming

# Resources are nouns, plural, lowercase, hyphen-separated
GET    /api/v1/users                    # list
POST   /api/v1/users                    # create
GET    /api/v1/users/{userId}           # read
PUT    /api/v1/users/{userId}           # full replace
PATCH  /api/v1/users/{userId}           # partial update
DELETE /api/v1/users/{userId}           # delete

# Nested resources for strong parent-child relationships
GET    /api/v1/users/{userId}/orders
POST   /api/v1/users/{userId}/orders

# Actions that don't map to CRUD: use verbs as sub-resources
POST   /api/v1/users/{userId}/activate
POST   /api/v1/orders/{orderId}/cancel
POST   /api/v1/reports/generate

Rules:

  • Never use verbs in resource paths (/getUser, /createOrder are wrong).
  • Use path params for identity (/users/123), query params for filtering (/users?role=admin).
  • Max nesting depth: 2 levels (/users/{id}/orders). Beyond that, promote to top-level with a filter.
  • Use kebab-case for multi-word resources: /order-items, not /orderItems.

HTTP Methods and Status Codes

Method Idempotent Safe Use Case
GET Yes Yes Read resource(s)
POST No No Create resource, trigger action
PUT Yes No Full replace (client sends complete resource)
PATCH No* No Partial update (send only changed fields)
DELETE Yes No Remove resource

Status codes to actually use:

200 OK              - GET success, PUT/PATCH success with body
201 Created         - POST success (include Location header)
204 No Content      - DELETE success, PUT/PATCH success without body
400 Bad Request     - Validation error, malformed request
401 Unauthorized    - Missing or invalid authentication
403 Forbidden       - Authenticated but not authorized
404 Not Found       - Resource doesn't exist (also use for authz to prevent enumeration)
409 Conflict        - Duplicate resource, version conflict
422 Unprocessable   - Semantically invalid (valid JSON, invalid business logic)
429 Too Many Reqs   - Rate limited (include Retry-After header)
500 Internal Error  - Unhandled server error (never expose stack traces)

Read the full file on GitHub · 407 lines

Files

What ships with it

1 file 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. 7d ago First seen · 407 lines · 89 tokens per session scan A 4b93099a5bf7

Subscribe to this mod's changes

api-design is a skill published in the GitHub repository medy-gribkov/arcana (1 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 89 tokens to every session and 3,244 once invoked, about $0.0004 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.