// GET: /<controller>/ public IActionResult Index(string code, string state) { var token = AuthorizationCode.ProcessCallback(_spotifyAuthService.GetAuthParameters(), code); //// Use the api with access to personal data. _spotifyAuthService.SetToken(token); return(RedirectToAction("Index", "Admin")); }
public IActionResult FetchToken() { var url = AuthorizationCode.GetUrl(_spotifyAuthService.GetAuthParameters(), ""); return(Redirect(url)); }