from . import util as util
from .client import AdyenClient
from .exceptions import (
    AdyenAPIAuthenticationError as AdyenAPIAuthenticationError,
)
from .exceptions import (
    AdyenAPICommunicationError as AdyenAPICommunicationError,
)
from .exceptions import (
    AdyenAPIInvalidPermission as AdyenAPIInvalidPermission,
)
from .exceptions import (
    AdyenAPIUnprocessableEntity as AdyenAPIUnprocessableEntity,
)
from .exceptions import (
    AdyenAPIValidationError as AdyenAPIValidationError,
)
from .exceptions import (
    AdyenError as AdyenError,
)
from .exceptions import (
    AdyenInvalidRequestError as AdyenInvalidRequestError,
)
from .httpclient import HTTPClient as HTTPClient
from .services import (
    AdyenBalancePlatformApi,
    AdyenBase,
    AdyenBinlookupApi,
    AdyenCapitalApi,
    AdyenCheckoutApi,
    AdyenDataProtectionApi,
    AdyenDisputesApi,
    AdyenLegalEntityManagementApi,
    AdyenManagementApi,
    AdyenPaymentsApi,
    AdyenPayoutsApi,
    AdyenPosMobileApi,
    AdyenRecurringApi,
    AdyenSessionAuthenticationApi,
    AdyenStoredValueApi,
    AdyenTerminalApi,
    AdyenTransfersApi,
)


class Adyen(AdyenBase):
    def __init__(self, **kwargs):
        self.client = AdyenClient(**kwargs)
        self.payment = AdyenPaymentsApi(client=self.client)
        self.capital = AdyenCapitalApi(client=self.client)
        self.binlookup = AdyenBinlookupApi(client=self.client)
        self.payout = AdyenPayoutsApi(client=self.client)
        self.recurring = AdyenRecurringApi(client=self.client)
        self.checkout = AdyenCheckoutApi(client=self.client)
        self.terminal = AdyenTerminalApi(client=self.client)
        self.management = AdyenManagementApi(client=self.client)
        self.legalEntityManagement = AdyenLegalEntityManagementApi(client=self.client)
        self.dataProtection = AdyenDataProtectionApi(client=self.client)
        self.transfers = AdyenTransfersApi(client=self.client)
        self.storedValue = AdyenStoredValueApi(client=self.client)
        self.balancePlatform = AdyenBalancePlatformApi(client=self.client)
        self.disputes = AdyenDisputesApi(client=self.client)
        self.sessionAuthentication = AdyenSessionAuthenticationApi(client=self.client)
        self.posMobile = AdyenPosMobileApi(client=self.client)


_base_adyen_obj = Adyen()
recurring = _base_adyen_obj.recurring
payment = _base_adyen_obj.payment
payout = _base_adyen_obj.payout
checkout = _base_adyen_obj.checkout
binlookup = _base_adyen_obj.binlookup
terminal = _base_adyen_obj.terminal
management = _base_adyen_obj.management
legalEntityManagement = _base_adyen_obj.legalEntityManagement
dataProtection = _base_adyen_obj.dataProtection
transfers = _base_adyen_obj.transfers
storedValue = _base_adyen_obj.storedValue
balancePlatform = _base_adyen_obj.balancePlatform
disputes = _base_adyen_obj.disputes
sessionAuthentication = _base_adyen_obj.sessionAuthentication
capital = _base_adyen_obj.capital
posMobile = _base_adyen_obj.posMobile
