Search docs
Docs searchValidation rule
Back to Rule CatalogAP-API-014API DesignAPI versioning strategy inconsistency
Flags API routes or contracts that do not follow the repository's versioning strategy.
warningviolationNo auto-fix
How to fix
- Move the route under the expected versioned path.
- Update OpenAPI paths to match implementation.
- Document any intentionally unversioned internal endpoint.
What the rule validates
An endpoint appears outside the expected versioned API surface or mixes versioning conventions.
Why it matters
Versioning consistency keeps compatibility and deprecation behavior understandable.
Common causes
- A route was mounted without the /v1 prefix.
- Contract generation includes mixed version paths.
- A new API surface skipped the style decision.
Typical violation example
Most routes use /api/v1, but a new public endpoint is exposed under /api/reports.Typical compliant example
Public endpoints follow /api/v1 unless an ADR documents a different strategy.Related rules
AP-API-010 - Missing pagination on collection endpointAP-API-011 - Bulk operation riskAP-API-012 - DTO/entity leakage through API boundaryAP-API-013 - Inconsistent resource design within API
Adjacent categories
Related files/config
contracts/openapi.yamlapps/api/src
Related CLI commands
archpilot validatearchpilot validate --ci
Related docs