Class BaseClientRegistrationEndpoint
- java.lang.Object
-
- com.authlete.jaxrs.BaseEndpoint
-
- com.authlete.jaxrs.BaseClientRegistrationEndpoint
-
public class BaseClientRegistrationEndpoint extends BaseEndpoint
A base class for dynamic client registration and dynamic client registration management endpoints.- Since:
- 2.17
- See Also:
- RFC 7591, RFC 7592, OpenID Connect Dynamic Client Registration
-
-
Constructor Summary
Constructors Constructor Description BaseClientRegistrationEndpoint()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.ws.rs.core.Response
handleDelete(com.authlete.common.api.AuthleteApi api, String clientId, String authorization)
Handle a client registration management delete request.javax.ws.rs.core.Response
handleGet(com.authlete.common.api.AuthleteApi api, String clientId, String authorization)
Handle a client registration management get request.javax.ws.rs.core.Response
handleRegister(com.authlete.common.api.AuthleteApi api, String json, String authorization)
Handle a client registration request.javax.ws.rs.core.Response
handleUpdate(com.authlete.common.api.AuthleteApi api, String clientId, String json, String authorization)
Handle a client registration management update request.-
Methods inherited from class com.authlete.jaxrs.BaseEndpoint
extractClientCertificate, extractClientCertificateChain, extractHeadersAsPairs, onError, takeAttribute
-
-
-
-
Method Detail
-
handleRegister
public javax.ws.rs.core.Response handleRegister(com.authlete.common.api.AuthleteApi api, String json, String authorization)
Handle a client registration request.This method internally creates a
ClientRegistrationRequestHandler
instance and calls itsClientRegistrationRequestHandler.handleRegister(String, String)
method. Then, this method uses the value returned from thehandle()
method as a response from this method.When
ClientRegistrationRequestHandler.handle()
method raises aWebApplicationException
, this method callsonError()
method with the exception. The default implementation ofonError()
does nothing. You can override the method as necessary. After callingonError()
method, this method callsgetResponse()
method of the exception and uses the returned value as a response from this method.- Parameters:
api
- An implementation ofAuthleteApi
.json
- The serialized JSON body of the client registration request.authorization
- The value ofAuthorization
header of the registration request. This is optional.- Returns:
- A response that should be returned to the client application.
-
handleGet
public javax.ws.rs.core.Response handleGet(com.authlete.common.api.AuthleteApi api, String clientId, String authorization)
Handle a client registration management get request.This method internally creates a
ClientRegistrationRequestHandler
instance and calls itsClientRegistrationRequestHandler.handleGet(String, String)
method. Then, this method uses the value returned from thehandle()
method as a response from this method.When
ClientRegistrationRequestHandler.handle()
method raises aWebApplicationException
, this method callsonError()
method with the exception. The default implementation ofonError()
does nothing. You can override the method as necessary. After callingonError()
method, this method callsgetResponse()
method of the exception and uses the returned value as a response from this method.- Parameters:
api
- An implementation ofAuthleteApi
.clientId
- The client ID as determined by the incoming request. You will commonly parse this from the incoming request URL as a path component. If your Service has itsregistrationManagementEndpoint
property set, Authlete will add the client ID as a path parameter to this URI automatically.authorization
- The value ofAuthorization
header of the registration request. This is optional.- Returns:
- A response that should be returned to the client application.
-
handleUpdate
public javax.ws.rs.core.Response handleUpdate(com.authlete.common.api.AuthleteApi api, String clientId, String json, String authorization)
Handle a client registration management update request.This method internally creates a
ClientRegistrationRequestHandler
instance and calls itsClientRegistrationRequestHandler.handleUpdate(String, String, String)
method. Then, this method uses the value returned from thehandle()
method as a response from this method.When
ClientRegistrationRequestHandler.handle()
method raises aWebApplicationException
, this method callsonError()
method with the exception. The default implementation ofonError()
does nothing. You can override the method as necessary. After callingonError()
method, this method callsgetResponse()
method of the exception and uses the returned value as a response from this method.- Parameters:
api
- An implementation ofAuthleteApi
.clientId
- The client ID as determined by the incoming request. You will commonly parse this from the incoming request URL as a path component. If your Service has itsregistrationManagementEndpoint
property set, Authlete will add the client ID as a path parameter to this URI automatically.json
- The serialized JSON body of the client update request.authorization
- The value ofAuthorization
header of the registration request. This is optional.- Returns:
- A response that should be returned to the client application.
-
handleDelete
public javax.ws.rs.core.Response handleDelete(com.authlete.common.api.AuthleteApi api, String clientId, String authorization)
Handle a client registration management delete request.This method internally creates a
ClientRegistrationRequestHandler
instance and calls itsClientRegistrationRequestHandler.handleDelete(String, String)
method. Then, this method uses the value returned from thehandle()
method as a response from this method.When
ClientRegistrationRequestHandler.handle()
method raises aWebApplicationException
, this method callsonError()
method with the exception. The default implementation ofonError()
does nothing. You can override the method as necessary. After callingonError()
method, this method callsgetResponse()
method of the exception and uses the returned value as a response from this method.- Parameters:
api
- An implementation ofAuthleteApi
.clientId
- The client ID as determined by the incoming request. You will commonly parse this from the incoming request URL as a path component. If your Service has itsregistrationManagementEndpoint
property set, Authlete will add the client ID as a path parameter to this URI automatically.authorization
- The value ofAuthorization
header of the registration request. This is optional.- Returns:
- A response that should be returned to the client application.
-
-