Flow baseline

Incoming API events progress through decode, validation, mapping, policy checks, connector execution, and final audit emission. Each stage should complete with deterministic outputs.

Flow phases

Inbound plane

Ingress -> AuthN/AuthZ -> Schema Validation -> Idempotency Check
Reject unauthenticated or malformed requests before any policy expansion.

Transformation plane

Mapper -> Policy Engine -> Entitlement Gate -> Connectors
Keep source-of-truth boundaries explicit and owned.

Operational invariants

Failure branching

Retries follow explicit classification: transport failures can retry, validation failures should not replay without operator correction, and mapping failures should create a remediation task with input diff.

Flow visibility

Request -> Validator -> Attribute Mapper -> Policy Engine -> Connector Adapter -> Audit Sink
Add correlation IDs at ingress so all downstream steps are searchable and explainable.

Filtering and pagination edge behavior

Replay-safe flow pattern

Request with opaque cursor -> Filter validation -> Sorted index query -> Deterministic limit -> Auditable page token
Cursors and sort order must be stable before any mutation path is allowed.