api-contract-design

api-contract-design is a skill for Claude Code from rsmdt/the-startup. It costs 44 tokens per session (902 once invoked), scanned A, original, MIT.

A guide for designing REST or GraphQL APIs, which are agreed ways for software systems to exchange data. It covers the contract, naming, errors, authentication, versioning, pagination, and other consumer-facing decisions.

In plain words
What is it for?
Use it to choose an API style, write OpenAPI or Swagger specifications, define authentication and error responses, plan version changes, and design endpoints for web, mobile, or service consumers.
Why use it?
It makes the API predictable for its users and lets teams agree on how endpoints behave before writing the implementation.

Skill for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

Part of the team plugin — 16 skills, 2 agents shipped together

Good fit Use it to choose an API style, write OpenAPI or Swagger specifications, define authentication and error responses, plan version changes, and design endpoints for web, mobile, or service consumers.

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

Made for: Claude Code.

Or install team, the plugin that ships this one along with the rest of its 16 skills, 2 agents.

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-contract-design

README.md
[![agentmods](https://agentmods.dev/badge/skills/rsmdt/the-startup/api-contract-design/github.svg)](https://agentmods.dev/skills/rsmdt/the-startup/api-contract-design)
Your own site
<a href="https://agentmods.dev/skills/rsmdt/the-startup/api-contract-design"><img src="https://agentmods.dev/badge/skills/rsmdt/the-startup/api-contract-design/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-contract-design

Your own site · 80×15
<a href="https://agentmods.dev/skills/rsmdt/the-startup/api-contract-design"><img src="https://agentmods.dev/badge/skills/rsmdt/the-startup/api-contract-design.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 44 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 902 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00044 $0.00902
Opus 5.5 $0.00018 $0.00361
Sonnet 5.5 $0.00009 $0.00180
Haiku 4.5 $0.00004 $0.00090

Measured 1mo ago against content hash 2f8533ee9ca6, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

api-contract-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 1mo 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.

plugins/team/skills/development/api-contract-design/SKILL.md · 119 lines

How it starts

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

Persona

Act as an API design specialist who creates developer-friendly, consistent, and evolvable API contracts. You apply contract-first design principles, ensuring APIs are defined before implementation to enable parallel development and clear communication.

Design Target: $ARGUMENTS

Interface

ApiStyle { type: REST | GRAPHQL | HYBRID versioning: URL_PATH | HEADER | QUERY_PARAM | DUAL auth: API_KEY | OAUTH2 | JWT | NONE }

DesignDecision { area: string // e.g., pagination, error format, naming choice: string // selected approach rationale: string // why this choice fits }

State { target = $ARGUMENTS apiStyle: ApiStyle decisions: DesignDecision[] contract: string }

Constraints

Always:

  • Define the API contract before any implementation begins.
  • Apply consistent naming conventions across all endpoints (plural nouns, kebab-case).
  • Standardize error response format across all endpoints.
  • Include rate limit headers and idempotency keys for non-idempotent operations.
  • Use HTTPS exclusively.
  • Version the API from day one.
  • Document all error codes with resolution steps.
  • Identify at least the primary consumer (web, mobile, server, third-party).
  • Map each use case to specific resource operations.

Never:

  • Expose internal implementation details (database IDs, stack traces) in responses.
  • Use GET for operations with side effects.
  • Mix REST and RPC styles in the same API.
  • Break existing consumers without versioning.
  • Authenticate via query parameters (except OAuth callbacks).
  • Create deeply nested URLs (more than 2 levels).
  • Return different structures for success vs error responses.

Reference Materials

Read the full file on GitHub · 119 lines

Files

What ships with it

6 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. 1mo ago First seen · 119 lines · 44 tokens per session scan A 2f8533ee9ca6

Subscribe to this mod's changes

api-contract-design is a skill published in the GitHub repository rsmdt/the-startup (575 stars, last pushed yesterday), licensed MIT. It adds 44 tokens to every session and 902 once invoked, about $0.0002 per session on Opus 5.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-30.

Related

Other skills, from other repositories

data-engineering

Builds and operates data pipelines — ingestion, transformation, orchestration, quality testing, and reliability of data delivery. Use this to design or debug a pipeline, decide batch versus streaming, add data quality checks, handle late or duplicate data, or work out why a dashboard's numbers changed without anyone…

cbrock84/headcount · 67 tokens

api-design

Designs interfaces that survive their consumers — resource modeling, errors, versioning, pagination, and compatibility. Use this to design a new API, review one before it ships, decide how to version or deprecate, fix an interface consumers keep misusing, or work out whether a change is breaking.

cbrock84/headcount · 64 tokens

python-patterns

Python backend patterns: layered architecture, async I/O, dependency injection, repository/service separation. TRIGGER when: creating routes, models, schemas, or services in a Python backend. SKIP: REST contract design (use api-design); schema/index tuning (use database-optimization). (Examples: FastAPI + SQLAlchemy +…

komluk/scaffolding · 73 tokens

api-design

RESTful API design standards: resource naming, HTTP methods, status codes, pagination, versioning. TRIGGER when: designing new API endpoints, defining error response shapes, or adding pagination/filtering. SKIP: implementing FastAPI route code (use python-patterns); error-handling internals (use error-handling).

komluk/scaffolding · 68 tokens

make-bot-ui

Use when a human invokes this skill to build a webhook UI that wakes a bot. Not for unpreviewed or unapproved credential, host, Tailscale, deployment, remote, paid, or irreversible changes.

OutlineDriven/odin-claude-plugin · 48 tokens

mcp-builder

Use when asked to create an MCP server to integrate an API or service in Python or TypeScript. Not for remote, credential, publish, deploy, or irreversible changes.

OutlineDriven/odin-claude-plugin · 38 tokens