got json code to validate in controller
working instance