merge REST API: register and login