class AisConsentServiceRemote implements AisConsentServiceEncrypted {

    @Override
    public CmsResponse<CmsResponse.VoidResponse> checkConsentAndSaveActionLog(AisConsentActionRequest request) {
        try {
            consentRestTemplate.postForEntity(remoteAisConsentUrls.consentActionLog(), request, Void.class);
        } catch (CmsRestException cmsRestException) {
            log.info("Couldn't check consent and save action log, HTTP response status: {}", cmsRestException.getHttpStatus());

            return CmsResponse.<CmsResponse.VoidResponse>builder()
                       .error(cmsRestException.getCmsError())
                       .build();
        }

        return CmsResponse.<CmsResponse.VoidResponse>builder()
                   .payload(CmsResponse.voidResponse())
                   .build();
    }

}