globalpayments-api 3.1.0 → 3.1.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.
Files changed (523) hide show
  1. package/lib/src/Builders/AuthorizationBuilder.d.ts +325 -0
  2. package/lib/src/Builders/AuthorizationBuilder.js +617 -0
  3. package/lib/src/Builders/AuthorizationBuilder.js.map +1 -0
  4. package/lib/src/Builders/BaseBuilder/ValidationClause.d.ts +14 -0
  5. package/lib/src/Builders/BaseBuilder/ValidationClause.js +62 -0
  6. package/lib/src/Builders/BaseBuilder/ValidationClause.js.map +1 -0
  7. package/lib/src/Builders/BaseBuilder/ValidationTarget.d.ts +16 -0
  8. package/lib/src/Builders/BaseBuilder/ValidationTarget.js +36 -0
  9. package/lib/src/Builders/BaseBuilder/ValidationTarget.js.map +1 -0
  10. package/lib/src/Builders/BaseBuilder/Validations.d.ts +11 -0
  11. package/lib/src/Builders/BaseBuilder/Validations.js +55 -0
  12. package/lib/src/Builders/BaseBuilder/Validations.js.map +1 -0
  13. package/lib/src/Builders/BaseBuilder.d.ts +11 -0
  14. package/lib/src/Builders/BaseBuilder.js +17 -0
  15. package/lib/src/Builders/BaseBuilder.js.map +1 -0
  16. package/lib/src/Builders/ManagementBuilder.d.ts +104 -0
  17. package/lib/src/Builders/ManagementBuilder.js +208 -0
  18. package/lib/src/Builders/ManagementBuilder.js.map +1 -0
  19. package/lib/src/Builders/PayFacBuilder.d.ts +98 -0
  20. package/lib/src/Builders/PayFacBuilder.js +234 -0
  21. package/lib/src/Builders/PayFacBuilder.js.map +1 -0
  22. package/lib/src/Builders/RecurringBuilder.d.ts +13 -0
  23. package/lib/src/Builders/RecurringBuilder.js +34 -0
  24. package/lib/src/Builders/RecurringBuilder.js.map +1 -0
  25. package/lib/src/Builders/ReportBuilder.d.ts +8 -0
  26. package/lib/src/Builders/ReportBuilder.js +21 -0
  27. package/lib/src/Builders/ReportBuilder.js.map +1 -0
  28. package/lib/src/Builders/RequestBuilder/GpApi/AccessTokenRequest.d.ts +11 -0
  29. package/lib/src/Builders/RequestBuilder/GpApi/AccessTokenRequest.js +23 -0
  30. package/lib/src/Builders/RequestBuilder/GpApi/AccessTokenRequest.js.map +1 -0
  31. package/lib/src/Builders/RequestBuilder/GpApi/GpApiAuthorizationRequestBuilder.d.ts +17 -0
  32. package/lib/src/Builders/RequestBuilder/GpApi/GpApiAuthorizationRequestBuilder.js +36 -0
  33. package/lib/src/Builders/RequestBuilder/GpApi/GpApiAuthorizationRequestBuilder.js.map +1 -0
  34. package/lib/src/Builders/RequestBuilder/GpApi/GpApiSessionInfo.d.ts +6 -0
  35. package/lib/src/Builders/RequestBuilder/GpApi/GpApiSessionInfo.js +49 -0
  36. package/lib/src/Builders/RequestBuilder/GpApi/GpApiSessionInfo.js.map +1 -0
  37. package/lib/src/Builders/RequestBuilder/GpApi/index.d.ts +3 -0
  38. package/lib/src/Builders/RequestBuilder/GpApi/index.js +20 -0
  39. package/lib/src/Builders/RequestBuilder/GpApi/index.js.map +1 -0
  40. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomAuthorizationRequestBuilder.d.ts +17 -0
  41. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomAuthorizationRequestBuilder.js +109 -0
  42. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomAuthorizationRequestBuilder.js.map +1 -0
  43. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomManagementRequestBuilder.d.ts +11 -0
  44. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomManagementRequestBuilder.js +83 -0
  45. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomManagementRequestBuilder.js.map +1 -0
  46. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomRequestBuilder.d.ts +9 -0
  47. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomRequestBuilder.js +66 -0
  48. package/lib/src/Builders/RequestBuilder/GpEcom/GpEcomRequestBuilder.js.map +1 -0
  49. package/lib/src/Builders/RequestBuilder/GpEcom/index.d.ts +3 -0
  50. package/lib/src/Builders/RequestBuilder/GpEcom/index.js +20 -0
  51. package/lib/src/Builders/RequestBuilder/GpEcom/index.js.map +1 -0
  52. package/lib/src/Builders/RequestBuilder/RequestBuilderFactory.d.ts +7 -0
  53. package/lib/src/Builders/RequestBuilder/RequestBuilderFactory.js +31 -0
  54. package/lib/src/Builders/RequestBuilder/RequestBuilderFactory.js.map +1 -0
  55. package/lib/src/Builders/RequestBuilder/index.d.ts +3 -0
  56. package/lib/src/Builders/RequestBuilder/index.js +20 -0
  57. package/lib/src/Builders/RequestBuilder/index.js.map +1 -0
  58. package/lib/src/Builders/TransactionBuilder.d.ts +12 -0
  59. package/lib/src/Builders/TransactionBuilder.js +43 -0
  60. package/lib/src/Builders/TransactionBuilder.js.map +1 -0
  61. package/lib/src/Builders/TransactionReportBuilder.d.ts +15 -0
  62. package/lib/src/Builders/TransactionReportBuilder.js +65 -0
  63. package/lib/src/Builders/TransactionReportBuilder.js.map +1 -0
  64. package/lib/src/Builders/index.d.ts +8 -0
  65. package/lib/src/Builders/index.js +25 -0
  66. package/lib/src/Builders/index.js.map +1 -0
  67. package/lib/src/ConfiguredServices.d.ts +18 -0
  68. package/lib/src/ConfiguredServices.js +24 -0
  69. package/lib/src/ConfiguredServices.js.map +1 -0
  70. package/lib/src/Entities/Address.d.ts +13 -0
  71. package/lib/src/Entities/Address.js +21 -0
  72. package/lib/src/Entities/Address.js.map +1 -0
  73. package/lib/src/Entities/BatchSummary.d.ts +6 -0
  74. package/lib/src/Entities/BatchSummary.js +11 -0
  75. package/lib/src/Entities/BatchSummary.js.map +1 -0
  76. package/lib/src/Entities/Customer.d.ts +64 -0
  77. package/lib/src/Entities/Customer.js +80 -0
  78. package/lib/src/Entities/Customer.js.map +1 -0
  79. package/lib/src/Entities/CustomerDocument.d.ts +8 -0
  80. package/lib/src/Entities/CustomerDocument.js +16 -0
  81. package/lib/src/Entities/CustomerDocument.js.map +1 -0
  82. package/lib/src/Entities/DocumentUploadData.d.ts +13 -0
  83. package/lib/src/Entities/DocumentUploadData.js +81 -0
  84. package/lib/src/Entities/DocumentUploadData.js.map +1 -0
  85. package/lib/src/Entities/EcommerceInfo.d.ts +12 -0
  86. package/lib/src/Entities/EcommerceInfo.js +22 -0
  87. package/lib/src/Entities/EcommerceInfo.js.map +1 -0
  88. package/lib/src/Entities/EncryptionData.d.ts +6 -0
  89. package/lib/src/Entities/EncryptionData.js +11 -0
  90. package/lib/src/Entities/EncryptionData.js.map +1 -0
  91. package/lib/src/Entities/Enums.d.ts +428 -0
  92. package/lib/src/Entities/Enums.js +565 -0
  93. package/lib/src/Entities/Enums.js.map +1 -0
  94. package/lib/src/Entities/Errors.d.ts +23 -0
  95. package/lib/src/Entities/Errors.js +72 -0
  96. package/lib/src/Entities/Errors.js.map +1 -0
  97. package/lib/src/Entities/GpApi/AccessTokenInfo.d.ts +16 -0
  98. package/lib/src/Entities/GpApi/AccessTokenInfo.js +21 -0
  99. package/lib/src/Entities/GpApi/AccessTokenInfo.js.map +1 -0
  100. package/lib/src/Entities/GpApi/GpApiAccount.d.ts +5 -0
  101. package/lib/src/Entities/GpApi/GpApiAccount.js +13 -0
  102. package/lib/src/Entities/GpApi/GpApiAccount.js.map +1 -0
  103. package/lib/src/Entities/GpApi/GpApiRequest.d.ts +21 -0
  104. package/lib/src/Entities/GpApi/GpApiRequest.js +26 -0
  105. package/lib/src/Entities/GpApi/GpApiRequest.js.map +1 -0
  106. package/lib/src/Entities/GpApi/GpApiTokenResponse.d.ts +52 -0
  107. package/lib/src/Entities/GpApi/GpApiTokenResponse.js +115 -0
  108. package/lib/src/Entities/GpApi/GpApiTokenResponse.js.map +1 -0
  109. package/lib/src/Entities/GpApi/index.d.ts +4 -0
  110. package/lib/src/Entities/GpApi/index.js +21 -0
  111. package/lib/src/Entities/GpApi/index.js.map +1 -0
  112. package/lib/src/Entities/HostedPaymentData.d.ts +10 -0
  113. package/lib/src/Entities/HostedPaymentData.js +17 -0
  114. package/lib/src/Entities/HostedPaymentData.js.map +1 -0
  115. package/lib/src/Entities/IRequestBuilder.d.ts +6 -0
  116. package/lib/src/Entities/IRequestBuilder.js +3 -0
  117. package/lib/src/Entities/IRequestBuilder.js.map +1 -0
  118. package/lib/src/Entities/ProFac/AccountBalanceResponseData.d.ts +7 -0
  119. package/lib/src/Entities/ProFac/AccountBalanceResponseData.js +12 -0
  120. package/lib/src/Entities/ProFac/AccountBalanceResponseData.js.map +1 -0
  121. package/lib/src/Entities/ProFac/AccountPermissions.d.ts +15 -0
  122. package/lib/src/Entities/ProFac/AccountPermissions.js +19 -0
  123. package/lib/src/Entities/ProFac/AccountPermissions.js.map +1 -0
  124. package/lib/src/Entities/ProFac/BankAccountData.d.ts +10 -0
  125. package/lib/src/Entities/ProFac/BankAccountData.js +42 -0
  126. package/lib/src/Entities/ProFac/BankAccountData.js.map +1 -0
  127. package/lib/src/Entities/ProFac/BankAccountOwnershipData.d.ts +8 -0
  128. package/lib/src/Entities/ProFac/BankAccountOwnershipData.js +15 -0
  129. package/lib/src/Entities/ProFac/BankAccountOwnershipData.js.map +1 -0
  130. package/lib/src/Entities/ProFac/BeneficialOwnerData.d.ts +6 -0
  131. package/lib/src/Entities/ProFac/BeneficialOwnerData.js +12 -0
  132. package/lib/src/Entities/ProFac/BeneficialOwnerData.js.map +1 -0
  133. package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.d.ts +5 -0
  134. package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.js +10 -0
  135. package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.js.map +1 -0
  136. package/lib/src/Entities/ProFac/BusinessData.d.ts +15 -0
  137. package/lib/src/Entities/ProFac/BusinessData.js +50 -0
  138. package/lib/src/Entities/ProFac/BusinessData.js.map +1 -0
  139. package/lib/src/Entities/ProFac/DeviceAttributeInfo.d.ts +4 -0
  140. package/lib/src/Entities/ProFac/DeviceAttributeInfo.js +17 -0
  141. package/lib/src/Entities/ProFac/DeviceAttributeInfo.js.map +1 -0
  142. package/lib/src/Entities/ProFac/DeviceData.d.ts +5 -0
  143. package/lib/src/Entities/ProFac/DeviceData.js +11 -0
  144. package/lib/src/Entities/ProFac/DeviceData.js.map +1 -0
  145. package/lib/src/Entities/ProFac/DeviceInfo.d.ts +6 -0
  146. package/lib/src/Entities/ProFac/DeviceInfo.js +19 -0
  147. package/lib/src/Entities/ProFac/DeviceInfo.js.map +1 -0
  148. package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.d.ts +7 -0
  149. package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.js +15 -0
  150. package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.js.map +1 -0
  151. package/lib/src/Entities/ProFac/GrossBillingInformation.d.ts +8 -0
  152. package/lib/src/Entities/ProFac/GrossBillingInformation.js +10 -0
  153. package/lib/src/Entities/ProFac/GrossBillingInformation.js.map +1 -0
  154. package/lib/src/Entities/ProFac/OrderDevice.d.ts +18 -0
  155. package/lib/src/Entities/ProFac/OrderDevice.js +23 -0
  156. package/lib/src/Entities/ProFac/OrderDevice.js.map +1 -0
  157. package/lib/src/Entities/ProFac/OwnersData.d.ts +12 -0
  158. package/lib/src/Entities/ProFac/OwnersData.js +43 -0
  159. package/lib/src/Entities/ProFac/OwnersData.js.map +1 -0
  160. package/lib/src/Entities/ProFac/PayFacResponseData.d.ts +55 -0
  161. package/lib/src/Entities/ProFac/PayFacResponseData.js +62 -0
  162. package/lib/src/Entities/ProFac/PayFacResponseData.js.map +1 -0
  163. package/lib/src/Entities/ProFac/RenewAccountData.d.ts +10 -0
  164. package/lib/src/Entities/ProFac/RenewAccountData.js +38 -0
  165. package/lib/src/Entities/ProFac/RenewAccountData.js.map +1 -0
  166. package/lib/src/Entities/ProFac/SignificantOwnerData.d.ts +8 -0
  167. package/lib/src/Entities/ProFac/SignificantOwnerData.js +27 -0
  168. package/lib/src/Entities/ProFac/SignificantOwnerData.js.map +1 -0
  169. package/lib/src/Entities/ProFac/ThreatRiskData.d.ts +5 -0
  170. package/lib/src/Entities/ProFac/ThreatRiskData.js +19 -0
  171. package/lib/src/Entities/ProFac/ThreatRiskData.js.map +1 -0
  172. package/lib/src/Entities/ProFac/UserPersonalData.d.ts +26 -0
  173. package/lib/src/Entities/ProFac/UserPersonalData.js +82 -0
  174. package/lib/src/Entities/ProFac/UserPersonalData.js.map +1 -0
  175. package/lib/src/Entities/RecurringEntity.d.ts +14 -0
  176. package/lib/src/Entities/RecurringEntity.js +92 -0
  177. package/lib/src/Entities/RecurringEntity.js.map +1 -0
  178. package/lib/src/Entities/Request.d.ts +10 -0
  179. package/lib/src/Entities/Request.js +18 -0
  180. package/lib/src/Entities/Request.js.map +1 -0
  181. package/lib/src/Entities/SSORequestData.d.ts +5 -0
  182. package/lib/src/Entities/SSORequestData.js +19 -0
  183. package/lib/src/Entities/SSORequestData.js.map +1 -0
  184. package/lib/src/Entities/Schedule.d.ts +47 -0
  185. package/lib/src/Entities/Schedule.js +325 -0
  186. package/lib/src/Entities/Schedule.js.map +1 -0
  187. package/lib/src/Entities/ServiceEndpoints.d.ts +12 -0
  188. package/lib/src/Entities/ServiceEndpoints.js +17 -0
  189. package/lib/src/Entities/ServiceEndpoints.js.map +1 -0
  190. package/lib/src/Entities/Transaction.d.ts +78 -0
  191. package/lib/src/Entities/Transaction.js +127 -0
  192. package/lib/src/Entities/Transaction.js.map +1 -0
  193. package/lib/src/Entities/TransactionSummary.d.ts +61 -0
  194. package/lib/src/Entities/TransactionSummary.js +66 -0
  195. package/lib/src/Entities/TransactionSummary.js.map +1 -0
  196. package/lib/src/Entities/index.d.ts +17 -0
  197. package/lib/src/Entities/index.js +34 -0
  198. package/lib/src/Entities/index.js.map +1 -0
  199. package/lib/src/Gateways/Gateway.d.ts +12 -0
  200. package/lib/src/Gateways/Gateway.js +70 -0
  201. package/lib/src/Gateways/Gateway.js.map +1 -0
  202. package/lib/src/Gateways/GatewayResponse.d.ts +8 -0
  203. package/lib/src/Gateways/GatewayResponse.js +15 -0
  204. package/lib/src/Gateways/GatewayResponse.js.map +1 -0
  205. package/lib/src/Gateways/GpApiConnector.d.ts +41 -0
  206. package/lib/src/Gateways/GpApiConnector.js +218 -0
  207. package/lib/src/Gateways/GpApiConnector.js.map +1 -0
  208. package/lib/src/Gateways/GpEcomConnector.d.ts +36 -0
  209. package/lib/src/Gateways/GpEcomConnector.js +465 -0
  210. package/lib/src/Gateways/GpEcomConnector.js.map +1 -0
  211. package/lib/src/Gateways/IPayFacProvider.d.ts +5 -0
  212. package/lib/src/Gateways/IPayFacProvider.js +3 -0
  213. package/lib/src/Gateways/IPayFacProvider.js.map +1 -0
  214. package/lib/src/Gateways/IPaymentGateway.d.ts +8 -0
  215. package/lib/src/Gateways/IPaymentGateway.js +3 -0
  216. package/lib/src/Gateways/IPaymentGateway.js.map +1 -0
  217. package/lib/src/Gateways/IRecurringService.d.ts +6 -0
  218. package/lib/src/Gateways/IRecurringService.js +3 -0
  219. package/lib/src/Gateways/IRecurringService.js.map +1 -0
  220. package/lib/src/Gateways/PayPlanConnector.d.ts +42 -0
  221. package/lib/src/Gateways/PayPlanConnector.js +532 -0
  222. package/lib/src/Gateways/PayPlanConnector.js.map +1 -0
  223. package/lib/src/Gateways/PorticoConnector.d.ts +48 -0
  224. package/lib/src/Gateways/PorticoConnector.js +1013 -0
  225. package/lib/src/Gateways/PorticoConnector.js.map +1 -0
  226. package/lib/src/Gateways/ProPayConnector.d.ts +45 -0
  227. package/lib/src/Gateways/ProPayConnector.js +802 -0
  228. package/lib/src/Gateways/ProPayConnector.js.map +1 -0
  229. package/lib/src/Gateways/RestGateway.d.ts +8 -0
  230. package/lib/src/Gateways/RestGateway.js +49 -0
  231. package/lib/src/Gateways/RestGateway.js.map +1 -0
  232. package/lib/src/Gateways/XmlGateway.d.ts +5 -0
  233. package/lib/src/Gateways/XmlGateway.js +14 -0
  234. package/lib/src/Gateways/XmlGateway.js.map +1 -0
  235. package/lib/src/Gateways/https-wrapper.d.ts +3 -0
  236. package/lib/src/Gateways/https-wrapper.js +77 -0
  237. package/lib/src/Gateways/https-wrapper.js.map +1 -0
  238. package/lib/src/Gateways/index.d.ts +9 -0
  239. package/lib/src/Gateways/index.js +26 -0
  240. package/lib/src/Gateways/index.js.map +1 -0
  241. package/lib/src/HostedPaymentConfig.d.ts +12 -0
  242. package/lib/src/HostedPaymentConfig.js +16 -0
  243. package/lib/src/HostedPaymentConfig.js.map +1 -0
  244. package/lib/src/Mapping/GpApiMapping.d.ts +5 -0
  245. package/lib/src/Mapping/GpApiMapping.js +14 -0
  246. package/lib/src/Mapping/GpApiMapping.js.map +1 -0
  247. package/lib/src/Mapping/GpEcomMapping.d.ts +9 -0
  248. package/lib/src/Mapping/GpEcomMapping.js +85 -0
  249. package/lib/src/Mapping/GpEcomMapping.js.map +1 -0
  250. package/lib/src/Mapping/index.d.ts +2 -0
  251. package/lib/src/Mapping/index.js +19 -0
  252. package/lib/src/Mapping/index.js.map +1 -0
  253. package/lib/src/PaymentMethods/Cash.d.ts +8 -0
  254. package/lib/src/PaymentMethods/Cash.js +16 -0
  255. package/lib/src/PaymentMethods/Cash.js.map +1 -0
  256. package/lib/src/PaymentMethods/Credit.d.ts +85 -0
  257. package/lib/src/PaymentMethods/Credit.js +105 -0
  258. package/lib/src/PaymentMethods/Credit.js.map +1 -0
  259. package/lib/src/PaymentMethods/CreditCardData.d.ts +20 -0
  260. package/lib/src/PaymentMethods/CreditCardData.js +47 -0
  261. package/lib/src/PaymentMethods/CreditCardData.js.map +1 -0
  262. package/lib/src/PaymentMethods/CreditTrackData.d.ts +7 -0
  263. package/lib/src/PaymentMethods/CreditTrackData.js +10 -0
  264. package/lib/src/PaymentMethods/CreditTrackData.js.map +1 -0
  265. package/lib/src/PaymentMethods/Debit.d.ts +40 -0
  266. package/lib/src/PaymentMethods/Debit.js +52 -0
  267. package/lib/src/PaymentMethods/Debit.js.map +1 -0
  268. package/lib/src/PaymentMethods/DebitTrackData.d.ts +7 -0
  269. package/lib/src/PaymentMethods/DebitTrackData.js +10 -0
  270. package/lib/src/PaymentMethods/DebitTrackData.js.map +1 -0
  271. package/lib/src/PaymentMethods/EBT.d.ts +48 -0
  272. package/lib/src/PaymentMethods/EBT.js +68 -0
  273. package/lib/src/PaymentMethods/EBT.js.map +1 -0
  274. package/lib/src/PaymentMethods/EBTCardData.d.ts +16 -0
  275. package/lib/src/PaymentMethods/EBTCardData.js +25 -0
  276. package/lib/src/PaymentMethods/EBTCardData.js.map +1 -0
  277. package/lib/src/PaymentMethods/EBTTrackData.d.ts +8 -0
  278. package/lib/src/PaymentMethods/EBTTrackData.js +11 -0
  279. package/lib/src/PaymentMethods/EBTTrackData.js.map +1 -0
  280. package/lib/src/PaymentMethods/ECheck.d.ts +32 -0
  281. package/lib/src/PaymentMethods/ECheck.js +38 -0
  282. package/lib/src/PaymentMethods/ECheck.js.map +1 -0
  283. package/lib/src/PaymentMethods/GiftCard.d.ts +131 -0
  284. package/lib/src/PaymentMethods/GiftCard.js +189 -0
  285. package/lib/src/PaymentMethods/GiftCard.js.map +1 -0
  286. package/lib/src/PaymentMethods/Interfaces.d.ts +55 -0
  287. package/lib/src/PaymentMethods/Interfaces.js +3 -0
  288. package/lib/src/PaymentMethods/Interfaces.js.map +1 -0
  289. package/lib/src/PaymentMethods/PaymentMethod.d.ts +19 -0
  290. package/lib/src/PaymentMethods/PaymentMethod.js +57 -0
  291. package/lib/src/PaymentMethods/PaymentMethod.js.map +1 -0
  292. package/lib/src/PaymentMethods/RecurringPaymentMethod.d.ts +23 -0
  293. package/lib/src/PaymentMethods/RecurringPaymentMethod.js +66 -0
  294. package/lib/src/PaymentMethods/RecurringPaymentMethod.js.map +1 -0
  295. package/lib/src/PaymentMethods/TransactionReference.d.ts +10 -0
  296. package/lib/src/PaymentMethods/TransactionReference.js +17 -0
  297. package/lib/src/PaymentMethods/TransactionReference.js.map +1 -0
  298. package/lib/src/PaymentMethods/index.d.ts +15 -0
  299. package/lib/src/PaymentMethods/index.js +32 -0
  300. package/lib/src/PaymentMethods/index.js.map +1 -0
  301. package/lib/src/ServiceConfigs/AcceptorConfig.d.ts +29 -0
  302. package/lib/src/ServiceConfigs/AcceptorConfig.js +43 -0
  303. package/lib/src/ServiceConfigs/AcceptorConfig.js.map +1 -0
  304. package/lib/src/ServiceConfigs/Configuration.d.ts +15 -0
  305. package/lib/src/ServiceConfigs/Configuration.js +20 -0
  306. package/lib/src/ServiceConfigs/Configuration.js.map +1 -0
  307. package/lib/src/ServiceConfigs/Gateways/GatewayConfig.d.ts +14 -0
  308. package/lib/src/ServiceConfigs/Gateways/GatewayConfig.js +30 -0
  309. package/lib/src/ServiceConfigs/Gateways/GatewayConfig.js.map +1 -0
  310. package/lib/src/ServiceConfigs/Gateways/GpApiConfig.d.ts +21 -0
  311. package/lib/src/ServiceConfigs/Gateways/GpApiConfig.js +44 -0
  312. package/lib/src/ServiceConfigs/Gateways/GpApiConfig.js.map +1 -0
  313. package/lib/src/ServiceConfigs/Gateways/GpEcomConfig.d.ts +21 -0
  314. package/lib/src/ServiceConfigs/Gateways/GpEcomConfig.js +50 -0
  315. package/lib/src/ServiceConfigs/Gateways/GpEcomConfig.js.map +1 -0
  316. package/lib/src/ServiceConfigs/Gateways/PorticoConfig.d.ts +22 -0
  317. package/lib/src/ServiceConfigs/Gateways/PorticoConfig.js +116 -0
  318. package/lib/src/ServiceConfigs/Gateways/PorticoConfig.js.map +1 -0
  319. package/lib/src/ServiceConfigs/Gateways/index.d.ts +4 -0
  320. package/lib/src/ServiceConfigs/Gateways/index.js +21 -0
  321. package/lib/src/ServiceConfigs/Gateways/index.js.map +1 -0
  322. package/lib/src/ServiceConfigs/ServicesConfigs.d.ts +6 -0
  323. package/lib/src/ServiceConfigs/ServicesConfigs.js +14 -0
  324. package/lib/src/ServiceConfigs/ServicesConfigs.js.map +1 -0
  325. package/lib/src/ServiceConfigs/index.d.ts +4 -0
  326. package/lib/src/ServiceConfigs/index.js +21 -0
  327. package/lib/src/ServiceConfigs/index.js.map +1 -0
  328. package/lib/src/Services/BatchService.d.ts +4 -0
  329. package/lib/src/Services/BatchService.js +15 -0
  330. package/lib/src/Services/BatchService.js.map +1 -0
  331. package/lib/src/Services/CheckService.d.ts +7 -0
  332. package/lib/src/Services/CheckService.js +20 -0
  333. package/lib/src/Services/CheckService.js.map +1 -0
  334. package/lib/src/Services/CreditService.d.ts +13 -0
  335. package/lib/src/Services/CreditService.js +54 -0
  336. package/lib/src/Services/CreditService.js.map +1 -0
  337. package/lib/src/Services/DebitService.d.ts +8 -0
  338. package/lib/src/Services/DebitService.js +28 -0
  339. package/lib/src/Services/DebitService.js.map +1 -0
  340. package/lib/src/Services/EBTService.d.ts +9 -0
  341. package/lib/src/Services/EBTService.js +31 -0
  342. package/lib/src/Services/EBTService.js.map +1 -0
  343. package/lib/src/Services/GiftService.d.ts +17 -0
  344. package/lib/src/Services/GiftService.js +54 -0
  345. package/lib/src/Services/GiftService.js.map +1 -0
  346. package/lib/src/Services/GpApiServices.d.ts +4 -0
  347. package/lib/src/Services/GpApiServices.js +44 -0
  348. package/lib/src/Services/GpApiServices.js.map +1 -0
  349. package/lib/src/Services/HostedService.d.ts +10 -0
  350. package/lib/src/Services/HostedService.js +59 -0
  351. package/lib/src/Services/HostedService.js.map +1 -0
  352. package/lib/src/Services/PayFacService.d.ts +26 -0
  353. package/lib/src/Services/PayFacService.js +76 -0
  354. package/lib/src/Services/PayFacService.js.map +1 -0
  355. package/lib/src/Services/RecurringService.d.ts +8 -0
  356. package/lib/src/Services/RecurringService.js +24 -0
  357. package/lib/src/Services/RecurringService.js.map +1 -0
  358. package/lib/src/Services/ReportingService.d.ts +6 -0
  359. package/lib/src/Services/ReportingService.js +18 -0
  360. package/lib/src/Services/ReportingService.js.map +1 -0
  361. package/lib/src/Services/index.d.ts +10 -0
  362. package/lib/src/Services/index.js +27 -0
  363. package/lib/src/Services/index.js.map +1 -0
  364. package/lib/src/ServicesContainer.d.ts +17 -0
  365. package/lib/src/ServicesContainer.js +58 -0
  366. package/lib/src/ServicesContainer.js.map +1 -0
  367. package/lib/src/Utils/GenerationUtils.d.ts +5 -0
  368. package/lib/src/Utils/GenerationUtils.js +34 -0
  369. package/lib/src/Utils/GenerationUtils.js.map +1 -0
  370. package/lib/src/Utils/InputValidation.d.ts +12 -0
  371. package/lib/src/Utils/InputValidation.js +71 -0
  372. package/lib/src/Utils/InputValidation.js.map +1 -0
  373. package/lib/src/Utils/Sha1.d.ts +6 -0
  374. package/lib/src/Utils/Sha1.js +231 -0
  375. package/lib/src/Utils/Sha1.js.map +1 -0
  376. package/lib/src/Utils/StringUtils.d.ts +6 -0
  377. package/lib/src/Utils/StringUtils.js +51 -0
  378. package/lib/src/Utils/StringUtils.js.map +1 -0
  379. package/lib/src/Utils/index.d.ts +2 -0
  380. package/lib/src/Utils/index.js +19 -0
  381. package/lib/src/Utils/index.js.map +1 -0
  382. package/lib/src/index.d.ts +12 -0
  383. package/lib/src/index.js +33 -0
  384. package/lib/src/index.js.map +1 -0
  385. package/lib/test/Data/BaseGpApiTestConfig.d.ts +13 -0
  386. package/lib/test/Data/BaseGpApiTestConfig.js +42 -0
  387. package/lib/test/Data/BaseGpApiTestConfig.js.map +1 -0
  388. package/lib/test/Data/TestCards.d.ts +24 -0
  389. package/lib/test/Data/TestCards.js +220 -0
  390. package/lib/test/Data/TestCards.js.map +1 -0
  391. package/lib/test/Data/TestChecks.d.ts +4 -0
  392. package/lib/test/Data/TestChecks.js +27 -0
  393. package/lib/test/Data/TestChecks.js.map +1 -0
  394. package/lib/test/Data/index.d.ts +2 -0
  395. package/lib/test/Data/index.js +19 -0
  396. package/lib/test/Data/index.js.map +1 -0
  397. package/lib/test/Integration/Gateways/GpApiConnector/AccessTokenTest.d.ts +1 -0
  398. package/lib/test/Integration/Gateways/GpApiConnector/AccessTokenTest.js +102 -0
  399. package/lib/test/Integration/Gateways/GpApiConnector/AccessTokenTest.js.map +1 -0
  400. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/AuthTest.d.ts +1 -0
  401. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/AuthTest.js +2446 -0
  402. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/AuthTest.js.map +1 -0
  403. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/AvsTest.d.ts +1 -0
  404. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/AvsTest.js +506 -0
  405. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/AvsTest.js.map +1 -0
  406. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/CreditTest.d.ts +1 -0
  407. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/CreditTest.js +1296 -0
  408. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/CreditTest.js.map +1 -0
  409. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/HoldTest.d.ts +1 -0
  410. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/HoldTest.js +847 -0
  411. package/lib/test/Integration/Gateways/GpEcomConnector/Certification/HoldTest.js.map +1 -0
  412. package/lib/test/Integration/Gateways/GpEcomConnector/CreditTest.d.ts +1 -0
  413. package/lib/test/Integration/Gateways/GpEcomConnector/CreditTest.js +214 -0
  414. package/lib/test/Integration/Gateways/GpEcomConnector/CreditTest.js.map +1 -0
  415. package/lib/test/Integration/Gateways/GpEcomConnector/HppTest.d.ts +1 -0
  416. package/lib/test/Integration/Gateways/GpEcomConnector/HppTest.js +98 -0
  417. package/lib/test/Integration/Gateways/GpEcomConnector/HppTest.js.map +1 -0
  418. package/lib/test/Integration/Gateways/GpEcomConnector/RecurringTest.d.ts +1 -0
  419. package/lib/test/Integration/Gateways/GpEcomConnector/RecurringTest.js +132 -0
  420. package/lib/test/Integration/Gateways/GpEcomConnector/RecurringTest.js.map +1 -0
  421. package/lib/test/Integration/Gateways/PorticoConnector/AchTest.d.ts +1 -0
  422. package/lib/test/Integration/Gateways/PorticoConnector/AchTest.js +59 -0
  423. package/lib/test/Integration/Gateways/PorticoConnector/AchTest.js.map +1 -0
  424. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.d.ts +1 -0
  425. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.js +378 -0
  426. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.js.map +1 -0
  427. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.d.ts +1 -0
  428. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.js +86 -0
  429. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.js.map +1 -0
  430. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.d.ts +1 -0
  431. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.js +1723 -0
  432. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.js.map +1 -0
  433. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.d.ts +1 -0
  434. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.js +86 -0
  435. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.js.map +1 -0
  436. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.d.ts +1 -0
  437. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.js +1760 -0
  438. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.js.map +1 -0
  439. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.d.ts +1 -0
  440. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.js +420 -0
  441. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.js.map +1 -0
  442. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.d.ts +1 -0
  443. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.js +2221 -0
  444. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.js.map +1 -0
  445. package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.d.ts +1 -0
  446. package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.js +392 -0
  447. package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.js.map +1 -0
  448. package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.d.ts +1 -0
  449. package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.js +82 -0
  450. package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.js.map +1 -0
  451. package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.d.ts +1 -0
  452. package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.js +72 -0
  453. package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.js.map +1 -0
  454. package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.d.ts +1 -0
  455. package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.js +111 -0
  456. package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.js.map +1 -0
  457. package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.d.ts +1 -0
  458. package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.js +147 -0
  459. package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.js.map +1 -0
  460. package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.d.ts +1 -0
  461. package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.js +101 -0
  462. package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.js.map +1 -0
  463. package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.d.ts +1 -0
  464. package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.js +50 -0
  465. package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.js.map +1 -0
  466. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTest.d.ts +1 -0
  467. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTest.js +44 -0
  468. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTest.js.map +1 -0
  469. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTest.d.ts +1 -0
  470. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTest.js +221 -0
  471. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTest.js.map +1 -0
  472. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTest.d.ts +1 -0
  473. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTest.js +60 -0
  474. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTest.js.map +1 -0
  475. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTest.d.ts +1 -0
  476. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTest.js +80 -0
  477. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTest.js.map +1 -0
  478. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.d.ts +39 -0
  479. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.js +393 -0
  480. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.js.map +1 -0
  481. package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTest.d.ts +1 -0
  482. package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTest.js +44 -0
  483. package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTest.js.map +1 -0
  484. package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTest.d.ts +1 -0
  485. package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTest.js +330 -0
  486. package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTest.js.map +1 -0
  487. package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTest.d.ts +1 -0
  488. package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTest.js +60 -0
  489. package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTest.js.map +1 -0
  490. package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTest.d.ts +1 -0
  491. package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTest.js +80 -0
  492. package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTest.js.map +1 -0
  493. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.d.ts +34 -0
  494. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.js +322 -0
  495. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.js.map +1 -0
  496. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.d.ts +4 -0
  497. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.js +28 -0
  498. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.js.map +1 -0
  499. package/lib/test/Integration/Services/CheckServiceTest.d.ts +1 -0
  500. package/lib/test/Integration/Services/CheckServiceTest.js +45 -0
  501. package/lib/test/Integration/Services/CheckServiceTest.js.map +1 -0
  502. package/lib/test/Integration/Services/CreditServiceTest.d.ts +1 -0
  503. package/lib/test/Integration/Services/CreditServiceTest.js +174 -0
  504. package/lib/test/Integration/Services/CreditServiceTest.js.map +1 -0
  505. package/lib/test/Integration/Services/DebitServiceTest.d.ts +1 -0
  506. package/lib/test/Integration/Services/DebitServiceTest.js +81 -0
  507. package/lib/test/Integration/Services/DebitServiceTest.js.map +1 -0
  508. package/lib/test/Integration/Services/EBTServiceTest.d.ts +1 -0
  509. package/lib/test/Integration/Services/EBTServiceTest.js +64 -0
  510. package/lib/test/Integration/Services/EBTServiceTest.js.map +1 -0
  511. package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.d.ts +1 -0
  512. package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.js +111 -0
  513. package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.js.map +1 -0
  514. package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.d.ts +1 -0
  515. package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.js +62 -0
  516. package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.js.map +1 -0
  517. package/lib/test/Unit/Gateways/GpEcomConnector/CreditTest.d.ts +1 -0
  518. package/lib/test/Unit/Gateways/GpEcomConnector/CreditTest.js +34 -0
  519. package/lib/test/Unit/Gateways/GpEcomConnector/CreditTest.js.map +1 -0
  520. package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.d.ts +1 -0
  521. package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.js +125 -0
  522. package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.js.map +1 -0
  523. package/package.json +1 -1
