class AuthorisationServiceInternal implements AuthorisationService {

    @Transactional(readOnly = true)
    @Override
    public CmsResponse<AuthorisationScaApproachResponse> getAuthorisationScaApproach(String authorisationId) {
        Optional<AuthorisationScaApproachResponse> approachResponseOptional = authorisationRepository.findByExternalId(authorisationId)
                                                                                  .map(a -> new AuthorisationScaApproachResponse(a.getScaApproach()));

        if (approachResponseOptional.isPresent()) {
            return CmsResponse.<AuthorisationScaApproachResponse>builder()
                       .payload(approachResponseOptional.get())
                       .build();
        }

        log.info("Authorisation ID: [{}]. Get SCA approach has failed, because authorisation couldn't be found",
                 authorisationId);

        return CmsResponse.<AuthorisationScaApproachResponse>builder()
                   .error(LOGICAL_ERROR)
                   .build();
    }

}