Class ClientScopeResource
- java.lang.Object
- 
- org.keycloak.services.resources.admin.ClientScopeResource
 
- 
 public class ClientScopeResource extends Object Base resource class for managing one particular client of a realm.- Version:
- $Revision: 1 $
- Author:
- Bill Burke
 
- 
- 
Field SummaryFields Modifier and Type Field Description protected ClientScopeModelclientScopeprotected static PatterndynamicScreenPatternprotected static org.jboss.logging.Loggerloggerprotected RealmModelrealmprotected static PatternscopeNamePatternprotected KeycloakSessionsession
 - 
Constructor SummaryConstructors Constructor Description ClientScopeResource(RealmModel realm, AdminPermissionEvaluator auth, ClientScopeModel clientScope, KeycloakSession session, AdminEventBuilder adminEvent)
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.ws.rs.core.ResponsedeleteClientScope()Delete the client scopeClientScopeRepresentationgetClientScope()Get representation of the client scopeProtocolMappersResourcegetProtocolMappers()ScopeMappedResourcegetScopeMappedResource()Base path for managing the role scope mappings for the client scopejavax.ws.rs.core.Responseupdate(ClientScopeRepresentation rep)Update the client scopestatic voidvalidateClientScopeName(String name)static voidvalidateDynamicClientScope(ClientScopeRepresentation clientScope)Performs some validation based on attributes combinations and format.voidvalidateDynamicScopeUpdate(ClientScopeRepresentation rep)Makes sure that an update that makes a Client Scope Dynamic is rejected if the Client Scope is assigned to a client as a default scope.
 
- 
- 
- 
Field Detail- 
loggerprotected static final org.jboss.logging.Logger logger 
 - 
realmprotected RealmModel realm 
 - 
clientScopeprotected ClientScopeModel clientScope 
 - 
sessionprotected KeycloakSession session 
 - 
dynamicScreenPatternprotected static Pattern dynamicScreenPattern 
 - 
scopeNamePatternprotected static final Pattern scopeNamePattern 
 
- 
 - 
Constructor Detail- 
ClientScopeResourcepublic ClientScopeResource(RealmModel realm, AdminPermissionEvaluator auth, ClientScopeModel clientScope, KeycloakSession session, AdminEventBuilder adminEvent) 
 
- 
 - 
Method Detail- 
getProtocolMappers@Path("protocol-mappers") public ProtocolMappersResource getProtocolMappers()
 - 
getScopeMappedResource@Path("scope-mappings") public ScopeMappedResource getScopeMappedResource()Base path for managing the role scope mappings for the client scope- Returns:
 
 - 
update@PUT @Consumes("application/json") public javax.ws.rs.core.Response update(ClientScopeRepresentation rep)Update the client scope- Parameters:
- rep-
- Returns:
 
 - 
getClientScope@GET @Produces("application/json") public ClientScopeRepresentation getClientScope()Get representation of the client scope- Returns:
 
 - 
deleteClientScope@DELETE public javax.ws.rs.core.Response deleteClientScope() Delete the client scope
 - 
validateDynamicClientScopepublic static void validateDynamicClientScope(ClientScopeRepresentation clientScope) throws ErrorResponseException Performs some validation based on attributes combinations and format. Validations differ based on whether the DYNAMIC_SCOPES feature is enabled or not- Parameters:
- clientScope-
- Throws:
- ErrorResponseException
 
 - 
validateClientScopeNamepublic static void validateClientScopeName(String name) throws ErrorResponseException - Throws:
- ErrorResponseException
 
 - 
validateDynamicScopeUpdatepublic void validateDynamicScopeUpdate(ClientScopeRepresentation rep) Makes sure that an update that makes a Client Scope Dynamic is rejected if the Client Scope is assigned to a client as a default scope.- Parameters:
- rep- the- ClientScopeRepresentationwith the changes from the frontend.
 
 
- 
 
-