Search docs
Docs searchValidation rule
Back to Rule CatalogAP-AUTH-001AuthorizationMissing authorization enforcement
Flags protected operations without clear authorization enforcement evidence.
warningviolationNo auto-fix
How to fix
- Add the expected role, permission, or organization access check.
- Use the local authorization helper used by adjacent endpoints.
- Add tests for allowed and forbidden callers.
What the rule validates
An endpoint or workflow appears to access protected data or actions without an authorization check.
Why it matters
Authentication only identifies a caller; authorization decides whether that caller can perform the action.
Common causes
- A route has authentication but no role/scope check.
- Authorization is hidden in a helper ArchPilot cannot identify.
- A new mutation copied a read-only route pattern.
Typical violation example
PATCH /organizations/:id/policy-config updates policy after only checking that a user is signed in.Typical compliant example
The endpoint requires organization admin access before updating policy configuration.Related rules
AP-AUTH-002 - Inconsistent authorization within resourceAP-AUTH-003 - Authorization logic placed in wrong layer
Adjacent categories
Related files/config
apps/api/srcapps/web/app/apipackages/db/prisma/schema.prisma
Related CLI commands
archpilot validatearchpilot validate --ci
Related docs