Normalize at the boundary
Column names, identifiers, whitespace, dates and categorical values should be normalized as data enters the workflow. Internal logic should not repeatedly guess what a field means.
Separate missing, invalid and duplicate
These conditions need different decisions. A missing email may be reviewable; an invalid account identifier may block processing; a duplicate event may need an idempotent no-op.
Do not erase evidence
Keep the original input, a transformation summary and a rejected-record output when appropriate. Traceability turns debugging from guesswork into a controlled review.
Only then connect the destination
Once the boundary is explicit, API retries and synchronization logic can be designed safely. The destination receives records with known structure and known exception handling.
Data cleaning is not cosmetic preparation. It is part of the integration architecture.

