mangopay4-nodejs-sdk 1.64.0
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/.github/workflows/node.js.yml +32 -0
- package/.github/workflows/npm-publish.yml +26 -0
- package/.jshintrc +16 -0
- package/CHANGELOG.md +946 -0
- package/LICENSE +21 -0
- package/README.md +179 -0
- package/docs/BankAccounts.md +35 -0
- package/docs/BankingAliases.md +108 -0
- package/docs/CardPreAuthorizations.md +55 -0
- package/docs/CardRegistrations.md +55 -0
- package/docs/Cards.md +82 -0
- package/docs/Clients.md +142 -0
- package/docs/DisputeDocuments.md +53 -0
- package/docs/Disputes.md +292 -0
- package/docs/Events.md +23 -0
- package/docs/Hooks.md +68 -0
- package/docs/Idempotency.md +11 -0
- package/docs/KycDocuments.md +52 -0
- package/docs/Mandates.md +125 -0
- package/docs/OptionsHelper.md +32 -0
- package/docs/PayIns.md +72 -0
- package/docs/PayOuts.md +55 -0
- package/docs/README.md +131 -0
- package/docs/Refunds.md +25 -0
- package/docs/Reports.md +63 -0
- package/docs/Repudiations.md +25 -0
- package/docs/Responses.md +33 -0
- package/docs/Transfers.md +72 -0
- package/docs/UboDeclarations.md +70 -0
- package/docs/Users.md +322 -0
- package/docs/Wallets.md +70 -0
- package/docs/templates/class.mustache +11 -0
- package/docs/templates/file.mustache +53 -0
- package/docs/templates/function.mustache +33 -0
- package/docs/templates/index.mustache +26 -0
- package/docs/templates/overview.mustache +1 -0
- package/examples/createUsers.js +112 -0
- package/examples/createWallet.js +28 -0
- package/examples/failedRequest.js +20 -0
- package/examples/getBankAccounts.js +29 -0
- package/examples/getUserEmoney.js +16 -0
- package/examples/getUsers.js +32 -0
- package/examples/readResponseHeaders.js +42 -0
- package/index.js +1 -0
- package/lib/Model.js +58 -0
- package/lib/api.js +467 -0
- package/lib/apiMethods.js +270 -0
- package/lib/config.js +57 -0
- package/lib/log.js +9 -0
- package/lib/mangopay.js +8 -0
- package/lib/models/Address.js +32 -0
- package/lib/models/BankAccount.js +45 -0
- package/lib/models/BankAccountDetails.js +7 -0
- package/lib/models/BankAccountDetailsCA.js +12 -0
- package/lib/models/BankAccountDetailsGB.js +10 -0
- package/lib/models/BankAccountDetailsIBAN.js +10 -0
- package/lib/models/BankAccountDetailsOTHER.js +16 -0
- package/lib/models/BankAccountDetailsUS.js +14 -0
- package/lib/models/BankAccountType.js +8 -0
- package/lib/models/BankingAlias.js +37 -0
- package/lib/models/BankingAliasIBAN.js +27 -0
- package/lib/models/Billing.js +14 -0
- package/lib/models/BinData.js +16 -0
- package/lib/models/Birthplace.js +10 -0
- package/lib/models/BrowserInfo.js +15 -0
- package/lib/models/Card.js +19 -0
- package/lib/models/CardInfo.js +32 -0
- package/lib/models/CardPreAuthorization.js +144 -0
- package/lib/models/CardRegistration.js +29 -0
- package/lib/models/CardValidation.js +19 -0
- package/lib/models/CategorizeUserLegal.js +15 -0
- package/lib/models/CategorizeUserNatural.js +18 -0
- package/lib/models/Check.js +13 -0
- package/lib/models/CheckData.js +8 -0
- package/lib/models/Client.js +62 -0
- package/lib/models/ClientWallet.js +28 -0
- package/lib/models/Conversion.js +19 -0
- package/lib/models/ConversionRate.js +10 -0
- package/lib/models/CountryAuthorization.js +12 -0
- package/lib/models/DebitedBankAccount.js +15 -0
- package/lib/models/DeclaredUbo.js +29 -0
- package/lib/models/DeclaredUboStatus.js +17 -0
- package/lib/models/Deposit.js +29 -0
- package/lib/models/Dispute.js +46 -0
- package/lib/models/DisputeDocument.js +10 -0
- package/lib/models/DisputeDocumentPage.js +12 -0
- package/lib/models/DisputeReason.js +11 -0
- package/lib/models/Document.js +12 -0
- package/lib/models/DocumentPageConsult.js +17 -0
- package/lib/models/EMoney.js +30 -0
- package/lib/models/EntityBase.js +70 -0
- package/lib/models/Hook.js +19 -0
- package/lib/models/IdempotencyResponse.js +11 -0
- package/lib/models/IdentityVerification.js +12 -0
- package/lib/models/KycDocument.js +11 -0
- package/lib/models/KycDocumentStatus.js +7 -0
- package/lib/models/KycDocumentType.js +7 -0
- package/lib/models/KycPage.js +12 -0
- package/lib/models/LegalPersonType.js +7 -0
- package/lib/models/LegalRepresentative.js +16 -0
- package/lib/models/Mandate.js +69 -0
- package/lib/models/MandateStatus.js +7 -0
- package/lib/models/Money.js +16 -0
- package/lib/models/PayByBankSupportedBank.js +7 -0
- package/lib/models/PayIn.js +36 -0
- package/lib/models/PayInExecutionDetails.js +7 -0
- package/lib/models/PayInExecutionDetailsBankingAlias.js +19 -0
- package/lib/models/PayInExecutionDetailsDirect.js +29 -0
- package/lib/models/PayInExecutionDetailsWeb.js +40 -0
- package/lib/models/PayInExecutionType.js +5 -0
- package/lib/models/PayInIntent.js +20 -0
- package/lib/models/PayInIntentSplit.js +14 -0
- package/lib/models/PayInIntentSplits.js +7 -0
- package/lib/models/PayInPaymentDetails.js +7 -0
- package/lib/models/PayInPaymentDetailsApplePay.js +19 -0
- package/lib/models/PayInPaymentDetailsBancontact.js +13 -0
- package/lib/models/PayInPaymentDetailsBankWire.js +23 -0
- package/lib/models/PayInPaymentDetailsBankingAlias.js +18 -0
- package/lib/models/PayInPaymentDetailsBizum.js +23 -0
- package/lib/models/PayInPaymentDetailsBlik.js +17 -0
- package/lib/models/PayInPaymentDetailsCard.js +10 -0
- package/lib/models/PayInPaymentDetailsCardDirect.js +14 -0
- package/lib/models/PayInPaymentDetailsCardWeb.js +28 -0
- package/lib/models/PayInPaymentDetailsDirectDebitDirect.js +22 -0
- package/lib/models/PayInPaymentDetailsDirectDebitWeb.js +13 -0
- package/lib/models/PayInPaymentDetailsGiropay.js +15 -0
- package/lib/models/PayInPaymentDetailsGooglePay.js +35 -0
- package/lib/models/PayInPaymentDetailsIdeal.js +25 -0
- package/lib/models/PayInPaymentDetailsKlarna.js +36 -0
- package/lib/models/PayInPaymentDetailsMbway.js +20 -0
- package/lib/models/PayInPaymentDetailsMultibanco.js +14 -0
- package/lib/models/PayInPaymentDetailsPayByBank.js +71 -0
- package/lib/models/PayInPaymentDetailsPayPal.js +63 -0
- package/lib/models/PayInPaymentDetailsPayconiq.js +23 -0
- package/lib/models/PayInPaymentDetailsPreAuthorized.js +10 -0
- package/lib/models/PayInPaymentDetailsSatispay.js +19 -0
- package/lib/models/PayInPaymentDetailsSwish.js +35 -0
- package/lib/models/PayInPaymentDetailsTwint.js +15 -0
- package/lib/models/PayInPaymentType.js +21 -0
- package/lib/models/PayInRecurringRegistration.js +64 -0
- package/lib/models/PayInTemplateURLOptions.js +10 -0
- package/lib/models/PayOut.js +24 -0
- package/lib/models/PayOutPaymentDetails.js +7 -0
- package/lib/models/PayOutPaymentDetailsBankWire.js +32 -0
- package/lib/models/PayOutPaymentType.js +3 -0
- package/lib/models/PaymentData.js +20 -0
- package/lib/models/PaymentMethodMetadata.js +38 -0
- package/lib/models/PayoutMethods.js +7 -0
- package/lib/models/PendingUserAction.js +16 -0
- package/lib/models/PersonType.js +5 -0
- package/lib/models/PlatformCategorization.js +16 -0
- package/lib/models/PlatformType.js +10 -0
- package/lib/models/Quote.js +11 -0
- package/lib/models/Recipient.js +20 -0
- package/lib/models/RecipientSchema.js +17 -0
- package/lib/models/RecurringPayIn.js +10 -0
- package/lib/models/RecurringPayInCIT.js +32 -0
- package/lib/models/RecurringPayInCurrentState.js +24 -0
- package/lib/models/RecurringPayInMIT.js +27 -0
- package/lib/models/RecurringPayInPut.js +24 -0
- package/lib/models/Refund.js +26 -0
- package/lib/models/RefundReasonDetails.js +10 -0
- package/lib/models/Report.js +54 -0
- package/lib/models/ReportFilter.js +52 -0
- package/lib/models/ReportFilterV2.js +11 -0
- package/lib/models/ReportV2.js +28 -0
- package/lib/models/Repudiation.js +51 -0
- package/lib/models/SecurityInfo.js +12 -0
- package/lib/models/Settlement.js +16 -0
- package/lib/models/SettlementTransfer.js +37 -0
- package/lib/models/Shipping.js +14 -0
- package/lib/models/ShippingAddress.js +25 -0
- package/lib/models/ShippingPreference.js +5 -0
- package/lib/models/Transaction.js +50 -0
- package/lib/models/Transfer.js +13 -0
- package/lib/models/Ubo.js +19 -0
- package/lib/models/UboDeclaration.js +42 -0
- package/lib/models/UboDeclarationRefusedReasonType.js +23 -0
- package/lib/models/UboDeclarationStatus.js +26 -0
- package/lib/models/UboRefusedReasonType.js +14 -0
- package/lib/models/User.js +66 -0
- package/lib/models/UserCategory.js +5 -0
- package/lib/models/UserConsent.js +7 -0
- package/lib/models/UserDataFormatValidation.js +7 -0
- package/lib/models/UserEnrollmentResult.js +7 -0
- package/lib/models/UserLegal.js +65 -0
- package/lib/models/UserLegalOwner.js +66 -0
- package/lib/models/UserLegalPayer.js +66 -0
- package/lib/models/UserLegalSca.js +57 -0
- package/lib/models/UserNatural.js +51 -0
- package/lib/models/UserNaturalCapacity.js +13 -0
- package/lib/models/UserNaturalOwner.js +55 -0
- package/lib/models/UserNaturalPayer.js +55 -0
- package/lib/models/UserNaturalPut.js +49 -0
- package/lib/models/UserNaturalSca.js +56 -0
- package/lib/models/VirtualAccount.js +22 -0
- package/lib/models/Wallet.js +32 -0
- package/lib/models/index.js +102 -0
- package/lib/service.js +14 -0
- package/lib/services/BankAccounts.js +31 -0
- package/lib/services/BankingAliases.js +137 -0
- package/lib/services/CardPreAuthorizations.js +75 -0
- package/lib/services/CardRegistrations.js +64 -0
- package/lib/services/Cards.js +168 -0
- package/lib/services/Clients.js +196 -0
- package/lib/services/Conversions.js +155 -0
- package/lib/services/Deposits.js +109 -0
- package/lib/services/DisputeDocuments.js +65 -0
- package/lib/services/Disputes.js +409 -0
- package/lib/services/Events.js +24 -0
- package/lib/services/Hooks.js +81 -0
- package/lib/services/Idempotency.js +17 -0
- package/lib/services/IdentityVerifications.js +48 -0
- package/lib/services/KycDocuments.js +66 -0
- package/lib/services/Mandates.js +161 -0
- package/lib/services/OptionsHelper.js +20 -0
- package/lib/services/PayIns.js +690 -0
- package/lib/services/PayOuts.js +110 -0
- package/lib/services/Recipients.js +117 -0
- package/lib/services/Refunds.js +29 -0
- package/lib/services/Regulatory.js +29 -0
- package/lib/services/Reports.js +61 -0
- package/lib/services/ReportsV2.js +55 -0
- package/lib/services/Repudiations.js +33 -0
- package/lib/services/Responses.js +23 -0
- package/lib/services/Settlements.js +74 -0
- package/lib/services/Transfers.js +87 -0
- package/lib/services/UboDeclarations.js +135 -0
- package/lib/services/Users.js +831 -0
- package/lib/services/VirtualAccounts.js +99 -0
- package/lib/services/Wallets.js +85 -0
- package/lib/services/index.js +34 -0
- package/lib/utils.js +36 -0
- package/package.json +40 -0
- package/test/TestKycPageFile.png +0 -0
- package/test/helpers.js +1431 -0
- package/test/main.js +10 -0
- package/test/mocha.opts +3 -0
- package/test/services/BankAccounts.js +46 -0
- package/test/services/BankingAliases.js +89 -0
- package/test/services/CardPreAuthorizations.js +70 -0
- package/test/services/CardRegistrations.js +239 -0
- package/test/services/Cards.js +54 -0
- package/test/services/Clients.js +235 -0
- package/test/services/Conversions.js +308 -0
- package/test/services/Deposits.js +148 -0
- package/test/services/Disputes.js +542 -0
- package/test/services/EMoney.js +54 -0
- package/test/services/Events.js +143 -0
- package/test/services/Hooks.js +109 -0
- package/test/services/Idempotency.js +46 -0
- package/test/services/IdentityVerifications.js +68 -0
- package/test/services/KycDocuments.js +73 -0
- package/test/services/Mandates.js +256 -0
- package/test/services/PayIns.js +2553 -0
- package/test/services/PayOuts.js +106 -0
- package/test/services/RateLimit.js +48 -0
- package/test/services/Recipients.js +234 -0
- package/test/services/Refunds.js +123 -0
- package/test/services/Regulatory.js +45 -0
- package/test/services/Reports.js +114 -0
- package/test/services/ReportsV2.js +306 -0
- package/test/services/Repudiations.js +22 -0
- package/test/services/Settlements.js +58 -0
- package/test/services/Tokens.js +55 -0
- package/test/services/Transfers.js +137 -0
- package/test/services/UboDeclarations.js +135 -0
- package/test/services/Users.js +1303 -0
- package/test/services/VirtualAccounts.js +105 -0
- package/test/services/Wallets.js +132 -0
- package/test/settlement_sample.csv +8 -0
- package/typings/base.d.ts +308 -0
- package/typings/enums.d.ts +204 -0
- package/typings/index.d.ts +885 -0
- package/typings/index.test-d.ts +1535 -0
- package/typings/models/address.d.ts +70 -0
- package/typings/models/bankAccount.d.ts +235 -0
- package/typings/models/bankingAlias.d.ts +97 -0
- package/typings/models/billing.d.ts +42 -0
- package/typings/models/birthplace.d.ts +9 -0
- package/typings/models/card.d.ts +119 -0
- package/typings/models/cardPreauthorization.d.ts +157 -0
- package/typings/models/cardRegistration.d.ts +83 -0
- package/typings/models/cardValidation.d.ts +125 -0
- package/typings/models/client.d.ts +208 -0
- package/typings/models/conversion.d.ts +225 -0
- package/typings/models/conversionRate.d.ts +29 -0
- package/typings/models/countryAuthorization.d.ts +16 -0
- package/typings/models/deposit.d.ts +104 -0
- package/typings/models/dispute.d.ts +116 -0
- package/typings/models/disputeDocument.d.ts +119 -0
- package/typings/models/entityBase.d.ts +9 -0
- package/typings/models/event.d.ts +142 -0
- package/typings/models/hook.d.ts +39 -0
- package/typings/models/idempotency.d.ts +36 -0
- package/typings/models/identityVerification.d.ts +98 -0
- package/typings/models/kycDocument.d.ts +114 -0
- package/typings/models/mandate.d.ts +93 -0
- package/typings/models/money.d.ts +45 -0
- package/typings/models/payIn.d.ts +3742 -0
- package/typings/models/payOut.d.ts +144 -0
- package/typings/models/recipient.d.ts +242 -0
- package/typings/models/refund.d.ts +92 -0
- package/typings/models/report.d.ts +234 -0
- package/typings/models/reportV2.d.ts +145 -0
- package/typings/models/repudiation.d.ts +26 -0
- package/typings/models/securityInfo.d.ts +12 -0
- package/typings/models/settlement.d.ts +50 -0
- package/typings/models/settlementTransfer.d.ts +37 -0
- package/typings/models/shipping.d.ts +37 -0
- package/typings/models/shippingAddress.d.ts +15 -0
- package/typings/models/transaction.d.ts +85 -0
- package/typings/models/transfer.d.ts +119 -0
- package/typings/models/uboDeclaration.d.ts +100 -0
- package/typings/models/user.d.ts +1001 -0
- package/typings/models/virtualAccount.d.ts +182 -0
- package/typings/models/wallet.d.ts +46 -0
- package/typings/models.d.ts +74 -0
- package/typings/services/BankAccounts.d.ts +12 -0
- package/typings/services/BankingAliases.d.ts +51 -0
- package/typings/services/CardPreauthorizations.d.ts +44 -0
- package/typings/services/CardRegistrations.d.ts +43 -0
- package/typings/services/Cards.d.ts +80 -0
- package/typings/services/Clients.d.ts +77 -0
- package/typings/services/Conversions.d.ts +23 -0
- package/typings/services/Deposits.d.ts +20 -0
- package/typings/services/DisputeDocuments.d.ts +27 -0
- package/typings/services/Disputes.d.ts +169 -0
- package/typings/services/Events.d.ts +11 -0
- package/typings/services/Hooks.d.ts +33 -0
- package/typings/services/Idempotency.d.ts +7 -0
- package/typings/services/IdentityVerifications.d.ts +29 -0
- package/typings/services/KycDocuments.d.ts +38 -0
- package/typings/services/Mandates.d.ts +59 -0
- package/typings/services/OptionsHelper.d.ts +11 -0
- package/typings/services/PayIns.d.ts +319 -0
- package/typings/services/PayOuts.d.ts +34 -0
- package/typings/services/Recipients.d.ts +55 -0
- package/typings/services/Refunds.d.ts +12 -0
- package/typings/services/Regulatory.d.ts +17 -0
- package/typings/services/Reports.d.ts +26 -0
- package/typings/services/ReportsV2.d.ts +26 -0
- package/typings/services/Repudiations.d.ts +12 -0
- package/typings/services/Responses.d.ts +10 -0
- package/typings/services/Settlements.d.ts +28 -0
- package/typings/services/Transfers.d.ts +38 -0
- package/typings/services/UboDeclarations.d.ts +81 -0
- package/typings/services/Users.d.ts +308 -0
- package/typings/services/VirtualAccounts.d.ts +42 -0
- package/typings/services/Wallets.d.ts +36 -0
- package/typings/tsconfig.json +20 -0
- package/typings/tslint.json +11 -0
- package/typings/types.d.ts +652 -0
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
|
|
3
|
+
var PaymentMethodMetadata = EntityBase.extend({
|
|
4
|
+
defaults: {
|
|
5
|
+
/**
|
|
6
|
+
* The type of metadata. Allowed values: BIN, GOOGLE_PAY
|
|
7
|
+
*/
|
|
8
|
+
Type: null,
|
|
9
|
+
/**
|
|
10
|
+
* The bank identification number (BIN). (Format: 6 or 8 digits)
|
|
11
|
+
*/
|
|
12
|
+
Bin: null,
|
|
13
|
+
/**
|
|
14
|
+
* The tokenized payment data provided by the third-party payment method.
|
|
15
|
+
*/
|
|
16
|
+
Token: null,
|
|
17
|
+
/**
|
|
18
|
+
* In the case of Google Pay, the format of the Token.
|
|
19
|
+
* PAN_ONLY – The card is registered in the Google account and requires 3DS authentication.
|
|
20
|
+
* CRYPTOGRAM_3DS – The card is enrolled in the customer’s Google Wallet and authentication is handled by the Android device.
|
|
21
|
+
*/
|
|
22
|
+
TokenFormat: null,
|
|
23
|
+
/**
|
|
24
|
+
* The country where the card was issued. Format: ISO-3166 alpha-2 two-letter country code
|
|
25
|
+
*/
|
|
26
|
+
IssuerCountryCode: null,
|
|
27
|
+
/**
|
|
28
|
+
* The name of the card issuer.
|
|
29
|
+
*/
|
|
30
|
+
IssuingBank: null,
|
|
31
|
+
/**
|
|
32
|
+
* Additional data about the card based on the BIN. In the case of co-branded card products, two objects are returned.
|
|
33
|
+
*/
|
|
34
|
+
BinData: null
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
module.exports = PaymentMethodMetadata;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
|
|
3
|
+
var PendingUserAction = EntityBase.extend({
|
|
4
|
+
defaults: {
|
|
5
|
+
/**
|
|
6
|
+
* The URL to which to redirect the user to perform strong customer authentication (SCA) via a Mangopay-hosted webpage. This value is a variable and should not be hardcoded.
|
|
7
|
+
* <p>
|
|
8
|
+
* Caution: Before redirecting the user on this URL, you must add the query parameter ReturnUrl with the percent-encoded URL to which you want the SCA session to return the user after authentication (whether successful or not).
|
|
9
|
+
* <p>
|
|
10
|
+
* For more details, see <a href="https://docs.mangopay.com/guides/users/sca#how-to-redirect-a-user-for-an-sca-session">How to redirect a user for an SCA session</a>
|
|
11
|
+
*/
|
|
12
|
+
RedirectUrl: null
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
module.exports = PendingUserAction;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
|
|
3
|
+
var PlatformCategorization = EntityBase.extend({
|
|
4
|
+
defaults: {
|
|
5
|
+
/**
|
|
6
|
+
* The type of business conducted by the client
|
|
7
|
+
*/
|
|
8
|
+
BusinessType: null,
|
|
9
|
+
/**
|
|
10
|
+
* Sector of business
|
|
11
|
+
*/
|
|
12
|
+
Sector: null
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
module.exports = PlatformCategorization;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
module.exports = {
|
|
2
|
+
NotSpecified: 'NotSpecified',
|
|
3
|
+
MARKETPLACE: 'MARKETPLACE',
|
|
4
|
+
P2P_PAYMENT: 'P2P_PAYMENT',
|
|
5
|
+
CROWDFUNDING_DONATION: 'CROWDFUNDING_DONATION',
|
|
6
|
+
CROWDFUNDING_REWARD: 'CROWDFUNDING_REWARD',
|
|
7
|
+
CROWDFUNDING_EQUITY: 'CROWDFUNDING_EQUITY',
|
|
8
|
+
CROWDFUNDING_LOAN: 'CROWDFUNDING_LOAN',
|
|
9
|
+
OTHER: 'OTHER'
|
|
10
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
|
|
3
|
+
module.exports = EntityBase.extend({
|
|
4
|
+
defaults: {
|
|
5
|
+
Status: null,
|
|
6
|
+
DisplayName: null,
|
|
7
|
+
PayoutMethodType: null,
|
|
8
|
+
RecipientType: null,
|
|
9
|
+
Currency: null,
|
|
10
|
+
Country: null,
|
|
11
|
+
RecipientScope: null,
|
|
12
|
+
UserId: null,
|
|
13
|
+
IndividualRecipient: null,
|
|
14
|
+
BusinessRecipient: null,
|
|
15
|
+
LocalBankTransfer: null,
|
|
16
|
+
InternationalBankTransfer: null,
|
|
17
|
+
PendingUserAction: null,
|
|
18
|
+
ScaContext: null
|
|
19
|
+
}
|
|
20
|
+
});
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
|
|
3
|
+
module.exports = EntityBase.extend({
|
|
4
|
+
defaults: {
|
|
5
|
+
DisplayName: null,
|
|
6
|
+
Currency: null,
|
|
7
|
+
Country: null,
|
|
8
|
+
RecipientType: null,
|
|
9
|
+
PayoutMethodType: null,
|
|
10
|
+
RecipientScope: null,
|
|
11
|
+
Tag: null,
|
|
12
|
+
LocalBankTransfer: null,
|
|
13
|
+
InternationalBankTransfer: null,
|
|
14
|
+
IndividualRecipient: null,
|
|
15
|
+
BusinessRecipient: null,
|
|
16
|
+
}
|
|
17
|
+
});
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
var BrowserInfo = require('./BrowserInfo');
|
|
3
|
+
var Money = require('./Money');
|
|
4
|
+
|
|
5
|
+
var RecurringPayInCIT = EntityBase.extend({
|
|
6
|
+
defaults: {
|
|
7
|
+
/**
|
|
8
|
+
* Array with owners identities
|
|
9
|
+
*/
|
|
10
|
+
RecurringPayinRegistrationId: null,
|
|
11
|
+
BrowserInfo: null,
|
|
12
|
+
IpAddress: null,
|
|
13
|
+
SecureModeReturnURL: null,
|
|
14
|
+
StatementDescriptor: null,
|
|
15
|
+
DebitedFunds: null,
|
|
16
|
+
Fees: null
|
|
17
|
+
},
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Get mapping of model properties and corresponding object types
|
|
21
|
+
* @returns {Object}
|
|
22
|
+
*/
|
|
23
|
+
getSubObjects: function() {
|
|
24
|
+
return {
|
|
25
|
+
'BrowserInfo': BrowserInfo,
|
|
26
|
+
'DebitedFunds': Money,
|
|
27
|
+
'Fees': Money
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
module.exports = RecurringPayInCIT;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
var Model = require('./../Model');
|
|
2
|
+
var Money = require('./Money')
|
|
3
|
+
|
|
4
|
+
var RecurringPayInCurrentState = Model.extend({
|
|
5
|
+
defaults: {
|
|
6
|
+
PayinsLinked: null,
|
|
7
|
+
CumulatedDebitedAmount: null,
|
|
8
|
+
CumulatedFeesAmount: null,
|
|
9
|
+
LastPayinId: null
|
|
10
|
+
},
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Get mapping of model properties and corresponding object types
|
|
14
|
+
* @returns {Object}
|
|
15
|
+
*/
|
|
16
|
+
getSubObjects: function() {
|
|
17
|
+
return {
|
|
18
|
+
'CumulatedDebitedAmount': Money,
|
|
19
|
+
'CumulatedFeesAmount': Money
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
module.exports = RecurringPayInCurrentState;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
var Money = require('./Money');
|
|
3
|
+
|
|
4
|
+
var RecurringPayInMIT = EntityBase.extend({
|
|
5
|
+
defaults: {
|
|
6
|
+
/**
|
|
7
|
+
* Array with owners identities
|
|
8
|
+
*/
|
|
9
|
+
RecurringPayinRegistrationId: null,
|
|
10
|
+
DebitedFunds: null,
|
|
11
|
+
Fees: null,
|
|
12
|
+
StatementDescriptor: null
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Get mapping of model properties and corresponding object types
|
|
17
|
+
* @returns {Object}
|
|
18
|
+
*/
|
|
19
|
+
getSubObjects: function() {
|
|
20
|
+
return {
|
|
21
|
+
'DebitedFunds': Money,
|
|
22
|
+
'Fees': Money
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
});
|
|
26
|
+
|
|
27
|
+
module.exports = RecurringPayInMIT;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
var Model = require('./../Model');
|
|
2
|
+
var Billing = require('./Billing');
|
|
3
|
+
var Shipping = require('./Shipping');
|
|
4
|
+
|
|
5
|
+
var RecurringPayInPut = Model.extend({
|
|
6
|
+
defaults: {
|
|
7
|
+
CardId: null,
|
|
8
|
+
Billing: null,
|
|
9
|
+
Shipping: null
|
|
10
|
+
},
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Get mapping of model properties and corresponding object types
|
|
14
|
+
* @returns {Object}
|
|
15
|
+
*/
|
|
16
|
+
getSubObjects: function() {
|
|
17
|
+
return {
|
|
18
|
+
'Billing': Billing,
|
|
19
|
+
'Shipping': Shipping
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
module.exports = RecurringPayInPut;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
var _ = require('underscore');
|
|
2
|
+
var Transaction = require('./Transaction');
|
|
3
|
+
var RefundReasonDetails = require('./RefundReasonDetails');
|
|
4
|
+
|
|
5
|
+
var Refund = Transaction.extend({
|
|
6
|
+
defaults: _.extend({}, Transaction.prototype.defaults, {
|
|
7
|
+
InitialTransactionId: null,
|
|
8
|
+
/**
|
|
9
|
+
* Initial transaction Type {PAYIN, PAYOUT, TRANSFER}
|
|
10
|
+
*/
|
|
11
|
+
InitialTransactionType: null,
|
|
12
|
+
DebitedWalletId: null,
|
|
13
|
+
CreditedWalletId: null,
|
|
14
|
+
RefundReason: null,
|
|
15
|
+
Reference: null,
|
|
16
|
+
StatementDescriptor: null
|
|
17
|
+
}),
|
|
18
|
+
|
|
19
|
+
getSubObjects: function() {
|
|
20
|
+
return {
|
|
21
|
+
'RefundReason': RefundReasonDetails
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
module.exports = Refund;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
var ReportFilter = require('./ReportFilter');
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
var Report = EntityBase.extend({
|
|
6
|
+
defaults: {
|
|
7
|
+
/**
|
|
8
|
+
*The date when the report was executed
|
|
9
|
+
*/
|
|
10
|
+
ReportDate: null,
|
|
11
|
+
/**
|
|
12
|
+
* The URL to download the report
|
|
13
|
+
*/
|
|
14
|
+
DownloadURL: null,
|
|
15
|
+
/**
|
|
16
|
+
* A URL that will be pinged when the report is ready to download (works in a similar way to the hooks)
|
|
17
|
+
*/
|
|
18
|
+
CallbackURL: null,
|
|
19
|
+
/**
|
|
20
|
+
* The format of the report download { CSV }
|
|
21
|
+
*/
|
|
22
|
+
DownloadFormat: null,
|
|
23
|
+
/**
|
|
24
|
+
* Report type {TRANSACTIONS, WALLETS}
|
|
25
|
+
*/
|
|
26
|
+
ReportType: null,
|
|
27
|
+
/**
|
|
28
|
+
* The column to sort against and direction
|
|
29
|
+
*/
|
|
30
|
+
Sort: null,
|
|
31
|
+
/**
|
|
32
|
+
* Whether the report should be limited to the first 10 lines (and therefore quicker to execute)
|
|
33
|
+
*/
|
|
34
|
+
Preview: null,
|
|
35
|
+
Filters: null,
|
|
36
|
+
/**
|
|
37
|
+
* A list of columns/infos to show in the report
|
|
38
|
+
*/
|
|
39
|
+
Columns: null,
|
|
40
|
+
/**
|
|
41
|
+
* The result code
|
|
42
|
+
*/
|
|
43
|
+
ResultCode: null,
|
|
44
|
+
ResultMessage: null
|
|
45
|
+
},
|
|
46
|
+
|
|
47
|
+
getSubObjects: function () {
|
|
48
|
+
return {
|
|
49
|
+
'Filters': ReportFilter
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
|
|
54
|
+
module.exports = Report;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
var Model = require('../Model');
|
|
2
|
+
|
|
3
|
+
var ReportFilter = Model.extend({
|
|
4
|
+
defaults: {
|
|
5
|
+
/**
|
|
6
|
+
* To return only resources that have CreationDate BEFORE this date
|
|
7
|
+
*/
|
|
8
|
+
BeforeDate: null,
|
|
9
|
+
/**
|
|
10
|
+
* To return only resources that have CreationDate AFTER this date
|
|
11
|
+
*/
|
|
12
|
+
AfterDate: null,
|
|
13
|
+
/**
|
|
14
|
+
* The type of the transaction
|
|
15
|
+
*/
|
|
16
|
+
Type: null,
|
|
17
|
+
/**
|
|
18
|
+
* The status of the transaction
|
|
19
|
+
*/
|
|
20
|
+
Status: null,
|
|
21
|
+
/**
|
|
22
|
+
* The nature of the transaction
|
|
23
|
+
*/
|
|
24
|
+
Nature: null,
|
|
25
|
+
/**
|
|
26
|
+
* The minimum amount of DebitedFunds
|
|
27
|
+
*/
|
|
28
|
+
MinDebitedFundsAmount: null,
|
|
29
|
+
/**
|
|
30
|
+
* The currency for the minimum amount of DebitedFunds
|
|
31
|
+
*/
|
|
32
|
+
MinDebitedFundsCurrency: null,
|
|
33
|
+
/**
|
|
34
|
+
* The maximum amount of DebitedFunds
|
|
35
|
+
*/
|
|
36
|
+
MaxDebitedFundsAmount: null,
|
|
37
|
+
/**
|
|
38
|
+
* The currency for the maximum amount of DebitedFunds
|
|
39
|
+
*/
|
|
40
|
+
MaxDebitedFundsCurrency: null,
|
|
41
|
+
/**
|
|
42
|
+
* The object owner's id
|
|
43
|
+
*/
|
|
44
|
+
AuthorId: null,
|
|
45
|
+
|
|
46
|
+
WalletId: null
|
|
47
|
+
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
module.exports = ReportFilter;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
var ReportFilterV2 = require('./ReportFilterV2');
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
var ReportV2 = EntityBase.extend({
|
|
6
|
+
defaults: {
|
|
7
|
+
ReportDate: null,
|
|
8
|
+
Status: null,
|
|
9
|
+
ResultCode: null,
|
|
10
|
+
ResultMessage: null,
|
|
11
|
+
DownloadFormat: null,
|
|
12
|
+
DownloadURL: null,
|
|
13
|
+
ReportType: null,
|
|
14
|
+
Sort: null,
|
|
15
|
+
AfterDate: null,
|
|
16
|
+
BeforeDate: null,
|
|
17
|
+
Filters: null,
|
|
18
|
+
Columns: null
|
|
19
|
+
},
|
|
20
|
+
|
|
21
|
+
getSubObjects: function () {
|
|
22
|
+
return {
|
|
23
|
+
'Filters': ReportFilterV2
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
module.exports = ReportV2;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
var _ = require('underscore');
|
|
2
|
+
var Model = require('../Model');
|
|
3
|
+
var Money = require('./Money');
|
|
4
|
+
|
|
5
|
+
var Repudiation = Model.extend({
|
|
6
|
+
defaults: {
|
|
7
|
+
AuthorId: null,
|
|
8
|
+
/**
|
|
9
|
+
* The funds repudiated from the wallet
|
|
10
|
+
*/
|
|
11
|
+
DebitedFunds: null,
|
|
12
|
+
/**
|
|
13
|
+
* The fees taken on the repudiation – will always be 0 at this stage
|
|
14
|
+
*/
|
|
15
|
+
Fees: null,
|
|
16
|
+
/**
|
|
17
|
+
* The amount of credited funds – since there are currently no fees,
|
|
18
|
+
* this will be equal to the DebitedFunds
|
|
19
|
+
*/
|
|
20
|
+
CreditedFunds: null,
|
|
21
|
+
/**
|
|
22
|
+
* The wallet from where the repudiation was taken
|
|
23
|
+
*/
|
|
24
|
+
DebitedWalletId: null,
|
|
25
|
+
/**
|
|
26
|
+
* The status of the transfer {CREATED, SUCCEEDED, FAILED}
|
|
27
|
+
*/
|
|
28
|
+
Status: null,
|
|
29
|
+
ResultCode: null,
|
|
30
|
+
ResultMessage: null,
|
|
31
|
+
ExecutionDate: null,
|
|
32
|
+
/**
|
|
33
|
+
* The Id of the dispute to which this repudation corresponds.
|
|
34
|
+
* Note that this value may be null (if it was created before the Dispute
|
|
35
|
+
* objects started to be used – October 2015)
|
|
36
|
+
*/
|
|
37
|
+
DisputeId: null,
|
|
38
|
+
InitialTransactionId: null,
|
|
39
|
+
InitialTransactionType: null
|
|
40
|
+
},
|
|
41
|
+
|
|
42
|
+
getSubObjects: function() {
|
|
43
|
+
return {
|
|
44
|
+
'DebitedFunds': Money,
|
|
45
|
+
'Fees': Money,
|
|
46
|
+
'CreditedFunds': Money
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
module.exports = Repudiation;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
|
|
3
|
+
var Settlement = EntityBase.extend({
|
|
4
|
+
defaults: {
|
|
5
|
+
SettlementId: null,
|
|
6
|
+
Status: null,
|
|
7
|
+
SettlementDate: null,
|
|
8
|
+
ExternalProviderName: null,
|
|
9
|
+
DeclaredIntentAmount: null,
|
|
10
|
+
ExternalProcessorFeesAmount: null,
|
|
11
|
+
ActualSettlementAmount: null,
|
|
12
|
+
FundsMissingAmount: null
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
module.exports = Settlement;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
var _ = require('underscore');
|
|
2
|
+
var Model = require('../Model');
|
|
3
|
+
var Money = require('./Money');
|
|
4
|
+
|
|
5
|
+
var SettlementTransfer = Model.extend({
|
|
6
|
+
defaults: {
|
|
7
|
+
/**
|
|
8
|
+
* The Id of the author of the original PayIn that was repudiated
|
|
9
|
+
*/
|
|
10
|
+
AuthorId: null,
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* The funds debited from the debited wallet
|
|
14
|
+
*/
|
|
15
|
+
DebitedFunds: null,
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* The amount you wish to charge for this settlement.
|
|
19
|
+
* This can be equal to 0, or more than 0 to charge for the settlement
|
|
20
|
+
* or less than 0 to refund some of the original Fees that were taken
|
|
21
|
+
* on the original settlement (eg DebitedFunds of 1000 and
|
|
22
|
+
* Fees of -200 will transfer 800 from the original wallet
|
|
23
|
+
* to the credit wallet, and transfer 200 from your Fees
|
|
24
|
+
* wallet to your Credit wallet
|
|
25
|
+
*/
|
|
26
|
+
Fees: null
|
|
27
|
+
},
|
|
28
|
+
|
|
29
|
+
getSubObjects: function() {
|
|
30
|
+
return {
|
|
31
|
+
'DebitedFunds': Money,
|
|
32
|
+
'Fees': Money
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
module.exports = SettlementTransfer;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
var Address = require('./Address');
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Models shipping details
|
|
6
|
+
*/
|
|
7
|
+
module.exports = EntityBase.extend({
|
|
8
|
+
defaults: {
|
|
9
|
+
/**
|
|
10
|
+
* Name of the shipping recipient
|
|
11
|
+
*/
|
|
12
|
+
RecipientName: null,
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* The shipping address
|
|
16
|
+
*/
|
|
17
|
+
Address: null
|
|
18
|
+
},
|
|
19
|
+
|
|
20
|
+
getSubObjects: function () {
|
|
21
|
+
return {
|
|
22
|
+
'Address': Address
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
});
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
var EntityBase = require('./EntityBase');
|
|
2
|
+
var Money = require('./Money');
|
|
3
|
+
|
|
4
|
+
var Wallet = EntityBase.extend({
|
|
5
|
+
defaults: {
|
|
6
|
+
/**
|
|
7
|
+
* Array with owners identities
|
|
8
|
+
*/
|
|
9
|
+
AuthorId: null,
|
|
10
|
+
CreditedUserId: null,
|
|
11
|
+
DebitedFunds: null,
|
|
12
|
+
CreditedFunds: null,
|
|
13
|
+
Fees: null,
|
|
14
|
+
/**
|
|
15
|
+
* TransactionStatus {CREATED, SUCCEEDED, FAILED}
|
|
16
|
+
*/
|
|
17
|
+
Status: null,
|
|
18
|
+
ResultCode: null,
|
|
19
|
+
ResultMessage: null,
|
|
20
|
+
ExecutionDate: null,
|
|
21
|
+
Type: null,
|
|
22
|
+
Nature: null,
|
|
23
|
+
DebitedWalletId: null,
|
|
24
|
+
CreditedWalletId: null
|
|
25
|
+
},
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Get mapping of model properties and corresponding object types
|
|
29
|
+
* @returns {Object}
|
|
30
|
+
*/
|
|
31
|
+
getSubObjects: function() {
|
|
32
|
+
return {
|
|
33
|
+
'DebitedFunds': Money,
|
|
34
|
+
'CreditedFunds': Money,
|
|
35
|
+
'Fees': Money
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Get array with read-only properties
|
|
41
|
+
* @return {Array} List of string properties
|
|
42
|
+
*/
|
|
43
|
+
getReadOnlyProperties: function() {
|
|
44
|
+
var properties = EntityBase.prototype.getReadOnlyProperties();
|
|
45
|
+
properties.push('Status', 'ResultCode', 'ExecutionDate');
|
|
46
|
+
return properties;
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
module.exports = Wallet;
|