Skip to main content

0006: Three-layer documentation, enforced in the build

Status: Accepted ยท Date: 2026-10-01

Contextโ€‹

PVC's documentation strategy (v1.0.0) puts UI pieces in Storybook, system knowledge in Docusaurus, and API and code reference in OpenAPI, XML docs and DocFX. Docs that live outside the repo drift.

Decisionโ€‹

  • Layer 1 (Storybook) doesn't apply: this service has no UI components to share.
  • Layer 2: this handbook, in docs/, built by Docusaurus (website/), broken links fail the build.
  • Layer 3: OpenAPI generated from the endpoints (every operation has a summary, and XML docs become schema descriptions) plus DocFX from the XML docs. CS1591 (missing XML comment) is an error.
  • Event pages are checked against the message contracts by a unit test.
  • All of it is published by the service itself under /docs.

Consequencesโ€‹

  • A PR can't add a public member, an endpoint or a message without documenting it.
  • The Docker build needs Node and DocFX (about a minute more).