REFACTOR json request migrating it from views to separate clj file