Class TokenController
java.lang.Object
io.getlime.security.powerauth.rest.api.spring.controller.v3.TokenController
@RestController("tokenControllerV3")
@RequestMapping("/pa/v3/token")
public class TokenController
extends java.lang.Object
Controller responsible for publishing services related to simple token-based authentication.
PowerAuth protocol versions:
- 3.0
- Author:
- Petr Dvorak, petr@wultra.com
-
Constructor Summary
Constructors Constructor Description TokenController() -
Method Summary
Modifier and Type Method Description io.getlime.security.powerauth.rest.api.model.response.v3.EciesEncryptedResponsecreateToken(io.getlime.security.powerauth.rest.api.model.request.v3.EciesEncryptedRequest request, io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthApiAuthentication authentication)Create token.io.getlime.core.rest.model.base.response.ObjectResponse<io.getlime.security.powerauth.rest.api.model.response.v3.TokenRemoveResponse>removeToken(io.getlime.core.rest.model.base.request.ObjectRequest<io.getlime.security.powerauth.rest.api.model.request.v3.TokenRemoveRequest> request, io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthApiAuthentication authentication)Remove token.voidsetTokenServiceV3(TokenService tokenServiceV3)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
TokenController
public TokenController()
-
-
Method Details
-
setTokenServiceV3
-
createToken
@RequestMapping(value="create", method=POST) public io.getlime.security.powerauth.rest.api.model.response.v3.EciesEncryptedResponse createToken(@RequestBody io.getlime.security.powerauth.rest.api.model.request.v3.EciesEncryptedRequest request, io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthApiAuthentication authentication) throws io.getlime.security.powerauth.rest.api.base.exception.PowerAuthAuthenticationExceptionCreate token.- Parameters:
request- ECIES encrypted create token request.authentication- PowerAuth API authentication object.- Returns:
- ECIES encrypted create token response.
- Throws:
io.getlime.security.powerauth.rest.api.base.exception.PowerAuthAuthenticationException- In case authentication fails or request is invalid.
-
removeToken
@RequestMapping(value="remove", method=POST) public io.getlime.core.rest.model.base.response.ObjectResponse<io.getlime.security.powerauth.rest.api.model.response.v3.TokenRemoveResponse> removeToken(@RequestBody io.getlime.core.rest.model.base.request.ObjectRequest<io.getlime.security.powerauth.rest.api.model.request.v3.TokenRemoveRequest> request, io.getlime.security.powerauth.rest.api.base.authentication.PowerAuthApiAuthentication authentication) throws io.getlime.security.powerauth.rest.api.base.exception.PowerAuthAuthenticationExceptionRemove token.- Parameters:
request- Remove token request.authentication- PowerAuth API authentication object.- Returns:
- Remove token response.
- Throws:
io.getlime.security.powerauth.rest.api.base.exception.PowerAuthAuthenticationException- In case authentication fails or request is invalid.
-