@Service public class Xs2aAisConsentService extends Object
| Constructor and Description |
|---|
Xs2aAisConsentService() |
| Modifier and Type | Method and Description |
|---|---|
void |
consentActionLog(String tppId,
String consentId,
ActionStatus actionStatus)
Sends a POST request to CMS to perform decrement of consent usages and report status of the operation held with certain AIS consent
|
Optional<String> |
createAisConsentAuthorization(String consentId,
ScaStatus scaStatus,
PsuIdData psuData)
Sends a POST request to CMS to store created consent authorization
|
String |
createConsent(CreateConsentReq request,
PsuIdData psuData,
TppInfo tppInfo)
Sends a POST request to CMS to store created AISconsent
|
boolean |
findAndTerminateOldConsentsByNewConsentId(String newConsentId)
Requests CMS to find old consents for current TPP and PSU and terminate them.
|
AccountConsentAuthorization |
getAccountConsentAuthorizationById(String authorizationId,
String consentId)
Requests CMS to retrieve AIS consent authorization by its identifier
|
AccountConsent |
getAccountConsentById(String consentId)
Requests CMS to retrieve AIS consent by its identifier
|
ConsentStatus |
getAccountConsentStatusById(String consentId)
Requests CMS to retrieve AIS consent status by its identifier
|
Optional<ScaStatus> |
getAuthorisationScaStatus(String consentId,
String authorisationId)
Requests CMS to retrieve SCA status of AIS consent authorisation
|
Optional<List<String>> |
getAuthorisationSubResources(String consentId)
Requests CMS to retrieve AIS consent authorisation IDs by consent ID
|
AccountConsent |
getInitialAccountConsentById(String consentId)
Requests CMS to retrieve AIS consent by its identifier
|
void |
updateAspspAccountAccess(String consentId,
AisAccountAccessInfo aisAccountAccessInfo)
Sends a PUT request to CMS to update AIS account access information by consent ID
|
void |
updateConsentAuthorization(UpdateConsentPsuDataReq updatePsuData)
Sends a PUT request to CMS to update created AIS consent authorization
|
void |
updateConsentStatus(String consentId,
ConsentStatus consentStatus)
Requests CMS to update consent status into provided one
|
public String createConsent(CreateConsentReq request, PsuIdData psuData, TppInfo tppInfo)
request - Request body storing main consent detailspsuData - PsuIdData container of authorisation data about PSUtppInfo - Information about particular TPP from TPP Certificatepublic AccountConsent getAccountConsentById(String consentId)
consentId - String representation of identifier of stored consentpublic AccountConsent getInitialAccountConsentById(String consentId)
consentId - String representation of identifier of stored consentpublic ConsentStatus getAccountConsentStatusById(String consentId)
consentId - String representation of identifier of stored consentpublic boolean findAndTerminateOldConsentsByNewConsentId(String newConsentId)
newConsentId - id of new consentpublic void updateConsentStatus(String consentId, ConsentStatus consentStatus)
consentId - String representation of identifier of stored consentconsentStatus - ConsentStatus the consent be changed topublic void consentActionLog(String tppId, String consentId, ActionStatus actionStatus)
tppId - String representation of TPP`s identifier from TPP CertificateconsentId - String representation of identifier of stored consentactionStatus - Enum value representing whether the acition is successful or errors occuredpublic Optional<String> createAisConsentAuthorization(String consentId, ScaStatus scaStatus, PsuIdData psuData)
consentId - String representation of identifier of stored consentpublic AccountConsentAuthorization getAccountConsentAuthorizationById(String authorizationId, String consentId)
authorizationId - String representation of identifier of stored consent authorizationpublic void updateConsentAuthorization(UpdateConsentPsuDataReq updatePsuData)
updatePsuData - Consent psu datapublic void updateAspspAccountAccess(String consentId, AisAccountAccessInfo aisAccountAccessInfo)
consentId - consentId String representation of identifier of stored consentaisAccountAccessInfo - AIS account access informationpublic Optional<List<String>> getAuthorisationSubResources(String consentId)
consentId - String representation of identifier of stored consentpublic Optional<ScaStatus> getAuthorisationScaStatus(String consentId, String authorisationId)
consentId - String representation of consent identifierauthorisationId - String representation of authorisation identifierCopyright © 2019. All rights reserved.