in digital-signature-ops-client/src/main/java/com/epam/digital/data/platform/dso/client/decoder/DigitalSignatureDecoder.java [49:64]
public Exception decode(String methodKey, Response response) {
if (response.status() == 400) {
return new BadRequestException(getErrorDto(response));
}
if (response.status() == 500) {
return new InternalServerErrorException(getErrorDto(response));
}
if (response.status() == 422) {
return new SignatureValidationException(getErrorDto(response));
}
if (response.status() == 412) {
var error = getErrorDto(response);
return new InvalidSignatureException(error.getMessage(), error);
}
return errorDecoderChain.decode(methodKey, response);
}