use of io.getlime.powerauth.soap.GetActivationStatusResponse in project powerauth-restful-integration by lime-company.
the class ActivationController method getActivationStatus.
/**
* Get activation status.
* @param request PowerAuth RESTful request with {@link ActivationStatusRequest} payload.
* @return PowerAuth RESTful response with {@link ActivationStatusResponse} payload.
*/
@RequestMapping(value = "status", method = RequestMethod.POST)
@ResponseBody
public ObjectResponse<ActivationStatusResponse> getActivationStatus(@RequestBody ObjectRequest<ActivationStatusRequest> request) throws PowerAuthActivationException {
try {
String activationId = request.getRequestObject().getActivationId();
GetActivationStatusResponse soapResponse = powerAuthClient.getActivationStatus(activationId);
ActivationStatusResponse response = new ActivationStatusResponse();
response.setActivationId(soapResponse.getActivationId());
response.setEncryptedStatusBlob(soapResponse.getEncryptedStatusBlob());
if (applicationConfiguration != null) {
response.setCustomObject(applicationConfiguration.statusServiceCustomObject());
}
return new ObjectResponse<>(response);
} catch (Exception ex) {
throw new PowerAuthActivationException();
}
}
Aggregations