api-endpoints · git:20261110.8400fe5 · 2026-11-10 · sha256 9dba7510b10ef833

api-endpoints git:20261110.8400fe5A

Immutable. This exact content never changes and is served at /api/v1/blob/9dba7510b10ef833.

No tool to install first
claude plugin marketplace add https://markdownregistry.com/mp/a/art_373ofypby64tzevn/9dba7510b10ef833422b18c8ad0ed27220047c872bbfb3940733f958d4e02533.json

Then /plugin install api-endpoints@markdownregistry-373ofypby64tzevn in Claude Code. It installs this exact version, the one graded A here, pinned to the commit it was graded at, and leaves it there.

---
name: api-endpoints
description: Comprehensive guidance for building and changing HTTP API endpoints in the Mossback platform. Covers routes, handlers, controllers, request validation, response shapes, serializers, status codes, error responses, pagination, filtering, sorting, versioning, authentication middleware, rate limiting, idempotency keys, webhooks, and the OpenAPI document. Also covers how endpoints are registered, how request and response schemas are shared with the web client, and how a breaking change is introduced under a new version. Helps with adding a new endpoint, changing an existing response, debugging a 4xx or 5xx, and keeping the OpenAPI document in step with the code. Use when the user mentions an endpoint, a route, the API, a handler, a request, a response, a status code, a webhook, REST, JSON, or OpenAPI, or asks how the client talks to the server. Always follows the Mossback platform conventions, house style, and established best practices.
---

# 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`.