Class KeycloakAdminController
java.lang.Object
com.arms.api.keycloak.admin.controller.KeycloakAdminController
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddGroupRoles(String realm, String groupId, List<org.keycloak.representations.idm.RoleRepresentation> roleRepresentations, org.springframework.web.server.ServerWebExchange exchange) reactor.core.publisher.Mono<Void>addMappingGroup(String realm, String user, String groupId) reactor.core.publisher.Mono<Void>addMappingRoles(String realm, String user, List<org.keycloak.representations.idm.RoleRepresentation> rolesToAdd) reactor.core.publisher.Mono<Void>configureSmtp(org.springframework.web.server.ServerWebExchange exchange, String realmName) voidcreateChildGroup(org.springframework.web.server.ServerWebExchange exchange, String realm, String groupId, org.keycloak.representations.idm.GroupRepresentation groupRepresentation) voidcreateGroup(org.springframework.web.server.ServerWebExchange exchange, String realm, org.keycloak.representations.idm.GroupRepresentation groupRepresentation) voidcreateRole(String realm, org.keycloak.representations.idm.RoleRepresentation roleRepresentation) reactor.core.publisher.Mono<Void>createUser(String realm, CreateUserVO createUserVO) voiddeleteGroup(org.springframework.web.server.ServerWebExchange exchange, String realm, String groupId) voiddeleteGroupRoles(String realm, String groupId, List<org.keycloak.representations.idm.RoleRepresentation> roleRepresentations, org.springframework.web.server.ServerWebExchange exchange) reactor.core.publisher.Mono<Void>deleteMappingGroup(String realm, String user, String groupId) reactor.core.publisher.Mono<Void>deleteMappingRoles(String realm, String user, List<org.keycloak.representations.idm.RoleRepresentation> rolesToRemove) voideditGroup(org.springframework.web.server.ServerWebExchange exchange, String realm, String groupId, org.keycloak.representations.idm.GroupRepresentation groupRepresentation) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.GroupRepresentation>>getAccessControlGroups(org.springframework.web.server.ServerWebExchange exchange, String realm) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.UserRepresentation>>getAccessControlUsers(org.springframework.web.server.ServerWebExchange exchange, String realm) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>>getAssignedRoles(String realm, String groupId, org.springframework.web.server.ServerWebExchange exchange) reactor.core.publisher.Mono<org.keycloak.admin.client.token.TokenManager>getAuthToken(org.springframework.web.server.ServerWebExchange exchange) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>>getAvailableRoles(String realm, String groupId, org.springframework.web.server.ServerWebExchange exchange) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.ClientRepresentation>>reactor.core.publisher.Mono<List<org.keycloak.representations.idm.ClientRepresentation>>getClients(org.springframework.web.server.ServerWebExchange exchange, String realm) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>>getComposite(String realm, String groupId, org.springframework.web.server.ServerWebExchange exchange) List<org.keycloak.representations.idm.GroupRepresentation>getFlattenGroup(List<org.keycloak.representations.idm.GroupRepresentation> groupRepresentationList, org.keycloak.representations.idm.GroupRepresentation group) reactor.core.publisher.Mono<org.keycloak.representations.idm.GroupRepresentation>reactor.core.publisher.Mono<List<org.keycloak.representations.idm.GroupRepresentation>>getGroupMappings(String realm, String user) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.UserRepresentation>>getGroupMembers(String realm, String groupId, org.springframework.web.server.ServerWebExchange exchange) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.GroupRepresentation>>reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RealmRepresentation>>getRealms(org.springframework.web.server.ServerWebExchange exchange) reactor.core.publisher.Mono<org.keycloak.representations.idm.RealmRepresentation>reactor.core.publisher.Mono<org.keycloak.representations.idm.RoleRepresentation>reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>>getRoleMappings(String realm, String user) reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>>reactor.core.publisher.Mono<org.keycloak.representations.idm.UserRepresentation>reactor.core.publisher.Mono<List<org.keycloak.representations.idm.UserRepresentation>>reactor.core.publisher.Mono<Set<org.keycloak.representations.idm.UserRepresentation>>getUsersInRole(org.springframework.web.server.ServerWebExchange exchange, String realm, String role) voidremoveRole(String realm, String role) voidremoveUser(String realm, String user) reactor.core.publisher.Mono<Void>resetPassword(String realm, String user, org.keycloak.representations.idm.CredentialRepresentation credentialRepresentation) reactor.core.publisher.Mono<Void>testSMTPConnection(org.springframework.web.server.ServerWebExchange exchange, String realm, org.keycloak.representations.idm.RealmRepresentation realmRepresentation) reactor.core.publisher.Mono<Void>updateRealm(org.springframework.web.server.ServerWebExchange exchange, String realm, org.keycloak.representations.idm.RealmRepresentation realmRepresentation) voidupdateRole(String realm, String role, org.keycloak.representations.idm.RoleRepresentation roleRepresentation) voidupdateUser(String realm, String user, org.keycloak.representations.idm.UserRepresentation userRepresentation)
-
Constructor Details
-
KeycloakAdminController
public KeycloakAdminController()
-
-
Method Details
-
getAuthToken
@GetMapping("/auth-admin/token") @ResponseBody public reactor.core.publisher.Mono<org.keycloak.admin.client.token.TokenManager> getAuthToken(org.springframework.web.server.ServerWebExchange exchange) -
getRealms
@GetMapping("/auth-admin/realms/") @ResponseBody public reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RealmRepresentation>> getRealms(org.springframework.web.server.ServerWebExchange exchange) -
getRealms
@GetMapping("/auth-admin/realms/{realm}") @ResponseBody public reactor.core.publisher.Mono<org.keycloak.representations.idm.RealmRepresentation> getRealms(org.springframework.web.server.ServerWebExchange exchange, @PathVariable("realm") String realm) -
updateRealm
-
testSMTPConnection
-
configureSmtp
-
getClients
-
getClient
@GetMapping("/auth-admin/realms/{realm}/client-id/{clientId}") @ResponseBody public reactor.core.publisher.Mono<List<org.keycloak.representations.idm.ClientRepresentation>> getClient(org.springframework.web.server.ServerWebExchange exchange, @PathVariable("realm") String realm, @PathVariable("clientId") String clientId) -
getGroups
-
getGroup
@GetMapping("/auth-admin/realms/{realm}/groups/{group-id}") @ResponseBody public reactor.core.publisher.Mono<org.keycloak.representations.idm.GroupRepresentation> getGroup(org.springframework.web.server.ServerWebExchange exchange, @PathVariable("realm") String realm, @PathVariable("group-id") String groupId) -
editGroup
@PutMapping("/auth-admin/realms/{realm}/groups/{group-id}") @ResponseBody public void editGroup(org.springframework.web.server.ServerWebExchange exchange, @PathVariable("realm") String realm, @PathVariable("group-id") String groupId, @RequestBody org.keycloak.representations.idm.GroupRepresentation groupRepresentation) -
deleteGroup
-
createGroup
@PostMapping("/auth-admin/realms/{realms}/groups") public void createGroup(org.springframework.web.server.ServerWebExchange exchange, @PathVariable("realms") String realm, @RequestBody org.keycloak.representations.idm.GroupRepresentation groupRepresentation) -
createChildGroup
@PostMapping("/auth-admin/realms/{realms}/groups/{group-id}/children") public void createChildGroup(org.springframework.web.server.ServerWebExchange exchange, @PathVariable("realms") String realm, @PathVariable("group-id") String groupId, @RequestBody org.keycloak.representations.idm.GroupRepresentation groupRepresentation) -
getComposite
@GetMapping("/auth-admin/realms/{realm}/groups/{group-id}/role-mappings/realm/composite") @ResponseBody public reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>> getComposite(@PathVariable("realm") String realm, @PathVariable("group-id") String groupId, org.springframework.web.server.ServerWebExchange exchange) -
getAvailableRoles
@GetMapping("/auth-admin/realms/{realm}/groups/{group-id}/role-mappings/realm/available") @ResponseBody public reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>> getAvailableRoles(@PathVariable("realm") String realm, @PathVariable("group-id") String groupId, org.springframework.web.server.ServerWebExchange exchange) -
getAssignedRoles
@GetMapping("/auth-admin/realms/{realm}/groups/{group-id}/role-mappings/realm") @ResponseBody public reactor.core.publisher.Mono<List<org.keycloak.representations.idm.RoleRepresentation>> getAssignedRoles(@PathVariable("realm") String realm, @PathVariable("group-id") String groupId, org.springframework.web.server.ServerWebExchange exchange) -
addGroupRoles
@PostMapping("/auth-admin/realms/{realm}/groups/{group-id}/role-mappings/realm") public void addGroupRoles(@PathVariable("realm") String realm, @PathVariable("group-id") String groupId, @RequestBody List<org.keycloak.representations.idm.RoleRepresentation> roleRepresentations, org.springframework.web.server.ServerWebExchange exchange) -
deleteGroupRoles
@DeleteMapping("/auth-admin/realms/{realm}/groups/{group-id}/role-mappings/realm") public void deleteGroupRoles(@PathVariable("realm") String realm, @PathVariable("group-id") String groupId, @RequestBody List<org.keycloak.representations.idm.RoleRepresentation> roleRepresentations, org.springframework.web.server.ServerWebExchange exchange) -
getGroupMembers
@GetMapping("/auth-admin/realms/{realm}/groups/{group-id}/members") @ResponseBody public reactor.core.publisher.Mono<List<org.keycloak.representations.idm.UserRepresentation>> getGroupMembers(@PathVariable("realm") String realm, @PathVariable("group-id") String groupId, org.springframework.web.server.ServerWebExchange exchange) -
createRole
@PostMapping("/auth-admin/realms/{realm}/role") public void createRole(@PathVariable("realm") String realm, @RequestBody org.keycloak.representations.idm.RoleRepresentation roleRepresentation) -
getRoles
-
getRole
-
getUsersInRole
@GetMapping("/auth-admin/realms/{realm}/role/{role}/users") @ResponseBody public reactor.core.publisher.Mono<Set<org.keycloak.representations.idm.UserRepresentation>> getUsersInRole(org.springframework.web.server.ServerWebExchange exchange, @PathVariable("realm") String realm, @PathVariable("role") String role) -
updateRole
-
removeRole
-
createUser
@PostMapping("/auth-admin/realms/{realm}/user") @ResponseBody public reactor.core.publisher.Mono<Void> createUser(@PathVariable("realm") String realm, @RequestBody CreateUserVO createUserVO) -
resetPassword
-
getUsers
-
getUser
-
updateUser
-
removeUser
-
getRoleMappings
-
addMappingRoles
-
deleteMappingRoles
-
getGroupMappings
-
addMappingGroup
-
deleteMappingGroup
-
getAccessControlUsers
-
getFlattenGroup
-
getAccessControlGroups
-