use of com.nexblocks.authguard.service.model.TokenOptionsBO in project AuthGuard by AuthGuard.
the class AuthorizationCodeToAccessToken method generateToken.
private Either<Exception, AuthResponseBO> generateToken(final AccountTokenDO accountToken) {
final TokenOptionsBO options = TokenOptionsBO.builder().source("aut_code").build();
final TokenRestrictionsBO restrictions = getRestrictions(accountToken);
return accountsServiceAdapter.getAccount(accountToken.getAssociatedAccountId()).map(account -> accessTokenProvider.generateToken(account, restrictions, options));
}
Aggregations