globalpayments-api 2.0.0 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/src/Builders/AuthorizationBuilder.d.ts +325 -0
- package/lib/src/Builders/AuthorizationBuilder.js +601 -0
- package/lib/src/Builders/AuthorizationBuilder.js.map +1 -0
- package/lib/src/Builders/BaseBuilder/ValidationClause.d.ts +14 -0
- package/lib/src/Builders/BaseBuilder/ValidationClause.js +62 -0
- package/lib/src/Builders/BaseBuilder/ValidationClause.js.map +1 -0
- package/lib/src/Builders/BaseBuilder/ValidationTarget.d.ts +16 -0
- package/lib/src/Builders/BaseBuilder/ValidationTarget.js +29 -0
- package/lib/src/Builders/BaseBuilder/ValidationTarget.js.map +1 -0
- package/lib/src/Builders/BaseBuilder/Validations.d.ts +11 -0
- package/lib/src/Builders/BaseBuilder/Validations.js +57 -0
- package/lib/src/Builders/BaseBuilder/Validations.js.map +1 -0
- package/lib/src/Builders/BaseBuilder.d.ts +11 -0
- package/lib/src/Builders/BaseBuilder.js +17 -0
- package/lib/src/Builders/BaseBuilder.js.map +1 -0
- package/lib/src/Builders/ManagementBuilder.d.ts +103 -0
- package/lib/src/Builders/ManagementBuilder.js +228 -0
- package/lib/src/Builders/ManagementBuilder.js.map +1 -0
- package/lib/src/Builders/PayFacBuilder.d.ts +96 -0
- package/lib/src/Builders/PayFacBuilder.js +185 -0
- package/lib/src/Builders/PayFacBuilder.js.map +1 -0
- package/lib/src/Builders/RecurringBuilder.d.ts +13 -0
- package/lib/src/Builders/RecurringBuilder.js +48 -0
- package/lib/src/Builders/RecurringBuilder.js.map +1 -0
- package/lib/src/Builders/ReportBuilder.d.ts +8 -0
- package/lib/src/Builders/ReportBuilder.js +37 -0
- package/lib/src/Builders/ReportBuilder.js.map +1 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomAuthorizationRequestBuilder.d.ts +22 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomAuthorizationRequestBuilder.js +160 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomAuthorizationRequestBuilder.js.map +1 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomRequestBuilder.d.ts +6 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomRequestBuilder.js +24 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomRequestBuilder.js.map +1 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/index.d.ts +2 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/index.js +15 -0
- package/lib/src/Builders/RequestBuilder/GpEcom/index.js.map +1 -0
- package/lib/src/Builders/RequestBuilder/RequestBuilderFactory.d.ts +6 -0
- package/lib/src/Builders/RequestBuilder/RequestBuilderFactory.js +30 -0
- package/lib/src/Builders/RequestBuilder/RequestBuilderFactory.js.map +1 -0
- package/lib/src/Builders/RequestBuilder/index.d.ts +2 -0
- package/lib/src/Builders/RequestBuilder/index.js +15 -0
- package/lib/src/Builders/RequestBuilder/index.js.map +1 -0
- package/lib/src/Builders/TransactionBuilder.d.ts +10 -0
- package/lib/src/Builders/TransactionBuilder.js +47 -0
- package/lib/src/Builders/TransactionBuilder.js.map +1 -0
- package/lib/src/Builders/TransactionReportBuilder.d.ts +15 -0
- package/lib/src/Builders/TransactionReportBuilder.js +80 -0
- package/lib/src/Builders/TransactionReportBuilder.js.map +1 -0
- package/lib/src/Builders/index.d.ts +8 -0
- package/lib/src/Builders/index.js +21 -0
- package/lib/src/Builders/index.js.map +1 -0
- package/lib/src/ConfiguredServices.d.ts +22 -0
- package/lib/src/ConfiguredServices.js +57 -0
- package/lib/src/ConfiguredServices.js.map +1 -0
- package/lib/src/Entities/Address.d.ts +13 -0
- package/lib/src/Entities/Address.js +20 -0
- package/lib/src/Entities/Address.js.map +1 -0
- package/lib/src/Entities/BatchSummary.d.ts +6 -0
- package/lib/src/Entities/BatchSummary.js +10 -0
- package/lib/src/Entities/BatchSummary.js.map +1 -0
- package/lib/src/Entities/Customer.d.ts +64 -0
- package/lib/src/Entities/Customer.js +48 -0
- package/lib/src/Entities/Customer.js.map +1 -0
- package/lib/src/Entities/DocumentUploadData.d.ts +13 -0
- package/lib/src/Entities/DocumentUploadData.js +49 -0
- package/lib/src/Entities/DocumentUploadData.js.map +1 -0
- package/lib/src/Entities/EcommerceInfo.d.ts +12 -0
- package/lib/src/Entities/EcommerceInfo.js +15 -0
- package/lib/src/Entities/EcommerceInfo.js.map +1 -0
- package/lib/src/Entities/EncryptionData.d.ts +6 -0
- package/lib/src/Entities/EncryptionData.js +10 -0
- package/lib/src/Entities/EncryptionData.js.map +1 -0
- package/lib/src/Entities/Enums.d.ts +373 -0
- package/lib/src/Entities/Enums.js +498 -0
- package/lib/src/Entities/Enums.js.map +1 -0
- package/lib/src/Entities/Errors.d.ts +23 -0
- package/lib/src/Entities/Errors.js +107 -0
- package/lib/src/Entities/Errors.js.map +1 -0
- package/lib/src/Entities/HostedPaymentData.d.ts +10 -0
- package/lib/src/Entities/HostedPaymentData.js +11 -0
- package/lib/src/Entities/HostedPaymentData.js.map +1 -0
- package/lib/src/Entities/IRequestBuilder.d.ts +7 -0
- package/lib/src/Entities/IRequestBuilder.js +3 -0
- package/lib/src/Entities/IRequestBuilder.js.map +1 -0
- package/lib/src/Entities/ProFac/AccountBalanceResponseData.d.ts +7 -0
- package/lib/src/Entities/ProFac/AccountBalanceResponseData.js +10 -0
- package/lib/src/Entities/ProFac/AccountBalanceResponseData.js.map +1 -0
- package/lib/src/Entities/ProFac/AccountPermissions.d.ts +15 -0
- package/lib/src/Entities/ProFac/AccountPermissions.js +10 -0
- package/lib/src/Entities/ProFac/AccountPermissions.js.map +1 -0
- package/lib/src/Entities/ProFac/BankAccountData.d.ts +10 -0
- package/lib/src/Entities/ProFac/BankAccountData.js +10 -0
- package/lib/src/Entities/ProFac/BankAccountData.js.map +1 -0
- package/lib/src/Entities/ProFac/BankAccountOwnershipData.d.ts +8 -0
- package/lib/src/Entities/ProFac/BankAccountOwnershipData.js +12 -0
- package/lib/src/Entities/ProFac/BankAccountOwnershipData.js.map +1 -0
- package/lib/src/Entities/ProFac/BeneficialOwnerData.d.ts +6 -0
- package/lib/src/Entities/ProFac/BeneficialOwnerData.js +11 -0
- package/lib/src/Entities/ProFac/BeneficialOwnerData.js.map +1 -0
- package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.d.ts +5 -0
- package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.js +10 -0
- package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.js.map +1 -0
- package/lib/src/Entities/ProFac/BusinessData.d.ts +14 -0
- package/lib/src/Entities/ProFac/BusinessData.js +12 -0
- package/lib/src/Entities/ProFac/BusinessData.js.map +1 -0
- package/lib/src/Entities/ProFac/DeviceAttributeInfo.d.ts +4 -0
- package/lib/src/Entities/ProFac/DeviceAttributeInfo.js +10 -0
- package/lib/src/Entities/ProFac/DeviceAttributeInfo.js.map +1 -0
- package/lib/src/Entities/ProFac/DeviceData.d.ts +5 -0
- package/lib/src/Entities/ProFac/DeviceData.js +11 -0
- package/lib/src/Entities/ProFac/DeviceData.js.map +1 -0
- package/lib/src/Entities/ProFac/DeviceInfo.d.ts +6 -0
- package/lib/src/Entities/ProFac/DeviceInfo.js +10 -0
- package/lib/src/Entities/ProFac/DeviceInfo.js.map +1 -0
- package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.d.ts +7 -0
- package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.js +14 -0
- package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.js.map +1 -0
- package/lib/src/Entities/ProFac/GrossBillingInformation.d.ts +8 -0
- package/lib/src/Entities/ProFac/GrossBillingInformation.js +10 -0
- package/lib/src/Entities/ProFac/GrossBillingInformation.js.map +1 -0
- package/lib/src/Entities/ProFac/OrderDevice.d.ts +18 -0
- package/lib/src/Entities/ProFac/OrderDevice.js +10 -0
- package/lib/src/Entities/ProFac/OrderDevice.js.map +1 -0
- package/lib/src/Entities/ProFac/OwnersData.d.ts +12 -0
- package/lib/src/Entities/ProFac/OwnersData.js +12 -0
- package/lib/src/Entities/ProFac/OwnersData.js.map +1 -0
- package/lib/src/Entities/ProFac/PayFacResponseData.d.ts +55 -0
- package/lib/src/Entities/ProFac/PayFacResponseData.js +10 -0
- package/lib/src/Entities/ProFac/PayFacResponseData.js.map +1 -0
- package/lib/src/Entities/ProFac/RenewAccountData.d.ts +10 -0
- package/lib/src/Entities/ProFac/RenewAccountData.js +12 -0
- package/lib/src/Entities/ProFac/RenewAccountData.js.map +1 -0
- package/lib/src/Entities/ProFac/SignificantOwnerData.d.ts +8 -0
- package/lib/src/Entities/ProFac/SignificantOwnerData.js +12 -0
- package/lib/src/Entities/ProFac/SignificantOwnerData.js.map +1 -0
- package/lib/src/Entities/ProFac/ThreatRiskData.d.ts +5 -0
- package/lib/src/Entities/ProFac/ThreatRiskData.js +10 -0
- package/lib/src/Entities/ProFac/ThreatRiskData.js.map +1 -0
- package/lib/src/Entities/ProFac/UserPersonalData.d.ts +26 -0
- package/lib/src/Entities/ProFac/UserPersonalData.js +15 -0
- package/lib/src/Entities/ProFac/UserPersonalData.js.map +1 -0
- package/lib/src/Entities/RecurringEntity.d.ts +14 -0
- package/lib/src/Entities/RecurringEntity.js +87 -0
- package/lib/src/Entities/RecurringEntity.js.map +1 -0
- package/lib/src/Entities/Request.d.ts +9 -0
- package/lib/src/Entities/Request.js +15 -0
- package/lib/src/Entities/Request.js.map +1 -0
- package/lib/src/Entities/SSORequestData.d.ts +5 -0
- package/lib/src/Entities/SSORequestData.js +10 -0
- package/lib/src/Entities/SSORequestData.js.map +1 -0
- package/lib/src/Entities/Schedule.d.ts +47 -0
- package/lib/src/Entities/Schedule.js +254 -0
- package/lib/src/Entities/Schedule.js.map +1 -0
- package/lib/src/Entities/ServiceEndpoints.d.ts +4 -0
- package/lib/src/Entities/ServiceEndpoints.js +9 -0
- package/lib/src/Entities/ServiceEndpoints.js.map +1 -0
- package/lib/src/Entities/Transaction.d.ts +78 -0
- package/lib/src/Entities/Transaction.js +109 -0
- package/lib/src/Entities/Transaction.js.map +1 -0
- package/lib/src/Entities/TransactionSummary.d.ts +61 -0
- package/lib/src/Entities/TransactionSummary.js +10 -0
- package/lib/src/Entities/TransactionSummary.js.map +1 -0
- package/lib/src/Entities/index.d.ts +15 -0
- package/lib/src/Entities/index.js +28 -0
- package/lib/src/Entities/index.js.map +1 -0
- package/lib/src/Gateways/Gateway.d.ts +10 -0
- package/lib/src/Gateways/Gateway.js +43 -0
- package/lib/src/Gateways/Gateway.js.map +1 -0
- package/lib/src/Gateways/GpEcomConnector.d.ts +36 -0
- package/lib/src/Gateways/GpEcomConnector.js +557 -0
- package/lib/src/Gateways/GpEcomConnector.js.map +1 -0
- package/lib/src/Gateways/IPayFacProvider.d.ts +5 -0
- package/lib/src/Gateways/IPayFacProvider.js +3 -0
- package/lib/src/Gateways/IPayFacProvider.js.map +1 -0
- package/lib/src/Gateways/IPaymentGateway.d.ts +8 -0
- package/lib/src/Gateways/IPaymentGateway.js +3 -0
- package/lib/src/Gateways/IPaymentGateway.js.map +1 -0
- package/lib/src/Gateways/IRecurringService.d.ts +6 -0
- package/lib/src/Gateways/IRecurringService.js +3 -0
- package/lib/src/Gateways/IRecurringService.js.map +1 -0
- package/lib/src/Gateways/PayPlanConnector.d.ts +42 -0
- package/lib/src/Gateways/PayPlanConnector.js +553 -0
- package/lib/src/Gateways/PayPlanConnector.js.map +1 -0
- package/lib/src/Gateways/PorticoConnector.d.ts +44 -0
- package/lib/src/Gateways/PorticoConnector.js +1018 -0
- package/lib/src/Gateways/PorticoConnector.js.map +1 -0
- package/lib/src/Gateways/ProPayConnector.d.ts +41 -0
- package/lib/src/Gateways/ProPayConnector.js +695 -0
- package/lib/src/Gateways/ProPayConnector.js.map +1 -0
- package/lib/src/Gateways/RealexConnector.d.ts +30 -0
- package/lib/src/Gateways/RealexConnector.js +524 -0
- package/lib/src/Gateways/RealexConnector.js.map +1 -0
- package/lib/src/Gateways/RestGateway.d.ts +6 -0
- package/lib/src/Gateways/RestGateway.js +32 -0
- package/lib/src/Gateways/RestGateway.js.map +1 -0
- package/lib/src/Gateways/XmlGateway.d.ts +6 -0
- package/lib/src/Gateways/XmlGateway.js +38 -0
- package/lib/src/Gateways/XmlGateway.js.map +1 -0
- package/lib/src/Gateways/https-wrapper.d.ts +3 -0
- package/lib/src/Gateways/https-wrapper.js +36 -0
- package/lib/src/Gateways/https-wrapper.js.map +1 -0
- package/lib/src/Gateways/index.d.ts +8 -0
- package/lib/src/Gateways/index.js +21 -0
- package/lib/src/Gateways/index.js.map +1 -0
- package/lib/src/HostedPaymentConfig.d.ts +12 -0
- package/lib/src/HostedPaymentConfig.js +10 -0
- package/lib/src/HostedPaymentConfig.js.map +1 -0
- package/lib/src/Mapping/GpEcomMapping.d.ts +9 -0
- package/lib/src/Mapping/GpEcomMapping.js +74 -0
- package/lib/src/Mapping/GpEcomMapping.js.map +1 -0
- package/lib/src/Mapping/index.d.ts +1 -0
- package/lib/src/Mapping/index.js +14 -0
- package/lib/src/Mapping/index.js.map +1 -0
- package/lib/src/PaymentMethods/Cash.d.ts +8 -0
- package/lib/src/PaymentMethods/Cash.js +37 -0
- package/lib/src/PaymentMethods/Cash.js.map +1 -0
- package/lib/src/PaymentMethods/Credit.d.ts +85 -0
- package/lib/src/PaymentMethods/Credit.js +107 -0
- package/lib/src/PaymentMethods/Credit.js.map +1 -0
- package/lib/src/PaymentMethods/CreditCardData.d.ts +20 -0
- package/lib/src/PaymentMethods/CreditCardData.js +58 -0
- package/lib/src/PaymentMethods/CreditCardData.js.map +1 -0
- package/lib/src/PaymentMethods/CreditTrackData.d.ts +7 -0
- package/lib/src/PaymentMethods/CreditTrackData.js +28 -0
- package/lib/src/PaymentMethods/CreditTrackData.js.map +1 -0
- package/lib/src/PaymentMethods/Debit.d.ts +40 -0
- package/lib/src/PaymentMethods/Debit.js +71 -0
- package/lib/src/PaymentMethods/Debit.js.map +1 -0
- package/lib/src/PaymentMethods/DebitTrackData.d.ts +7 -0
- package/lib/src/PaymentMethods/DebitTrackData.js +28 -0
- package/lib/src/PaymentMethods/DebitTrackData.js.map +1 -0
- package/lib/src/PaymentMethods/EBT.d.ts +48 -0
- package/lib/src/PaymentMethods/EBT.js +89 -0
- package/lib/src/PaymentMethods/EBT.js.map +1 -0
- package/lib/src/PaymentMethods/EBTCardData.d.ts +16 -0
- package/lib/src/PaymentMethods/EBTCardData.js +33 -0
- package/lib/src/PaymentMethods/EBTCardData.js.map +1 -0
- package/lib/src/PaymentMethods/EBTTrackData.d.ts +8 -0
- package/lib/src/PaymentMethods/EBTTrackData.js +28 -0
- package/lib/src/PaymentMethods/EBTTrackData.js.map +1 -0
- package/lib/src/PaymentMethods/ECheck.d.ts +32 -0
- package/lib/src/PaymentMethods/ECheck.js +41 -0
- package/lib/src/PaymentMethods/ECheck.js.map +1 -0
- package/lib/src/PaymentMethods/GiftCard.d.ts +131 -0
- package/lib/src/PaymentMethods/GiftCard.js +206 -0
- package/lib/src/PaymentMethods/GiftCard.js.map +1 -0
- package/lib/src/PaymentMethods/Interfaces.d.ts +55 -0
- package/lib/src/PaymentMethods/Interfaces.js +3 -0
- package/lib/src/PaymentMethods/Interfaces.js.map +1 -0
- package/lib/src/PaymentMethods/PaymentMethod.d.ts +19 -0
- package/lib/src/PaymentMethods/PaymentMethod.js +115 -0
- package/lib/src/PaymentMethods/PaymentMethod.js.map +1 -0
- package/lib/src/PaymentMethods/RecurringPaymentMethod.d.ts +23 -0
- package/lib/src/PaymentMethods/RecurringPaymentMethod.js +78 -0
- package/lib/src/PaymentMethods/RecurringPaymentMethod.js.map +1 -0
- package/lib/src/PaymentMethods/TransactionReference.d.ts +10 -0
- package/lib/src/PaymentMethods/TransactionReference.js +13 -0
- package/lib/src/PaymentMethods/TransactionReference.js.map +1 -0
- package/lib/src/PaymentMethods/index.d.ts +15 -0
- package/lib/src/PaymentMethods/index.js +28 -0
- package/lib/src/PaymentMethods/index.js.map +1 -0
- package/lib/src/ServiceConfigs/AcceptorConfig.d.ts +41 -0
- package/lib/src/ServiceConfigs/AcceptorConfig.js +30 -0
- package/lib/src/ServiceConfigs/AcceptorConfig.js.map +1 -0
- package/lib/src/ServiceConfigs/Configuration.d.ts +15 -0
- package/lib/src/ServiceConfigs/Configuration.js +16 -0
- package/lib/src/ServiceConfigs/Configuration.js.map +1 -0
- package/lib/src/ServiceConfigs/Gateways/GatewayConfig.d.ts +14 -0
- package/lib/src/ServiceConfigs/Gateways/GatewayConfig.js +46 -0
- package/lib/src/ServiceConfigs/Gateways/GatewayConfig.js.map +1 -0
- package/lib/src/ServiceConfigs/Gateways/GpEcomConfig.d.ts +27 -0
- package/lib/src/ServiceConfigs/Gateways/GpEcomConfig.js +61 -0
- package/lib/src/ServiceConfigs/Gateways/GpEcomConfig.js.map +1 -0
- package/lib/src/ServiceConfigs/Gateways/index.d.ts +2 -0
- package/lib/src/ServiceConfigs/Gateways/index.js +15 -0
- package/lib/src/ServiceConfigs/Gateways/index.js.map +1 -0
- package/lib/src/ServiceConfigs/ServicesConfig.d.ts +27 -0
- package/lib/src/ServiceConfigs/ServicesConfig.js +51 -0
- package/lib/src/ServiceConfigs/ServicesConfig.js.map +1 -0
- package/lib/src/ServiceConfigs/ServicesConfigsAdded.d.ts +10 -0
- package/lib/src/ServiceConfigs/ServicesConfigsAdded.js +27 -0
- package/lib/src/ServiceConfigs/ServicesConfigsAdded.js.map +1 -0
- package/lib/src/ServiceConfigs/index.d.ts +5 -0
- package/lib/src/ServiceConfigs/index.js +18 -0
- package/lib/src/ServiceConfigs/index.js.map +1 -0
- package/lib/src/Services/BatchService.d.ts +4 -0
- package/lib/src/Services/BatchService.js +18 -0
- package/lib/src/Services/BatchService.js.map +1 -0
- package/lib/src/Services/CheckService.d.ts +6 -0
- package/lib/src/Services/CheckService.js +21 -0
- package/lib/src/Services/CheckService.js.map +1 -0
- package/lib/src/Services/CreditService.d.ts +12 -0
- package/lib/src/Services/CreditService.js +55 -0
- package/lib/src/Services/CreditService.js.map +1 -0
- package/lib/src/Services/DebitService.d.ts +7 -0
- package/lib/src/Services/DebitService.js +29 -0
- package/lib/src/Services/DebitService.js.map +1 -0
- package/lib/src/Services/EBTService.d.ts +8 -0
- package/lib/src/Services/EBTService.js +33 -0
- package/lib/src/Services/EBTService.js.map +1 -0
- package/lib/src/Services/GiftService.d.ts +16 -0
- package/lib/src/Services/GiftService.js +55 -0
- package/lib/src/Services/GiftService.js.map +1 -0
- package/lib/src/Services/HostedService.d.ts +9 -0
- package/lib/src/Services/HostedService.js +60 -0
- package/lib/src/Services/HostedService.js.map +1 -0
- package/lib/src/Services/PayFacService.d.ts +26 -0
- package/lib/src/Services/PayFacService.js +78 -0
- package/lib/src/Services/PayFacService.js.map +1 -0
- package/lib/src/Services/RecurringService.d.ts +8 -0
- package/lib/src/Services/RecurringService.js +28 -0
- package/lib/src/Services/RecurringService.js.map +1 -0
- package/lib/src/Services/ReportingService.d.ts +6 -0
- package/lib/src/Services/ReportingService.js +20 -0
- package/lib/src/Services/ReportingService.js.map +1 -0
- package/lib/src/Services/index.d.ts +9 -0
- package/lib/src/Services/index.js +22 -0
- package/lib/src/Services/index.js.map +1 -0
- package/lib/src/ServicesConfig.d.ts +27 -0
- package/lib/src/ServicesConfig.js +51 -0
- package/lib/src/ServicesConfig.js.map +1 -0
- package/lib/src/ServicesContainer.d.ts +26 -0
- package/lib/src/ServicesContainer.js +140 -0
- package/lib/src/ServicesContainer.js.map +1 -0
- package/lib/src/Utils/GenerationUtils.d.ts +5 -0
- package/lib/src/Utils/GenerationUtils.js +37 -0
- package/lib/src/Utils/GenerationUtils.js.map +1 -0
- package/lib/src/Utils/InputValidation.d.ts +12 -0
- package/lib/src/Utils/InputValidation.js +73 -0
- package/lib/src/Utils/InputValidation.js.map +1 -0
- package/lib/src/Utils/Sha1.d.ts +6 -0
- package/lib/src/Utils/Sha1.js +226 -0
- package/lib/src/Utils/Sha1.js.map +1 -0
- package/lib/src/Utils/StringUtils.d.ts +6 -0
- package/lib/src/Utils/StringUtils.js +54 -0
- package/lib/src/Utils/StringUtils.js.map +1 -0
- package/lib/src/Utils/index.d.ts +2 -0
- package/lib/src/Utils/index.js +15 -0
- package/lib/src/Utils/index.js.map +1 -0
- package/lib/src/index.d.ts +12 -0
- package/lib/src/index.js +29 -0
- package/lib/src/index.js.map +1 -0
- package/lib/test/Data/TestCards.d.ts +24 -0
- package/lib/test/Data/TestCards.js +233 -0
- package/lib/test/Data/TestCards.js.map +1 -0
- package/lib/test/Data/TestChecks.d.ts +4 -0
- package/lib/test/Data/TestChecks.js +33 -0
- package/lib/test/Data/TestChecks.js.map +1 -0
- package/lib/test/Data/index.d.ts +2 -0
- package/lib/test/Data/index.js +15 -0
- package/lib/test/Data/index.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/AchTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/AchTest.js +113 -0
- package/lib/test/Integration/Gateways/PorticoConnector/AchTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.js +484 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.js +84 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.js +1721 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.js +84 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.js +1758 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.js +683 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.js +2219 -0
- package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.js +708 -0
- package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.js +152 -0
- package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.js +172 -0
- package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.js +193 -0
- package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.js +378 -0
- package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.js +197 -0
- package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.js.map +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.js +48 -0
- package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTests.js +101 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTests.js +353 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTests.js +124 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTests.js +143 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.d.ts +39 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.js +372 -0
- package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTests.js +101 -0
- package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTests.js +536 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTests.js +125 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTests.d.ts +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTests.js +145 -0
- package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTests.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.d.ts +33 -0
- package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.js +269 -0
- package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.js.map +1 -0
- package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.d.ts +4 -0
- package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.js +31 -0
- package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/AuthTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/AuthTest.js +4374 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/AuthTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/AvsTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/AvsTest.js +759 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/AvsTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/CreditTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/CreditTest.js +2400 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/CreditTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/HoldTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/HoldTest.js +1657 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/HoldTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ManualTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ManualTest.js +5651 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ManualTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/OtbTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/OtbTest.js +1986 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/OtbTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/RebateTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/RebateTest.js +2370 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/RebateTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ReleaseTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ReleaseTest.js +1704 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ReleaseTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/SettleTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/SettleTest.js +2054 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/SettleTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ValidationTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ValidationTest.js +2470 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/ValidationTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/VerifyEnrolledTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/VerifyEnrolledTest.js +3117 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/VerifyEnrolledTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/VoidTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/VoidTest.js +2032 -0
- package/lib/test/Integration/Gateways/RealexConnector/Certification/VoidTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/CreditTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/CreditTest.js +323 -0
- package/lib/test/Integration/Gateways/RealexConnector/CreditTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/HppTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/HppTest.js +99 -0
- package/lib/test/Integration/Gateways/RealexConnector/HppTest.js.map +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/RecurringTest.d.ts +1 -0
- package/lib/test/Integration/Gateways/RealexConnector/RecurringTest.js +264 -0
- package/lib/test/Integration/Gateways/RealexConnector/RecurringTest.js.map +1 -0
- package/lib/test/Integration/Services/CheckServiceTest.d.ts +1 -0
- package/lib/test/Integration/Services/CheckServiceTest.js +99 -0
- package/lib/test/Integration/Services/CheckServiceTest.js.map +1 -0
- package/lib/test/Integration/Services/CreditServiceTest.d.ts +1 -0
- package/lib/test/Integration/Services/CreditServiceTest.js +314 -0
- package/lib/test/Integration/Services/CreditServiceTest.js.map +1 -0
- package/lib/test/Integration/Services/DebitServiceTest.d.ts +1 -0
- package/lib/test/Integration/Services/DebitServiceTest.js +155 -0
- package/lib/test/Integration/Services/DebitServiceTest.js.map +1 -0
- package/lib/test/Integration/Services/EBTServiceTest.d.ts +1 -0
- package/lib/test/Integration/Services/EBTServiceTest.js +136 -0
- package/lib/test/Integration/Services/EBTServiceTest.js.map +1 -0
- package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.d.ts +1 -0
- package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.js +162 -0
- package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.js.map +1 -0
- package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.d.ts +1 -0
- package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.js +140 -0
- package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.js.map +1 -0
- package/lib/test/Unit/Gateways/GpEcomConnector/CreditTest.d.ts +1 -0
- package/lib/test/Unit/Gateways/GpEcomConnector/CreditTest.js +73 -0
- package/lib/test/Unit/Gateways/GpEcomConnector/CreditTest.js.map +1 -0
- package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.d.ts +1 -0
- package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.js +203 -0
- package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.js.map +1 -0
- package/lib/test/Unit/Gateways/RealexConnector/CreditTest.d.ts +1 -0
- package/lib/test/Unit/Gateways/RealexConnector/CreditTest.js +71 -0
- package/lib/test/Unit/Gateways/RealexConnector/CreditTest.js.map +1 -0
- package/package.json +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ValidationClause.js","sourceRoot":"","sources":["../../../../src/Builders/BaseBuilder/ValidationClause.ts"],"names":[],"mappings":";;;AAIA;IAOE,0BACE,MAAmB,EACnB,MAAwB,EACxB,YAAoB;QAApB,6BAAA,EAAA,oBAAoB;QAEpB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;IACnC,CAAC;IAEM,oCAAS,GAAhB,UAAiB,OAAgB;QAAjC,iBAgBC;QAfC,IAAI,CAAC,QAAQ,GAAG,UAAI,OAAuB;YACzC,IAAM,KAAK,GAAG,OAAO,CAAC,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAC5C,OAAO,SAAS,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,CAAC;QAC/C,CAAC,CAAC;QACF,IAAI,CAAC,OAAO,GAAG,OAAO;YACpB,CAAC,CAAC,OAAO;YACT,CAAC,CAAI,IAAI,CAAC,MAAM,CAAC,QAAQ,+CAA4C,CAAC;QAExE,IAAI,IAAI,CAAC,YAAY,EAAE;YACrB,OAAO,IAAI,CAAC,MAAM,CAAC;SACpB;QAED,OAAO,IAAI,CAAC,MAAM;aACf,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;aAC1C,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB,EAAE,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;IAClE,CAAC;IAEM,iCAAM,GAAb,UAAc,OAAgB;QAA9B,iBAgBC;QAfC,IAAI,CAAC,QAAQ,GAAG,UAAI,OAAuB;YACzC,IAAM,KAAK,GAAG,OAAO,CAAC,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAC5C,OAAO,SAAS,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,CAAC;QAC/C,CAAC,CAAC;QACF,IAAI,CAAC,OAAO,GAAG,OAAO;YACpB,CAAC,CAAC,OAAO;YACT,CAAC,CAAI,IAAI,CAAC,MAAM,CAAC,QAAQ,8CAA2C,CAAC;QAEvE,IAAI,IAAI,CAAC,YAAY,EAAE;YACrB,OAAO,IAAI,CAAC,MAAM,CAAC;SACpB;QAED,OAAO,IAAI,CAAC,MAAM;aACf,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;aAC1C,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB,EAAE,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;IAClE,CAAC;IAEM,qCAAU,GAAjB,UAAkB,OAAgB;QAAlC,iBAgBC;QAfC,IAAI,CAAC,QAAQ,GAAG,UAAI,OAAuB;YACzC,IAAM,KAAK,GAAG,OAAO,CAAC,KAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;YAC5C,OAAO,CAAC,CAAC,KAAK,CAAC;QACjB,CAAC,CAAC;QACF,IAAI,CAAC,OAAO,GAAG,OAAO;YACpB,CAAC,CAAC,OAAO;YACT,CAAC,CAAI,IAAI,CAAC,MAAM,CAAC,QAAQ,gDAA6C,CAAC;QAEzE,IAAI,IAAI,CAAC,YAAY,EAAE;YACrB,OAAO,IAAI,CAAC,MAAM,CAAC;SACpB;QAED,OAAO,IAAI,CAAC,MAAM;aACf,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;aAC1C,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,kBAAkB,EAAE,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;IAClE,CAAC;IACH,uBAAC;AAAD,CAAC,AAtED,IAsEC;AAtEY,4CAAgB"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ValidationClause } from "./ValidationClause";
|
|
2
|
+
import { Validations } from "./Validations";
|
|
3
|
+
export declare class ValidationTarget {
|
|
4
|
+
parent: Validations;
|
|
5
|
+
type: number;
|
|
6
|
+
property: string;
|
|
7
|
+
clause: ValidationClause;
|
|
8
|
+
constraint: number;
|
|
9
|
+
constraintProperty: string;
|
|
10
|
+
enumName: string;
|
|
11
|
+
precondition: ValidationClause;
|
|
12
|
+
constructor(parent: Validations, enumName: string, type: number);
|
|
13
|
+
with(property: string, constraint: number): this;
|
|
14
|
+
check(targetProperty: string): ValidationClause;
|
|
15
|
+
when(targetProperty: string): ValidationClause;
|
|
16
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ValidationTarget = void 0;
|
|
4
|
+
var ValidationClause_1 = require("./ValidationClause");
|
|
5
|
+
var ValidationTarget = /** @class */ (function () {
|
|
6
|
+
function ValidationTarget(parent, enumName, type) {
|
|
7
|
+
this.parent = parent;
|
|
8
|
+
this.type = type;
|
|
9
|
+
this.enumName = enumName;
|
|
10
|
+
}
|
|
11
|
+
ValidationTarget.prototype.with = function (property, constraint) {
|
|
12
|
+
this.constraintProperty = property;
|
|
13
|
+
this.constraint = constraint;
|
|
14
|
+
return this;
|
|
15
|
+
};
|
|
16
|
+
ValidationTarget.prototype.check = function (targetProperty) {
|
|
17
|
+
this.property = targetProperty;
|
|
18
|
+
this.clause = new ValidationClause_1.ValidationClause(this.parent, this);
|
|
19
|
+
return this.clause;
|
|
20
|
+
};
|
|
21
|
+
ValidationTarget.prototype.when = function (targetProperty) {
|
|
22
|
+
this.property = targetProperty;
|
|
23
|
+
this.precondition = new ValidationClause_1.ValidationClause(this.parent, this, true);
|
|
24
|
+
return this.precondition;
|
|
25
|
+
};
|
|
26
|
+
return ValidationTarget;
|
|
27
|
+
}());
|
|
28
|
+
exports.ValidationTarget = ValidationTarget;
|
|
29
|
+
//# sourceMappingURL=ValidationTarget.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ValidationTarget.js","sourceRoot":"","sources":["../../../../src/Builders/BaseBuilder/ValidationTarget.ts"],"names":[],"mappings":";;;AAAA,uDAAsD;AAGtD;IAUE,0BAAmB,MAAmB,EAAE,QAAgB,EAAE,IAAY;QACpE,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;IAC3B,CAAC;IAEM,+BAAI,GAAX,UAAY,QAAgB,EAAE,UAAkB;QAC9C,IAAI,CAAC,kBAAkB,GAAG,QAAQ,CAAC;QACnC,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,OAAO,IAAI,CAAC;IACd,CAAC;IAEM,gCAAK,GAAZ,UAAa,cAAsB;QACjC,IAAI,CAAC,QAAQ,GAAG,cAAc,CAAC;QAC/B,IAAI,CAAC,MAAM,GAAG,IAAI,mCAAgB,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;QACtD,OAAO,IAAI,CAAC,MAAM,CAAC;IACrB,CAAC;IAEM,+BAAI,GAAX,UAAY,cAAsB;QAChC,IAAI,CAAC,QAAQ,GAAG,cAAc,CAAC;QAC/B,IAAI,CAAC,YAAY,GAAG,IAAI,mCAAgB,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;QAClE,OAAO,IAAI,CAAC,YAAY,CAAC;IAC3B,CAAC;IACH,uBAAC;AAAD,CAAC,AAjCD,IAiCC;AAjCY,4CAAgB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { BaseBuilder } from "../../";
|
|
2
|
+
import { ValidationTarget } from "./ValidationTarget";
|
|
3
|
+
export interface IRuleSet {
|
|
4
|
+
[key: string]: ValidationTarget[][];
|
|
5
|
+
}
|
|
6
|
+
export declare class Validations {
|
|
7
|
+
rules: IRuleSet;
|
|
8
|
+
constructor();
|
|
9
|
+
of(enumProperty: string, type: number): ValidationTarget;
|
|
10
|
+
validate<T>(builder: BaseBuilder<T>): void;
|
|
11
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Validations = void 0;
|
|
4
|
+
var __1 = require("../../");
|
|
5
|
+
var ValidationTarget_1 = require("./ValidationTarget");
|
|
6
|
+
var Validations = /** @class */ (function () {
|
|
7
|
+
function Validations() {
|
|
8
|
+
this.rules = {};
|
|
9
|
+
}
|
|
10
|
+
Validations.prototype.of = function (enumProperty, type) {
|
|
11
|
+
if (!this.rules.hasOwnProperty(enumProperty)) {
|
|
12
|
+
this.rules[enumProperty] = [];
|
|
13
|
+
}
|
|
14
|
+
if (!this.rules[enumProperty].hasOwnProperty(type.toString())) {
|
|
15
|
+
this.rules[enumProperty][type] = [];
|
|
16
|
+
}
|
|
17
|
+
var target = new ValidationTarget_1.ValidationTarget(this, enumProperty, type);
|
|
18
|
+
this.rules[enumProperty][type].push(target);
|
|
19
|
+
return target;
|
|
20
|
+
};
|
|
21
|
+
Validations.prototype.validate = function (builder) {
|
|
22
|
+
var _this = this;
|
|
23
|
+
Object.keys(this.rules).forEach(function (enumName) {
|
|
24
|
+
_this.rules[enumName].forEach(function (rules, iKey) {
|
|
25
|
+
var value = builder[enumName];
|
|
26
|
+
if ((value === undefined || value === null) &&
|
|
27
|
+
builder instanceof __1.TransactionBuilder &&
|
|
28
|
+
builder.paymentMethod) {
|
|
29
|
+
value = builder.paymentMethod[enumName];
|
|
30
|
+
if (value === undefined || value === null) {
|
|
31
|
+
return;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
if ((iKey & value) !== value) {
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
for (var _i = 0, rules_1 = rules; _i < rules_1.length; _i++) {
|
|
38
|
+
var validation = rules_1[_i];
|
|
39
|
+
if (!validation.clause) {
|
|
40
|
+
continue;
|
|
41
|
+
}
|
|
42
|
+
if (validation.constraint !== undefined &&
|
|
43
|
+
validation.constraint !== null &&
|
|
44
|
+
validation.constraint !== builder[validation.constraintProperty]) {
|
|
45
|
+
continue;
|
|
46
|
+
}
|
|
47
|
+
if (!validation.clause.callback(builder)) {
|
|
48
|
+
throw new __1.BuilderError(validation.clause.message);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
return Validations;
|
|
55
|
+
}());
|
|
56
|
+
exports.Validations = Validations;
|
|
57
|
+
//# sourceMappingURL=Validations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Validations.js","sourceRoot":"","sources":["../../../../src/Builders/BaseBuilder/Validations.ts"],"names":[],"mappings":";;;AAAA,4BAAuE;AACvE,uDAAsD;AAMtD;IAGE;QACE,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC;IAClB,CAAC;IAEM,wBAAE,GAAT,UAAU,YAAoB,EAAE,IAAY;QAC1C,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,YAAY,CAAC,EAAE;YAC5C,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,GAAG,EAAE,CAAC;SAC/B;QAED,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,cAAc,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,EAAE;YAC7D,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC;SACrC;QAED,IAAM,MAAM,GAAG,IAAI,mCAAgB,CAAC,IAAI,EAAE,YAAY,EAAE,IAAI,CAAC,CAAC;QAC9D,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QAC5C,OAAO,MAAM,CAAC;IAChB,CAAC;IAEM,8BAAQ,GAAf,UAAmB,OAAuB;QAA1C,iBAuCC;QAtCC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,UAAC,QAAQ;YACvC,KAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,OAAO,CAAC,UAAC,KAAK,EAAE,IAAI;gBACvC,IAAI,KAAK,GAAW,OAAO,CAAC,QAAQ,CAAC,CAAC;gBAEtC,IACE,CAAC,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,IAAI,CAAC;oBACvC,OAAO,YAAY,sBAAkB;oBACrC,OAAO,CAAC,aAAa,EACrB;oBACA,KAAK,GAAG,OAAO,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC;oBACxC,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,IAAI,EAAE;wBACzC,OAAO;qBACR;iBACF;gBAED,IAAI,CAAC,IAAI,GAAG,KAAK,CAAC,KAAK,KAAK,EAAE;oBAC5B,OAAO;iBACR;gBAED,KAAyB,UAAK,EAAL,eAAK,EAAL,mBAAK,EAAL,IAAK,EAAE;oBAA3B,IAAM,UAAU,cAAA;oBACnB,IAAI,CAAC,UAAU,CAAC,MAAM,EAAE;wBACtB,SAAS;qBACV;oBAED,IACE,UAAU,CAAC,UAAU,KAAK,SAAS;wBACnC,UAAU,CAAC,UAAU,KAAK,IAAI;wBAC9B,UAAU,CAAC,UAAU,KAAK,OAAO,CAAC,UAAU,CAAC,kBAAkB,CAAC,EAChE;wBACA,SAAS;qBACV;oBAED,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE;wBACxC,MAAM,IAAI,gBAAY,CAAC,UAAU,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;qBACnD;iBACF;YACH,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IACH,kBAAC;AAAD,CAAC,AA7DD,IA6DC;AA7DY,kCAAW"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Validations } from "./BaseBuilder/Validations";
|
|
2
|
+
export interface IDictionary<T> {
|
|
3
|
+
[key: string]: T;
|
|
4
|
+
}
|
|
5
|
+
export declare abstract class BaseBuilder<T> {
|
|
6
|
+
protected validations: Validations;
|
|
7
|
+
[key: string]: any;
|
|
8
|
+
constructor();
|
|
9
|
+
execute(): Promise<T | undefined>;
|
|
10
|
+
protected abstract setupValidations(): void;
|
|
11
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BaseBuilder = void 0;
|
|
4
|
+
var Validations_1 = require("./BaseBuilder/Validations");
|
|
5
|
+
var BaseBuilder = /** @class */ (function () {
|
|
6
|
+
function BaseBuilder() {
|
|
7
|
+
this.validations = new Validations_1.Validations();
|
|
8
|
+
this.setupValidations();
|
|
9
|
+
}
|
|
10
|
+
BaseBuilder.prototype.execute = function () {
|
|
11
|
+
this.validations.validate(this);
|
|
12
|
+
return Promise.resolve(undefined);
|
|
13
|
+
};
|
|
14
|
+
return BaseBuilder;
|
|
15
|
+
}());
|
|
16
|
+
exports.BaseBuilder = BaseBuilder;
|
|
17
|
+
//# sourceMappingURL=BaseBuilder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseBuilder.js","sourceRoot":"","sources":["../../../src/Builders/BaseBuilder.ts"],"names":[],"mappings":";;;AAAA,yDAAwD;AAMxD;IAIE;QACE,IAAI,CAAC,WAAW,GAAG,IAAI,yBAAW,EAAE,CAAC;QACrC,IAAI,CAAC,gBAAgB,EAAE,CAAC;IAC1B,CAAC;IAEM,6BAAO,GAAd;QACE,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QAChC,OAAO,OAAO,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;IACpC,CAAC;IAGH,kBAAC;AAAD,CAAC,AAfD,IAeC;AAfqB,kCAAW"}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { ReasonCode, TaxType, Transaction } from "../";
|
|
2
|
+
import { TransactionBuilder } from "./TransactionBuilder";
|
|
3
|
+
export declare class ManagementBuilder extends TransactionBuilder<Transaction> {
|
|
4
|
+
amount: string | number;
|
|
5
|
+
authAmount: string | number;
|
|
6
|
+
get authorizationCode(): string | undefined;
|
|
7
|
+
get clientTransactionId(): string | undefined;
|
|
8
|
+
currency: string;
|
|
9
|
+
description: string;
|
|
10
|
+
gratuity: string | number;
|
|
11
|
+
get orderId(): string | undefined;
|
|
12
|
+
poNumber: string;
|
|
13
|
+
reasonCode?: ReasonCode;
|
|
14
|
+
taxAmount: string | number;
|
|
15
|
+
taxType: TaxType;
|
|
16
|
+
get transactionId(): string | undefined;
|
|
17
|
+
constructor(type: number);
|
|
18
|
+
/**
|
|
19
|
+
* Executes the builder against the gateway.
|
|
20
|
+
*
|
|
21
|
+
* @returns Promise<Transaction>
|
|
22
|
+
*/
|
|
23
|
+
execute(): Promise<Transaction>;
|
|
24
|
+
protected setupValidations(): void;
|
|
25
|
+
/**
|
|
26
|
+
* Sets the current transaction's amount.
|
|
27
|
+
*
|
|
28
|
+
* @param amount The amount
|
|
29
|
+
* @returns ManagementBuilder
|
|
30
|
+
*/
|
|
31
|
+
withAmount(amount?: string | number): this;
|
|
32
|
+
/**
|
|
33
|
+
* Sets the current transaction's authorized amount; where applicable.
|
|
34
|
+
*
|
|
35
|
+
* @param amount The authorized amount
|
|
36
|
+
* @returns ManagementBuilder
|
|
37
|
+
*/
|
|
38
|
+
withAuthAmount(amount?: string | number): this;
|
|
39
|
+
/**
|
|
40
|
+
* Sets the currency.
|
|
41
|
+
*
|
|
42
|
+
* The formatting for the supplied value will currently depend on
|
|
43
|
+
* the configured gateway's requirements.
|
|
44
|
+
*
|
|
45
|
+
* @param currency The currency
|
|
46
|
+
* @returns ManagementBuilder
|
|
47
|
+
*/
|
|
48
|
+
withCurrency(currency?: string): this;
|
|
49
|
+
/**
|
|
50
|
+
* Sets the transaction's description.
|
|
51
|
+
*
|
|
52
|
+
* This value is not guaranteed to be sent in the authorization
|
|
53
|
+
* or settlement process.
|
|
54
|
+
*
|
|
55
|
+
* @param description The description
|
|
56
|
+
* @returns ManagementBuilder
|
|
57
|
+
*/
|
|
58
|
+
withDescription(description?: string): this;
|
|
59
|
+
/**
|
|
60
|
+
* Sets the gratuity amount; where applicable.
|
|
61
|
+
*
|
|
62
|
+
* This value is information only and does not affect
|
|
63
|
+
* the authorization amount.
|
|
64
|
+
*
|
|
65
|
+
* @param gratuity The gratuity amount
|
|
66
|
+
* @returns ManagementBuilder
|
|
67
|
+
*/
|
|
68
|
+
withGratuity(gratuity?: string | number): this;
|
|
69
|
+
/**
|
|
70
|
+
* Sets the purchase order number; where applicable.
|
|
71
|
+
*
|
|
72
|
+
* @param poNumber The PO number
|
|
73
|
+
* @returns ManagementBuilder
|
|
74
|
+
*/
|
|
75
|
+
withPoNumber(poNumber?: string): this;
|
|
76
|
+
/**
|
|
77
|
+
* Sets the reason code for the transaction.
|
|
78
|
+
*
|
|
79
|
+
* @param reasonCode The reason code
|
|
80
|
+
* @returns ManagementBuilder
|
|
81
|
+
*/
|
|
82
|
+
withReasonCode(reasonCode?: ReasonCode): this;
|
|
83
|
+
/**
|
|
84
|
+
* Sets the tax amount.
|
|
85
|
+
*
|
|
86
|
+
* Useful for commercial purchase card requests.
|
|
87
|
+
*
|
|
88
|
+
* @see AuthorizationBuilder.WithCommercialRequest
|
|
89
|
+
* @param amount The tax amount
|
|
90
|
+
* @returns ManagementBuilder
|
|
91
|
+
*/
|
|
92
|
+
withTaxAmount(amount?: string | number): this;
|
|
93
|
+
/**
|
|
94
|
+
* Sets the tax type.
|
|
95
|
+
*
|
|
96
|
+
* Useful for commercial purchase card requests.
|
|
97
|
+
*
|
|
98
|
+
* @see AuthorizationBuilder.withCommercialRequest
|
|
99
|
+
* @param type The tax type
|
|
100
|
+
* @returns ManagementBuilder
|
|
101
|
+
*/
|
|
102
|
+
withTaxType(type?: TaxType): this;
|
|
103
|
+
}
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
|
3
|
+
var extendStatics = function (d, b) {
|
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
+
return extendStatics(d, b);
|
|
8
|
+
};
|
|
9
|
+
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
+
extendStatics(d, b);
|
|
13
|
+
function __() { this.constructor = d; }
|
|
14
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
+
};
|
|
16
|
+
})();
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.ManagementBuilder = void 0;
|
|
19
|
+
var __1 = require("../");
|
|
20
|
+
var TransactionBuilder_1 = require("./TransactionBuilder");
|
|
21
|
+
var ManagementBuilder = /** @class */ (function (_super) {
|
|
22
|
+
__extends(ManagementBuilder, _super);
|
|
23
|
+
function ManagementBuilder(type) {
|
|
24
|
+
return _super.call(this, type) || this;
|
|
25
|
+
}
|
|
26
|
+
Object.defineProperty(ManagementBuilder.prototype, "authorizationCode", {
|
|
27
|
+
get: function () {
|
|
28
|
+
if (this.paymentMethod instanceof __1.TransactionReference) {
|
|
29
|
+
return this.paymentMethod.authCode;
|
|
30
|
+
}
|
|
31
|
+
return undefined;
|
|
32
|
+
},
|
|
33
|
+
enumerable: false,
|
|
34
|
+
configurable: true
|
|
35
|
+
});
|
|
36
|
+
Object.defineProperty(ManagementBuilder.prototype, "clientTransactionId", {
|
|
37
|
+
get: function () {
|
|
38
|
+
if (this.paymentMethod instanceof __1.TransactionReference) {
|
|
39
|
+
return this.paymentMethod.clientTransactionId;
|
|
40
|
+
}
|
|
41
|
+
return undefined;
|
|
42
|
+
},
|
|
43
|
+
enumerable: false,
|
|
44
|
+
configurable: true
|
|
45
|
+
});
|
|
46
|
+
Object.defineProperty(ManagementBuilder.prototype, "orderId", {
|
|
47
|
+
get: function () {
|
|
48
|
+
if (this.paymentMethod instanceof __1.TransactionReference) {
|
|
49
|
+
return this.paymentMethod.orderId;
|
|
50
|
+
}
|
|
51
|
+
return undefined;
|
|
52
|
+
},
|
|
53
|
+
enumerable: false,
|
|
54
|
+
configurable: true
|
|
55
|
+
});
|
|
56
|
+
Object.defineProperty(ManagementBuilder.prototype, "transactionId", {
|
|
57
|
+
get: function () {
|
|
58
|
+
if (this.paymentMethod instanceof __1.TransactionReference) {
|
|
59
|
+
return this.paymentMethod.transactionId;
|
|
60
|
+
}
|
|
61
|
+
return undefined;
|
|
62
|
+
},
|
|
63
|
+
enumerable: false,
|
|
64
|
+
configurable: true
|
|
65
|
+
});
|
|
66
|
+
/**
|
|
67
|
+
* Executes the builder against the gateway.
|
|
68
|
+
*
|
|
69
|
+
* @returns Promise<Transaction>
|
|
70
|
+
*/
|
|
71
|
+
ManagementBuilder.prototype.execute = function () {
|
|
72
|
+
_super.prototype.execute.call(this);
|
|
73
|
+
return __1.ServicesContainer.instance()
|
|
74
|
+
.getClient()
|
|
75
|
+
.manageTransaction(this);
|
|
76
|
+
};
|
|
77
|
+
ManagementBuilder.prototype.setupValidations = function () {
|
|
78
|
+
this.validations
|
|
79
|
+
.of("transactionType",
|
|
80
|
+
/* tslint:disable:trailing-comma */
|
|
81
|
+
__1.TransactionType.Capture |
|
|
82
|
+
__1.TransactionType.Edit |
|
|
83
|
+
__1.TransactionType.Hold |
|
|
84
|
+
__1.TransactionType.Release)
|
|
85
|
+
.check("transactionId")
|
|
86
|
+
.isNotNull();
|
|
87
|
+
this.validations
|
|
88
|
+
.of("transactionType", __1.TransactionType.Edit)
|
|
89
|
+
.with("transactionModifier", __1.TransactionModifier.LevelII)
|
|
90
|
+
.check("taxType")
|
|
91
|
+
.isNotNull();
|
|
92
|
+
this.validations
|
|
93
|
+
.of("transactionType", __1.TransactionType.Refund)
|
|
94
|
+
.when("amount")
|
|
95
|
+
.isNotNull()
|
|
96
|
+
.check("currency")
|
|
97
|
+
.isNotNull();
|
|
98
|
+
};
|
|
99
|
+
/**
|
|
100
|
+
* Sets the current transaction's amount.
|
|
101
|
+
*
|
|
102
|
+
* @param amount The amount
|
|
103
|
+
* @returns ManagementBuilder
|
|
104
|
+
*/
|
|
105
|
+
ManagementBuilder.prototype.withAmount = function (amount) {
|
|
106
|
+
if (amount !== undefined) {
|
|
107
|
+
this.amount = amount;
|
|
108
|
+
}
|
|
109
|
+
return this;
|
|
110
|
+
};
|
|
111
|
+
/**
|
|
112
|
+
* Sets the current transaction's authorized amount; where applicable.
|
|
113
|
+
*
|
|
114
|
+
* @param amount The authorized amount
|
|
115
|
+
* @returns ManagementBuilder
|
|
116
|
+
*/
|
|
117
|
+
ManagementBuilder.prototype.withAuthAmount = function (amount) {
|
|
118
|
+
if (amount !== undefined) {
|
|
119
|
+
this.authAmount = amount;
|
|
120
|
+
}
|
|
121
|
+
return this;
|
|
122
|
+
};
|
|
123
|
+
/**
|
|
124
|
+
* Sets the currency.
|
|
125
|
+
*
|
|
126
|
+
* The formatting for the supplied value will currently depend on
|
|
127
|
+
* the configured gateway's requirements.
|
|
128
|
+
*
|
|
129
|
+
* @param currency The currency
|
|
130
|
+
* @returns ManagementBuilder
|
|
131
|
+
*/
|
|
132
|
+
ManagementBuilder.prototype.withCurrency = function (currency) {
|
|
133
|
+
if (currency !== undefined) {
|
|
134
|
+
this.currency = currency;
|
|
135
|
+
}
|
|
136
|
+
return this;
|
|
137
|
+
};
|
|
138
|
+
/**
|
|
139
|
+
* Sets the transaction's description.
|
|
140
|
+
*
|
|
141
|
+
* This value is not guaranteed to be sent in the authorization
|
|
142
|
+
* or settlement process.
|
|
143
|
+
*
|
|
144
|
+
* @param description The description
|
|
145
|
+
* @returns ManagementBuilder
|
|
146
|
+
*/
|
|
147
|
+
ManagementBuilder.prototype.withDescription = function (description) {
|
|
148
|
+
if (description !== undefined) {
|
|
149
|
+
this.description = description;
|
|
150
|
+
}
|
|
151
|
+
return this;
|
|
152
|
+
};
|
|
153
|
+
/**
|
|
154
|
+
* Sets the gratuity amount; where applicable.
|
|
155
|
+
*
|
|
156
|
+
* This value is information only and does not affect
|
|
157
|
+
* the authorization amount.
|
|
158
|
+
*
|
|
159
|
+
* @param gratuity The gratuity amount
|
|
160
|
+
* @returns ManagementBuilder
|
|
161
|
+
*/
|
|
162
|
+
ManagementBuilder.prototype.withGratuity = function (gratuity) {
|
|
163
|
+
if (gratuity !== undefined) {
|
|
164
|
+
this.gratuity = gratuity;
|
|
165
|
+
}
|
|
166
|
+
return this;
|
|
167
|
+
};
|
|
168
|
+
/**
|
|
169
|
+
* Sets the purchase order number; where applicable.
|
|
170
|
+
*
|
|
171
|
+
* @param poNumber The PO number
|
|
172
|
+
* @returns ManagementBuilder
|
|
173
|
+
*/
|
|
174
|
+
ManagementBuilder.prototype.withPoNumber = function (poNumber) {
|
|
175
|
+
this.transactionModifier = __1.TransactionModifier.LevelII;
|
|
176
|
+
if (poNumber !== undefined) {
|
|
177
|
+
this.poNumber = poNumber;
|
|
178
|
+
}
|
|
179
|
+
return this;
|
|
180
|
+
};
|
|
181
|
+
/**
|
|
182
|
+
* Sets the reason code for the transaction.
|
|
183
|
+
*
|
|
184
|
+
* @param reasonCode The reason code
|
|
185
|
+
* @returns ManagementBuilder
|
|
186
|
+
*/
|
|
187
|
+
ManagementBuilder.prototype.withReasonCode = function (reasonCode) {
|
|
188
|
+
if (reasonCode !== undefined) {
|
|
189
|
+
this.reasonCode = reasonCode;
|
|
190
|
+
}
|
|
191
|
+
return this;
|
|
192
|
+
};
|
|
193
|
+
/**
|
|
194
|
+
* Sets the tax amount.
|
|
195
|
+
*
|
|
196
|
+
* Useful for commercial purchase card requests.
|
|
197
|
+
*
|
|
198
|
+
* @see AuthorizationBuilder.WithCommercialRequest
|
|
199
|
+
* @param amount The tax amount
|
|
200
|
+
* @returns ManagementBuilder
|
|
201
|
+
*/
|
|
202
|
+
ManagementBuilder.prototype.withTaxAmount = function (amount) {
|
|
203
|
+
this.transactionModifier = __1.TransactionModifier.LevelII;
|
|
204
|
+
if (amount !== undefined) {
|
|
205
|
+
this.taxAmount = amount;
|
|
206
|
+
}
|
|
207
|
+
return this;
|
|
208
|
+
};
|
|
209
|
+
/**
|
|
210
|
+
* Sets the tax type.
|
|
211
|
+
*
|
|
212
|
+
* Useful for commercial purchase card requests.
|
|
213
|
+
*
|
|
214
|
+
* @see AuthorizationBuilder.withCommercialRequest
|
|
215
|
+
* @param type The tax type
|
|
216
|
+
* @returns ManagementBuilder
|
|
217
|
+
*/
|
|
218
|
+
ManagementBuilder.prototype.withTaxType = function (type) {
|
|
219
|
+
this.transactionModifier = __1.TransactionModifier.LevelII;
|
|
220
|
+
if (type !== undefined) {
|
|
221
|
+
this.taxType = type;
|
|
222
|
+
}
|
|
223
|
+
return this;
|
|
224
|
+
};
|
|
225
|
+
return ManagementBuilder;
|
|
226
|
+
}(TransactionBuilder_1.TransactionBuilder));
|
|
227
|
+
exports.ManagementBuilder = ManagementBuilder;
|
|
228
|
+
//# sourceMappingURL=ManagementBuilder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ManagementBuilder.js","sourceRoot":"","sources":["../../../src/Builders/ManagementBuilder.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,yBAQa;AACb,2DAA0D;AAE1D;IAAuC,qCAA+B;IAmCpE,2BAAmB,IAAY;eAC7B,kBAAM,IAAI,CAAC;IACb,CAAC;IAlCD,sBAAW,gDAAiB;aAA5B;YACE,IAAI,IAAI,CAAC,aAAa,YAAY,wBAAoB,EAAE;gBACtD,OAAO,IAAI,CAAC,aAAa,CAAC,QAAQ,CAAC;aACpC;YACD,OAAO,SAAS,CAAC;QACnB,CAAC;;;OAAA;IACD,sBAAW,kDAAmB;aAA9B;YACE,IAAI,IAAI,CAAC,aAAa,YAAY,wBAAoB,EAAE;gBACtD,OAAO,IAAI,CAAC,aAAa,CAAC,mBAAmB,CAAC;aAC/C;YACD,OAAO,SAAS,CAAC;QACnB,CAAC;;;OAAA;IAID,sBAAW,sCAAO;aAAlB;YACE,IAAI,IAAI,CAAC,aAAa,YAAY,wBAAoB,EAAE;gBACtD,OAAO,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC;aACnC;YACD,OAAO,SAAS,CAAC;QACnB,CAAC;;;OAAA;IAKD,sBAAW,4CAAa;aAAxB;YACE,IAAI,IAAI,CAAC,aAAa,YAAY,wBAAoB,EAAE;gBACtD,OAAO,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC;aACzC;YACD,OAAO,SAAS,CAAC;QACnB,CAAC;;;OAAA;IAMD;;;;OAIG;IACI,mCAAO,GAAd;QACE,iBAAM,OAAO,WAAE,CAAC;QAChB,OAAO,qBAAiB,CAAC,QAAQ,EAAE;aAChC,SAAS,EAAE;aACX,iBAAiB,CAAC,IAAI,CAAC,CAAC;IAC7B,CAAC;IAES,4CAAgB,GAA1B;QACE,IAAI,CAAC,WAAW;aACb,EAAE,CACD,iBAAiB;QACjB,mCAAmC;QACnC,mBAAe,CAAC,OAAO;YACrB,mBAAe,CAAC,IAAI;YACpB,mBAAe,CAAC,IAAI;YACpB,mBAAe,CAAC,OAAO,CAE1B;aACA,KAAK,CAAC,eAAe,CAAC;aACtB,SAAS,EAAE,CAAC;QAEf,IAAI,CAAC,WAAW;aACb,EAAE,CAAC,iBAAiB,EAAE,mBAAe,CAAC,IAAI,CAAC;aAC3C,IAAI,CAAC,qBAAqB,EAAE,uBAAmB,CAAC,OAAO,CAAC;aACxD,KAAK,CAAC,SAAS,CAAC;aAChB,SAAS,EAAE,CAAC;QAEf,IAAI,CAAC,WAAW;aACb,EAAE,CAAC,iBAAiB,EAAE,mBAAe,CAAC,MAAM,CAAC;aAC7C,IAAI,CAAC,QAAQ,CAAC;aACd,SAAS,EAAE;aACX,KAAK,CAAC,UAAU,CAAC;aACjB,SAAS,EAAE,CAAC;IACjB,CAAC;IAED;;;;;OAKG;IACI,sCAAU,GAAjB,UAAkB,MAAwB;QACxC,IAAI,MAAM,KAAK,SAAS,EAAE;YACxB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;SACtB;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;OAKG;IACI,0CAAc,GAArB,UAAsB,MAAwB;QAC5C,IAAI,MAAM,KAAK,SAAS,EAAE;YACxB,IAAI,CAAC,UAAU,GAAG,MAAM,CAAC;SAC1B;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;;;;OAQG;IACI,wCAAY,GAAnB,UAAoB,QAAiB;QACnC,IAAI,QAAQ,KAAK,SAAS,EAAE;YAC1B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;SAC1B;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;;;;OAQG;IACI,2CAAe,GAAtB,UAAuB,WAAoB;QACzC,IAAI,WAAW,KAAK,SAAS,EAAE;YAC7B,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;SAChC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;;;;OAQG;IACI,wCAAY,GAAnB,UAAoB,QAA0B;QAC5C,IAAI,QAAQ,KAAK,SAAS,EAAE;YAC1B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;SAC1B;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;OAKG;IACI,wCAAY,GAAnB,UAAoB,QAAiB;QACnC,IAAI,CAAC,mBAAmB,GAAG,uBAAmB,CAAC,OAAO,CAAC;QACvD,IAAI,QAAQ,KAAK,SAAS,EAAE;YAC1B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;SAC1B;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;OAKG;IACI,0CAAc,GAArB,UAAsB,UAAuB;QAC3C,IAAI,UAAU,KAAK,SAAS,EAAE;YAC5B,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;SAC9B;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;;;;OAQG;IACI,yCAAa,GAApB,UAAqB,MAAwB;QAC3C,IAAI,CAAC,mBAAmB,GAAG,uBAAmB,CAAC,OAAO,CAAC;QACvD,IAAI,MAAM,KAAK,SAAS,EAAE;YACxB,IAAI,CAAC,SAAS,GAAG,MAAM,CAAC;SACzB;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;;;;OAQG;IACI,uCAAW,GAAlB,UAAmB,IAAc;QAC/B,IAAI,CAAC,mBAAmB,GAAG,uBAAmB,CAAC,OAAO,CAAC;QACvD,IAAI,IAAI,KAAK,SAAS,EAAE;YACtB,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;SACrB;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IACH,wBAAC;AAAD,CAAC,AArND,CAAuC,uCAAkB,GAqNxD;AArNY,8CAAiB"}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { BaseBuilder } from "./";
|
|
2
|
+
import { CreditCardData } from "../PaymentMethods";
|
|
3
|
+
import { DocumentUploadData } from "../Entities/DocumentUploadData";
|
|
4
|
+
import { AccountPermissions } from "../Entities/ProFac/AccountPermissions";
|
|
5
|
+
import { BankAccountData } from "../Entities/ProFac/BankAccountData";
|
|
6
|
+
import { BankAccountOwnershipData } from "../Entities/ProFac/BankAccountOwnershipData";
|
|
7
|
+
import { BeneficialOwnerData } from "../Entities/ProFac/BeneficialOwnerData";
|
|
8
|
+
import { BusinessData } from "../Entities/ProFac/BusinessData";
|
|
9
|
+
import { DeviceData } from "../Entities/ProFac/DeviceData";
|
|
10
|
+
import { FlashFundsPaymentCardData } from "../Entities/ProFac/FlashFundsPaymentCardData";
|
|
11
|
+
import { GrossBillingInformation } from "../Entities/ProFac/GrossBillingInformation";
|
|
12
|
+
import { RenewAccountData } from "../Entities/ProFac/RenewAccountData";
|
|
13
|
+
import { SignificantOwnerData } from "../Entities/ProFac/SignificantOwnerData";
|
|
14
|
+
import { ThreatRiskData } from "../Entities/ProFac/ThreatRiskData";
|
|
15
|
+
import { UserPersonalData } from "../Entities/ProFac/UserPersonalData";
|
|
16
|
+
import { SSORequestData } from "../Entities/SSORequestData";
|
|
17
|
+
import { Address, Transaction, TransactionModifier, TransactionType } from "../";
|
|
18
|
+
import { OrderDevice } from "../Entities/ProFac/OrderDevice";
|
|
19
|
+
export declare class PayFacBuilder extends BaseBuilder<Transaction> {
|
|
20
|
+
protected setupValidations(): void;
|
|
21
|
+
transactionType: TransactionType;
|
|
22
|
+
transactionModifier: TransactionModifier;
|
|
23
|
+
bankAccountData: BankAccountData;
|
|
24
|
+
beneficialOwnerData: BeneficialOwnerData;
|
|
25
|
+
deviceData: DeviceData;
|
|
26
|
+
timeZone: string;
|
|
27
|
+
businessData: BusinessData;
|
|
28
|
+
significantOwnerData: SignificantOwnerData;
|
|
29
|
+
threatRiskData: ThreatRiskData;
|
|
30
|
+
userPersonalData: UserPersonalData;
|
|
31
|
+
creditCardInformation: CreditCardData;
|
|
32
|
+
aCHInformation: BankAccountData;
|
|
33
|
+
mailingAddressInformation: Address;
|
|
34
|
+
secondaryBankInformation: BankAccountData;
|
|
35
|
+
grossBillingInformation: GrossBillingInformation;
|
|
36
|
+
negativeLimit: string;
|
|
37
|
+
renewalAccountData: RenewAccountData;
|
|
38
|
+
accountNumber: string;
|
|
39
|
+
password: string;
|
|
40
|
+
accountPermissions: AccountPermissions;
|
|
41
|
+
primaryBankAccountOwner: BankAccountOwnershipData;
|
|
42
|
+
secondaryBankAccountOwner: BankAccountOwnershipData;
|
|
43
|
+
documentUploadData: DocumentUploadData;
|
|
44
|
+
sSORequestData: SSORequestData;
|
|
45
|
+
amount: string;
|
|
46
|
+
receivingAccountNumber: string;
|
|
47
|
+
allowPending: boolean;
|
|
48
|
+
cCAmount: string;
|
|
49
|
+
requireCCRefund: boolean;
|
|
50
|
+
transNum: string;
|
|
51
|
+
externalID: string;
|
|
52
|
+
sourceEmail: string;
|
|
53
|
+
gatewayTransactionId: string;
|
|
54
|
+
cardBrandTransactionId: string;
|
|
55
|
+
globaltransId: string;
|
|
56
|
+
globalTransSource: string;
|
|
57
|
+
orderDevice: OrderDevice;
|
|
58
|
+
constructor(type: TransactionType, modifer?: TransactionModifier);
|
|
59
|
+
execute(): Promise<Transaction>;
|
|
60
|
+
withBankAccountData(bankAccountData: BankAccountData): this;
|
|
61
|
+
withBeneficialOwnerData(beneficialOwnerData: BeneficialOwnerData): this;
|
|
62
|
+
withDeviceData(deviceData: DeviceData): this;
|
|
63
|
+
withTimeZone(timezone: string): this;
|
|
64
|
+
withBusinessData(businessData: BusinessData): this;
|
|
65
|
+
withSignificantOwnerData(significantOwnerData: SignificantOwnerData): this;
|
|
66
|
+
withThreatRiskData(threatRiskData: ThreatRiskData): this;
|
|
67
|
+
withUserPersonalData(userPersonalData: UserPersonalData): this;
|
|
68
|
+
withCreditCardData(creditCardInformation: CreditCardData): this;
|
|
69
|
+
withACHData(achInformation: BankAccountData): this;
|
|
70
|
+
withMailingAddress(mailingAddressInformation: Address): this;
|
|
71
|
+
withSecondaryBankAccountData(secondaryBankInformation: BankAccountData): this;
|
|
72
|
+
withGrossBillingSettleData(grossBillingInformation: GrossBillingInformation): this;
|
|
73
|
+
withAccountNumber(accountNumber: string): this;
|
|
74
|
+
withPassword(password: string): this;
|
|
75
|
+
withAccountPermissions(accountPermissions: AccountPermissions): this;
|
|
76
|
+
withPrimaryBankAccountOwner(primaryBankAccountOwner: BankAccountOwnershipData): this;
|
|
77
|
+
withSecondaryBankAccountOwner(secondaryBankAccountOwner: BankAccountOwnershipData): this;
|
|
78
|
+
withDocumentUploadData(docUploadData: DocumentUploadData): this;
|
|
79
|
+
withSSORequestData(ssoRequestData: SSORequestData): this;
|
|
80
|
+
withNegativeLimit(negativeLimit: string): this;
|
|
81
|
+
withRenewalAccountData(renewalAccountData: RenewAccountData): this;
|
|
82
|
+
withAmount(amount: string): this;
|
|
83
|
+
withFlashFundsPaymentCardData(cardData: FlashFundsPaymentCardData): this;
|
|
84
|
+
withReceivingAccountNumber(receivingAccountNumber: string): this;
|
|
85
|
+
withAllowPending(allowPending: boolean): this;
|
|
86
|
+
withCCAmount(ccAmount: string): this;
|
|
87
|
+
withRequireCCRefund(requireCCRefund: boolean): this;
|
|
88
|
+
withTransNum(transNum: string): this;
|
|
89
|
+
withGatewayTransactionId(gatewayTransactionId: string): this;
|
|
90
|
+
withCardBrandTransactionId(cardBrandTransactionId: string): this;
|
|
91
|
+
withGlobaltransId(globaltransId: string): this;
|
|
92
|
+
withGlobalTransSource(globalTransSource: string): this;
|
|
93
|
+
withExternalID(externalId: string): this;
|
|
94
|
+
withSourceEmail(sourceEmail: string): this;
|
|
95
|
+
withOrderDevice(orderDevice: OrderDevice): this;
|
|
96
|
+
}
|