refactoring to add in merchants_controller and response classes
refactoring common methods into helper