globalpayments-api 1.4.8 → 1.4.9

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 (88) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/lib/src/Builders/PayFacBuilder.d.ts +96 -0
  3. package/lib/src/Builders/PayFacBuilder.js +184 -0
  4. package/lib/src/Entities/DocumentUploadData.d.ts +13 -0
  5. package/lib/src/Entities/DocumentUploadData.js +48 -0
  6. package/lib/src/Entities/Enums.d.ts +44 -1
  7. package/lib/src/Entities/Enums.js +119 -1
  8. package/lib/src/Entities/ProFac/AccountBalanceResponseData.d.ts +7 -0
  9. package/lib/src/Entities/ProFac/AccountBalanceResponseData.js +9 -0
  10. package/lib/src/Entities/ProFac/AccountPermissions.d.ts +15 -0
  11. package/lib/src/Entities/ProFac/AccountPermissions.js +9 -0
  12. package/lib/src/Entities/ProFac/BankAccountData.d.ts +10 -0
  13. package/lib/src/Entities/ProFac/BankAccountData.js +9 -0
  14. package/lib/src/Entities/ProFac/BankAccountOwnershipData.d.ts +8 -0
  15. package/lib/src/Entities/ProFac/BankAccountOwnershipData.js +11 -0
  16. package/lib/src/Entities/ProFac/BeneficialOwnerData.d.ts +6 -0
  17. package/lib/src/Entities/ProFac/BeneficialOwnerData.js +10 -0
  18. package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.d.ts +5 -0
  19. package/lib/src/Entities/ProFac/BeneficialOwnerDataResult.js +9 -0
  20. package/lib/src/Entities/ProFac/BusinessData.d.ts +14 -0
  21. package/lib/src/Entities/ProFac/BusinessData.js +11 -0
  22. package/lib/src/Entities/ProFac/DeviceAttributeInfo.d.ts +4 -0
  23. package/lib/src/Entities/ProFac/DeviceAttributeInfo.js +9 -0
  24. package/lib/src/Entities/ProFac/DeviceData.d.ts +5 -0
  25. package/lib/src/Entities/ProFac/DeviceData.js +10 -0
  26. package/lib/src/Entities/ProFac/DeviceInfo.d.ts +6 -0
  27. package/lib/src/Entities/ProFac/DeviceInfo.js +9 -0
  28. package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.d.ts +7 -0
  29. package/lib/src/Entities/ProFac/FlashFundsPaymentCardData.js +13 -0
  30. package/lib/src/Entities/ProFac/GrossBillingInformation.d.ts +8 -0
  31. package/lib/src/Entities/ProFac/GrossBillingInformation.js +9 -0
  32. package/lib/src/Entities/ProFac/OrderDevice.d.ts +18 -0
  33. package/lib/src/Entities/ProFac/OrderDevice.js +9 -0
  34. package/lib/src/Entities/ProFac/OwnersData.d.ts +12 -0
  35. package/lib/src/Entities/ProFac/OwnersData.js +11 -0
  36. package/lib/src/Entities/ProFac/PayFacResponseData.d.ts +55 -0
  37. package/lib/src/Entities/ProFac/PayFacResponseData.js +9 -0
  38. package/lib/src/Entities/ProFac/RenewAccountData.d.ts +10 -0
  39. package/lib/src/Entities/ProFac/RenewAccountData.js +11 -0
  40. package/lib/src/Entities/ProFac/SignificantOwnerData.d.ts +8 -0
  41. package/lib/src/Entities/ProFac/SignificantOwnerData.js +11 -0
  42. package/lib/src/Entities/ProFac/ThreatRiskData.d.ts +5 -0
  43. package/lib/src/Entities/ProFac/ThreatRiskData.js +9 -0
  44. package/lib/src/Entities/ProFac/UserPersonalData.d.ts +26 -0
  45. package/lib/src/Entities/ProFac/UserPersonalData.js +14 -0
  46. package/lib/src/Entities/SSORequestData.d.ts +5 -0
  47. package/lib/src/Entities/SSORequestData.js +9 -0
  48. package/lib/src/Entities/Transaction.d.ts +2 -0
  49. package/lib/src/Gateways/IPayFacProvider.d.ts +5 -0
  50. package/lib/src/Gateways/IPayFacProvider.js +2 -0
  51. package/lib/src/Gateways/PayPlanConnector.d.ts +1 -0
  52. package/lib/src/Gateways/PayPlanConnector.js +13 -1
  53. package/lib/src/Gateways/PorticoConnector.js +0 -1
  54. package/lib/src/Gateways/ProPayConnector.d.ts +41 -0
  55. package/lib/src/Gateways/ProPayConnector.js +698 -0
  56. package/lib/src/Gateways/XmlGateway.js +1 -0
  57. package/lib/src/PaymentMethods/CreditCardData.d.ts +1 -0
  58. package/lib/src/PaymentMethods/CreditCardData.js +6 -0
  59. package/lib/src/Services/PayFacService.d.ts +26 -0
  60. package/lib/src/Services/PayFacService.js +77 -0
  61. package/lib/src/ServicesConfig.d.ts +4 -0
  62. package/lib/src/ServicesContainer.d.ts +4 -1
  63. package/lib/src/ServicesContainer.js +16 -2
  64. package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.js +1 -2
  65. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTests.d.ts +1 -0
  66. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTests.js +100 -0
  67. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTests.d.ts +1 -0
  68. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTests.js +352 -0
  69. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTests.d.ts +1 -0
  70. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTests.js +123 -0
  71. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTests.d.ts +1 -0
  72. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTests.js +146 -0
  73. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.d.ts +39 -0
  74. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/TestData/TestAccountData.js +371 -0
  75. package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTests.d.ts +1 -0
  76. package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTests.js +100 -0
  77. package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTests.d.ts +1 -0
  78. package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTests.js +535 -0
  79. package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTests.d.ts +1 -0
  80. package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTests.js +124 -0
  81. package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTests.d.ts +1 -0
  82. package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTests.js +144 -0
  83. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.d.ts +33 -0
  84. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestAccountData.js +268 -0
  85. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.d.ts +4 -0
  86. package/lib/test/Integration/Gateways/ProPayConnector/TestData/TestFundsData.js +30 -0
  87. package/logger.txt +481 -2
  88. package/package.json +1 -1
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BeneficialOwnerDataResult = void 0;
4
+ var BeneficialOwnerDataResult = /** @class */ (function () {
5
+ function BeneficialOwnerDataResult() {
6
+ }
7
+ return BeneficialOwnerDataResult;
8
+ }());
9
+ exports.BeneficialOwnerDataResult = BeneficialOwnerDataResult;
@@ -0,0 +1,14 @@
1
+ import { Address } from "../../Entities";
2
+ export declare class BusinessData {
3
+ businessLegalName: string;
4
+ doingBusinessAs: string;
5
+ employerIdentificationNumber: string;
6
+ merchantCategoryCode: string;
7
+ websiteURL: string;
8
+ businessDescription: string;
9
+ monthlyBankCardVolume: string;
10
+ averageTicket: string;
11
+ highestTicket: string;
12
+ businessAddress: Address;
13
+ constructor();
14
+ }
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BusinessData = void 0;
4
+ var Entities_1 = require("../../Entities");
5
+ var BusinessData = /** @class */ (function () {
6
+ function BusinessData() {
7
+ this.businessAddress = new Entities_1.Address();
8
+ }
9
+ return BusinessData;
10
+ }());
11
+ exports.BusinessData = BusinessData;
@@ -0,0 +1,4 @@
1
+ export declare class DeviceAttributeInfo {
2
+ name: string;
3
+ value: string;
4
+ }
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DeviceAttributeInfo = void 0;
4
+ var DeviceAttributeInfo = /** @class */ (function () {
5
+ function DeviceAttributeInfo() {
6
+ }
7
+ return DeviceAttributeInfo;
8
+ }());
9
+ exports.DeviceAttributeInfo = DeviceAttributeInfo;
@@ -0,0 +1,5 @@
1
+ import { DeviceInfo } from "./DeviceInfo";
2
+ export declare class DeviceData {
3
+ devices: Array<DeviceInfo>;
4
+ constructor();
5
+ }
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DeviceData = void 0;
4
+ var DeviceData = /** @class */ (function () {
5
+ function DeviceData() {
6
+ this.devices = new Array();
7
+ }
8
+ return DeviceData;
9
+ }());
10
+ exports.DeviceData = DeviceData;
@@ -0,0 +1,6 @@
1
+ import { DeviceAttributeInfo } from "../ProFac/DeviceAttributeInfo";
2
+ export declare class DeviceInfo {
3
+ name: string;
4
+ quantity: number;
5
+ attributes: Array<DeviceAttributeInfo>;
6
+ }
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DeviceInfo = void 0;
4
+ var DeviceInfo = /** @class */ (function () {
5
+ function DeviceInfo() {
6
+ }
7
+ return DeviceInfo;
8
+ }());
9
+ exports.DeviceInfo = DeviceInfo;
@@ -0,0 +1,7 @@
1
+ import { CreditCardData } from "../../PaymentMethods/CreditCardData";
2
+ import { Address } from "../Address";
3
+ export declare class FlashFundsPaymentCardData {
4
+ creditCard: CreditCardData;
5
+ cardholderAddress: Address;
6
+ constructor();
7
+ }
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.FlashFundsPaymentCardData = void 0;
4
+ var CreditCardData_1 = require("../../PaymentMethods/CreditCardData");
5
+ var Address_1 = require("../Address");
6
+ var FlashFundsPaymentCardData = /** @class */ (function () {
7
+ function FlashFundsPaymentCardData() {
8
+ this.creditCard = new CreditCardData_1.CreditCardData();
9
+ this.cardholderAddress = new Address_1.Address();
10
+ }
11
+ return FlashFundsPaymentCardData;
12
+ }());
13
+ exports.FlashFundsPaymentCardData = FlashFundsPaymentCardData;
@@ -0,0 +1,8 @@
1
+ import { Address } from "../Address";
2
+ import { BankAccountData } from "./BankAccountData";
3
+ import { CreditCardData } from "../../PaymentMethods";
4
+ export declare class GrossBillingInformation {
5
+ grossSettleAddress: Address;
6
+ grossSettleBankData: BankAccountData;
7
+ grossSettleCreditCardData: CreditCardData;
8
+ }
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.GrossBillingInformation = void 0;
4
+ var GrossBillingInformation = /** @class */ (function () {
5
+ function GrossBillingInformation() {
6
+ }
7
+ return GrossBillingInformation;
8
+ }());
9
+ exports.GrossBillingInformation = GrossBillingInformation;
@@ -0,0 +1,18 @@
1
+ export declare class OrderDevice {
2
+ accountNum: number;
3
+ shipTo: string;
4
+ shipToContact: string;
5
+ shipToAddress: string;
6
+ shipToAddress2: string;
7
+ shipToCity: string;
8
+ shipToState: string;
9
+ shipToZip: string;
10
+ shipToPhone: string;
11
+ cardholderName: string;
12
+ ccNum: string;
13
+ expDate: string;
14
+ cVV2: string;
15
+ billingZip: string;
16
+ name: string;
17
+ quantity: string;
18
+ }
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OrderDevice = void 0;
4
+ var OrderDevice = /** @class */ (function () {
5
+ function OrderDevice() {
6
+ }
7
+ return OrderDevice;
8
+ }());
9
+ exports.OrderDevice = OrderDevice;
@@ -0,0 +1,12 @@
1
+ import { Address } from "../../Entities";
2
+ export declare class OwnersData {
3
+ title: string;
4
+ firstName: string;
5
+ lastName: string;
6
+ email: string;
7
+ DateOfBirth: string;
8
+ sSN: string;
9
+ percentage: string;
10
+ ownerAddress: Address;
11
+ constructor();
12
+ }
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OwnersData = void 0;
4
+ var Entities_1 = require("../../Entities");
5
+ var OwnersData = /** @class */ (function () {
6
+ function OwnersData() {
7
+ this.ownerAddress = new Entities_1.Address();
8
+ }
9
+ return OwnersData;
10
+ }());
11
+ exports.OwnersData = OwnersData;
@@ -0,0 +1,55 @@
1
+ import { Address } from "../Address";
2
+ import { BeneficialOwnerDataResult } from "./BeneficialOwnerDataResult";
3
+ import { UserPersonalData } from "./UserPersonalData";
4
+ import { BusinessData } from "./BusinessData";
5
+ import { AccountPermissions } from "./AccountPermissions";
6
+ import { AccountBalanceResponseData } from "./AccountBalanceResponseData";
7
+ import { BankAccountData } from "./BankAccountData";
8
+ import { GrossBillingInformation } from "./GrossBillingInformation";
9
+ export declare class PayFacResponseData {
10
+ accountNumber: string;
11
+ recAccountNum: string;
12
+ password: string;
13
+ amount: string;
14
+ transNum: string;
15
+ pending: string;
16
+ secondaryAmount: string;
17
+ secondaryTransNum: string;
18
+ sourceEmail: string;
19
+ authToken: string;
20
+ beneficialOwnerDataResults: Array<BeneficialOwnerDataResult>;
21
+ accountStatus: string;
22
+ physicalAddress: Address;
23
+ affiliation: string;
24
+ aPIReady: string;
25
+ currencyCode: string;
26
+ expiration: string;
27
+ signupDate: string;
28
+ tier: string;
29
+ visaCheckoutMerchantID: string;
30
+ creditCardTransactionLimit: string;
31
+ creditCardMonthLimit: string;
32
+ aCHPaymentPerTranLimit: string;
33
+ aCHPaymentMonthLimit: string;
34
+ creditCardMonthlyVolume: string;
35
+ aCHPaymentMonthlyVolume: string;
36
+ reserveBalance: string;
37
+ masterPassCheckoutMerchantID: string;
38
+ personalData: UserPersonalData;
39
+ homeAddress: Address;
40
+ mailAddress: Address;
41
+ businessData: BusinessData;
42
+ accountLimits: AccountPermissions;
43
+ availableBalance: string;
44
+ pendingBalance: string;
45
+ accountBalance: AccountBalanceResponseData;
46
+ primaryBankAccountData: BankAccountData;
47
+ secondaryBankAccountData: BankAccountData;
48
+ grossBillingInformation: GrossBillingInformation;
49
+ pendingAmount: string;
50
+ reserveAmount: string;
51
+ aCHOut: AccountBalanceResponseData;
52
+ flashFunds: AccountBalanceResponseData;
53
+ transactionId: string;
54
+ transactionNumber: string;
55
+ }
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PayFacResponseData = void 0;
4
+ var PayFacResponseData = /** @class */ (function () {
5
+ function PayFacResponseData() {
6
+ }
7
+ return PayFacResponseData;
8
+ }());
9
+ exports.PayFacResponseData = PayFacResponseData;
@@ -0,0 +1,10 @@
1
+ import { CreditCardData } from "../../PaymentMethods";
2
+ export declare class RenewAccountData {
3
+ tier: string;
4
+ creditCard: CreditCardData;
5
+ zipCode: string;
6
+ paymentBankAccountNumber: string;
7
+ paymentBankRoutingNumber: string;
8
+ paymentBankAccountType: string;
9
+ constructor();
10
+ }
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.RenewAccountData = void 0;
4
+ var PaymentMethods_1 = require("../../PaymentMethods");
5
+ var RenewAccountData = /** @class */ (function () {
6
+ function RenewAccountData() {
7
+ this.creditCard = new PaymentMethods_1.CreditCardData();
8
+ }
9
+ return RenewAccountData;
10
+ }());
11
+ exports.RenewAccountData = RenewAccountData;
@@ -0,0 +1,8 @@
1
+ import { OwnersData } from "./OwnersData";
2
+ export declare class SignificantOwnerData {
3
+ authorizedSignerFirstName: string;
4
+ authorizedSignerLastName: string;
5
+ authorizedSignerTitle: string;
6
+ significantOwner: OwnersData;
7
+ constructor();
8
+ }
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SignificantOwnerData = void 0;
4
+ var OwnersData_1 = require("./OwnersData");
5
+ var SignificantOwnerData = /** @class */ (function () {
6
+ function SignificantOwnerData() {
7
+ this.significantOwner = new OwnersData_1.OwnersData();
8
+ }
9
+ return SignificantOwnerData;
10
+ }());
11
+ exports.SignificantOwnerData = SignificantOwnerData;
@@ -0,0 +1,5 @@
1
+ export declare class ThreatRiskData {
2
+ merchantSourceIP: string;
3
+ threatMetrixPolicy: string;
4
+ threatMetrixSessionID: string;
5
+ }
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ThreatRiskData = void 0;
4
+ var ThreatRiskData = /** @class */ (function () {
5
+ function ThreatRiskData() {
6
+ }
7
+ return ThreatRiskData;
8
+ }());
9
+ exports.ThreatRiskData = ThreatRiskData;
@@ -0,0 +1,26 @@
1
+ import { Address } from "../Address";
2
+ export declare class UserPersonalData {
3
+ firstName: string;
4
+ middleInitial: string;
5
+ lastName: string;
6
+ dateOfBirth: string;
7
+ sSN: string;
8
+ sourceEmail: string;
9
+ dayPhone: string;
10
+ eveningPhone: string;
11
+ notificationEmail: string;
12
+ currencyCode: string;
13
+ tier: string;
14
+ externalID: string;
15
+ phonePIN: string;
16
+ userID: string;
17
+ ipSignup: string;
18
+ uSCitizen: boolean;
19
+ bOAttestation: boolean;
20
+ termsAcceptanceIP: string;
21
+ termsAcceptanceTimeStamp: string;
22
+ termsVersion: number;
23
+ userAddress: Address;
24
+ mailingAddress: Address;
25
+ UserPersonalData(): void;
26
+ }
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.UserPersonalData = void 0;
4
+ var Address_1 = require("../Address");
5
+ var UserPersonalData = /** @class */ (function () {
6
+ function UserPersonalData() {
7
+ }
8
+ UserPersonalData.prototype.UserPersonalData = function () {
9
+ this.userAddress = new Address_1.Address();
10
+ this.mailingAddress = new Address_1.Address();
11
+ };
12
+ return UserPersonalData;
13
+ }());
14
+ exports.UserPersonalData = UserPersonalData;
@@ -0,0 +1,5 @@
1
+ export declare class SSORequestData {
2
+ referrerURL: string;
3
+ iPAddress: string;
4
+ iPSubnetMask: string;
5
+ }
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SSORequestData = void 0;
4
+ var SSORequestData = /** @class */ (function () {
5
+ function SSORequestData() {
6
+ }
7
+ return SSORequestData;
8
+ }());
9
+ exports.SSORequestData = SSORequestData;
@@ -1,4 +1,5 @@
1
1
  import { AuthorizationBuilder, GiftCard, ManagementBuilder, PaymentMethodType, TransactionReference } from "../";
