started to refactor web service