Auth0 Home Blog Docs

Auth0Client.LoginAsync() v4.x doesn't return refresh token in a C# WPF app

wpf
refresh-tokens
c
loginasync

#1

Here’s my code:

var auth0 = new Auth0Client(
    Properties.Settings.Default.auth0Domain,
    Properties.Settings.Default.auth0ClientID);
var handle = new WindowInteropHelper(this).Handle;
var windowWrapper = new WindowWrapper(handle);

var user = await auth0.LoginAsync(
    owner: windowWrapper, 
    scope: "openid profile", 
    withRefreshToken: true);

The return value contains a null refresh token. I tried settings device to an arbitrary value, but that didn’t help. I recently switched from Auth0 v3.x to v4.x. Auth0 v3.x returned a refresh token. Did this break in v4.x? If not, what do I need to do to get a refresh token?


#2