# Documentation Structure Standard

Last updated: 2026-02-15

This standard defines strict organization for domain documentation in
`docs/domains/<domain>/`.

## Required Files Per Domain

- `README.md`
- `features.md`
- `architecture.md`
- `developer-guide.md`
- `database.md`
- `api/README.md`
- `service-catalog.md`
- `user-stories.md`

## Required Section Intent

- `README.md`: Domain entrypoint and links to all required docs.
- `features.md`: Feature inventory and capability definition.
- `architecture.md`: System topology and integration boundaries.
- `developer-guide.md`: Build, run, test, and contribution guidance.
- `database.md`: Data schema, storage model, and migration ownership.
- `api/README.md`: API index and references to protocol docs.
- `service-catalog.md`: Manifest-derived list of apps/libs/services.
- `user-stories.md`: Test-evidence-backed user stories.

## Accuracy Rules

- Derive catalogs from `project.json` manifests in `apps/`, `libs/`, and
  `services/`.
- Derive user stories from executable tests under `testing/`.
- Prefer generated inventories over free-form claims.
- Update `docs/reference/domain-documentation-coverage.md` whenever domain docs
  change.

## Regeneration

Run:

```bash
node tools/docs/generate-domain-docs.mjs
```
