API Designer
Jeffallan/claude-skills
Designs REST and GraphQL APIs from resource modeling to an OpenAPI 3.1 contract, with versioning, pagination and RFC 7807 error handling.
REST and GraphQL API design principles, versioning, error handling, and documentation patterns
$ npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install cosmicstack-labs/mercury-agent-skills api-design --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/cosmicstack-labs/mercury-agent-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/categories/backend/api-design .claude/skills/api-design && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "api-design" agent skill from https://github.com/cosmicstack-labs/mercury-agent-skills/tree/main/categories/backend/api-design into .claude/skills/api-design/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "api-design", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/cosmicstack-labs/mercury-agent-skills/tree/main/categories/backend/api-designType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install cosmicstack-labs/mercury-agent-skills api-design --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/cosmicstack-labs/mercury-agent-skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/categories/backend/api-design .agents/skills/api-design && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "api-design" agent skill from https://github.com/cosmicstack-labs/mercury-agent-skills/tree/main/categories/backend/api-design into .agents/skills/api-design/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "api-design", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install cosmicstack-labs/mercury-agent-skills api-design --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/cosmicstack-labs/mercury-agent-skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/categories/backend/api-design .cursor/skills/api-design && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "api-design" agent skill from https://github.com/cosmicstack-labs/mercury-agent-skills/tree/main/categories/backend/api-design into .cursor/skills/api-design/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "api-design", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/cosmicstack-labs/mercury-agent-skills.git --path categories/backend/api-design--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install cosmicstack-labs/mercury-agent-skills api-design --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/cosmicstack-labs/mercury-agent-skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/categories/backend/api-design .gemini/skills/api-design && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "api-design" agent skill from https://github.com/cosmicstack-labs/mercury-agent-skills/tree/main/categories/backend/api-design into .gemini/skills/api-design/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "api-design", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install cosmicstack-labs/mercury-agent-skills api-designInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/cosmicstack-labs/mercury-agent-skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/categories/backend/api-design .github/skills/api-design && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "api-design" agent skill from https://github.com/cosmicstack-labs/mercury-agent-skills/tree/main/categories/backend/api-design into .github/skills/api-design/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "api-design", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install cosmicstack-labs/mercury-agent-skills api-design --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/cosmicstack-labs/mercury-agent-skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/categories/backend/api-design .opencode/skills/api-design && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "api-design" agent skill from https://github.com/cosmicstack-labs/mercury-agent-skills/tree/main/categories/backend/api-design into .opencode/skills/api-design/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "api-design", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
api-designREST and GraphQL API design principles, versioning, error handling, and documentation patterns
API Design is an agent skill from cosmicstack-labs/mercury-agent-skills. REST and GraphQL API design principles, versioning, error handling, and documentation patterns
Its SKILL.md is about 1.9k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in Backend & APIs, covering API design and GraphQL. It works with GraphQL. The repository describes itself as: A curated registry of reusable Mercury Agent, Open Claw or Hermes Agent skills designed for real developer workflows, persistent memory, and token-efficient execution. The licence is MIT.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 30392fb. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md (its code samples are json, graphql and yaml).
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
API Design loads about 1.9k tokens when it runs. Until then it costs about 26 tokens; SKILL.md has 580 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from cosmicstack-labs/mercury-agent-skills at commit 30392fb, republished under its MIT licence (© cosmicstack-labs). 580 words, ~1,914 tokens.
.claude/skills/api-design/SKILL.md (or your agent's skills folder).Design APIs that are intuitive, consistent, and a joy to integrate with.
Your API should be predictable. If one resource uses POST /users, another shouldn't use POST /createUser. Patterns should be uniform across the entire surface.
URLs name resources. HTTP verbs name actions. /users is a resource. POST /users creates one. DELETE /users/123 removes one.
Your API's consumers are developers. Good DX means clear errors, thorough documentation, predictable responses, and sensible defaults.
Once a field or endpoint is public, removing it breaks consumers. Version carefully. Add fields, don't remove them. Deprecate before deleting.
| Dimension | Poor | Good | Excellent |
|---|---|---|---|
| URL structure | /getUsers, /create_user | /users, POST /users | /users, /users/:id, with HATEOAS links |
| HTTP methods | All POST | CRUD mapped properly | Proper status codes, idempotency |
| Error format | HTML or plain text | JSON with message | RFC 7807 Problem Details |
| Pagination | None or offset | Cursor-based | Cursor + metadata + total hints |
| Versioning | None | URL prefix /v1/ | Header or content negotiation |
| Documentation | None | Swagger/OpenAPI | Interactive docs with examples |
| Rate limiting | None | X-RateLimit-* headers | Granular per-endpoint limits |
Target: Good for internal APIs. Excellent for public APIs.
Pattern: /{version}/{resource}[/{resource-id}][/{sub-resource}]
# Good
GET /v1/users # List users
POST /v1/users # Create user
GET /v1/users/{id} # Get user by ID
PATCH /v1/users/{id} # Partial update user
DELETE /v1/users/{id} # Delete user
GET /v1/users/{id}/orders # List user's orders
GET /v1/users/{id}/orders/{oid} # Get specific order
# Bad
GET /v1/getUserInfo # Verb in URL
POST /v1/createNewUser # Verb, camelCase
PUT /v1/updateUser # Verb, vague
GET /v1/users_list # Underscore, not a resource
POST /v1/delete_user/123 # POST for deletion, imperative styleNaming conventions:
/users, /orders, /products/order-items, not /orderItems or /order_items/users/123, not /users/123.json| Method | Action | Success Code | Body Contains |
|---|---|---|---|
GET | Retrieve | 200 OK | Resource(s) |
POST | Create | 201 Created | Created resource |
PUT | Full replace | 200 OK | Replaced resource |
PATCH | Partial update | 200 OK | Updated resource |
DELETE | Remove | 204 No Content | (empty) |
Common status codes:
| Code | Meaning | When |
|---|---|---|
| 200 | OK | Successful GET, PUT, PATCH |
| 201 | Created | Successful POST |
| 204 | No Content | Successful DELETE |
| 400 | Bad Request | Malformed input, validation failure |
| 401 | Unauthorized | Missing/invalid auth token |
| 403 | Forbidden | Valid auth but insufficient permissions |
| 404 | Not Found | Resource doesn't exist |
| 409 | Conflict | Duplicate resource, version conflict |
| 422 | Unprocessable | Semantic validation failure |
| 429 | Too Many Requests | Rate limit exceeded |
| 500 | Internal Server Error | Unhandled server error |
Use RFC 7807 (Problem Details):
HTTP/1.1 422 Unprocessable Content
Content-Type: application/problem+json
{
"type": "https://api.example.com/errors/validation-error",
"title": "Validation Error",
"status": 422,
"detail": "The request body contains invalid fields.",
"instance": "/v1/users",
"errors": [
{
"field": "email",
"message": "Must be a valid email address",
"code": "INVALID_FORMAT"
},
{
"field": "age",
"message": "Must be a positive integer",
"code": "OUT_OF_RANGE"
}
]
}Cursor-based pagination (recommended for most APIs):
GET /v1/users?cursor=eyJpZCI6MTB9&limit=20
{
"data": [...],
"pagination": {
"next_cursor": "eyJpZCI6MzB9",
"has_more": true
}
}Offset-based (acceptable for small, stable datasets):
GET /v1/users?page=2&per_page=20
{
"data": [...],
"pagination": {
"page": 2,
"per_page": 20,
"total": 154,
"total_pages": 8
}
}Strategy: URL prefix versioning (most common, clearest)
/v1/users
/v2/usersWhen to bump version:
When NOT to bump version:
type Query {
user(id: ID!): User
}
type User {
id: ID!
name: String!
email: String # Nullable — might be hidden for privacy
orders: [Order!]! # Non-null list, but could be empty
}OpenAPI 3.0 example:
openapi: "3.0.0"
paths:
/v1/users:
get:
summary: List users
parameters:
- name: cursor
in: query
schema: { type: string }
- name: limit
in: query
schema: { type: integer, minimum: 1, maximum: 100, default: 20 }
responses:
"200":
description: Paginated list of users
content:
application/json:
schema:
type: object
properties:
data:
type: array
items: { $ref: "#/components/schemas/User" }
pagination:
$ref: "#/components/schemas/Pagination"/v1/users/{id}/orders/{oid}/items/{iid} — keep nesting to 2-3 levels max.© cosmicstack-labs, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in categories/backend/api-design of cosmicstack-labs/mercury-agent-skills.
Open the folder on GitHubat commit 30392fb
API Design next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| API Design this skillcosmicstack-labs/mercury-agent-skills | 476 | — | ~1.9k | Automated safety check: Pass | MIT | |
| API DesignerJeffallan/claude-skills | 12k | 2 repos | ~2k | Automated safety check: Pass | MIT | |
| Nodejs Backend Patternsever-works/ever-works | 158 | 18 repos | ~4k | Automated safety check: Pass | AGPL-3.0 | |
| API Design Principlesjh941213/my-cc-harness | 126 | 20 repos | ~3.4k | Automated safety check: Pass | None | |
| API And Interface Designdzhalaevd/Donatello | 135 | 9 repos | ~2.6k | Automated safety check: Pass | Apache-2.0 | |
| Designing APIsCloudAI-X/claude-workflow-v2 | 1.4k | 2 repos | ~1.2k | Automated safety check: Pass | MIT |
Jeffallan/claude-skills
Designs REST and GraphQL APIs from resource modeling to an OpenAPI 3.1 contract, with versioning, pagination and RFC 7807 error handling.
ever-works/ever-works
Build production-ready Node.js backend services with Express/Fastify, implementing middleware patterns, error handling, authentication, database integration, and API design best practices.
jh941213/my-cc-harness
REST 및 GraphQL API 설계 원칙 가이드. An agent skill from jh941213/my-cc-harness.
dzhalaevd/Donatello
Guides stable API and interface design. An agent skill from dzhalaevd/Donatello.
CloudAI-X/claude-workflow-v2
Designs REST and GraphQL APIs including endpoints, error handling, versioning, and documentation.
Jeffallan/claude-skills
Designs GraphQL schemas and Apollo Federation graphs, with DataLoader resolvers, subscriptions, query complexity limits and caching.
cosmicstack-labs/mercury-agent-skills
Use this before implementing a product, feature, SaaS, AI app, or side project to score product risk and choose the smallest validation step.
cosmicstack-labs/mercury-agent-skills
HyperFrames CLI dev loop — project scaffolding, validation (lint/inspect), browser preview with live reload, MP4/WebM rendering, and environment troubleshooting (doctor, browser, info, upgrade).
cosmicstack-labs/mercury-agent-skills
Asset preprocessing for HyperFrames compositions — local text-to-speech narration (Kokoro-82M, no API key), audio/video transcription (Whisper), and background removal for transparent overlays…
cosmicstack-labs/mercury-agent-skills
Design and implement agent-to-agent handoff protocols for multi-agent systems.
cosmicstack-labs/mercury-agent-skills
Monitor AI agent health, detect anomalies, set up alerting, and maintain observability dashboards for production multi-agent systems.
cosmicstack-labs/mercury-agent-skills
Design and operate task delegation systems for multi-agent fleets.
Works with
Categories
REST and GraphQL API design principles, versioning, error handling, and documentation patterns. API Design is an agent skill from cosmicstack-labs/mercury-agent-skills.
API Design fits situations like: tasks that involve API design; tasks that involve GraphQL.
Run `npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a claude-code`. Or copy the skill folder (categories/backend/api-design in cosmicstack-labs/mercury-agent-skills) into .claude/skills/api-design in your project. Claude Code loads it when a task matches its description.
Run `npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a codex`. Or copy the skill folder (categories/backend/api-design in cosmicstack-labs/mercury-agent-skills) into .agents/skills/api-design in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add cosmicstack-labs/mercury-agent-skills --skill api-design -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/api-design, .gemini/skills/api-design, .github/skills/api-design and .opencode/skills/api-design in your project.
SKILL.md names no scripts, command-line tools or credentials: API Design is instructions for the agent only.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
API Design is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.9k tokens (SKILL.md is roughly 7.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with API Design: API Designer (Jeffallan/claude-skills, 12k stars), Nodejs Backend Patterns (ever-works/ever-works, 158 stars), API Design Principles (jh941213/my-cc-harness, 126 stars) and API And Interface Design (dzhalaevd/Donatello, 135 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
cosmicstack-labs (a GitHub organization) maintains it in cosmicstack-labs/mercury-agent-skills, which has 476 GitHub stars. The repository holds 12 skills in this directory. The repository was last updated on August 25, 2026.
Source: cosmicstack-labs/mercury-agent-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.