Class IDTokenReissueResponse
- java.lang.Object
-
- com.authlete.common.dto.ApiResponse
-
- com.authlete.common.dto.IDTokenReissueResponse
-
- All Implemented Interfaces:
Serializable
public class IDTokenReissueResponse extends ApiResponse
A response from Authlete's/idtoken/reissue
API.A response from the
/idtoken/reissue
API can be mapped to this class. The API caller should extract the value of the "action
" parameter from the API response and take the next action based on the value of the parameter.
action
=OK
The
action
valueOK
means that an ID token has been reissued successfully. In this case, the implementation of the token endpoint should return a successful response to the client application. The HTTP status code and the content type of the response should be 200 andapplication/json
, respectively. The value of theresponseContent
parameter can be used as the message body of the response.HTTP/1.1 200 OK Content-Type: application/json Cache-Control: no-store (Put the value of the "responseContent" parameter here.)
action
=INTERNAL_SERVER_ERROR
The
action
valueINTERNAL_SERVER_ERROR
means that something wrong happened on Authlete side. In this case, the implementation of the token endpoint should return an error response to the client application. The HTTP status code and the content type of the error response should be 500 andapplication/json
, respectively. The value of theresponseContent
parameter can be used as the message body of the error response.HTTP/1.1 500 Internal Server Error Content-Type: application/json Cache-Control: no-store (Put the value of the "responseContent" parameter here.)
Note that, however, in real production deployments, it may be better to return a vaguer error response instead of a bare one like above.
action
=CALLER_ERROR
The
action
valueCALLER_ERROR
means that the API call is wrong. For example, the "accessToken
" request parameter is missing.Caller errors should be solved before the service is deployed in a production environment.
- Since:
- 3.68, Authlete 2.3.8
- See Also:
- OpenID Connect Core 1.0, 12.2. Successful Refresh Response,
IDTokenReissueRequest
, Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
IDTokenReissueResponse.Action
The next action that the implementation of the token endpoint should take.
-
Constructor Summary
Constructors Constructor Description IDTokenReissueResponse()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IDTokenReissueResponse.Action
getAction()
Get the next action that the implementation of the token endpoint should take.String
getIdToken()
Get the reissued ID token.String
getResponseContent()
Get the response content that can be used as the message body of the token response that should be returned from the token endpoint.IDTokenReissueResponse
setAction(IDTokenReissueResponse.Action action)
Set the next action that the implementation of the token endpoint should take.IDTokenReissueResponse
setIdToken(String idToken)
Set the reissued ID token.IDTokenReissueResponse
setResponseContent(String responseContent)
Set the response content that can be used as the message body of the token response that should be returned from the token endpoint.-
Methods inherited from class com.authlete.common.dto.ApiResponse
getResultCode, getResultMessage, setResultCode, setResultMessage
-
-
-
-
Method Detail
-
getAction
public IDTokenReissueResponse.Action getAction()
Get the next action that the implementation of the token endpoint should take.- Returns:
- The next action that the implementation of the token endpoint should take.
-
setAction
public IDTokenReissueResponse setAction(IDTokenReissueResponse.Action action)
Set the next action that the implementation of the token endpoint should take.- Parameters:
action
- The next action that the implementation of the token endpoint should take.- Returns:
this
object.
-
getResponseContent
public String getResponseContent()
Get the response content that can be used as the message body of the token response that should be returned from the token endpoint.- Returns:
- The response content.
-
setResponseContent
public IDTokenReissueResponse setResponseContent(String responseContent)
Set the response content that can be used as the message body of the token response that should be returned from the token endpoint.- Parameters:
responseContent
- The response content.- Returns:
this
object.
-
getIdToken
public String getIdToken()
Get the reissued ID token.- Returns:
- The reissued ID token in the JWS compact serialization format.
-
setIdToken
public IDTokenReissueResponse setIdToken(String idToken)
Set the reissued ID token.- Parameters:
idToken
- The reissued ID token in the JWS compact serialization format.- Returns:
this
object.
-
-