Implement strict validation for payment callbacks
Description
The payment callback endpoints currently process external webhook data without a centralized validation layer. This introduces potential risks related to malformed payloads, inconsistent structures, and unsafe data handling.
This issue proposes implementing strict request validation for all supported payment processor callbacks.
Proposed Solution
Introduce a unified schema-based validation system for incoming webhook requests.
Key tasks:
- Create centralized schema definitions for callback payloads
- Validate all incoming callback requests before business logic execution
- Align callback validation with the project's existing validation patterns
Additional Context
Related TODO:
Validate markers in src/controllers/callbacks/
Implement strict validation for payment callbacks
Description
The payment callback endpoints currently process external webhook data without a centralized validation layer. This introduces potential risks related to malformed payloads, inconsistent structures, and unsafe data handling.
This issue proposes implementing strict request validation for all supported payment processor callbacks.
Proposed Solution
Introduce a unified schema-based validation system for incoming webhook requests.
Key tasks:
Additional Context
Related TODO:
Validate markers in src/controllers/callbacks/