login with token, first implementation