refactor(service): adopt the module revealing pattern to hide variables