From b8421274b47c6d1778b83c6b0acb70fd82891e71 Mon Sep 17 00:00:00 2001 From: nitrix Date: Wed, 4 Mar 2026 22:08:19 +0100 Subject: [PATCH] Add API-first development methodology to project statutes The OpenAPI spec is the single source of truth for the REST API contract. Endpoints and schemas must be defined in the spec before writing implementation code. Co-Authored-By: Claude Opus 4.6 --- CLAUDE.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CLAUDE.md b/CLAUDE.md index 5eba3bb..835d3a8 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -16,6 +16,7 @@ These are the non-negotiable principles of this project. Every decision — arch ### Methodology - Follow Research → Spec → Test → Implement → Review. No shortcuts. +- API-first development: the OpenAPI spec (`backend/src/main/resources/openapi/api.yaml`) is the single source of truth for the REST API contract. Define endpoints and schemas in the spec first, then generate backend interfaces and frontend types before writing any implementation code. - Never write implementation code without a specification. - Always write tests before implementation (TDD). Red → Green → Refactor. - Refactoring is permitted freely as long as it does not alter the fundamental architecture.