moved api endpoint to plog
created RestTask and Emitter interface