The Schema Validator component performs validation for the POST and PUT methods. Once the Run-time component performs the path validation, it will perform the schema validation.
The validator component will validate the structure of the incoming payload and check if the required fields are available and in the correct format, for example, string vs numeric fields. It will also check for the mandatory fields and the required character lengths. In addition, it will validate the field value against the allowed values for specific fields. Additionally, it will also check the format of date fields and can identify any attempt to update the read-only fields.
The schema Validator component collates all the errors encountered during the schema validation. Then, it passes the errors to the Exception handling component. Worth noting that the validation component will report all the errors collectively to allow for seamless exception management.
For the next level of validation and handling, the Validator component will pass the ownership to the Request and Response Handler component.