def __init__(self, id=None, externalId=None, contactAccountId=None, email=None, firstName=None, lastName=None, businessName=None, countryCode=None, dialCode=None, phoneNumber=None, batchItemId=None, type=None, bankAccount=None, address=None, **kwargs): self._validate_constants(AccountType, type) self._validate_country_code(countryCode) self.id = id self.externalId = externalId self.contactAccountId = contactAccountId self.email = email self.firstName = firstName self.lastName = lastName self.businessName = businessName self.countryCode = countryCode self.dialCode = dialCode self.phoneNumber = phoneNumber self.batchItemId = batchItemId self.type = type self.bankAccount = deseralize(BankAccount, bankAccount) self.address = deseralize(Address, address)
def __init__(self, id=None, status=None, exchangeRate=None, claimLink=None, payer=None, clientId=None, amount=None, notes=None, externalInvoiceRefId=None, ccEmails=[], purposeOfPayment=None, attachments=[], exchangeRateQuoteId=None, dueDate=None, timeCreated=None, **kwargs): self.id = id self.status = status self.exchangeRate = deseralize(ExchangeRateResponse, exchangeRate) self.claimLink = claimLink self.payer = deseralize(AccountResponse, payer) self.clientId = clientId self.amount = deseralize(AmountResponse, amount) self.notes = notes self.externalInvoiceRefId = externalInvoiceRefId self.ccEmails = ccEmails self.purposeOfPayment = purposeOfPayment self.attachments = [ deseralize(AttachmentResponse, attach) for attach in attachments ] self.exchangeRateQuoteId = exchangeRateQuoteId self.dueDate = dueDate self.timeCreated = timeCreated
def __init__(self, status=None, email=None, firstName=None, lastName=None, middleName=None, **kwargs): self._validate_currency_code(currencyCode) self._validate_country_code(isoCountryCode) self._validate_constants(ApprovalStatus, status) self.routingNumber = routingNumber self.bankName = bankName self.bankAccountNumber = bankAccountNumber self.currencyCode = currencyCode self.isoCountryCode = isoCountryCode self.iban = iban self.swiftBic = swiftBic self.beneficiaryName = beneficiaryName self.bsbBankCode = bsbBankCode self.branchCode = branchCode self.transitCode = transitCode self.bankInstitutionNumber = bankInstitutionNumber self.bankIfscBranchCode = bankIfscBranchCode self.sortCode = sortCode self.bankCode = bankCode self.clabe = clabe self.bankCnaps = bankCnaps self.bankAddress = deseralize(Address, bankAddress)
def __init__(self, id=None, requestId=None, claimLink=None, externalInvoiceRefId=None, payee=None, payer=None, status=None, amount=None, payeeAmount=None, exchangeRate=None, exchangeRateResponse=None, attachments=[], batchItemId=None, ccEmails=[], exchangeRateQuoteId=None, purposeOfPayment=None, pushPaymentInfoResponse=None, paymentApprovalResponse=None, timeCreated=None, timeUpdated=None, timeSent=None, **kwargs): self.id = id self.requestId = requestId self.claimLink = claimLink self.externalInvoiceRefId = externalInvoiceRefId self.payee = deseralize(AccountResponse, payee) self.payer = deseralize(AccountResponse, payer) self.status = status self.payeeAmount = deseralize(AmountResponse, payeeAmount) self.amount = deseralize(AmountResponse, amount) or self.payeeAmount self.exchangeRateResponse = deseralize(ExchangeRateResponse, exchangeRateResponse) self.exchangeRate = deseralize(ExchangeRateResponse, exchangeRate) \ or self.exchangeRateResponse self.attachments = [ deseralize(AttachmentResponse, attach) for attach in attachments ] self.batchItemId = batchItemId self.ccEmails = ccEmails self.exchangeRateQuoteId = exchangeRateQuoteId self.purposeOfPayment = purposeOfPayment self.pushPaymentInfoResponse = deseralize(PushPaymentInfoResponse, pushPaymentInfoResponse) self.paymentApprovalResponse = deseralize(PaymentApprovalResponse, paymentApprovalResponse) self.timeCreated = timeCreated self.timeUpdated = timeUpdated self.timeSent = timeSent
def __init__(self, amount=None, reference=None, pushPaymentInfo=None, **kwargs): self.amount = deseralize(Amount, amount) self.reference = reference self.pushPaymentInfo = pushPaymentInfo
def __init__(self, approversCompleted=None, status=None, approversRequired=None, approvers=[], **kwargs): self._validate_constants(ApprovalStatus, status) self.approversCompleted = approversCompleted self.status = status self.approversRequired = approversRequired self.approvers = [deseralize(Approver, apr) for apr in approvers]
def __init__(self, batchItemId=None, exchangeRateQuoteId=None, payee=None, amount=None, notes=None, externalInvoiceRefId=None, ccEmails=[], purposeOfPayment=None, attachments=[], approveAutomatically=False, **kwargs): self.batchItemId = batchItemId self.exchangeRateQuoteId = exchangeRateQuoteId self.payee = deseralize(AccountRequest, payee).json self.amount = deseralize(AmountRequest, amount).json self.notes = notes self.externalInvoiceRefId = externalInvoiceRefId self.ccEmails = ccEmails self.purposeOfPayment = purposeOfPayment self.attachments = [deseralize(AttachmentRequest, attach).json for attach in attachments] self.approveAutomatically = approveAutomatically
def __init__(self, id=None, batchId=None, status=None, hasErrors=None, processedItems=None, totalItems=None, batchItems=[], **kwargs): self._validate_constants(BatchStatus, status) self.id = id or batchId self.batchId = id or batchId self.status = status self.hasErrors = hasErrors self.processedItems = processedItems self.totalItems = totalItems self.batchItems = [deseralize(BatchItem, b) for b in batchItems]
def __init__(self, bankFields=None, country=None, invoiceAttachmentRequired=None, purposeOfPaymentInfo=[], purposeOfPaymentRequired=None, receivingCurrencies=[], sendingCurrencies=[], **kwargs): self.bankFields = bankFields self.country = country self.purposeOfPaymentInfo = [ deseralize(PurposeOfPayment, info) for info in purposeOfPaymentInfo ] self.purposeOfPaymentRequired = purposeOfPaymentRequired self.invoiceAttachmentRequired = invoiceAttachmentRequired self.receivingCurrencies = receivingCurrencies self.sendingCurrencies = sendingCurrencies
def __init__(self, id=None, status=None, exchangeRate=None, timeCreated=None, claimLink=None, pushPaymentInfo=None, paymentApproval=None, batchItemId=None, payee=None, payer=None, clientId=None, amount=None, notes=None, externalInvoiceRefId=None, ccEmails=[], purposeOfPayment=None, attachments=[], exchangeRateQuoteId=None, **kwargs): self._validate_constants(PaymentStatus, status) self.id = id self.status = status self.exchangeRate = deseralize(ExchangeRate, exchangeRate) self.timeCreated = timeCreated self.claimLink = claimLink self.pushPaymentInfo = deseralize(PushPaymentInfo, pushPaymentInfo) self.paymentApproval = deseralize(PaymentApproval, paymentApproval) self.batchItemId = batchItemId self.payee = deseralize(Account, payee) self.payer = deseralize(Account, payer) self.clientId = clientId self.amount = deseralize(Amount, amount) self.notes = notes self.externalInvoiceRefId = externalInvoiceRefId self.ccEmails = ccEmails self.purposeOfPayment = purposeOfPayment self.attachments = [ deseralize(Attachment, attach) for attach in attachments ] self.exchangeRateQuoteId = exchangeRateQuoteId
def __init__(self, country=None, sendingCurrencies=[], receivingCurrencies=[], purposeOfPaymentRequired=None, invoiceAttachmentRequired=None, bankFields=[], purposeOfPaymentInfo=[], **kwargs): self._validate_country_code(country) self._validate_currency_code(sendingCurrencies) self._validate_currency_code(receivingCurrencies) self.country = country self.sendingCurrencies = sendingCurrencies self.receivingCurrencies = receivingCurrencies self.purposeOfPaymentRequired = purposeOfPaymentRequired self.invoiceAttachmentRequired = invoiceAttachmentRequired self.bankFields = bankFields self.purposeOfPaymentInfo = [ deseralize(PurposeOfPayment, p) for p in purposeOfPaymentInfo ]
def convertContent(self, cls): self.content = [deseralize(cls, c) for c in self.content] return self