api-endpoints

Comprehensive guidance for building and changing HTTP API endpoints in the Mossback platform. Covers routes, handlers, controllers, request validation, response shapes, serializers, status codes, erro

SKILL.md

GitHub

API Endpoints

Rules

  • Routes live in src/api/routes/<resource>.ts and are registered in src/api/index.ts.
  • Schemas come from packages/contracts. Do not define one inline.
  • Errors go through problem() in src/api/problem.ts.
  • Run pnpm openapi:write after any route change and commit openapi.json.