本文へ移動
cccskills
無料GitHub で公開

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.

インストール方法を見る

含まれるファイル(2)

  • SKILL.md3.7 KB
  • references/sources.md2.2 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

API design

An API is a promise you cannot withdraw once someone depends on it. Design accordingly: the cost of getting it wrong is paid continuously by everyone who integrates.

Model the domain, not the database

Expose concepts the consumer thinks in. An interface that mirrors internal table structure leaks implementation, breaks whenever storage changes, and forces consumers to reconstruct meaning you already had.

Name things as the domain names them. Consistency in naming, casing, date formats and identifier style matters more than any individual choice being optimal — an interface that is uniformly imperfect is learnable, and one that is inconsistently excellent is not.

Errors are part of the contract

Most integrations spend most of their code on failure. Give it the same care as the success path:

  • Distinguish machine-readable code from human-readable message. Consumers branch on the code; the message is for the developer reading logs.
  • Say what to do about it. Retryable or not, and after how long.
  • Never leak internals — stack traces and SQL in error bodies are a security finding as well as bad design.
  • Be consistent about which failures are which status. Validation, authorization, and conflict are different situations and should never share a shape.

Compatibility

Adding an optional field is safe. Removing a field, renaming one, tightening validation, changing a default, or adding a required parameter are all breaking, and the last three break consumers who are doing nothing wrong.

Version when you must break, and be explicit about how long the previous version lives. A deprecation without a date is a deprecation nobody acts on.

Prefer expansion over versioning where possible: a new optional field costs a consumer nothing, a new version costs them a migration.

Pagination, filtering and limits

Any collection that can grow needs pagination from the first release — retrofitting it is a breaking change to every consumer. Prefer cursors over offsets for anything that changes while being read; offset pagination silently skips and duplicates records under concurrent writes.

State rate limits in the contract and communicate them in responses. An undocumented limit is discovered in the consumer's production incident.

Sources

references/sources.md in this skill lists the outside authorities that settle the questions here — what each one is authoritative for, and what you may do with it. Check them before answering on anything they cover, and cite what you used. Most are free to read and not free to reproduce; the use note on each is binding.

Tooling

Specification and documentation: OpenAPI with Redocly, Stoplight, or Scalar; gRPC with protocol buffers where the consumers are internal services, and similar.

Design review and testing: Postman, Insomnia, Bruno, and similar. Contract testing — Pact and similar — is what catches a breaking change before a consumer does.

Generate the documentation from the specification and the specification from or alongside the code. Hand-maintained API documentation is wrong within a release, and being confidently wrong is worse for a consumer than being absent.

Never

  • Expose internal identifiers or storage structure through the interface.
  • Return errors whose meaning must be inferred from the message text.
  • Tighten validation on an existing endpoint and call it non-breaking.
  • Ship a collection endpoint without pagination.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Designs and audits who can reach what — authentication, authorization models, privileged access, service credentials, and joiner-mover-leaver process. Use this to design a permissions model, run an access review, reduce standing privilege, handle offboarding, set up SSO or MFA, manage service and machine credentials, or diagnose why permissions have sprawled.

日本語の概要は準備中です。原文の説明を表示しています。

cbrock84/headcount2,0282026年9月18日 更新

Concentrates marketing and sales effort on a named set of accounts rather than on volume — qualifying whether the model fits your economics at all, building the account list and the buying group inside each, tiering effort against account value, coordinating so the account experiences one campaign rather than several, and measuring account progression instead of leads. Use this to decide whether to run an account-based program, build one, or work out why an existing one produces activity and no pipeline.

日本語の概要は準備中です。原文の説明を表示しています。

cbrock84/headcount2,0282026年9月18日 更新

Gets new users from signup to first real value — signup flow, onboarding, time-to-value, and the early experience that determines whether someone becomes a user or a lapsed account. Use this to design or fix signup and onboarding, diagnose why signups do not convert to active use, reduce time-to-value, or decide what a new user must accomplish first.

日本語の概要は準備中です。原文の説明を表示しています。

cbrock84/headcount2,0282026年9月18日 更新

Designs orchestrator-and-subagent hierarchies for a repository — splitting agents by exclusive write surface, pairing every producer with an independent auditor, and enforcing the split with a script that runs in CI. Use this whenever the user wants to set up, expand, audit, or fix a multi-agent or subagent structure for a codebase; asks how to divide work between agents; wants agent charters, roles, or a surface map written; or is hitting agents that collide on the same files, review their own work, or drift from their remit. Also use when sizing a roster or deciding whether a new agent is justified.

日本語の概要は準備中です。原文の説明を表示しています。

cbrock84/headcount2,0282026年9月18日 更新

Governs models and AI systems in production — intended use, evaluation, monitoring, human oversight, documentation, and the decision to deploy or retire. Use this before deploying a model or AI feature, when defining evaluation criteria, when a model's behavior has drifted, when assessing AI risk or regulatory exposure, or when deciding whether an AI system is fit for a consequential decision.

日本語の概要は準備中です。原文の説明を表示しています。

cbrock84/headcount2,0282026年9月18日 更新

Produces executive-level research — market sizing, competitor mapping, trend analysis, and strategic intelligence — grounded in cited sources with the confidence in each claim made explicit. Use this to analyze a market or industry, map competitors, evaluate a market-entry or build-versus-buy decision, produce a research brief, or assemble evidence for a decision. Also use when comparing options that need a structured, evidence-based verdict rather than an opinion.

日本語の概要は準備中です。原文の説明を表示しています。

cbrock84/headcount2,0282026年9月18日 更新

cbrock84 のスキルをすべて見る

このスキルの問題を報告する