public class KeycloakOidcRestClient extends Object
Constructor and Description |
---|
KeycloakOidcRestClient() |
Modifier and Type | Method and Description |
---|---|
org.keycloak.representations.AccessTokenResponse |
getKeycloakToken(KeycloakOidcProperties keycloakProperties,
String username,
String password)
Acquires an access token from Keycloak.
|
void |
logout(KeycloakOidcProperties keycloakProperties,
String refreshToken)
Logs out the user from Keycloak and invalidates the refresh tokens
|
public org.keycloak.representations.AccessTokenResponse getKeycloakToken(KeycloakOidcProperties keycloakProperties, String username, String password)
keycloakProperties
- Keycloak deployment propertiesusername
- user loginpassword
- user passwordpublic void logout(KeycloakOidcProperties keycloakProperties, String refreshToken)
keycloakProperties
- Keycloak deployment propertiesrefreshToken
- Refresh token to be invalidated