Refactored Code into proper directories, added testcases for client and api, added proper configured logging