How to validate a payload schema