Package de.klg71.keycloakmigration.keycloakapi

Types

EmailActions
Link copied to clipboard
enum EmailActions : Enum<EmailActions>
KeycloakApiException
Link copied to clipboard
class KeycloakApiException(message: String, statusCode: Int?) : RuntimeException
KeycloakClient
Link copied to clipboard
interface KeycloakClient

Interface access resources on keycloak. Build with initKeycloakClient

KeycloakLoginClient
Link copied to clipboard
interface KeycloakLoginClient

Interface to get acquire tokens from keycloak. Build with initKeycloakLoginClient

RealmName
Link copied to clipboard
data class RealmName(realm: String)

Functions

clientById
Link copied to clipboard
fun KeycloakClient.clientById(clientId: String, realm: String): Client
clientMapperExistsByName
Link copied to clipboard
fun KeycloakClient.clientMapperExistsByName(clientId: String, mapperName: String, realm: String): Boolean
clientRoleByName
Link copied to clipboard
fun KeycloakClient.clientRoleByName(name: String, clientId: String, realm: String): Role
clientScopeByName
Link copied to clipboard
fun KeycloakClient.clientScopeByName(name: String, realm: String): ClientScope
clientScopeMapperExistsByName
Link copied to clipboard
fun KeycloakClient.clientScopeMapperExistsByName(clientScopeName: String, mapperName: String, realm: String): Boolean
clientScopeUUID
Link copied to clipboard
fun KeycloakClient.clientScopeUUID(clientScopeName: String, realm: String): UUID
clientUUID
Link copied to clipboard
fun KeycloakClient.clientUUID(clientId: String, realm: String): UUID
executionsToImport
Link copied to clipboard
fun KeycloakClient.executionsToImport(realm: String, flowAlias: String): List<AuthenticationExecutionImport>
existsClient
Link copied to clipboard
fun KeycloakClient.existsClient(clientId: String, realm: String): Boolean
existsClientRole
Link copied to clipboard
fun KeycloakClient.existsClientRole(name: String, realm: String, clientId: String): Boolean
existsClientScope
Link copied to clipboard
fun KeycloakClient.existsClientScope(name: String, realm: String): Boolean
existsGroup
Link copied to clipboard
fun KeycloakClient.existsGroup(name: String, realm: String): Boolean
existsRole
Link copied to clipboard
fun KeycloakClient.existsRole(name: String, realm: String): Boolean
existsUser
Link copied to clipboard
fun KeycloakClient.existsUser(name: String, realm: String): Boolean
extractLocationUUID
Link copied to clipboard
fun Response.extractLocationUUID(): UUID
groupByName
Link copied to clipboard
fun KeycloakClient.groupByName(name: String, realm: String): Group
groupUUID
Link copied to clipboard
fun KeycloakClient.groupUUID(group: String, realm: String): UUID
identityProviderByAlias
Link copied to clipboard
fun KeycloakClient.identityProviderByAlias(alias: String, realm: String): IdentityProvider
identityProviderExistsByAlias
Link copied to clipboard
fun KeycloakClient.identityProviderExistsByAlias(alias: String, realm: String): Boolean
identityProviderItems
Link copied to clipboard
fun KeycloakClient.identityProviderItems(realm: String): List<IdentityProviderItem>
identityProviderMapperByName
Link copied to clipboard
fun KeycloakClient.identityProviderMapperByName(identityProviderAlias: String, name: String, realm: String): IdentityProviderMapper
identityProviderMapperExistsByName
Link copied to clipboard
fun KeycloakClient.identityProviderMapperExistsByName(identityProviderAlias: String, name: String, realm: String): Boolean
importFlow
Link copied to clipboard
fun KeycloakClient.importFlow(realm: String, importFlow: ImportFlow): UUID
initKeycloakClient
Link copied to clipboard
fun initKeycloakClient(baseUrl: String, adminUser: String, adminPassword: String, adminUseOauth: Boolean, adminUseOauthLocalPort: Int, realm: String, clientId: String, logger: Logger? = null, totp: String = "", tokenOffsetMs: Long = 1000): KeycloakClient

Builds the KeycloakClient

initKeycloakLoginClient
Link copied to clipboard
fun initKeycloakLoginClient(baseUrl: String, logger: Logger? = null): KeycloakLoginClient

Builds the KeycloakLoginClient Only build this if you just need a token and don't need any other keycloak resources. initKeycloakClient automatically acquires tokens.

isSuccessful
Link copied to clipboard
fun Response.isSuccessful(): Boolean
ldapMapperByName
Link copied to clipboard
fun KeycloakClient.ldapMapperByName(ldapName: String, name: String, realm: String): UserFederationMapper
ldapMapperExistsByName
Link copied to clipboard
fun KeycloakClient.ldapMapperExistsByName(ldapName: String, name: String, realm: String): Boolean
realmById
Link copied to clipboard
fun KeycloakClient.realmById(id: String): Realm
realmExistsById
Link copied to clipboard
fun KeycloakClient.realmExistsById(id: String): Boolean
retryDefaultConfig
Link copied to clipboard
fun retryDefaultConfig(): RetryConfig
roleExistsByName
Link copied to clipboard
fun KeycloakClient.roleExistsByName(name: String, realm: String): Boolean
fun KeycloakClient.roleExistsByName(name: String, realm: String, client: String): Boolean
updateFlowInPlace
Link copied to clipboard
fun KeycloakClient.updateFlowInPlace(realm: String, alias: String, updateFlow: UpdateFlowInPlace)
userByName
Link copied to clipboard
fun KeycloakClient.userByName(name: String, realm: String): User

File contains a lot of convenience functions when interacting with the keycloak client

userExists
Link copied to clipboard
fun KeycloakClient.userExists(user: UUID, realm: String): Boolean
userFederationByName
Link copied to clipboard
fun KeycloakClient.userFederationByName(name: String, realm: String): UserFederation
userFederationExistsByName
Link copied to clipboard
fun KeycloakClient.userFederationExistsByName(name: String, realm: String): Boolean
userUUID
Link copied to clipboard
fun KeycloakClient.userUUID(user: String, realm: String): UUID