Package org.keycloak.authentication
Interface RequiredActionContext
- 
- All Known Implementing Classes:
- RequiredActionContextResult
 
 public interface RequiredActionContextInterface that encapsulates current information about the current requred action- Version:
- $Revision: 1 $
- Author:
- Bill Burke
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Interface Description static classRequiredActionContext.KcActionStatusstatic classRequiredActionContext.Status
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description voidchallenge(javax.ws.rs.core.Response response)Send a challenge Response back to uservoidfailure()Abort the authentication with an errorLoginFormsProviderform()Create a Freemarker form builder that presets the user, action URI, and a generated access codeStringgenerateCode()Generates access code and updates clientsession timestamp Access codes must be included in form action callbacks as a query parameter.URIgetActionUrl()Get the action URL for the required action.URIgetActionUrl(String code)Get the action URL for the required action.AuthenticationSessionModelgetAuthenticationSession()javax.ws.rs.core.ResponsegetChallenge()If challenge has been sent this returns the JAX-RS ResponseClientConnectiongetConnection()EventBuildergetEvent()Current event builder being usedHttpRequestgetHttpRequest()RealmModelgetRealm()KeycloakSessiongetSession()RequiredActionContext.StatusgetStatus()javax.ws.rs.core.UriInfogetUriInfo()UserModelgetUser()Current uservoidignore()Ignore this required action and go onto the next, or complete the flow.voidsuccess()Mark this required action as successful.
 
- 
- 
- 
Method Detail- 
getActionUrlURI getActionUrl(String code) Get the action URL for the required action.- Parameters:
- code- client sessino access code
- Returns:
 
 - 
getActionUrlURI getActionUrl() Get the action URL for the required action. This auto-generates the access code.- Returns:
 
 - 
formLoginFormsProvider form() Create a Freemarker form builder that presets the user, action URI, and a generated access code- Returns:
 
 - 
getChallengejavax.ws.rs.core.Response getChallenge() If challenge has been sent this returns the JAX-RS Response- Returns:
 
 - 
getEventEventBuilder getEvent() Current event builder being used- Returns:
 
 - 
getUserUserModel getUser() Current user- Returns:
 
 - 
getRealmRealmModel getRealm() 
 - 
getAuthenticationSessionAuthenticationSessionModel getAuthenticationSession() 
 - 
getConnectionClientConnection getConnection() 
 - 
getUriInfojavax.ws.rs.core.UriInfo getUriInfo() 
 - 
getSessionKeycloakSession getSession() 
 - 
getHttpRequestHttpRequest getHttpRequest() 
 - 
generateCodeString generateCode() Generates access code and updates clientsession timestamp Access codes must be included in form action callbacks as a query parameter.- Returns:
 
 - 
getStatusRequiredActionContext.Status getStatus() 
 - 
challengevoid challenge(javax.ws.rs.core.Response response) Send a challenge Response back to user- Parameters:
- response-
 
 - 
failurevoid failure() Abort the authentication with an error
 - 
successvoid success() Mark this required action as successful. The required action will be removed from the UserModel
 - 
ignorevoid ignore() Ignore this required action and go onto the next, or complete the flow.
 
- 
 
-