Skip to content

Commit b3935ee

Browse files
authored
exposing rt grant flow as public api (#48)
* exposing rt grant flow as public api
1 parent 7327d0b commit b3935ee

File tree

2 files changed

+14
-11
lines changed

2 files changed

+14
-11
lines changed

src/main/java/com/microsoft/aad/msal4j/ClientApplicationBase.java

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -103,17 +103,8 @@ public CompletableFuture<IAuthenticationResult> acquireToken(AuthorizationCodePa
103103
return this.executeRequest(authorizationCodeRequest);
104104
}
105105

106-
/**
107-
* Acquires a security token from the authority using a Refresh Token
108-
* previously received.
109-
*
110-
* @param parameters#refreshToken Refresh Token to use in the refresh flow.
111-
* @param parameters#scopes scopes of the access request
112-
* @return A {@link CompletableFuture} object representing the
113-
* {@link IAuthenticationResult} of the call. It contains Access
114-
* Token, Refresh Token and the Access Token's expiration time.
115-
*/
116-
CompletableFuture<IAuthenticationResult> acquireToken(RefreshTokenParameters parameters) {
106+
@Override
107+
public CompletableFuture<IAuthenticationResult> acquireToken(RefreshTokenParameters parameters) {
117108

118109
validateNotNull("parameters", parameters);
119110

src/main/java/com/microsoft/aad/msal4j/IClientApplicationBase.java

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,18 @@ public interface IClientApplicationBase {
9292
*/
9393
CompletableFuture<IAuthenticationResult> acquireToken(AuthorizationCodeParameters parameters);
9494

95+
/**
96+
* Acquires a security token from the authority using a Refresh Token previously received.
97+
* Can be used in migration to MSAL from ADAL v2, and in various integration
98+
* scenarios where you have a RefreshToken available.
99+
* See https://aka.ms/msal-net-migration-adal2-msal2.
100+
*
101+
* @param parameters#refreshToken Refresh Token to use in the refresh flow.
102+
* @param parameters#scopes scopes of the access request
103+
* @return A {@link CompletableFuture} object representing the {@link IAuthenticationResult} of the call.
104+
*/
105+
CompletableFuture<IAuthenticationResult> acquireToken(RefreshTokenParameters parameters);
106+
95107
/**
96108
* Returning tokens from cache or requesting new one using previously cached refresh tokens
97109
*

0 commit comments

Comments
 (0)