get token, minor changes