I am trying to migrate my existing acquire token implementation from ADAL to MSAL. I am able to get the access token and the grant_type=auth_code flow is working fine.
But the issue comes when I am trying to implement the grant_type=refresh_token with scope as offline_access, even though I am able see the refresh_token while debugging the code but since MSAL does not expose refresh_token to the client I do not get that as part of my response.
As per MSAL documentation it says that we should use acquireTokenSilently to get the token once it is expired.
In this link ADAL to MSAL Migration it says that
MSAL for Java has an API that allows you to migrate refresh tokens you acquired with ADAL4j into the ClientApplication: acquireToken(RefreshTokenParameters). With this method, you can provide the previously used refresh token along with any scopes (resources) you desire. The refresh token will be exchanged for a new one and cached for use by your application.
So I am confused with the above line since MSAL will not expose refresh_token how can we create RefreshTokenParameter.
Also I have a use case where I do need to send the refresh_token back to the client.
Can anyone help me by providing further guidance on this.