Added schema validation for posts