共用方式為


RefreshTokenParameters Class

  • java.lang.Object
    • com.microsoft.aad.msal4j.RefreshTokenParameters

Implements

com.microsoft.aad.msal4j.IAcquireTokenParameters

public class RefreshTokenParameters
implements com.microsoft.aad.msal4j.IAcquireTokenParameters

Object containing parameters for refresh token request. Can be used as parameter to PublicClientApplication#acquireToken(RefreshTokenParameters) or to ConfidentialClientApplication#acquireToken(RefreshTokenParameters)

RefreshTokenParameters should only be used for migration scenarios (when moving from ADAL to MSAL). To acquire tokens silently, use acquireTokenSilently(SilentParameters parameters)

Method Summary

Modifier and Type Method and Description
static RefreshTokenParametersBuilder builder(Set<String> scopes, String refreshToken)

Builder for RefreshTokenParameters

ClaimsRequest claims()

Claims to be requested through the OIDC claims request parameter, allowing requests for standard and custom claims

java.util.Map<java.lang.String,java.lang.String> extraHttpHeaders()

Adds additional headers to the token request

java.util.Map<java.lang.String,java.lang.String> extraQueryParameters()

Adds additional parameters to the token request

@lombok.NonNull java.lang.String refreshToken()

Refresh token received from the STS

@lombok.NonNull java.util.Set<java.lang.String> scopes()

Scopes the application is requesting access to

java.lang.String tenant()

Overrides the tenant value in the authority URL for this request

Methods inherited from java.lang.Object

java.lang.Object.clone java.lang.Object.equals java.lang.Object.finalize java.lang.Object.getClass java.lang.Object.hashCode java.lang.Object.notify java.lang.Object.notifyAll java.lang.Object.toString java.lang.Object.wait java.lang.Object.wait java.lang.Object.wait

Method Details

builder

public static RefreshTokenParameters.RefreshTokenParametersBuilder builder(Set scopes, String refreshToken)

Builder for RefreshTokenParameters

Parameters:

scopes - scopes application is requesting access to
refreshToken - refresh token received form the STS

Returns:

builder object that can be used to construct RefreshTokenParameters

claims

public ClaimsRequest claims()

Claims to be requested through the OIDC claims request parameter, allowing requests for standard and custom claims

extraHttpHeaders

public Map extraHttpHeaders()

Adds additional headers to the token request

extraQueryParameters

public Map extraQueryParameters()

Adds additional parameters to the token request

refreshToken

public @NonNull String refreshToken()

Refresh token received from the STS

scopes

public @NonNull Set scopes()

Scopes the application is requesting access to

tenant

public String tenant()

Overrides the tenant value in the authority URL for this request

Applies to