iOS Lock V2: Refresh token

Hi,

How to refresh token in auth0 lock v2. I tried to use the delegation api like this

Auth0
                    .authentication(clientId: "clientID", domain: "domain")

                    .delegation(withParameters: "refresh_token" : "refresh Token"])

But JWT id token generated by this process doe not contain all the information. So basically there is difference in payload of JWT id token generated during login and refresh token via delegation.

Please enlighten me on this.

Thanks

Ankit

I wouldn’t recommend the older delegation method, take a look at the iOS Swift User Sessions QuickStart. This covers using the renew method to return a new token using the refresh_token and comes with complete sample source code.