Interface ConsentService


  • public interface ConsentService
    ConsentService without any encryption/decryption. Should not be used in XS2A directly.
    See Also:
    ConsentServiceBase, ConsentServiceEncrypted
    • Method Detail

      • createConsent

        CmsResponse<CmsCreateConsentResponse> createConsent​(de.adorsys.psd2.consent.api.ais.CmsConsent consent)
                                                     throws de.adorsys.psd2.consent.api.WrongChecksumException
        Create AIS consent
        Parameters:
        consent - needed parameters for creating AIS consent
        Returns:
        create consent response, containing consent and its encrypted ID
        Throws:
        de.adorsys.psd2.consent.api.WrongChecksumException
      • getConsentStatusById

        CmsResponse<de.adorsys.psd2.xs2a.core.consent.ConsentStatus> getConsentStatusById​(String consentId)
        Reads status of consent by id
        Parameters:
        consentId - id of consent
        Returns:
        ConsentStatus
      • updateConsentStatusById

        CmsResponse<Boolean> updateConsentStatusById​(String consentId,
                                                     de.adorsys.psd2.xs2a.core.consent.ConsentStatus status)
                                              throws de.adorsys.psd2.consent.api.WrongChecksumException
        Updates consent status by id
        Parameters:
        consentId - id of consent
        status - new consent status
        Returns:
        Boolean
        Throws:
        de.adorsys.psd2.consent.api.WrongChecksumException
      • getConsentById

        CmsResponse<de.adorsys.psd2.consent.api.ais.CmsConsent> getConsentById​(String consentId)
        Reads full information of consent by id
        Parameters:
        consentId - id of consent
        Returns:
        AisAccountConsent
      • findAndTerminateOldConsentsByNewConsentId

        CmsResponse<Boolean> findAndTerminateOldConsentsByNewConsentId​(String newConsentId)
        Finds old consents for current TPP and PSU and terminates them. This method should be invoked, when a new consent is authorised.
        Parameters:
        newConsentId - id of new consent
        Returns:
        true if any consents have been terminated, false - if none
      • getPsuDataByConsentId

        CmsResponse<List<de.adorsys.psd2.xs2a.core.psu.PsuIdData>> getPsuDataByConsentId​(String consentId)
      • updateMultilevelScaRequired

        CmsResponse<Boolean> updateMultilevelScaRequired​(String consentId,
                                                         boolean multilevelScaRequired)
                                                  throws de.adorsys.psd2.consent.api.WrongChecksumException
        Updates multilevel SCA required field
        Parameters:
        consentId - String representation of the consent identifier
        multilevelScaRequired - multilevel SCA required indicator
        Returns:
        true if authorisation was found and SCA required field updated, false otherwise
        Throws:
        de.adorsys.psd2.consent.api.WrongChecksumException