Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Adyen/services/balancePlatform/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
from .payment_instrument_groups_api import PaymentInstrumentGroupsApi
from .payment_instruments_api import PaymentInstrumentsApi
from .platform_api import PlatformApi
from .sca_association_management_api import SCAAssociationManagementApi
from .sca_device_management_api import SCADeviceManagementApi
from .transaction_rules_api import TransactionRulesApi
from .transfer_limits_balance_account_level_api import TransferLimitsBalanceAccountLevelApi
from .transfer_limits_balance_platform_level_api import TransferLimitsBalancePlatformLevelApi
Expand Down Expand Up @@ -42,6 +44,8 @@ def __init__(self, client=None):
self.payment_instrument_groups_api = PaymentInstrumentGroupsApi(client=client)
self.payment_instruments_api = PaymentInstrumentsApi(client=client)
self.platform_api = PlatformApi(client=client)
self.sca_association_management_api = SCAAssociationManagementApi(client=client)
self.sca_device_management_api = SCADeviceManagementApi(client=client)
self.transaction_rules_api = TransactionRulesApi(client=client)
self.transfer_limits_balance_account_level_api = TransferLimitsBalanceAccountLevelApi(client=client)
self.transfer_limits_balance_platform_level_api = TransferLimitsBalancePlatformLevelApi(client=client)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
from ..base import AdyenServiceBase


class SCAAssociationManagementApi(AdyenServiceBase):
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech

Do not edit the class manually.
"""

def __init__(self, client=None):
super(SCAAssociationManagementApi, self).__init__(client=client)
self.service = "balancePlatform"
self.baseUrl = "https://balanceplatform-api-test.adyen.com/bcl/v2"

def approve_association(self, request, idempotency_key=None, **kwargs):
"""
Approve a pending approval association
"""
endpoint = self.baseUrl + f"/scaAssociations"
method = "PATCH"
return self.client.call_adyen_api(request, self.service, method, endpoint, idempotency_key, **kwargs)

def list_associations(self, idempotency_key=None, **kwargs):
"""
Get a list of devices associated with an entity
"""
endpoint = self.baseUrl + f"/scaAssociations"
method = "GET"
return self.client.call_adyen_api(None, self.service, method, endpoint, idempotency_key, **kwargs)

def remove_association(self, request, idempotency_key=None, **kwargs):
"""
Delete association to devices
"""
endpoint = self.baseUrl + f"/scaAssociations"
method = "DELETE"
return self.client.call_adyen_api(request, self.service, method, endpoint, idempotency_key, **kwargs)

39 changes: 39 additions & 0 deletions Adyen/services/balancePlatform/sca_device_management_api.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
from ..base import AdyenServiceBase


class SCADeviceManagementApi(AdyenServiceBase):
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech
Do not edit the class manually.
"""

def __init__(self, client=None):
super(SCADeviceManagementApi, self).__init__(client=client)
self.service = "balancePlatform"
self.baseUrl = "https://balanceplatform-api-test.adyen.com/bcl/v2"

def begin_sca_device_registration(self, request, idempotency_key=None, **kwargs):
"""
Begin SCA device registration
"""
endpoint = self.baseUrl + f"/scaDevices"
method = "POST"
return self.client.call_adyen_api(request, self.service, method, endpoint, idempotency_key, **kwargs)

def finish_sca_device_registration(self, request, deviceId, idempotency_key=None, **kwargs):
"""
Finish registration process for a SCA device
"""
endpoint = self.baseUrl + f"/scaDevices/{deviceId}"
method = "PATCH"
return self.client.call_adyen_api(request, self.service, method, endpoint, idempotency_key, **kwargs)

def submit_sca_association(self, request, deviceId, idempotency_key=None, **kwargs):
"""
Create a new SCA association for a device
"""
endpoint = self.baseUrl + f"/scaDevices/{deviceId}/scaAssociations"
method = "POST"
return self.client.call_adyen_api(request, self.service, method, endpoint, idempotency_key, **kwargs)