Package com.authlete.jakarta
Class DeviceVerificationRequestHandler
- java.lang.Object
-
- com.authlete.jakarta.DeviceVerificationRequestHandler
-
public class DeviceVerificationRequestHandler extends Object
Handler for getting information associated with a user code that the end-user input at the verification endpoint in OAuth 2.0 Device Authorization Grant (Device Flow).handle()
method should be called after the authorization server receives a user code that the end-user input at the verification endpoint. Thehandle()
method calls Authlete's/api/device/verification
API, receives a response from the API, and dispatches processing according to theaction
parameter in the response.- Since:
- 2.18
- Author:
- Hideki Ikeda
-
-
Constructor Summary
Constructors Constructor Description DeviceVerificationRequestHandler(com.authlete.common.api.AuthleteApi api, DeviceVerificationRequestHandlerSpi spi)
Constructor with an implementation ofAuthleteApi
interface and an implementation ofDeviceVerificationRequestHandlerSpi
interface.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected com.authlete.jakarta.AuthleteApiCaller
getApiCaller()
jakarta.ws.rs.core.Response
handle()
Handle information associated with a user code that the end-user input at the verification endpoint in OAuth 2.0 Device Authorization Grant (Device Flow).jakarta.ws.rs.core.Response
handle(com.authlete.common.api.Options options)
Handle information associated with a user code that the end-user input at the verification endpoint in OAuth 2.0 Device Authorization Grant (Device Flow).protected jakarta.ws.rs.InternalServerErrorException
unexpected(String message, Throwable cause)
-
-
-
Constructor Detail
-
DeviceVerificationRequestHandler
public DeviceVerificationRequestHandler(com.authlete.common.api.AuthleteApi api, DeviceVerificationRequestHandlerSpi spi)
Constructor with an implementation ofAuthleteApi
interface and an implementation ofDeviceVerificationRequestHandlerSpi
interface.- Parameters:
api
- Implementation ofAuthleteApi
interface.spi
- Implementation ofDeviceVerificationRequestHandlerSpi
interface.
-
-
Method Detail
-
handle
public jakarta.ws.rs.core.Response handle() throws jakarta.ws.rs.WebApplicationException
Handle information associated with a user code that the end-user input at the verification endpoint in OAuth 2.0 Device Authorization Grant (Device Flow). This method is an alias ofhandle
(null)
.- Returns:
- A response that should be returned to the end-user.
- Throws:
jakarta.ws.rs.WebApplicationException
- An error occurred.
-
handle
public jakarta.ws.rs.core.Response handle(com.authlete.common.api.Options options) throws jakarta.ws.rs.WebApplicationException
Handle information associated with a user code that the end-user input at the verification endpoint in OAuth 2.0 Device Authorization Grant (Device Flow).- Parameters:
options
- The request options for the/api/device/verification
API.- Returns:
- A response that should be returned to the end-user.
- Throws:
jakarta.ws.rs.WebApplicationException
- An error occurred.- Since:
- 2.82
-
getApiCaller
protected com.authlete.jakarta.AuthleteApiCaller getApiCaller()
-
-