@@ -0,0 +1,62 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ValidationClause = void 0;
4
+ class ValidationClause {
5
+ parent;
6
+ target;
7
+ callback;
8
+ message;
9
+ precondition;
10
+ constructor(parent, target, precondition = false) {
11
+ this.parent = parent;
12
+ this.target = target;
13
+ this.precondition = precondition;
14
+ }
15
+ isNotNull(message) {
16
+ this.callback = (builder) => {
17
+ const value = builder[this.target.property];
18
+ return undefined !== value && null !== value;
19
+ };
20
+ this.message = message
21
+ ? message
22
+ : `${this.target.property} cannot be null for this transaction type.`;
23
+ if (this.precondition) {
24
+ return this.target;
25
+ }
26
+ return this.parent
27
+ .of(this.target.enumName, this.target.type)
28
+ .with(this.target.constraintProperty, this.target.constraint);
29
+ }
30
+ isNull(message) {
31
+ this.callback = (builder) => {
32
+ const value = builder[this.target.property];
33
+ return undefined === value || null === value;
34
+ };
35
+ this.message = message
36
+ ? message
37
+ : `${this.target.property} cannot be set for this transaction type.`;
38
+ if (this.precondition) {
39
+ return this.target;
40
+ }
41
+ return this.parent
42
+ .of(this.target.enumName, this.target.type)
43
+ .with(this.target.constraintProperty, this.target.constraint);
44
+ }
45
+ isNotEmpty(message) {
46
+ this.callback = (builder) => {
47
+ const value = builder[this.target.property];
48
+ return !!value;
49
+ };
50
+ this.message = message
51
+ ? message
52
+ : `${this.target.property} cannot be empty for this transaction type.`;
53
+ if (this.precondition) {
54
+ return this.target;
55
+ }
56
+ return this.parent
57
+ .of(this.target.enumName, this.target.type)
58
+ .with(this.target.constraintProperty, this.target.constraint);
59
+ }
60
+ }
61
+ exports.ValidationClause = ValidationClause;
62
+ //# sourceMappingURL=ValidationClause.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ValidationClause.js","sourceRoot":"","sources":["../../../../src/Builders/BaseBuilder/ValidationClause.ts"],"names":[],"mappings":";;;AAIA,MAAa,gBAAgB;IACpB,MAAM,CAAc;IACpB,MAAM,CAAmB;IACzB,QAAQ,CAAwC;IAChD,OAAO,CAAS;IAChB,YAAY,CAAU;IAE7B,YACE,MAAmB,EACnB,MAAwB,EACxB,YAAY,GAAG,KAAK;QAEpB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;IACnC,CAAC;IAEM,SAAS,CAAC,OAAgB;QAC/B,IAAI,CAAC,QAAQ,GAAG,CAAI,OAAuB,EAAE,EAAE;YAC7C,MAAM,KAAK,GAAG,OAAO,CAAC,IAAI,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,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,4CAA4C,CAAC;QAExE,IAAI,IAAI,CAAC,YAAY,EAAE;YACrB,OAAO,IAAI,CAAC,MAAM,CAAC;SACpB;QAED,OAAO,IAAI,CAAC,MAAM;aACf,EAAE,CAAC,IAAI,CA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AY,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;CACF;AAtED,4CAsEC"}
@@ -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,36 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ValidationTarget = void 0;
4
+ const ValidationClause_1 = require("./ValidationClause");
5
+ class ValidationTarget {
6
+ parent;
7
+ type;
8
+ property;
9
+ clause;
10
+ constraint;
11
+ constraintProperty;
12
+ enumName;
13
+ precondition;
14
+ constructor(parent, enumName, type) {
15
+ this.parent = parent;
16
+ this.type = type;
17
+ this.enumName = enumName;
18
+ }
19
+ with(property, constraint) {
20
+ this.constraintProperty = property;
21
+ this.constraint = constraint;
22
+ return this;
23
+ }
24
+ check(targetProperty) {
25
+ this.property = targetProperty;
26
+ this.clause = new ValidationClause_1.ValidationClause(this.parent, this);
27
+ return this.clause;
28
+ }
29
+ when(targetProperty) {
30
+ this.property = targetProperty;
31
+ this.precondition = new ValidationClause_1.ValidationClause(this.parent, this, true);
32
+ return this.precondition;
33
+ }
34
+ }
35
+ exports.ValidationTarget = ValidationTarget;
36
+ //# sourceMappingURL=ValidationTarget.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ValidationTarget.js","sourceRoot":"","sources":["../../../../src/Builders/BaseBuilder/ValidationTarget.ts"],"names":[],"mappings":";;;AAAA,yDAAsD;AAGtD,MAAa,gBAAgB;IACpB,MAAM,CAAc;IACpB,IAAI,CAAS;IACb,QAAQ,CAAS;IACjB,MAAM,CAAmB;IACzB,UAAU,CAAS;IACnB,kBAAkB,CAAS;IAC3B,QAAQ,CAAS;IACjB,YAAY,CAAmB;IAEtC,YAAmB,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,IAAI,CAAC,QAAgB,EAAE,UAAkB;QAC9C,IAAI,CAAC,kBAAkB,GAAG,QAAQ,CAAC;QACnC,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,OAAO,IAAI,CAAC;IACd,CAAC;IAEM,KAAK,CAAC,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,IAAI,CAAC,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;CACF;AAjCD,4CAiCC"}
@@ -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,55 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Validations = void 0;
4
+ const __1 = require("../../");
5
+ const ValidationTarget_1 = require("./ValidationTarget");
6
+ class Validations {
7
+ rules;
8
+ constructor() {
9
+ this.rules = {};
10
+ }
11
+ of(enumProperty, type) {
12
+ if (!this.rules.hasOwnProperty(enumProperty)) {
13
+ this.rules[enumProperty] = [];
14
+ }
15
+ if (!this.rules[enumProperty].hasOwnProperty(type.toString())) {
16
+ this.rules[enumProperty][type] = [];
17
+ }
18
+ const target = new ValidationTarget_1.ValidationTarget(this, enumProperty, type);
19
+ this.rules[enumProperty][type].push(target);
20
+ return target;
21
+ }
22
+ validate(builder) {
23
+ Object.keys(this.rules).forEach((enumName) => {
24
+ this.rules[enumName].forEach((rules, iKey) => {
25
+ let 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 (const validation of rules) {
38
+ if (!validation.clause) {
39
+ continue;
40
+ }
41
+ if (validation.constraint !== undefined &&
42
+ validation.constraint !== null &&
43
+ validation.constraint !== builder[validation.constraintProperty]) {
44
+ continue;
45
+ }
46
+ if (!validation.clause.callback(builder)) {
47
+ throw new __1.BuilderError(validation.clause.message);
48
+ }
49
+ }
50
+ });
51
+ });
52
+ }
53
+ }
54
+ exports.Validations = Validations;
55
+ //# sourceMappingURL=Validations.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Validations.js","sourceRoot":"","sources":["../../../../src/Builders/BaseBu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K,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,KAAK,MAAM,UAAU,IAAI,KAAK,EAAE;oBAC9B,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;CACF;AA7DD,kCA6DC"}
@@ -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
+ const Validations_1 = require("./BaseBuilder/Validations");
5
+ class BaseBuilder {
6
+ validations;
7
+ constructor() {
8
+ this.validations = new Validations_1.Validations();
9
+ this.setupValidations();
10
+ }
11
+ execute() {
12
+ this.validations.validate(this);
13
+ return Promise.resolve(undefined);
14
+ }
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,2DAAwD;AAMxD,MAAsB,WAAW;IACrB,WAAW,CAAc;IAGnC;QACE,IAAI,CAAC,WAAW,GAAG,IAAI,yBAAW,EAAE,CAAC;QACrC,IAAI,CAAC,gBAAgB,EAAE,CAAC;IAC1B,CAAC;IAEM,OAAO;QACZ,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QAChC,OAAO,OAAO,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;IACpC,CAAC;CAGF;AAfD,kCAeC"}
@@ -0,0 +1,104 @@
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(configName?: string): 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
+ withDynamicDescriptor(dynamicDescriptor: string): this;
104
+ }
@@ -0,0 +1,208 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ManagementBuilder = void 0;
4
+ const __1 = require("../");
5
+ const TransactionBuilder_1 = require("./TransactionBuilder");
6
+ class ManagementBuilder extends TransactionBuilder_1.TransactionBuilder {
7
+ amount;
8
+ authAmount;
9
+ get authorizationCode() {
10
+ if (this.paymentMethod instanceof __1.TransactionReference) {
11
+ return this.paymentMethod.authCode;
12
+ }
13
+ return undefined;
14
+ }
15
+ get clientTransactionId() {
16
+ if (this.paymentMethod instanceof __1.TransactionReference) {
17
+ return this.paymentMethod.clientTransactionId;
18
+ }
19
+ return undefined;
20
+ }
21
+ currency;
22
+ description;
23
+ gratuity;
24
+ get orderId() {
25
+ if (this.paymentMethod instanceof __1.TransactionReference) {
26
+ return this.paymentMethod.orderId;
27
+ }
28
+ return undefined;
29
+ }
30
+ poNumber;
31
+ reasonCode;
32
+ taxAmount;
33
+ taxType;
34
+ get transactionId() {
35
+ if (this.paymentMethod instanceof __1.TransactionReference) {
36
+ return this.paymentMethod.transactionId;
37
+ }
38
+ return undefined;
39
+ }
40
+ constructor(type) {
41
+ super(type);
42
+ }
43
+ /**
44
+ * Executes the builder against the gateway.
45
+ *
46
+ * @returns Promise<Transaction>
47
+ */
48
+ execute(configName = "default") {
49
+ super.execute();
50
+ return __1.ServicesContainer.instance()
51
+ .getClient(configName)
52
+ .manageTransaction(this);
53
+ }
54
+ setupValidations() {
55
+ this.validations
56
+ .of("transactionType",
57
+ /* tslint:disable:trailing-comma */
58
+ __1.TransactionType.Capture |
59
+ __1.TransactionType.Edit |
60
+ __1.TransactionType.Hold |
61
+ __1.TransactionType.Release)
62
+ .check("transactionId")
63
+ .isNotNull();
64
+ this.validations
65
+ .of("transactionType", __1.TransactionType.Edit)
66
+ .with("transactionModifier", __1.TransactionModifier.LevelII)
67
+ .check("taxType")
68
+ .isNotNull();
69
+ this.validations
70
+ .of("transactionType", __1.TransactionType.Refund)
71
+ .when("amount")
72
+ .isNotNull()
73
+ .check("currency")
74
+ .isNotNull();
75
+ }
76
+ /**
77
+ * Sets the current transaction's amount.
78
+ *
79
+ * @param amount The amount
80
+ * @returns ManagementBuilder
81
+ */
82
+ withAmount(amount) {
83
+ if (amount !== undefined) {
84
+ this.amount = amount;
85
+ }
86
+ return this;
87
+ }
88
+ /**
89
+ * Sets the current transaction's authorized amount; where applicable.
90
+ *
91
+ * @param amount The authorized amount
92
+ * @returns ManagementBuilder
93
+ */
94
+ withAuthAmount(amount) {
95
+ if (amount !== undefined) {
96
+ this.authAmount = amount;
97
+ }
98
+ return this;
99
+ }
100
+ /**
101
+ * Sets the currency.
102
+ *
103
+ * The formatting for the supplied value will currently depend on
104
+ * the configured gateway's requirements.
105
+ *
106
+ * @param currency The currency
107
+ * @returns ManagementBuilder
108
+ */
109
+ withCurrency(currency) {
110
+ if (currency !== undefined) {
111
+ this.currency = currency;
112
+ }
113
+ return this;
114
+ }
115
+ /**
116
+ * Sets the transaction's description.
117
+ *
118
+ * This value is not guaranteed to be sent in the authorization
119
+ * or settlement process.
120
+ *
121
+ * @param description The description
122
+ * @returns ManagementBuilder
123
+ */
124
+ withDescription(description) {
125
+ if (description !== undefined) {
126
+ this.description = description;
127
+ }
128
+ return this;
129
+ }
130
+ /**
131
+ * Sets the gratuity amount; where applicable.
132
+ *
133
+ * This value is information only and does not affect
134
+ * the authorization amount.
135
+ *
136
+ * @param gratuity The gratuity amount
137
+ * @returns ManagementBuilder
138
+ */
139
+ withGratuity(gratuity) {
140
+ if (gratuity !== undefined) {
141
+ this.gratuity = gratuity;
142
+ }
143
+ return this;
144
+ }
145
+ /**
146
+ * Sets the purchase order number; where applicable.
147
+ *
148
+ * @param poNumber The PO number
149
+ * @returns ManagementBuilder
150
+ */
151
+ withPoNumber(poNumber) {
152
+ this.transactionModifier = __1.TransactionModifier.LevelII;
153
+ if (poNumber !== undefined) {
154
+ this.poNumber = poNumber;
155
+ }
156
+ return this;
157
+ }
158
+ /**
159
+ * Sets the reason code for the transaction.
160
+ *
161
+ * @param reasonCode The reason code
162
+ * @returns ManagementBuilder
163
+ */
164
+ withReasonCode(reasonCode) {
165
+ if (reasonCode !== undefined) {
166
+ this.reasonCode = reasonCode;
167
+ }
168
+ return this;
169
+ }
170
+ /**
171
+ * Sets the tax amount.
172
+ *
173
+ * Useful for commercial purchase card requests.
174
+ *
175
+ * @see AuthorizationBuilder.WithCommercialRequest
176
+ * @param amount The tax amount
177
+ * @returns ManagementBuilder
178
+ */
179
+ withTaxAmount(amount) {
180
+ this.transactionModifier = __1.TransactionModifier.LevelII;
181
+ if (amount !== undefined) {
182
+ this.taxAmount = amount;
183
+ }
184
+ return this;
185
+ }
186
+ /**
187
+ * Sets the tax type.
188
+ *
189
+ * Useful for commercial purchase card requests.
190
+ *
191
+ * @see AuthorizationBuilder.withCommercialRequest
192
+ * @param type The tax type
193
+ * @returns ManagementBuilder
194
+ */
195
+ withTaxType(type) {
196
+ this.transactionModifier = __1.TransactionModifier.LevelII;
197
+ if (type !== undefined) {
198
+ this.taxType = type;
199
+ }
200
+ return this;
201
+ }
202
+ withDynamicDescriptor(dynamicDescriptor) {
203
+ this.dynamicDescriptor = dynamicDescriptor;
204
+ return this;
205
+ }
206
+ }
207
+ exports.ManagementBuilder = ManagementBuilder;
208
+ //# sourceMappingURL=ManagementBuilder.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ManagementBuilder.js","sourceRoot":"","sources":["../../../src/Builders/ManagementBuilder.ts"],"names":[],"mappings":";;;AAAA,2BAQa;AACb,6DAA0D;AAE1D,MAAa,iBAAkB,SAAQ,uCAA+B;IAC7D,MAAM,CAAkB;IACxB,UAAU,CAAkB;IACnC,IAAW,iBAAiB;QAC1B,IAAI,IAAI,CAAC,aAAa,YAAY,wBAAoB,EAAE;YACtD,OAAO,IAAI,CAAC,aAAa,CAAC,QAAQ,CAAC;SACpC;QACD,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,IAAW,mBAAmB;QAC5B,IAAI,IAAI,CAAC,aAAa,YAAY,wBAAoB,EAAE;YACtD,OAAO,IAAI,CAAC,aAAa,CAAC,mBAAmB,CAAC;SAC/C;QACD,OAAO,SAAS,CAAC;IACnB,CAAC;IACM,QAAQ,CAAS;IACjB,WAAW,CAAS;IACpB,QAAQ,CAAkB;IACjC,IAAW,OAAO;QAChB,IAAI,IAAI,CAAC,aAAa,YAA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CAAC,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,WAAW,CAAC,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;IAEM,qBAAqB,CAAC,iBAAyB;QACpD,IAAI,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;QAE3C,OAAO,IAAI,CAAC;IACd,CAAC;CACF;AA3ND,8CA2NC"}
@@ -0,0 +1,98 @@
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
+ orderDeviceData: DeviceData;
59
+ constructor(type: TransactionType, modifer?: TransactionModifier);
60
+ execute(configName?: string): Promise<Transaction>;
61
+ withBankAccountData(bankAccountData: BankAccountData): this;
62
+ withBeneficialOwnerData(beneficialOwnerData: BeneficialOwnerData): this;
63
+ withDeviceData(deviceData: DeviceData): this;
64
+ withTimeZone(timezone: string): this;
65
+ withBusinessData(businessData: BusinessData): this;
66
+ withSignificantOwnerData(significantOwnerData: SignificantOwnerData): this;
67
+ withThreatRiskData(threatRiskData: ThreatRiskData): this;
68
+ withUserPersonalData(userPersonalData: UserPersonalData): this;
69
+ withCreditCardData(creditCardInformation: CreditCardData): this;
70
+ withACHData(achInformation: BankAccountData): this;
71
+ withMailingAddress(mailingAddressInformation: Address): this;
72
+ withSecondaryBankAccountData(secondaryBankInformation: BankAccountData): this;
73
+ withGrossBillingSettleData(grossBillingInformation: GrossBillingInformation): this;
74
+ withAccountNumber(accountNumber: string): this;
75
+ withPassword(password: string): this;
76
+ withAccountPermissions(accountPermissions: AccountPermissions): this;
77
+ withPrimaryBankAccountOwner(primaryBankAccountOwner: BankAccountOwnershipData): this;
78
+ withSecondaryBankAccountOwner(secondaryBankAccountOwner: BankAccountOwnershipData): this;
79
+ withDocumentUploadData(docUploadData: DocumentUploadData): this;
80
+ withSSORequestData(ssoRequestData: SSORequestData): this;
81
+ withNegativeLimit(negativeLimit: string): this;
82
+ withRenewalAccountData(renewalAccountData: RenewAccountData): this;
83
+ withAmount(amount: string): this;
84
+ withFlashFundsPaymentCardData(cardData: FlashFundsPaymentCardData): this;
85
+ withReceivingAccountNumber(receivingAccountNumber: string): this;
86
+ withAllowPending(allowPending: boolean): this;
87
+ withCCAmount(ccAmount: string): this;
88
+ withRequireCCRefund(requireCCRefund: boolean): this;
89
+ withTransNum(transNum: string): this;
90
+ withGatewayTransactionId(gatewayTransactionId: string): this;
91
+ withCardBrandTransactionId(cardBrandTransactionId: string): this;
92
+ withGlobaltransId(globaltransId: string): this;
93
+ withGlobalTransSource(globalTransSource: string): this;
94
+ withExternalID(externalId: string): this;
95
+ withSourceEmail(sourceEmail: string): this;
96
+ withOrderDevice(orderDevice: OrderDevice): this;
97
+ withOrderDeviceData(orderDeviceData: DeviceData): this;
98
+ }