api-and-interface-design

Guides design and review of API contracts, versioning, pagination, idempotency, and auth boundaries.

1|Updated Sep 10, 2026
One-click install
npx skills add https://github.com/thienty1207/Hotel_Staff --skill api-and-interface-design-thienty1207
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: api-and-interface-design
Source: https://github.com/thienty1207/Hotel_Staff/tree/main/.baron/core/skills/api-and-interface-design
Command: npx skills add https://github.com/thienty1207/Hotel_Staff --skill api-and-interface-design-thienty1207

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Changing or adding APIs without a clear contract process leads to broken clients, inconsistent error schemas, missing auth checks, and unbounded list endpoints. This Skill provides a structured, evidence-based checklist for designing and reviewing interface boundaries before changes ship. ## Core Features & Use Cases - Contract and Compatibility Review: Maps callers, request/response shapes, versioning, and migration windows before proposing breaking changes. - Boundary Safety Rules: Enforces server-side auth checks, idempotency for payments and webhooks, bounded pagination, and consistent machine-readable error schemas. - Use Case: When adding a new REST endpoint to a Go backend, use this Skill to verify the auth boundary, define pagination limits and stable sorting, design the error schema, and produce a verification plan with contract tests. ## Quick Start Ask the AI to review the new endpoint you are adding for contract shape, auth boundary, pagination, idempotency, and backward compatibility using this Skill.

Frequently Asked Questions about api-and-interface-design

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I design a REST API without breaking existing clients?

Prefer additive changes over modifications, use a compatibility window for breaking changes, and never silently rename or remove response fields. This Skill walks through caller mapping, versioning strategy, and backward-compatibility proof with old-shape requests.

How to add pagination to a list API endpoint?

Define a default and maximum limit, choose cursor pagination for large or frequently changing collections, and enforce stable sorting. List endpoints must never return unbounded records, and filter interactions plus empty-state behavior should be documented.

When should an API require idempotency keys?

Idempotency keys or dedupe records are required for retry-prone writes such as payments, subscription changes, imports, uploads, webhooks, and order creation. The response behavior for duplicates must be predictable: same response, conflict, or status lookup.

What should an API error schema include?

Use consistent machine-readable error codes, preserve HTTP status semantics, and differentiate validation, auth, permission, not-found, conflict, rate-limit, and dependency failures. Never leak stack traces, database names, file paths, or internal IDs to clients.

When should I not use this API design guidance?

Skip it for implementation-only refactors that keep all interface behavior identical. It is intended for tasks that add or change endpoints, contracts, auth boundaries, or versioning, not internal code cleanup with no caller-visible change.