Agent skill · Backend & API

api-design

Use when designing or reviewing a public API, exported function signature, module boundary, exported type/interface, or any contract other code depends on

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill api-design-oribarilan-97 --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 13 KB
Bundled scripts: none
Path: skills/api/api-design-oribarilan-97/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# API and Interface Design ## Overview The headline rule, from Scott Meyers (97/55), governs everything else: **make interfaces easy to use correctly and hard to use incorrectly.** Every other decision below is a tactic for that rule — encapsulate behavior so callers can't reach past the contract, lean on the type system so wrong calls fail at compile time. This is a **rigid** skill. Run the decisions in order. If you can't satisfy one, stop and tell the user what's blocking you. ## When to invoke Invoke when you're about to: - Add or change a function/method that will be called from another module, package, service, or repo - Export a new type, interface, trait, protocol, or class - Define a request/response schema, RPC method, or message format - Publish a library, SDK, or plugin contract - Change an existing public signature (parameter order, optionality, return type, thrown errors) - Add or remove a configuration flag, CLI option, or env-var contract that other code reads - Decide what to make `public`, `internal`, `final`, `sealed`, or `private` - Review an API design, interface, or public contract for usability, correctness, or ergonomics If you're not sure whether a change i

What's inside
Steps it walks through
  1. Overview
  2. When to invoke
  3. Non-triggers — do NOT invoke for
  4. API design decisions
  5. Make wrong code look wrong
  6. Encapsulate
  7. Use the type system
  8. API ergonomics
  9. Polymorphism over conditionals
  10. Red Flags
  11. What "done" looks like
  12. Principles in this skill
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the api-design skill do?

Use when designing or reviewing a public API, exported function signature, module boundary, exported type/interface, or any contract other code depends on

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill api-design-oribarilan-97 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going