通过身份验证api Auth0

时间:2017-01-12 06:32:28

标签: authentication auth0

如何使用资源所有者流通过auth0的身份验证api重新发出access_token,同时获取refresh_token和access_token?

我尝试使用以下代码

DelegationRequestBase delegationRequest = new RefreshTokenDelegationRequest(["auth0:ClientId"], ["auth0:ClientId"],refreshToken);

  delegationRequest.Scope = "openid offline_access";
  delegationRequest.GrantType = "refresh_token";

  var res = cl.GetDelegationTokenAsync(delegationRequest).GetAwaiter().GetResult();

但我得到的是异常

  

Auth0.Core.Exceptions.ApiException

消息 不支持refresh_token

还有其他任何接口或方法可以实现吗?

0 个答案:

没有答案