Package com.authlete.jaxrs
Class RevocationRequestHandler
- java.lang.Object
-
- com.authlete.jaxrs.RevocationRequestHandler
-
public class RevocationRequestHandler extends Object
Handler for token revocation requests (RFC 7009).In an implementation of revocation endpoint, call
handle(Params)method and use the response as the response from the endpoint to the client application.handle()method calls Authlete's/api/auth/revocationAPI, receives a response from the API, and dispatches processing according to theactionparameter in the response.- Since:
- 1.1
- Author:
- Takahiko Kawasaki
- See Also:
- RFC 7009: OAuth 2.0 Token Revocation
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classRevocationRequestHandler.ParamsParameters passed to thehandle(Params)method.
-
Constructor Summary
Constructors Constructor Description RevocationRequestHandler(com.authlete.common.api.AuthleteApi api)Constructor with an implementation ofAuthleteApiinterface.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected com.authlete.jaxrs.AuthleteApiCallergetApiCaller()javax.ws.rs.core.Responsehandle(RevocationRequestHandler.Params params)Handle a token revocation request.javax.ws.rs.core.Responsehandle(RevocationRequestHandler.Params params, com.authlete.common.api.Options options)Handle a token revocation request.javax.ws.rs.core.Responsehandle(javax.ws.rs.core.MultivaluedMap<String,String> parameters, String authorization)Handle a token revocation request (RFC 7009).javax.ws.rs.core.Responsehandle(javax.ws.rs.core.MultivaluedMap<String,String> parameters, String authorization, com.authlete.common.api.Options options)Handle a token revocation request (RFC 7009).protected javax.ws.rs.InternalServerErrorExceptionunexpected(String message, Throwable cause)
-
-
-
Method Detail
-
handle
public javax.ws.rs.core.Response handle(javax.ws.rs.core.MultivaluedMap<String,String> parameters, String authorization) throws javax.ws.rs.WebApplicationException
Handle a token revocation request (RFC 7009). This method is an alias ofhandle(parameters, authorization, null).- Parameters:
parameters- The request parameters of a token revocation request.authorization- The value ofAuthorizationheader in the token revocation request. A client application may embed its pair of client ID and client secret in a token revocation request using Basic Authentication.- Returns:
- A response that should be returned from the endpoint to the client application.
- Throws:
javax.ws.rs.WebApplicationException- An error occurred.
-
handle
public javax.ws.rs.core.Response handle(javax.ws.rs.core.MultivaluedMap<String,String> parameters, String authorization, com.authlete.common.api.Options options) throws javax.ws.rs.WebApplicationException
Handle a token revocation request (RFC 7009). This method is an alias of thehandle(Params, Options)method.- Parameters:
parameters- The request parameters of a token revocation request.authorization- The value ofAuthorizationheader in the token revocation request. A client application may embed its pair of client ID and client secret in a token revocation request using Basic Authentication.options- The request options for the/api/auth/revocationAPI.- Returns:
- A response that should be returned from the endpoint to the client application.
- Throws:
javax.ws.rs.WebApplicationException- An error occurred.- Since:
- 2.82
-
handle
public javax.ws.rs.core.Response handle(RevocationRequestHandler.Params params) throws javax.ws.rs.WebApplicationException
Handle a token revocation request. This method is an alias ofhandle(params, null).- Parameters:
params- The request parameters for Authlete's/api/auth/revocationAPI.- Returns:
- A response that should be returned from the endpoint to the client application.
- Throws:
javax.ws.rs.WebApplicationException- An error occurred.- Since:
- 2.79
-
handle
public javax.ws.rs.core.Response handle(RevocationRequestHandler.Params params, com.authlete.common.api.Options options) throws javax.ws.rs.WebApplicationException
Handle a token revocation request.- Parameters:
params- The request parameters for Authlete's/api/auth/revocationAPI.options- The request options for the/api/auth/revocationAPI.- Returns:
- A response that should be returned from the endpoint to the client application.
- Throws:
javax.ws.rs.WebApplicationException- An error occurred.- Since:
- 2.82
-
getApiCaller
protected com.authlete.jaxrs.AuthleteApiCaller getApiCaller()
-
-