2
+ import { PayFacResponseData } from "./ProFac/PayFacResponseData";
2
3
  export declare class Transaction {
3
4
  authorizedAmount: string;
4
5
  balanceAmount: string;
@@ -25,6 +26,7 @@ export declare class Transaction {
25
26
  timestamp: string;
26
27
  batchId: string;
27
28
  batchSeqNbr: string;
29
+ payFacData: PayFacResponseData;
28
30
  get transactionId(): string;
29
31
  static fromId(transactionId: string, orderId?: string | PaymentMethodType, paymentMethodType?: PaymentMethodType): Transaction;
30
32
  /**
@@ -0,0 +1,5 @@
1
+ import { Transaction } from "../Entities/Transaction";
2
+ import { PayFacBuilder } from "../Builders/PayFacBuilder";
3
+ export interface IPayFacProvider {
4
+ processPayFac(builder: PayFacBuilder): Promise<Transaction>;
5
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -19,6 +19,7 @@ export declare class PayPlanConnector extends RestGateway implements IRecurringS
19
19
  set password(value: string);
20
20
  processRecurring<T extends IRecurringEntity>(builder: RecurringBuilder<T>): Promise<T>;
21
21
  protected mapResponse<T extends IRecurringEntity>(builder: RecurringBuilder<T>, rawResponse: string): T;
22
+ log(text: string): void;
22
23
  protected buildCustomer(request: any, entity: Customer): any;
23
24
  protected buildPaymentMethod(request: any, entity: RecurringPaymentMethod, transactionType: TransactionType): any;
24
25
  protected buildSchedule(request: any, entity: Schedule, transactionType: TransactionType): any;
@@ -18,6 +18,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
18
18
  exports.PayPlanConnector = void 0;
19
19
  var __1 = require("../");
20
20
  var RestGateway_1 = require("./RestGateway");
21
+ var fs = require("fs");
21
22
  var PayPlanConnector = /** @class */ (function (_super) {
22
23
  __extends(PayPlanConnector, _super);
23
24
  function PayPlanConnector() {
@@ -93,14 +94,18 @@ var PayPlanConnector = /** @class */ (function (_super) {
93
94
  }
94
95
  this.maybeSetIdentityHeader();
95
96
  this.maybeSetIntegrationHeader();
96
- return this.doTransaction(this.mapMethod(builder.transactionType), this.mapUrl(builder), JSON.stringify(request)).then(function (response) { return _this.mapResponse(builder, response); });
97
+ return this.doTransaction(this.mapMethod(builder.transactionType), this.mapUrl(builder), JSON.stringify(request)).then(function (response) {
98
+ return _this.mapResponse(builder, response);
99
+ });
97
100
  };
98
101
  PayPlanConnector.prototype.mapResponse = function (builder, rawResponse) {
99
102
  var _this = this;
100
103
  if (!rawResponse) {
104
+ this.log(rawResponse);
101
105
  return new Object();
102
106
  }
103
107
  var response = JSON.parse(rawResponse);
108
+ this.log(response);
104
109
  var result;
105
110
  if ((builder.entity instanceof __1.Customer || builder.entity.name === 'Customer') &&
106
111
  builder.transactionType === __1.TransactionType.Search) {
@@ -131,6 +136,13 @@ var PayPlanConnector = /** @class */ (function (_super) {
131
136
  }
132
137
  return result;
133
138
  };
139
+ PayPlanConnector.prototype.log = function (text) {
140
+ fs.appendFile('loggerResponse.txt', text + '\n', function (err) {
141
+ if (err)
142
+ throw err;
143
+ });
144
+ };
145
+ ;
134
146
  PayPlanConnector.prototype.buildCustomer = function (request, entity) {
135
147
  if (entity) {
136
148
  request.customerIdentifier = entity.id;
@@ -17,7 +17,6 @@ var __extends = (this && this.__extends) || (function () {
17
17
  Object.defineProperty(exports, "__esModule", { value: true });
18
18
  exports.PorticoConnector = void 0;
19
19
  var elementtree_1 = require("@azz/elementtree");
20
- // var pjson = require('package.json')
21
20
  var __1 = require("../");
22
21
  var InputValidation_1 = require("../Utils/InputValidation");
23
22
  var XmlGateway_1 = require("./XmlGateway");
@@ -0,0 +1,41 @@
1
+ import { Transaction } from "../";
2
+ import { PayFacBuilder } from "../../src/Builders/PayFacBuilder";
3
+ import { IPayFacProvider } from "./IPayFacProvider";
4
+ import { XmlGateway } from "./XmlGateway";
5
+ export declare class ProPayConnector extends XmlGateway implements IPayFacProvider {
6
+ certStr: string;
7
+ termID: string;
8
+ x509CertificatePath: string;
9
+ x509CertStr: string;
10
+ processPayFac(builder: PayFacBuilder): Promise<Transaction>;
11
+ private HydrateAccountDetails;
12
+ private hydrateCommonFields;
13
+ private HydrateBankAccountOwnershipData;
14
+ private HydrateMailAddress;
15
+ private HydrateBankDetails;
16
+ private HydrateBusinessData;
17
+ private HydrateUserPersonalData;
18
+ private HydrateThreatRiskData;
19
+ private HydrateSignificantOwnerData;
20
+ private HydrateAccountPermissions;
21
+ private HydrateDeviceData;
22
+ private HydrateBeneficialOwnerData;
23
+ private HydrateGrossBillingData;
24
+ private HydrateAccountRenewDetails;
25
+ private HydrateFlashFundsPaymentCardData;
26
+ private HydrateDocumentUploadData;
27
+ private HydrateSSORequestData;
28
+ private HydrateOrderDeviceData;
29
+ private UpdateGatewaySettings;
30
+ private createNewElements;
31
+ private setX509Certificate;
32
+ mapRequestType(builder: PayFacBuilder): string;
33
+ mapResponse(builder: PayFacBuilder, rawResponse: string): Transaction;
34
+ private populateProPayResponse;
35
+ private populateResponseWithEnhancedAccountDetails;
36
+ private getAccountNumberFromResponse;
37
+ private getBeneficialOwnerDataResultsFromResponse;
38
+ private getPhysicalAddressFromResponse;
39
+ private getACHOutBalanceInfoFromResponse;
40
+ private getFlashFundsBalanceInfoFromResponse;
41
+ }