Search docs

Docs search
Back to Rule Catalog
AP-ARCH-007Architecture

Module contract identity matches registry

Checks that module contract identity and field shape align with the registry.

errorsetup-gapNo auto-fix

How to fix

  1. Update the contract identity to match the registry.
  2. Fix missing or malformed contract fields.
  3. Avoid copying contracts without changing module-specific values.

What it means

A contract file exists, but its declared module identity or expected fields do not match the architecture registry.

Why it matters

Identity mismatches can make a finding look like it belongs to the wrong module.

Common causes

  • A contract was copied between modules.
  • A module was renamed without updating contract identity.
  • The contract schema is incomplete.

Example bad pattern

The billing module contract still declares id: payments.

Example good pattern

The billing contract identity, path, and registry entry all match.

Related files/config

  • .archpilot/architecture.json
  • .archpilot/contracts/*.json

Related CLI commands

  • archpilot validate
  • archpilot validate --ci
AP-ARCH-007 - Module contract identity matches registry | ArchPilot Docs