From 5c61cd394536cdb36962f8661fc4cebbf7da99a0 Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Thu, 10 Mar 2022 13:59:37 +0100 Subject: [PATCH 01/13] Chore: Model update --- lib/apis/index.js | 1 - lib/models/index.js | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/apis/index.js b/lib/apis/index.js index 7b00116..1838d2c 100644 --- a/lib/apis/index.js +++ b/lib/apis/index.js @@ -1,6 +1,5 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.Verification = exports.TransferRecipient = exports.Transfer = exports.Transaction = exports.Subscription = exports.Subaccount = exports.Split = exports.Settlement = exports.Refund = exports.Product = exports.Plan = exports.PaymentRequest = exports.Page = exports.Integration = exports.Dispute = exports.DedicatedVirtualAccount = exports.Customer = exports.Charge = exports.BulkCharge = exports.Balance = void 0; exports.Balance = require("./Balance"); exports.BulkCharge = require("./BulkCharge"); exports.Charge = require("./Charge"); diff --git a/lib/models/index.js b/lib/models/index.js index e23c199..8aeff36 100644 --- a/lib/models/index.js +++ b/lib/models/index.js @@ -7,7 +7,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./Bank"), exports); From 49be650861d3f4568879915431b74457350c2cfc Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Wed, 8 Jun 2022 12:07:29 +0400 Subject: [PATCH 02/13] Chore: Package and Readme cleanup --- .openapi-generator/FILES | 1 + README.md | 6 +- lib/apis/Balance.d.ts | 2 +- lib/apis/Balance.js | 2 +- lib/apis/BulkCharge.d.ts | 2 +- lib/apis/BulkCharge.js | 2 +- lib/apis/Charge.d.ts | 2 +- lib/apis/Charge.js | 2 +- lib/apis/Customer.d.ts | 6 +- lib/apis/Customer.js | 2 +- lib/apis/DedicatedVirtualAccount.d.ts | 2 +- lib/apis/DedicatedVirtualAccount.js | 2 +- lib/apis/Dispute.d.ts | 2 +- lib/apis/Dispute.js | 2 +- lib/apis/Integration.d.ts | 2 +- lib/apis/Integration.js | 2 +- lib/apis/Page.d.ts | 2 +- lib/apis/Page.js | 2 +- lib/apis/PaymentRequest.d.ts | 2 +- lib/apis/PaymentRequest.js | 2 +- lib/apis/Plan.d.ts | 2 +- lib/apis/Plan.js | 2 +- lib/apis/Product.d.ts | 2 +- lib/apis/Product.js | 2 +- lib/apis/Refund.d.ts | 2 +- lib/apis/Refund.js | 2 +- lib/apis/Settlement.d.ts | 2 +- lib/apis/Settlement.js | 2 +- lib/apis/Split.d.ts | 2 +- lib/apis/Split.js | 2 +- lib/apis/Subaccount.d.ts | 2 +- lib/apis/Subaccount.js | 2 +- lib/apis/Subscription.d.ts | 2 +- lib/apis/Subscription.js | 2 +- lib/apis/Transaction.d.ts | 2 +- lib/apis/Transaction.js | 2 +- lib/apis/Transfer.d.ts | 2 +- lib/apis/Transfer.js | 2 +- lib/apis/TransferRecipient.d.ts | 2 +- lib/apis/TransferRecipient.js | 2 +- lib/apis/Verification.d.ts | 21 +---- lib/apis/Verification.js | 62 +------------ lib/apis/index.js | 1 + lib/models/Accepted.d.ts | 33 +++++++ lib/models/Accepted.js | 44 ++++++++++ lib/models/Bank.d.ts | 2 +- lib/models/Bank.js | 2 +- lib/models/BulkChargeInitiate.d.ts | 2 +- lib/models/BulkChargeInitiate.js | 2 +- lib/models/ChargeCreate.d.ts | 2 +- lib/models/ChargeCreate.js | 2 +- lib/models/ChargeSubmitAddress.d.ts | 2 +- lib/models/ChargeSubmitAddress.js | 2 +- lib/models/ChargeSubmitBirthday.d.ts | 2 +- lib/models/ChargeSubmitBirthday.js | 2 +- lib/models/ChargeSubmitOTP.d.ts | 2 +- lib/models/ChargeSubmitOTP.js | 2 +- lib/models/ChargeSubmitPhone.d.ts | 2 +- lib/models/ChargeSubmitPhone.js | 2 +- lib/models/ChargeSubmitPin.d.ts | 2 +- lib/models/ChargeSubmitPin.js | 2 +- lib/models/CustomerCreate.d.ts | 2 +- lib/models/CustomerCreate.js | 2 +- .../CustomerDeactivateAuthorization.d.ts | 2 +- lib/models/CustomerDeactivateAuthorization.js | 2 +- lib/models/CustomerRiskAction.d.ts | 2 +- lib/models/CustomerRiskAction.js | 2 +- lib/models/CustomerUpdate.d.ts | 2 +- lib/models/CustomerUpdate.js | 2 +- lib/models/CustomerValidate.d.ts | 2 +- lib/models/CustomerValidate.js | 2 +- lib/models/CustomerValidation.d.ts | 2 +- lib/models/CustomerValidation.js | 2 +- lib/models/DedicatedVirtualAccountCreate.d.ts | 2 +- lib/models/DedicatedVirtualAccountCreate.js | 2 +- lib/models/DedicatedVirtualAccountSplit.d.ts | 2 +- lib/models/DedicatedVirtualAccountSplit.js | 2 +- lib/models/DisputeEvidence.d.ts | 2 +- lib/models/DisputeEvidence.js | 2 +- lib/models/DisputeResolve.d.ts | 2 +- lib/models/DisputeResolve.js | 2 +- lib/models/DisputeUpdate.d.ts | 2 +- lib/models/DisputeUpdate.js | 2 +- lib/models/EFT.d.ts | 2 +- lib/models/EFT.js | 2 +- lib/models/MobileMoney.d.ts | 2 +- lib/models/MobileMoney.js | 2 +- lib/models/ModelError.d.ts | 2 +- lib/models/ModelError.js | 2 +- lib/models/PageCreate.d.ts | 2 +- lib/models/PageCreate.js | 2 +- lib/models/PageProduct.d.ts | 2 +- lib/models/PageProduct.js | 2 +- lib/models/PageUpdate.d.ts | 2 +- lib/models/PageUpdate.js | 2 +- lib/models/PaymentRequestCreate.d.ts | 2 +- lib/models/PaymentRequestCreate.js | 2 +- lib/models/PaymentRequestUpdate.d.ts | 2 +- lib/models/PaymentRequestUpdate.js | 2 +- lib/models/PlanCreate.d.ts | 2 +- lib/models/PlanCreate.js | 2 +- lib/models/PlanUpdate.d.ts | 2 +- lib/models/PlanUpdate.js | 2 +- lib/models/ProductCreate.d.ts | 2 +- lib/models/ProductCreate.js | 2 +- lib/models/ProductUpdate.d.ts | 2 +- lib/models/ProductUpdate.js | 2 +- lib/models/RefundCreate.d.ts | 2 +- lib/models/RefundCreate.js | 2 +- lib/models/Response.d.ts | 2 +- lib/models/Response.js | 2 +- lib/models/SplitCreate.d.ts | 2 +- lib/models/SplitCreate.js | 2 +- lib/models/SplitSubaccounts.d.ts | 2 +- lib/models/SplitSubaccounts.js | 2 +- lib/models/SplitUpdate.d.ts | 2 +- lib/models/SplitUpdate.js | 2 +- lib/models/SubaccountCreate.d.ts | 2 +- lib/models/SubaccountCreate.js | 2 +- lib/models/SubaccountUpdate.d.ts | 2 +- lib/models/SubaccountUpdate.js | 2 +- lib/models/SubscriptionCreate.d.ts | 2 +- lib/models/SubscriptionCreate.js | 2 +- lib/models/SubscriptionToggle.d.ts | 2 +- lib/models/SubscriptionToggle.js | 2 +- .../TransactionChargeAuthorization.d.ts | 2 +- lib/models/TransactionChargeAuthorization.js | 2 +- lib/models/TransactionCheckAuthorization.d.ts | 2 +- lib/models/TransactionCheckAuthorization.js | 2 +- lib/models/TransactionInitialize.d.ts | 2 +- lib/models/TransactionInitialize.js | 2 +- lib/models/TransactionPartialDebit.d.ts | 2 +- lib/models/TransactionPartialDebit.js | 2 +- lib/models/TransferBulk.d.ts | 2 +- lib/models/TransferBulk.js | 2 +- lib/models/TransferFinalize.d.ts | 2 +- lib/models/TransferFinalize.js | 2 +- lib/models/TransferFinalizeDisableOTP.d.ts | 2 +- lib/models/TransferFinalizeDisableOTP.js | 2 +- lib/models/TransferInitiate.d.ts | 2 +- lib/models/TransferInitiate.js | 2 +- lib/models/TransferRecipientBulk.d.ts | 2 +- lib/models/TransferRecipientBulk.js | 2 +- lib/models/TransferRecipientCreate.d.ts | 2 +- lib/models/TransferRecipientCreate.js | 2 +- lib/models/TransferRecipientUpdate.d.ts | 2 +- lib/models/TransferRecipientUpdate.js | 2 +- lib/models/TransferResendOTP.d.ts | 2 +- lib/models/TransferResendOTP.js | 2 +- lib/models/USSD.d.ts | 2 +- lib/models/USSD.js | 2 +- lib/models/VerificationBVNMatch.d.ts | 2 +- lib/models/VerificationBVNMatch.js | 2 +- lib/models/index.d.ts | 1 + lib/models/index.js | 3 +- lib/runtime.d.ts | 2 +- lib/runtime.js | 4 +- package.json | 4 +- src/apis/Balance.ts | 2 +- src/apis/BulkCharge.ts | 2 +- src/apis/Charge.ts | 2 +- src/apis/Customer.ts | 5 +- src/apis/DedicatedVirtualAccount.ts | 2 +- src/apis/Dispute.ts | 2 +- src/apis/Integration.ts | 2 +- src/apis/Page.ts | 2 +- src/apis/PaymentRequest.ts | 2 +- src/apis/Plan.ts | 2 +- src/apis/Product.ts | 2 +- src/apis/Refund.ts | 2 +- src/apis/Settlement.ts | 2 +- src/apis/Split.ts | 2 +- src/apis/Subaccount.ts | 2 +- src/apis/Subscription.ts | 2 +- src/apis/Transaction.ts | 2 +- src/apis/Transfer.ts | 2 +- src/apis/TransferRecipient.ts | 2 +- src/apis/Verification.ts | 86 +------------------ src/models/Accepted.ts | 65 ++++++++++++++ src/models/Bank.ts | 2 +- src/models/BulkChargeInitiate.ts | 2 +- src/models/ChargeCreate.ts | 2 +- src/models/ChargeSubmitAddress.ts | 2 +- src/models/ChargeSubmitBirthday.ts | 2 +- src/models/ChargeSubmitOTP.ts | 2 +- src/models/ChargeSubmitPhone.ts | 2 +- src/models/ChargeSubmitPin.ts | 2 +- src/models/CustomerCreate.ts | 2 +- src/models/CustomerDeactivateAuthorization.ts | 2 +- src/models/CustomerRiskAction.ts | 2 +- src/models/CustomerUpdate.ts | 2 +- src/models/CustomerValidate.ts | 2 +- src/models/CustomerValidation.ts | 2 +- src/models/DedicatedVirtualAccountCreate.ts | 2 +- src/models/DedicatedVirtualAccountSplit.ts | 2 +- src/models/DisputeEvidence.ts | 2 +- src/models/DisputeResolve.ts | 2 +- src/models/DisputeUpdate.ts | 2 +- src/models/EFT.ts | 2 +- src/models/MobileMoney.ts | 2 +- src/models/ModelError.ts | 2 +- src/models/PageCreate.ts | 2 +- src/models/PageProduct.ts | 2 +- src/models/PageUpdate.ts | 2 +- src/models/PaymentRequestCreate.ts | 2 +- src/models/PaymentRequestUpdate.ts | 2 +- src/models/PlanCreate.ts | 2 +- src/models/PlanUpdate.ts | 2 +- src/models/ProductCreate.ts | 2 +- src/models/ProductUpdate.ts | 2 +- src/models/RefundCreate.ts | 2 +- src/models/Response.ts | 2 +- src/models/SplitCreate.ts | 2 +- src/models/SplitSubaccounts.ts | 2 +- src/models/SplitUpdate.ts | 2 +- src/models/SubaccountCreate.ts | 2 +- src/models/SubaccountUpdate.ts | 2 +- src/models/SubscriptionCreate.ts | 2 +- src/models/SubscriptionToggle.ts | 2 +- src/models/TransactionChargeAuthorization.ts | 2 +- src/models/TransactionCheckAuthorization.ts | 2 +- src/models/TransactionInitialize.ts | 2 +- src/models/TransactionPartialDebit.ts | 2 +- src/models/TransferBulk.ts | 2 +- src/models/TransferFinalize.ts | 2 +- src/models/TransferFinalizeDisableOTP.ts | 2 +- src/models/TransferInitiate.ts | 2 +- src/models/TransferRecipientBulk.ts | 2 +- src/models/TransferRecipientCreate.ts | 2 +- src/models/TransferRecipientUpdate.ts | 2 +- src/models/TransferResendOTP.ts | 2 +- src/models/USSD.ts | 2 +- src/models/VerificationBVNMatch.ts | 2 +- src/models/index.ts | 1 + src/runtime.ts | 4 +- 235 files changed, 384 insertions(+), 399 deletions(-) create mode 100644 lib/models/Accepted.d.ts create mode 100644 lib/models/Accepted.js create mode 100644 src/models/Accepted.ts diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index 1de0f39..34c768f 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -24,6 +24,7 @@ src/apis/TransferRecipient.ts src/apis/Verification.ts src/apis/index.ts src/index.ts +src/models/Accepted.ts src/models/Bank.ts src/models/BulkChargeInitiate.ts src/models/ChargeCreate.ts diff --git a/README.md b/README.md index 92a1511..e6d5797 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -## Paystack Node.js Library +## Paystack Node Library A Node client library for consuming the Paystack API @@ -8,13 +8,13 @@ live secret keys. ## Installation ``` -npm install @paystack/node --save +npm install @paystack/paystack-sdk --save ``` ## Usage Import and initialize the library: ``` -import Paystack from '@paystack/node' +import Paystack from '@paystack/paystack-sdk' const paystack = new Paystack("sk_test_xxxxxx") ``` diff --git a/lib/apis/Balance.d.ts b/lib/apis/Balance.d.ts index 65056d5..15fa176 100644 --- a/lib/apis/Balance.d.ts +++ b/lib/apis/Balance.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Balance.js b/lib/apis/Balance.js index 108dc95..f72ed8f 100644 --- a/lib/apis/Balance.js +++ b/lib/apis/Balance.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/BulkCharge.d.ts b/lib/apis/BulkCharge.d.ts index f5d91f8..1d6b284 100644 --- a/lib/apis/BulkCharge.d.ts +++ b/lib/apis/BulkCharge.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/BulkCharge.js b/lib/apis/BulkCharge.js index 559dcad..968f8b1 100644 --- a/lib/apis/BulkCharge.js +++ b/lib/apis/BulkCharge.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Charge.d.ts b/lib/apis/Charge.d.ts index b51620c..27dfb25 100644 --- a/lib/apis/Charge.d.ts +++ b/lib/apis/Charge.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Charge.js b/lib/apis/Charge.js index 1642b32..ff993d8 100644 --- a/lib/apis/Charge.js +++ b/lib/apis/Charge.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Customer.d.ts b/lib/apis/Customer.d.ts index 1552c29..5214e90 100644 --- a/lib/apis/Customer.d.ts +++ b/lib/apis/Customer.d.ts @@ -3,14 +3,14 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { BaseAPI } from '../runtime'; -import { Response } from '../models'; +import { Accepted, Response } from '../models'; export interface CreateRequest { email: string; first_name?: string; @@ -90,5 +90,5 @@ export declare class Customer extends BaseAPI { * Validate a customer\'s identity * Validate Customer */ - validatte(requestParameters: ValidatteRequest): Promise; + validatte(requestParameters: ValidatteRequest): Promise; } diff --git a/lib/apis/Customer.js b/lib/apis/Customer.js index 3fb5b8d..2638ac2 100644 --- a/lib/apis/Customer.js +++ b/lib/apis/Customer.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/DedicatedVirtualAccount.d.ts b/lib/apis/DedicatedVirtualAccount.d.ts index 42969e9..9469616 100644 --- a/lib/apis/DedicatedVirtualAccount.d.ts +++ b/lib/apis/DedicatedVirtualAccount.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/DedicatedVirtualAccount.js b/lib/apis/DedicatedVirtualAccount.js index e5b6898..755c1ea 100644 --- a/lib/apis/DedicatedVirtualAccount.js +++ b/lib/apis/DedicatedVirtualAccount.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Dispute.d.ts b/lib/apis/Dispute.d.ts index 4f93ac3..cd760bc 100644 --- a/lib/apis/Dispute.d.ts +++ b/lib/apis/Dispute.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Dispute.js b/lib/apis/Dispute.js index 2d7fa89..96c2e65 100644 --- a/lib/apis/Dispute.js +++ b/lib/apis/Dispute.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Integration.d.ts b/lib/apis/Integration.d.ts index 8e11c56..c4111e9 100644 --- a/lib/apis/Integration.d.ts +++ b/lib/apis/Integration.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Integration.js b/lib/apis/Integration.js index a9a216d..100a688 100644 --- a/lib/apis/Integration.js +++ b/lib/apis/Integration.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Page.d.ts b/lib/apis/Page.d.ts index f2430d2..8957510 100644 --- a/lib/apis/Page.d.ts +++ b/lib/apis/Page.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Page.js b/lib/apis/Page.js index 76760aa..4b6aedf 100644 --- a/lib/apis/Page.js +++ b/lib/apis/Page.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/PaymentRequest.d.ts b/lib/apis/PaymentRequest.d.ts index 5997d6d..16f2610 100644 --- a/lib/apis/PaymentRequest.d.ts +++ b/lib/apis/PaymentRequest.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/PaymentRequest.js b/lib/apis/PaymentRequest.js index 458f19f..ae4061a 100644 --- a/lib/apis/PaymentRequest.js +++ b/lib/apis/PaymentRequest.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Plan.d.ts b/lib/apis/Plan.d.ts index eff2cfa..4eb15a2 100644 --- a/lib/apis/Plan.d.ts +++ b/lib/apis/Plan.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Plan.js b/lib/apis/Plan.js index 14eb665..39d7cde 100644 --- a/lib/apis/Plan.js +++ b/lib/apis/Plan.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Product.d.ts b/lib/apis/Product.d.ts index 97bcd09..0f0a597 100644 --- a/lib/apis/Product.d.ts +++ b/lib/apis/Product.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Product.js b/lib/apis/Product.js index 0e9c956..8ea2e73 100644 --- a/lib/apis/Product.js +++ b/lib/apis/Product.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Refund.d.ts b/lib/apis/Refund.d.ts index 69bafdb..373615a 100644 --- a/lib/apis/Refund.d.ts +++ b/lib/apis/Refund.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Refund.js b/lib/apis/Refund.js index b75638d..ebed95a 100644 --- a/lib/apis/Refund.js +++ b/lib/apis/Refund.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Settlement.d.ts b/lib/apis/Settlement.d.ts index 8e0d09e..eaca315 100644 --- a/lib/apis/Settlement.d.ts +++ b/lib/apis/Settlement.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Settlement.js b/lib/apis/Settlement.js index 543f90d..c2ee64b 100644 --- a/lib/apis/Settlement.js +++ b/lib/apis/Settlement.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Split.d.ts b/lib/apis/Split.d.ts index d3f3248..b1d1a68 100644 --- a/lib/apis/Split.d.ts +++ b/lib/apis/Split.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Split.js b/lib/apis/Split.js index 7ca2051..1813c6d 100644 --- a/lib/apis/Split.js +++ b/lib/apis/Split.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Subaccount.d.ts b/lib/apis/Subaccount.d.ts index 63c2411..375c1de 100644 --- a/lib/apis/Subaccount.d.ts +++ b/lib/apis/Subaccount.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Subaccount.js b/lib/apis/Subaccount.js index 9aaa68a..0b757a9 100644 --- a/lib/apis/Subaccount.js +++ b/lib/apis/Subaccount.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Subscription.d.ts b/lib/apis/Subscription.d.ts index ded120d..7684244 100644 --- a/lib/apis/Subscription.d.ts +++ b/lib/apis/Subscription.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Subscription.js b/lib/apis/Subscription.js index 2ba1f97..678f4b2 100644 --- a/lib/apis/Subscription.js +++ b/lib/apis/Subscription.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Transaction.d.ts b/lib/apis/Transaction.d.ts index d73012e..7b48336 100644 --- a/lib/apis/Transaction.d.ts +++ b/lib/apis/Transaction.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Transaction.js b/lib/apis/Transaction.js index 6e4e386..e5acc7a 100644 --- a/lib/apis/Transaction.js +++ b/lib/apis/Transaction.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Transfer.d.ts b/lib/apis/Transfer.d.ts index b2d3f94..bd24d88 100644 --- a/lib/apis/Transfer.d.ts +++ b/lib/apis/Transfer.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Transfer.js b/lib/apis/Transfer.js index c160d30..9d06708 100644 --- a/lib/apis/Transfer.js +++ b/lib/apis/Transfer.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/TransferRecipient.d.ts b/lib/apis/TransferRecipient.d.ts index 78f0180..b8a2a44 100644 --- a/lib/apis/TransferRecipient.d.ts +++ b/lib/apis/TransferRecipient.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/TransferRecipient.js b/lib/apis/TransferRecipient.js index a61ed2a..c0a75ee 100644 --- a/lib/apis/TransferRecipient.js +++ b/lib/apis/TransferRecipient.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/apis/Verification.d.ts b/lib/apis/Verification.d.ts index 329f6a7..d722245 100644 --- a/lib/apis/Verification.d.ts +++ b/lib/apis/Verification.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -16,14 +16,6 @@ export interface AvsRequest { country?: string; currency?: string; } -export interface BvnMatchRequest { - account_number: string; - bank_code: number; - bvn: string; - first_name?: string; - middle_name?: string; - last_name?: string; -} export interface FetchBanksRequest { country?: string; pay_with_bank_transfer?: boolean; @@ -37,9 +29,6 @@ export interface ResolveAccountNumberRequest { account_number?: number; bank_code?: number; } -export interface ResolveBvnRequest { - bvn: string; -} export interface ResolveCardBinRequest { bin: string; } @@ -51,10 +40,6 @@ export declare class Verification extends BaseAPI { * List States (AVS) */ avs(requestParameters: AvsRequest): Promise; - /** - * Match Service - */ - bvnMatch(requestParameters: BvnMatchRequest): Promise; /** * Fetch Banks */ @@ -67,10 +52,6 @@ export declare class Verification extends BaseAPI { * Resolve Account Number */ resolveAccountNumber(requestParameters: ResolveAccountNumberRequest): Promise; - /** - * Resolve BVN - */ - resolveBvn(requestParameters: ResolveBvnRequest): Promise; /** * Resolve Card BIN */ diff --git a/lib/apis/Verification.js b/lib/apis/Verification.js index c8bb7ef..490b2ed 100644 --- a/lib/apis/Verification.js +++ b/lib/apis/Verification.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -52,49 +52,6 @@ class Verification extends runtime_1.BaseAPI { return models_1.ResponseFromJSON(response); }); } - /** - * Match Service - */ - bvnMatch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling bvnMatch.'); - } - if (requestParameters.bank_code === null || requestParameters.bank_code === undefined) { - throw new runtime_1.RequiredError('bank_code', 'Required parameter bank_code was null or undefined when calling bvnMatch.'); - } - if (requestParameters.bvn === null || requestParameters.bvn === undefined) { - throw new runtime_1.RequiredError('bvn', 'Required parameter bvn was null or undefined when calling bvnMatch.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - if (requestParameters.bank_code !== undefined) { - formParams['bank_code'] = requestParameters.bank_code; - } - if (requestParameters.bvn !== undefined) { - formParams['bvn'] = requestParameters.bvn; - } - if (requestParameters.first_name !== undefined) { - formParams['first_name'] = requestParameters.first_name; - } - if (requestParameters.middle_name !== undefined) { - formParams['middle_name'] = requestParameters.middle_name; - } - if (requestParameters.last_name !== undefined) { - formParams['last_name'] = requestParameters.last_name; - } - const response = yield this.request({ - path: `/bvn/match`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } /** * Fetch Banks */ @@ -164,23 +121,6 @@ class Verification extends runtime_1.BaseAPI { return models_1.ResponseFromJSON(response); }); } - /** - * Resolve BVN - */ - resolveBvn(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.bvn === null || requestParameters.bvn === undefined) { - throw new runtime_1.RequiredError('bvn', 'Required parameter bvn was null or undefined when calling resolveBvn.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/bank/resolve_bvn/{bvn}`.replace(`{${"bvn"}}`, encodeURIComponent(String(requestParameters.bvn))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } /** * Resolve Card BIN */ diff --git a/lib/apis/index.js b/lib/apis/index.js index 1838d2c..7b00116 100644 --- a/lib/apis/index.js +++ b/lib/apis/index.js @@ -1,5 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); +exports.Verification = exports.TransferRecipient = exports.Transfer = exports.Transaction = exports.Subscription = exports.Subaccount = exports.Split = exports.Settlement = exports.Refund = exports.Product = exports.Plan = exports.PaymentRequest = exports.Page = exports.Integration = exports.Dispute = exports.DedicatedVirtualAccount = exports.Customer = exports.Charge = exports.BulkCharge = exports.Balance = void 0; exports.Balance = require("./Balance"); exports.BulkCharge = require("./BulkCharge"); exports.Charge = require("./Charge"); diff --git a/lib/models/Accepted.d.ts b/lib/models/Accepted.d.ts new file mode 100644 index 0000000..7b15c0e --- /dev/null +++ b/lib/models/Accepted.d.ts @@ -0,0 +1,33 @@ +/** + * Paystack + * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. + * + * The version of the Paystack Node library: 1.0.0 + * Contact: techsupport@paystack.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +/** + * + * @export + * @interface Accepted + */ +export interface Accepted { + /** + * + * @type {boolean} + * @memberof Accepted + */ + status?: boolean; + /** + * + * @type {string} + * @memberof Accepted + */ + message?: string; +} +export declare function AcceptedFromJSON(json: any): Accepted; +export declare function AcceptedFromJSONTyped(json: any, ignoreDiscriminator: boolean): Accepted; +export declare function AcceptedToJSON(value?: Accepted | null): any; diff --git a/lib/models/Accepted.js b/lib/models/Accepted.js new file mode 100644 index 0000000..5b99daa --- /dev/null +++ b/lib/models/Accepted.js @@ -0,0 +1,44 @@ +"use strict"; +/* tslint:disable */ +/* eslint-disable */ +/** + * Paystack + * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. + * + * The version of the Paystack Node library: 1.0.0 + * Contact: techsupport@paystack.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.AcceptedToJSON = exports.AcceptedFromJSONTyped = exports.AcceptedFromJSON = void 0; +const runtime_1 = require("../runtime"); +function AcceptedFromJSON(json) { + return AcceptedFromJSONTyped(json, false); +} +exports.AcceptedFromJSON = AcceptedFromJSON; +function AcceptedFromJSONTyped(json, ignoreDiscriminator) { + if ((json === undefined) || (json === null)) { + return json; + } + return { + 'status': !runtime_1.exists(json, 'status') ? undefined : json['status'], + 'message': !runtime_1.exists(json, 'message') ? undefined : json['message'], + }; +} +exports.AcceptedFromJSONTyped = AcceptedFromJSONTyped; +function AcceptedToJSON(value) { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + 'status': value.status, + 'message': value.message, + }; +} +exports.AcceptedToJSON = AcceptedToJSON; diff --git a/lib/models/Bank.d.ts b/lib/models/Bank.d.ts index 8490c27..cb3fa2e 100644 --- a/lib/models/Bank.d.ts +++ b/lib/models/Bank.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/Bank.js b/lib/models/Bank.js index ad929c5..fb8f8dd 100644 --- a/lib/models/Bank.js +++ b/lib/models/Bank.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/BulkChargeInitiate.d.ts b/lib/models/BulkChargeInitiate.d.ts index 271547e..2e92f42 100644 --- a/lib/models/BulkChargeInitiate.d.ts +++ b/lib/models/BulkChargeInitiate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/BulkChargeInitiate.js b/lib/models/BulkChargeInitiate.js index d375641..847bfbd 100644 --- a/lib/models/BulkChargeInitiate.js +++ b/lib/models/BulkChargeInitiate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeCreate.d.ts b/lib/models/ChargeCreate.d.ts index 871e3bb..56f591b 100644 --- a/lib/models/ChargeCreate.d.ts +++ b/lib/models/ChargeCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeCreate.js b/lib/models/ChargeCreate.js index c0e1446..0df1b99 100644 --- a/lib/models/ChargeCreate.js +++ b/lib/models/ChargeCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitAddress.d.ts b/lib/models/ChargeSubmitAddress.d.ts index d50b751..28d3dc5 100644 --- a/lib/models/ChargeSubmitAddress.d.ts +++ b/lib/models/ChargeSubmitAddress.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitAddress.js b/lib/models/ChargeSubmitAddress.js index 9c95719..e273550 100644 --- a/lib/models/ChargeSubmitAddress.js +++ b/lib/models/ChargeSubmitAddress.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitBirthday.d.ts b/lib/models/ChargeSubmitBirthday.d.ts index 7b88c70..38af0a3 100644 --- a/lib/models/ChargeSubmitBirthday.d.ts +++ b/lib/models/ChargeSubmitBirthday.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitBirthday.js b/lib/models/ChargeSubmitBirthday.js index a2cea18..f193ff0 100644 --- a/lib/models/ChargeSubmitBirthday.js +++ b/lib/models/ChargeSubmitBirthday.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitOTP.d.ts b/lib/models/ChargeSubmitOTP.d.ts index 4894032..6f1be4d 100644 --- a/lib/models/ChargeSubmitOTP.d.ts +++ b/lib/models/ChargeSubmitOTP.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitOTP.js b/lib/models/ChargeSubmitOTP.js index 6b25eaa..4037dbf 100644 --- a/lib/models/ChargeSubmitOTP.js +++ b/lib/models/ChargeSubmitOTP.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitPhone.d.ts b/lib/models/ChargeSubmitPhone.d.ts index bbf4caa..5b1608b 100644 --- a/lib/models/ChargeSubmitPhone.d.ts +++ b/lib/models/ChargeSubmitPhone.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitPhone.js b/lib/models/ChargeSubmitPhone.js index 5fccf93..34f74c5 100644 --- a/lib/models/ChargeSubmitPhone.js +++ b/lib/models/ChargeSubmitPhone.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitPin.d.ts b/lib/models/ChargeSubmitPin.d.ts index 46bfbde..d75ec3e 100644 --- a/lib/models/ChargeSubmitPin.d.ts +++ b/lib/models/ChargeSubmitPin.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ChargeSubmitPin.js b/lib/models/ChargeSubmitPin.js index 7f75a57..d0809ba 100644 --- a/lib/models/ChargeSubmitPin.js +++ b/lib/models/ChargeSubmitPin.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerCreate.d.ts b/lib/models/CustomerCreate.d.ts index 4dfeec8..f310b02 100644 --- a/lib/models/CustomerCreate.d.ts +++ b/lib/models/CustomerCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerCreate.js b/lib/models/CustomerCreate.js index 2b0d5ba..4f7a410 100644 --- a/lib/models/CustomerCreate.js +++ b/lib/models/CustomerCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerDeactivateAuthorization.d.ts b/lib/models/CustomerDeactivateAuthorization.d.ts index 1d3c5ac..858fb42 100644 --- a/lib/models/CustomerDeactivateAuthorization.d.ts +++ b/lib/models/CustomerDeactivateAuthorization.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerDeactivateAuthorization.js b/lib/models/CustomerDeactivateAuthorization.js index e7381ef..748360e 100644 --- a/lib/models/CustomerDeactivateAuthorization.js +++ b/lib/models/CustomerDeactivateAuthorization.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerRiskAction.d.ts b/lib/models/CustomerRiskAction.d.ts index 49e5403..88010a9 100644 --- a/lib/models/CustomerRiskAction.d.ts +++ b/lib/models/CustomerRiskAction.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerRiskAction.js b/lib/models/CustomerRiskAction.js index 1e93654..75ec79f 100644 --- a/lib/models/CustomerRiskAction.js +++ b/lib/models/CustomerRiskAction.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerUpdate.d.ts b/lib/models/CustomerUpdate.d.ts index 69f2b97..8f5bbf9 100644 --- a/lib/models/CustomerUpdate.d.ts +++ b/lib/models/CustomerUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerUpdate.js b/lib/models/CustomerUpdate.js index e442dfd..e27f66b 100644 --- a/lib/models/CustomerUpdate.js +++ b/lib/models/CustomerUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerValidate.d.ts b/lib/models/CustomerValidate.d.ts index 3473383..039132c 100644 --- a/lib/models/CustomerValidate.d.ts +++ b/lib/models/CustomerValidate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerValidate.js b/lib/models/CustomerValidate.js index 2ccf4f8..307a814 100644 --- a/lib/models/CustomerValidate.js +++ b/lib/models/CustomerValidate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerValidation.d.ts b/lib/models/CustomerValidation.d.ts index 6a3bb44..d3df455 100644 --- a/lib/models/CustomerValidation.d.ts +++ b/lib/models/CustomerValidation.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/CustomerValidation.js b/lib/models/CustomerValidation.js index 266457a..958ee83 100644 --- a/lib/models/CustomerValidation.js +++ b/lib/models/CustomerValidation.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DedicatedVirtualAccountCreate.d.ts b/lib/models/DedicatedVirtualAccountCreate.d.ts index b3f016e..012071f 100644 --- a/lib/models/DedicatedVirtualAccountCreate.d.ts +++ b/lib/models/DedicatedVirtualAccountCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DedicatedVirtualAccountCreate.js b/lib/models/DedicatedVirtualAccountCreate.js index 6de900d..9493834 100644 --- a/lib/models/DedicatedVirtualAccountCreate.js +++ b/lib/models/DedicatedVirtualAccountCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DedicatedVirtualAccountSplit.d.ts b/lib/models/DedicatedVirtualAccountSplit.d.ts index 6e8ab53..86d28d7 100644 --- a/lib/models/DedicatedVirtualAccountSplit.d.ts +++ b/lib/models/DedicatedVirtualAccountSplit.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DedicatedVirtualAccountSplit.js b/lib/models/DedicatedVirtualAccountSplit.js index 23cf29d..9aa7d1a 100644 --- a/lib/models/DedicatedVirtualAccountSplit.js +++ b/lib/models/DedicatedVirtualAccountSplit.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DisputeEvidence.d.ts b/lib/models/DisputeEvidence.d.ts index fc73bb1..7bc6a3c 100644 --- a/lib/models/DisputeEvidence.d.ts +++ b/lib/models/DisputeEvidence.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DisputeEvidence.js b/lib/models/DisputeEvidence.js index 9c36976..b40c5d4 100644 --- a/lib/models/DisputeEvidence.js +++ b/lib/models/DisputeEvidence.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DisputeResolve.d.ts b/lib/models/DisputeResolve.d.ts index a885689..54e8ba8 100644 --- a/lib/models/DisputeResolve.d.ts +++ b/lib/models/DisputeResolve.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DisputeResolve.js b/lib/models/DisputeResolve.js index 7f26b95..d2aa597 100644 --- a/lib/models/DisputeResolve.js +++ b/lib/models/DisputeResolve.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DisputeUpdate.d.ts b/lib/models/DisputeUpdate.d.ts index ab94f04..d73a018 100644 --- a/lib/models/DisputeUpdate.d.ts +++ b/lib/models/DisputeUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/DisputeUpdate.js b/lib/models/DisputeUpdate.js index dd901a4..6fe4325 100644 --- a/lib/models/DisputeUpdate.js +++ b/lib/models/DisputeUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/EFT.d.ts b/lib/models/EFT.d.ts index ab750fb..d377295 100644 --- a/lib/models/EFT.d.ts +++ b/lib/models/EFT.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/EFT.js b/lib/models/EFT.js index 214df66..496f705 100644 --- a/lib/models/EFT.js +++ b/lib/models/EFT.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/MobileMoney.d.ts b/lib/models/MobileMoney.d.ts index 9a22c03..43cf9dd 100644 --- a/lib/models/MobileMoney.d.ts +++ b/lib/models/MobileMoney.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/MobileMoney.js b/lib/models/MobileMoney.js index 3b69437..0cecd5d 100644 --- a/lib/models/MobileMoney.js +++ b/lib/models/MobileMoney.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ModelError.d.ts b/lib/models/ModelError.d.ts index 483a2ea..a412b1c 100644 --- a/lib/models/ModelError.d.ts +++ b/lib/models/ModelError.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ModelError.js b/lib/models/ModelError.js index 598c2ab..d0848b7 100644 --- a/lib/models/ModelError.js +++ b/lib/models/ModelError.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PageCreate.d.ts b/lib/models/PageCreate.d.ts index dbf272e..d1a6511 100644 --- a/lib/models/PageCreate.d.ts +++ b/lib/models/PageCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PageCreate.js b/lib/models/PageCreate.js index 0a189e0..c6fc950 100644 --- a/lib/models/PageCreate.js +++ b/lib/models/PageCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PageProduct.d.ts b/lib/models/PageProduct.d.ts index ede2605..842c760 100644 --- a/lib/models/PageProduct.d.ts +++ b/lib/models/PageProduct.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PageProduct.js b/lib/models/PageProduct.js index c3f6b0e..f04d057 100644 --- a/lib/models/PageProduct.js +++ b/lib/models/PageProduct.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PageUpdate.d.ts b/lib/models/PageUpdate.d.ts index 8857267..20fbe34 100644 --- a/lib/models/PageUpdate.d.ts +++ b/lib/models/PageUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PageUpdate.js b/lib/models/PageUpdate.js index fb438f0..45fc7cc 100644 --- a/lib/models/PageUpdate.js +++ b/lib/models/PageUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PaymentRequestCreate.d.ts b/lib/models/PaymentRequestCreate.d.ts index 150df26..e8121cf 100644 --- a/lib/models/PaymentRequestCreate.d.ts +++ b/lib/models/PaymentRequestCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PaymentRequestCreate.js b/lib/models/PaymentRequestCreate.js index aa17afc..5e8a461 100644 --- a/lib/models/PaymentRequestCreate.js +++ b/lib/models/PaymentRequestCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PaymentRequestUpdate.d.ts b/lib/models/PaymentRequestUpdate.d.ts index f489736..a45ac16 100644 --- a/lib/models/PaymentRequestUpdate.d.ts +++ b/lib/models/PaymentRequestUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PaymentRequestUpdate.js b/lib/models/PaymentRequestUpdate.js index 602852c..1703d96 100644 --- a/lib/models/PaymentRequestUpdate.js +++ b/lib/models/PaymentRequestUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PlanCreate.d.ts b/lib/models/PlanCreate.d.ts index 89a8aa7..cdec1e1 100644 --- a/lib/models/PlanCreate.d.ts +++ b/lib/models/PlanCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PlanCreate.js b/lib/models/PlanCreate.js index 9459c16..dcc6a8f 100644 --- a/lib/models/PlanCreate.js +++ b/lib/models/PlanCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PlanUpdate.d.ts b/lib/models/PlanUpdate.d.ts index 4fb2363..f0afb8d 100644 --- a/lib/models/PlanUpdate.d.ts +++ b/lib/models/PlanUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/PlanUpdate.js b/lib/models/PlanUpdate.js index 9a4368e..fb43a82 100644 --- a/lib/models/PlanUpdate.js +++ b/lib/models/PlanUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ProductCreate.d.ts b/lib/models/ProductCreate.d.ts index a51eeb4..b4391dc 100644 --- a/lib/models/ProductCreate.d.ts +++ b/lib/models/ProductCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ProductCreate.js b/lib/models/ProductCreate.js index 0fdc794..d257afa 100644 --- a/lib/models/ProductCreate.js +++ b/lib/models/ProductCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ProductUpdate.d.ts b/lib/models/ProductUpdate.d.ts index 4f45043..ae8d167 100644 --- a/lib/models/ProductUpdate.d.ts +++ b/lib/models/ProductUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/ProductUpdate.js b/lib/models/ProductUpdate.js index 39ed81b..917d203 100644 --- a/lib/models/ProductUpdate.js +++ b/lib/models/ProductUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/RefundCreate.d.ts b/lib/models/RefundCreate.d.ts index 2c0519a..2dbb349 100644 --- a/lib/models/RefundCreate.d.ts +++ b/lib/models/RefundCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/RefundCreate.js b/lib/models/RefundCreate.js index 60b30f5..d07cbdc 100644 --- a/lib/models/RefundCreate.js +++ b/lib/models/RefundCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/Response.d.ts b/lib/models/Response.d.ts index 31c85f7..ff4dd47 100644 --- a/lib/models/Response.d.ts +++ b/lib/models/Response.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/Response.js b/lib/models/Response.js index 44514b0..55fb985 100644 --- a/lib/models/Response.js +++ b/lib/models/Response.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SplitCreate.d.ts b/lib/models/SplitCreate.d.ts index 72aca95..fd260b7 100644 --- a/lib/models/SplitCreate.d.ts +++ b/lib/models/SplitCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SplitCreate.js b/lib/models/SplitCreate.js index d670b3b..d3cd9ff 100644 --- a/lib/models/SplitCreate.js +++ b/lib/models/SplitCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SplitSubaccounts.d.ts b/lib/models/SplitSubaccounts.d.ts index 876e69d..d97023c 100644 --- a/lib/models/SplitSubaccounts.d.ts +++ b/lib/models/SplitSubaccounts.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SplitSubaccounts.js b/lib/models/SplitSubaccounts.js index a37676a..d69f9f1 100644 --- a/lib/models/SplitSubaccounts.js +++ b/lib/models/SplitSubaccounts.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SplitUpdate.d.ts b/lib/models/SplitUpdate.d.ts index ca43090..ce6921c 100644 --- a/lib/models/SplitUpdate.d.ts +++ b/lib/models/SplitUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SplitUpdate.js b/lib/models/SplitUpdate.js index 0602b6f..f62fc3a 100644 --- a/lib/models/SplitUpdate.js +++ b/lib/models/SplitUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubaccountCreate.d.ts b/lib/models/SubaccountCreate.d.ts index 1a4ad1b..a3fec07 100644 --- a/lib/models/SubaccountCreate.d.ts +++ b/lib/models/SubaccountCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubaccountCreate.js b/lib/models/SubaccountCreate.js index b21b35f..2a6ab45 100644 --- a/lib/models/SubaccountCreate.js +++ b/lib/models/SubaccountCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubaccountUpdate.d.ts b/lib/models/SubaccountUpdate.d.ts index a4b918c..3d958ad 100644 --- a/lib/models/SubaccountUpdate.d.ts +++ b/lib/models/SubaccountUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubaccountUpdate.js b/lib/models/SubaccountUpdate.js index 3f9cf96..4ac6753 100644 --- a/lib/models/SubaccountUpdate.js +++ b/lib/models/SubaccountUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubscriptionCreate.d.ts b/lib/models/SubscriptionCreate.d.ts index e4d533e..49a20cd 100644 --- a/lib/models/SubscriptionCreate.d.ts +++ b/lib/models/SubscriptionCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubscriptionCreate.js b/lib/models/SubscriptionCreate.js index 4e7aef8..9c4c187 100644 --- a/lib/models/SubscriptionCreate.js +++ b/lib/models/SubscriptionCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubscriptionToggle.d.ts b/lib/models/SubscriptionToggle.d.ts index 59202c7..dfd7338 100644 --- a/lib/models/SubscriptionToggle.d.ts +++ b/lib/models/SubscriptionToggle.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/SubscriptionToggle.js b/lib/models/SubscriptionToggle.js index b3a4c60..2ad190f 100644 --- a/lib/models/SubscriptionToggle.js +++ b/lib/models/SubscriptionToggle.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionChargeAuthorization.d.ts b/lib/models/TransactionChargeAuthorization.d.ts index 8e2d4ef..b8271a4 100644 --- a/lib/models/TransactionChargeAuthorization.d.ts +++ b/lib/models/TransactionChargeAuthorization.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionChargeAuthorization.js b/lib/models/TransactionChargeAuthorization.js index 91c311b..7899b05 100644 --- a/lib/models/TransactionChargeAuthorization.js +++ b/lib/models/TransactionChargeAuthorization.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionCheckAuthorization.d.ts b/lib/models/TransactionCheckAuthorization.d.ts index 5ba09d4..ed43e9a 100644 --- a/lib/models/TransactionCheckAuthorization.d.ts +++ b/lib/models/TransactionCheckAuthorization.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionCheckAuthorization.js b/lib/models/TransactionCheckAuthorization.js index c25cbf1..51d95d1 100644 --- a/lib/models/TransactionCheckAuthorization.js +++ b/lib/models/TransactionCheckAuthorization.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionInitialize.d.ts b/lib/models/TransactionInitialize.d.ts index 01f88db..c164fca 100644 --- a/lib/models/TransactionInitialize.d.ts +++ b/lib/models/TransactionInitialize.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionInitialize.js b/lib/models/TransactionInitialize.js index 5b5df06..2fe3e82 100644 --- a/lib/models/TransactionInitialize.js +++ b/lib/models/TransactionInitialize.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionPartialDebit.d.ts b/lib/models/TransactionPartialDebit.d.ts index 8834027..e5858a0 100644 --- a/lib/models/TransactionPartialDebit.d.ts +++ b/lib/models/TransactionPartialDebit.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransactionPartialDebit.js b/lib/models/TransactionPartialDebit.js index 523758a..5786c52 100644 --- a/lib/models/TransactionPartialDebit.js +++ b/lib/models/TransactionPartialDebit.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferBulk.d.ts b/lib/models/TransferBulk.d.ts index 50e641e..229be26 100644 --- a/lib/models/TransferBulk.d.ts +++ b/lib/models/TransferBulk.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferBulk.js b/lib/models/TransferBulk.js index c287388..c37633f 100644 --- a/lib/models/TransferBulk.js +++ b/lib/models/TransferBulk.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferFinalize.d.ts b/lib/models/TransferFinalize.d.ts index cd3eaab..7b4e6bb 100644 --- a/lib/models/TransferFinalize.d.ts +++ b/lib/models/TransferFinalize.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferFinalize.js b/lib/models/TransferFinalize.js index dc0bd59..082ca27 100644 --- a/lib/models/TransferFinalize.js +++ b/lib/models/TransferFinalize.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferFinalizeDisableOTP.d.ts b/lib/models/TransferFinalizeDisableOTP.d.ts index 658747c..4df76e6 100644 --- a/lib/models/TransferFinalizeDisableOTP.d.ts +++ b/lib/models/TransferFinalizeDisableOTP.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferFinalizeDisableOTP.js b/lib/models/TransferFinalizeDisableOTP.js index 86c2ff1..140748a 100644 --- a/lib/models/TransferFinalizeDisableOTP.js +++ b/lib/models/TransferFinalizeDisableOTP.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferInitiate.d.ts b/lib/models/TransferInitiate.d.ts index 8abaa95..640664b 100644 --- a/lib/models/TransferInitiate.d.ts +++ b/lib/models/TransferInitiate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferInitiate.js b/lib/models/TransferInitiate.js index 256e6f3..8639c8d 100644 --- a/lib/models/TransferInitiate.js +++ b/lib/models/TransferInitiate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferRecipientBulk.d.ts b/lib/models/TransferRecipientBulk.d.ts index 88ee987..15ff0e4 100644 --- a/lib/models/TransferRecipientBulk.d.ts +++ b/lib/models/TransferRecipientBulk.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferRecipientBulk.js b/lib/models/TransferRecipientBulk.js index 21baca4..6f05a9c 100644 --- a/lib/models/TransferRecipientBulk.js +++ b/lib/models/TransferRecipientBulk.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferRecipientCreate.d.ts b/lib/models/TransferRecipientCreate.d.ts index 9cb8324..3280624 100644 --- a/lib/models/TransferRecipientCreate.d.ts +++ b/lib/models/TransferRecipientCreate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferRecipientCreate.js b/lib/models/TransferRecipientCreate.js index f04dfa5..72cc2e1 100644 --- a/lib/models/TransferRecipientCreate.js +++ b/lib/models/TransferRecipientCreate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferRecipientUpdate.d.ts b/lib/models/TransferRecipientUpdate.d.ts index 2deae7c..9e34055 100644 --- a/lib/models/TransferRecipientUpdate.d.ts +++ b/lib/models/TransferRecipientUpdate.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferRecipientUpdate.js b/lib/models/TransferRecipientUpdate.js index b8ccf1a..4b29706 100644 --- a/lib/models/TransferRecipientUpdate.js +++ b/lib/models/TransferRecipientUpdate.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferResendOTP.d.ts b/lib/models/TransferResendOTP.d.ts index add633f..9761eed 100644 --- a/lib/models/TransferResendOTP.d.ts +++ b/lib/models/TransferResendOTP.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/TransferResendOTP.js b/lib/models/TransferResendOTP.js index 2a06a64..3a11f59 100644 --- a/lib/models/TransferResendOTP.js +++ b/lib/models/TransferResendOTP.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/USSD.d.ts b/lib/models/USSD.d.ts index 0ed8e00..3c2337f 100644 --- a/lib/models/USSD.d.ts +++ b/lib/models/USSD.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/USSD.js b/lib/models/USSD.js index 1f42311..2dde740 100644 --- a/lib/models/USSD.js +++ b/lib/models/USSD.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/VerificationBVNMatch.d.ts b/lib/models/VerificationBVNMatch.d.ts index 547a30f..70b9fae 100644 --- a/lib/models/VerificationBVNMatch.d.ts +++ b/lib/models/VerificationBVNMatch.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/VerificationBVNMatch.js b/lib/models/VerificationBVNMatch.js index d4a0edf..c9e43d9 100644 --- a/lib/models/VerificationBVNMatch.js +++ b/lib/models/VerificationBVNMatch.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/models/index.d.ts b/lib/models/index.d.ts index c55803d..8680e5b 100644 --- a/lib/models/index.d.ts +++ b/lib/models/index.d.ts @@ -1,3 +1,4 @@ +export * from './Accepted'; export * from './Bank'; export * from './BulkChargeInitiate'; export * from './ChargeCreate'; diff --git a/lib/models/index.js b/lib/models/index.js index 8aeff36..1839dd2 100644 --- a/lib/models/index.js +++ b/lib/models/index.js @@ -7,9 +7,10 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); +__exportStar(require("./Accepted"), exports); __exportStar(require("./Bank"), exports); __exportStar(require("./BulkChargeInitiate"), exports); __exportStar(require("./ChargeCreate"), exports); diff --git a/lib/runtime.d.ts b/lib/runtime.d.ts index d871bf8..8ab319d 100644 --- a/lib/runtime.d.ts +++ b/lib/runtime.d.ts @@ -3,7 +3,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/lib/runtime.js b/lib/runtime.js index 04f6a7a..0e04be2 100644 --- a/lib/runtime.js +++ b/lib/runtime.js @@ -6,7 +6,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -51,7 +51,7 @@ class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/node - 1.0.0-beta.3` + "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.4` } }; return new Promise((resolve, reject) => { diff --git a/package.json b/package.json index 64ba6f0..eff03d2 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "@paystack/node", - "version": "1.0.0-beta.3", + "name": "@paystack/paystack-sdk", + "version": "1.0.0-beta.4", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", "keywords": [ diff --git a/src/apis/Balance.ts b/src/apis/Balance.ts index 48a0f6e..ef96d21 100644 --- a/src/apis/Balance.ts +++ b/src/apis/Balance.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/BulkCharge.ts b/src/apis/BulkCharge.ts index 503c1ee..baebea5 100644 --- a/src/apis/BulkCharge.ts +++ b/src/apis/BulkCharge.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Charge.ts b/src/apis/Charge.ts index 1aa83b9..f1da914 100644 --- a/src/apis/Charge.ts +++ b/src/apis/Charge.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Customer.ts b/src/apis/Customer.ts index ed7e5df..f84afc9 100644 --- a/src/apis/Customer.ts +++ b/src/apis/Customer.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -15,6 +15,7 @@ import { BaseAPI, RequiredError } from '../runtime'; import { + Accepted, Response, ResponseFromJSON } from '../models'; @@ -281,7 +282,7 @@ export class Customer extends BaseAPI { * Validate a customer\'s identity * Validate Customer */ - async validatte(requestParameters: ValidatteRequest): Promise { + async validatte(requestParameters: ValidatteRequest): Promise { if (requestParameters.code === null || requestParameters.code === undefined) { throw new RequiredError('code','Required parameter code was null or undefined when calling validatte.'); } diff --git a/src/apis/DedicatedVirtualAccount.ts b/src/apis/DedicatedVirtualAccount.ts index af13c57..2ad939e 100644 --- a/src/apis/DedicatedVirtualAccount.ts +++ b/src/apis/DedicatedVirtualAccount.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Dispute.ts b/src/apis/Dispute.ts index f5acaf5..bd5eb15 100644 --- a/src/apis/Dispute.ts +++ b/src/apis/Dispute.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Integration.ts b/src/apis/Integration.ts index ff331a4..0ff7509 100644 --- a/src/apis/Integration.ts +++ b/src/apis/Integration.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Page.ts b/src/apis/Page.ts index 7dc8793..ee5810e 100644 --- a/src/apis/Page.ts +++ b/src/apis/Page.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/PaymentRequest.ts b/src/apis/PaymentRequest.ts index 5fdda90..7108bb9 100644 --- a/src/apis/PaymentRequest.ts +++ b/src/apis/PaymentRequest.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Plan.ts b/src/apis/Plan.ts index bbc48aa..1d049de 100644 --- a/src/apis/Plan.ts +++ b/src/apis/Plan.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Product.ts b/src/apis/Product.ts index 46a032b..ce1d99b 100644 --- a/src/apis/Product.ts +++ b/src/apis/Product.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Refund.ts b/src/apis/Refund.ts index 0877768..3ddd4aa 100644 --- a/src/apis/Refund.ts +++ b/src/apis/Refund.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Settlement.ts b/src/apis/Settlement.ts index 5de5807..96bcdf3 100644 --- a/src/apis/Settlement.ts +++ b/src/apis/Settlement.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Split.ts b/src/apis/Split.ts index 49b3fa1..fb535f9 100644 --- a/src/apis/Split.ts +++ b/src/apis/Split.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Subaccount.ts b/src/apis/Subaccount.ts index a3c84a3..308bfa5 100644 --- a/src/apis/Subaccount.ts +++ b/src/apis/Subaccount.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Subscription.ts b/src/apis/Subscription.ts index 7ad9cb5..2006334 100644 --- a/src/apis/Subscription.ts +++ b/src/apis/Subscription.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Transaction.ts b/src/apis/Transaction.ts index 3d6d8b2..cb4d0ff 100644 --- a/src/apis/Transaction.ts +++ b/src/apis/Transaction.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Transfer.ts b/src/apis/Transfer.ts index f045d1c..2e1f49f 100644 --- a/src/apis/Transfer.ts +++ b/src/apis/Transfer.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/TransferRecipient.ts b/src/apis/TransferRecipient.ts index ba88848..67f2f2b 100644 --- a/src/apis/TransferRecipient.ts +++ b/src/apis/TransferRecipient.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/apis/Verification.ts b/src/apis/Verification.ts index 7085d85..56ed5bc 100644 --- a/src/apis/Verification.ts +++ b/src/apis/Verification.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -25,15 +25,6 @@ export interface AvsRequest { currency?: string; } -export interface BvnMatchRequest { - account_number: string; - bank_code: number; - bvn: string; - first_name?: string; - middle_name?: string; - last_name?: string; -} - export interface FetchBanksRequest { country?: string; pay_with_bank_transfer?: boolean; @@ -49,10 +40,6 @@ export interface ResolveAccountNumberRequest { bank_code?: number; } -export interface ResolveBvnRequest { - bvn: string; -} - export interface ResolveCardBinRequest { bin: string; } @@ -90,58 +77,6 @@ export class Verification extends BaseAPI { return ResponseFromJSON(response); } - /** - * Match Service - */ - async bvnMatch(requestParameters: BvnMatchRequest): Promise { - if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new RequiredError('account_number','Required parameter account_number was null or undefined when calling bvnMatch.'); - } - if (requestParameters.bank_code === null || requestParameters.bank_code === undefined) { - throw new RequiredError('bank_code','Required parameter bank_code was null or undefined when calling bvnMatch.'); - } - if (requestParameters.bvn === null || requestParameters.bvn === undefined) { - throw new RequiredError('bvn','Required parameter bvn was null or undefined when calling bvnMatch.'); - } - const queryParameters: any = {}; - - let formParams: any = {}; - - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - - if (requestParameters.bank_code !== undefined) { - formParams['bank_code'] = requestParameters.bank_code; - } - - if (requestParameters.bvn !== undefined) { - formParams['bvn'] = requestParameters.bvn; - } - - if (requestParameters.first_name !== undefined) { - formParams['first_name'] = requestParameters.first_name; - } - - if (requestParameters.middle_name !== undefined) { - formParams['middle_name'] = requestParameters.middle_name; - } - - if (requestParameters.last_name !== undefined) { - formParams['last_name'] = requestParameters.last_name; - } - - - const response = await this.request({ - path: `/bvn/match`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - - return ResponseFromJSON(response); - } - /** * Fetch Banks */ @@ -226,25 +161,6 @@ export class Verification extends BaseAPI { return ResponseFromJSON(response); } - /** - * Resolve BVN - */ - async resolveBvn(requestParameters: ResolveBvnRequest): Promise { - if (requestParameters.bvn === null || requestParameters.bvn === undefined) { - throw new RequiredError('bvn','Required parameter bvn was null or undefined when calling resolveBvn.'); - } - const queryParameters: any = {}; - - - const response = await this.request({ - path: `/bank/resolve_bvn/{bvn}`.replace(`{${"bvn"}}`, encodeURIComponent(String(requestParameters.bvn))), - method: 'GET', - query: queryParameters, - }); - - return ResponseFromJSON(response); - } - /** * Resolve Card BIN */ diff --git a/src/models/Accepted.ts b/src/models/Accepted.ts new file mode 100644 index 0000000..fba8582 --- /dev/null +++ b/src/models/Accepted.ts @@ -0,0 +1,65 @@ +/* tslint:disable */ +/* eslint-disable */ +/** + * Paystack + * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. + * + * The version of the Paystack Node library: 1.0.0 + * Contact: techsupport@paystack.com + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +import { exists, mapValues } from '../runtime'; +/** + * + * @export + * @interface Accepted + */ +export interface Accepted { + /** + * + * @type {boolean} + * @memberof Accepted + */ + status?: boolean; + /** + * + * @type {string} + * @memberof Accepted + */ + message?: string; +} + +export function AcceptedFromJSON(json: any): Accepted { + return AcceptedFromJSONTyped(json, false); +} + +export function AcceptedFromJSONTyped(json: any, ignoreDiscriminator: boolean): Accepted { + if ((json === undefined) || (json === null)) { + return json; + } + return { + + 'status': !exists(json, 'status') ? undefined : json['status'], + 'message': !exists(json, 'message') ? undefined : json['message'], + }; +} + +export function AcceptedToJSON(value?: Accepted | null): any { + if (value === undefined) { + return undefined; + } + if (value === null) { + return null; + } + return { + + 'status': value.status, + 'message': value.message, + }; +} + + diff --git a/src/models/Bank.ts b/src/models/Bank.ts index 0dadf41..9e7868b 100644 --- a/src/models/Bank.ts +++ b/src/models/Bank.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/BulkChargeInitiate.ts b/src/models/BulkChargeInitiate.ts index 0fe94e9..2d72f5a 100644 --- a/src/models/BulkChargeInitiate.ts +++ b/src/models/BulkChargeInitiate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ChargeCreate.ts b/src/models/ChargeCreate.ts index e035ba6..9058902 100644 --- a/src/models/ChargeCreate.ts +++ b/src/models/ChargeCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ChargeSubmitAddress.ts b/src/models/ChargeSubmitAddress.ts index d7e9eb9..fa5d355 100644 --- a/src/models/ChargeSubmitAddress.ts +++ b/src/models/ChargeSubmitAddress.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ChargeSubmitBirthday.ts b/src/models/ChargeSubmitBirthday.ts index 3c685a1..2d69964 100644 --- a/src/models/ChargeSubmitBirthday.ts +++ b/src/models/ChargeSubmitBirthday.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ChargeSubmitOTP.ts b/src/models/ChargeSubmitOTP.ts index 6d245d2..d0f8aed 100644 --- a/src/models/ChargeSubmitOTP.ts +++ b/src/models/ChargeSubmitOTP.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ChargeSubmitPhone.ts b/src/models/ChargeSubmitPhone.ts index 2bcce2a..011f420 100644 --- a/src/models/ChargeSubmitPhone.ts +++ b/src/models/ChargeSubmitPhone.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ChargeSubmitPin.ts b/src/models/ChargeSubmitPin.ts index 52b68dd..2f5d7cc 100644 --- a/src/models/ChargeSubmitPin.ts +++ b/src/models/ChargeSubmitPin.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/CustomerCreate.ts b/src/models/CustomerCreate.ts index 868b42c..3b8d78a 100644 --- a/src/models/CustomerCreate.ts +++ b/src/models/CustomerCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/CustomerDeactivateAuthorization.ts b/src/models/CustomerDeactivateAuthorization.ts index e777b47..b8c1155 100644 --- a/src/models/CustomerDeactivateAuthorization.ts +++ b/src/models/CustomerDeactivateAuthorization.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/CustomerRiskAction.ts b/src/models/CustomerRiskAction.ts index 0c50f75..b6d0ce3 100644 --- a/src/models/CustomerRiskAction.ts +++ b/src/models/CustomerRiskAction.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/CustomerUpdate.ts b/src/models/CustomerUpdate.ts index 5311eca..e25fa00 100644 --- a/src/models/CustomerUpdate.ts +++ b/src/models/CustomerUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/CustomerValidate.ts b/src/models/CustomerValidate.ts index 68d0a01..1a53968 100644 --- a/src/models/CustomerValidate.ts +++ b/src/models/CustomerValidate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/CustomerValidation.ts b/src/models/CustomerValidation.ts index 2724c9c..a10adff 100644 --- a/src/models/CustomerValidation.ts +++ b/src/models/CustomerValidation.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/DedicatedVirtualAccountCreate.ts b/src/models/DedicatedVirtualAccountCreate.ts index a82d0d3..87f16a4 100644 --- a/src/models/DedicatedVirtualAccountCreate.ts +++ b/src/models/DedicatedVirtualAccountCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/DedicatedVirtualAccountSplit.ts b/src/models/DedicatedVirtualAccountSplit.ts index 02c94db..c7bc0a4 100644 --- a/src/models/DedicatedVirtualAccountSplit.ts +++ b/src/models/DedicatedVirtualAccountSplit.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/DisputeEvidence.ts b/src/models/DisputeEvidence.ts index 05cb384..3097bdb 100644 --- a/src/models/DisputeEvidence.ts +++ b/src/models/DisputeEvidence.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/DisputeResolve.ts b/src/models/DisputeResolve.ts index ec126cc..32b8216 100644 --- a/src/models/DisputeResolve.ts +++ b/src/models/DisputeResolve.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/DisputeUpdate.ts b/src/models/DisputeUpdate.ts index 54788e6..17d6265 100644 --- a/src/models/DisputeUpdate.ts +++ b/src/models/DisputeUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/EFT.ts b/src/models/EFT.ts index ad19ad0..d73bdb7 100644 --- a/src/models/EFT.ts +++ b/src/models/EFT.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/MobileMoney.ts b/src/models/MobileMoney.ts index 6fe0c13..a8b80a4 100644 --- a/src/models/MobileMoney.ts +++ b/src/models/MobileMoney.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ModelError.ts b/src/models/ModelError.ts index 52b2050..7f2819e 100644 --- a/src/models/ModelError.ts +++ b/src/models/ModelError.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/PageCreate.ts b/src/models/PageCreate.ts index b320a2b..7ac7850 100644 --- a/src/models/PageCreate.ts +++ b/src/models/PageCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/PageProduct.ts b/src/models/PageProduct.ts index 96bbc96..5d26028 100644 --- a/src/models/PageProduct.ts +++ b/src/models/PageProduct.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/PageUpdate.ts b/src/models/PageUpdate.ts index 2c63b95..0d5d77d 100644 --- a/src/models/PageUpdate.ts +++ b/src/models/PageUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/PaymentRequestCreate.ts b/src/models/PaymentRequestCreate.ts index 87dcefd..38abc68 100644 --- a/src/models/PaymentRequestCreate.ts +++ b/src/models/PaymentRequestCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/PaymentRequestUpdate.ts b/src/models/PaymentRequestUpdate.ts index 02df94a..0d18e62 100644 --- a/src/models/PaymentRequestUpdate.ts +++ b/src/models/PaymentRequestUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/PlanCreate.ts b/src/models/PlanCreate.ts index 3f0d0cb..7c73566 100644 --- a/src/models/PlanCreate.ts +++ b/src/models/PlanCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/PlanUpdate.ts b/src/models/PlanUpdate.ts index b903d23..f600340 100644 --- a/src/models/PlanUpdate.ts +++ b/src/models/PlanUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ProductCreate.ts b/src/models/ProductCreate.ts index 349efce..3753afe 100644 --- a/src/models/ProductCreate.ts +++ b/src/models/ProductCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/ProductUpdate.ts b/src/models/ProductUpdate.ts index c0d4ab4..b69d8c6 100644 --- a/src/models/ProductUpdate.ts +++ b/src/models/ProductUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/RefundCreate.ts b/src/models/RefundCreate.ts index 55062c3..9d60190 100644 --- a/src/models/RefundCreate.ts +++ b/src/models/RefundCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/Response.ts b/src/models/Response.ts index fd69496..2fe59ad 100644 --- a/src/models/Response.ts +++ b/src/models/Response.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/SplitCreate.ts b/src/models/SplitCreate.ts index 7844050..fb1824f 100644 --- a/src/models/SplitCreate.ts +++ b/src/models/SplitCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/SplitSubaccounts.ts b/src/models/SplitSubaccounts.ts index caf3278..e97740f 100644 --- a/src/models/SplitSubaccounts.ts +++ b/src/models/SplitSubaccounts.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/SplitUpdate.ts b/src/models/SplitUpdate.ts index 3cf32a5..5334791 100644 --- a/src/models/SplitUpdate.ts +++ b/src/models/SplitUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/SubaccountCreate.ts b/src/models/SubaccountCreate.ts index 1e34203..b89dd84 100644 --- a/src/models/SubaccountCreate.ts +++ b/src/models/SubaccountCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/SubaccountUpdate.ts b/src/models/SubaccountUpdate.ts index c1b54b8..0fa8813 100644 --- a/src/models/SubaccountUpdate.ts +++ b/src/models/SubaccountUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/SubscriptionCreate.ts b/src/models/SubscriptionCreate.ts index 872c630..8325b8b 100644 --- a/src/models/SubscriptionCreate.ts +++ b/src/models/SubscriptionCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/SubscriptionToggle.ts b/src/models/SubscriptionToggle.ts index 9071ff8..5b7db1d 100644 --- a/src/models/SubscriptionToggle.ts +++ b/src/models/SubscriptionToggle.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransactionChargeAuthorization.ts b/src/models/TransactionChargeAuthorization.ts index 551ce6e..06291cb 100644 --- a/src/models/TransactionChargeAuthorization.ts +++ b/src/models/TransactionChargeAuthorization.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransactionCheckAuthorization.ts b/src/models/TransactionCheckAuthorization.ts index 637b6a5..5b17943 100644 --- a/src/models/TransactionCheckAuthorization.ts +++ b/src/models/TransactionCheckAuthorization.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransactionInitialize.ts b/src/models/TransactionInitialize.ts index bf6cd4a..16888f0 100644 --- a/src/models/TransactionInitialize.ts +++ b/src/models/TransactionInitialize.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransactionPartialDebit.ts b/src/models/TransactionPartialDebit.ts index 97105b6..cfefd6e 100644 --- a/src/models/TransactionPartialDebit.ts +++ b/src/models/TransactionPartialDebit.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferBulk.ts b/src/models/TransferBulk.ts index 7587547..b4813bc 100644 --- a/src/models/TransferBulk.ts +++ b/src/models/TransferBulk.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferFinalize.ts b/src/models/TransferFinalize.ts index 0971853..b1bebac 100644 --- a/src/models/TransferFinalize.ts +++ b/src/models/TransferFinalize.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferFinalizeDisableOTP.ts b/src/models/TransferFinalizeDisableOTP.ts index 799a941..930bd87 100644 --- a/src/models/TransferFinalizeDisableOTP.ts +++ b/src/models/TransferFinalizeDisableOTP.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferInitiate.ts b/src/models/TransferInitiate.ts index c830968..0a3f711 100644 --- a/src/models/TransferInitiate.ts +++ b/src/models/TransferInitiate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferRecipientBulk.ts b/src/models/TransferRecipientBulk.ts index 813909c..6ccceef 100644 --- a/src/models/TransferRecipientBulk.ts +++ b/src/models/TransferRecipientBulk.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferRecipientCreate.ts b/src/models/TransferRecipientCreate.ts index e2a8612..0cdafea 100644 --- a/src/models/TransferRecipientCreate.ts +++ b/src/models/TransferRecipientCreate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferRecipientUpdate.ts b/src/models/TransferRecipientUpdate.ts index f16ba1a..714e87a 100644 --- a/src/models/TransferRecipientUpdate.ts +++ b/src/models/TransferRecipientUpdate.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/TransferResendOTP.ts b/src/models/TransferResendOTP.ts index 62ffba9..4709434 100644 --- a/src/models/TransferResendOTP.ts +++ b/src/models/TransferResendOTP.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/USSD.ts b/src/models/USSD.ts index f86fc78..bd5b29e 100644 --- a/src/models/USSD.ts +++ b/src/models/USSD.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/VerificationBVNMatch.ts b/src/models/VerificationBVNMatch.ts index 8c566ba..11c1d4c 100644 --- a/src/models/VerificationBVNMatch.ts +++ b/src/models/VerificationBVNMatch.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech diff --git a/src/models/index.ts b/src/models/index.ts index c55803d..8680e5b 100644 --- a/src/models/index.ts +++ b/src/models/index.ts @@ -1,3 +1,4 @@ +export * from './Accepted'; export * from './Bank'; export * from './BulkChargeInitiate'; export * from './ChargeCreate'; diff --git a/src/runtime.ts b/src/runtime.ts index be8eb82..f4489d5 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -5,7 +5,7 @@ * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. * * The version of the Paystack Node library: 1.0.0 - * + * Contact: techsupport@paystack.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/node - 1.0.0-beta.3` + "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.4` } } From 37508f3d538ce4b519c4966064b71388e99574dd Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Wed, 8 Jun 2022 12:17:47 +0400 Subject: [PATCH 03/13] Chore: Update package version --- lib/runtime.js | 2 +- package.json | 2 +- src/runtime.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/runtime.js b/lib/runtime.js index 0e04be2..263b92a 100644 --- a/lib/runtime.js +++ b/lib/runtime.js @@ -51,7 +51,7 @@ class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.4` + "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.5` } }; return new Promise((resolve, reject) => { diff --git a/package.json b/package.json index eff03d2..71bf288 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@paystack/paystack-sdk", - "version": "1.0.0-beta.4", + "version": "1.0.0-beta.5", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", "keywords": [ diff --git a/src/runtime.ts b/src/runtime.ts index f4489d5..0763bfb 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.4` + "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.5` } } From d613383031c66815d31e1ba764d7e460b254f40a Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Wed, 8 Jun 2022 12:29:16 +0400 Subject: [PATCH 04/13] Chore: Update package details for NPM --- lib/runtime.js | 2 +- package.json | 6 +++--- src/runtime.ts | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/runtime.js b/lib/runtime.js index 263b92a..b0c0f9c 100644 --- a/lib/runtime.js +++ b/lib/runtime.js @@ -51,7 +51,7 @@ class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.5` + "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.6` } }; return new Promise((resolve, reject) => { diff --git a/package.json b/package.json index 71bf288..d29aea8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@paystack/paystack-sdk", - "version": "1.0.0-beta.5", + "version": "1.0.0-beta.6", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", "keywords": [ @@ -16,8 +16,8 @@ "send money", "multi splits" ], - "homepage": "https://github.com/owner/project", - "bugs": "https://github.com/owner/project/issues", + "homepage": "https://github.com/PaystackOSS/paystack-node", + "bugs": "https://github.com/PaystackOSS/paystack-node/issues", "license": "MIT", "main": "./lib/index.js", "typings": "./lib/index.d.ts", diff --git a/src/runtime.ts b/src/runtime.ts index 0763bfb..6067bdb 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.5` + "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.6` } } From 9398fa449761b007504a4eec962f15e2c0d8914c Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Tue, 27 Sep 2022 16:46:23 +0100 Subject: [PATCH 05/13] Cleanup for version 1 --- README.md | 43 +++++++++++++++++++++++++++++++++++++++---- package.json | 2 +- src/apis/Customer.ts | 20 ++++++++++---------- src/index.ts | 3 ++- src/runtime.ts | 2 +- 5 files changed, 53 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index e6d5797..7600c75 100644 --- a/README.md +++ b/README.md @@ -14,15 +14,50 @@ npm install @paystack/paystack-sdk --save ## Usage Import and initialize the library: ``` +const Paystack = require('@paystack/paystack-sdk') +const paystack = new Paystack("sk_test_xxxxxx") + +paystack.transaction.initialize({email: "test@example.com", amount: 20000}) + .then(response => console.log(response)) + .catch(error => console.log(error)) +``` + +Import and initialize the library using ES module with `async/await`: +``` import Paystack from '@paystack/paystack-sdk' const paystack = new Paystack("sk_test_xxxxxx") + +const initialize = async(email, amount) => { + const response = await paystack.transaction.initialize({ + email, + amount + }) + + console.log(response) +} + +const email = 'test@example.com' +const amount = 2000 +initialize(email, amount) ``` -Initiate a request and parse response: +### Typescript ``` -paystack.customer.fetch({code: "CUS_o9rf5kuwei3lt4vl"}) - .then(customer => console.log(customer)) - .catch(error => console.log(error)) +import Paystack from '@paystack/paystack-sdk'; +const paystack = new Paystack("sk_test_xxxxxx"); + +const initialize = async(email, amount) => { + const response = await paystack.transaction.initialize({ + email, + amount + }); + + console.log(response); +} + +const email = 'test@example.com'; +const amount = 2000; +initialize(email, amount); ``` ## Issues diff --git a/package.json b/package.json index d29aea8..3643821 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@paystack/paystack-sdk", - "version": "1.0.0-beta.6", + "version": "1.0.0", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", "keywords": [ diff --git a/src/apis/Customer.ts b/src/apis/Customer.ts index f84afc9..123a117 100644 --- a/src/apis/Customer.ts +++ b/src/apis/Customer.ts @@ -59,7 +59,7 @@ export interface UpdateRequest { metadata?: string; } -export interface ValidatteRequest { +export interface ValidateRequest { code: string; first_name: string; last_name: string; @@ -282,30 +282,30 @@ export class Customer extends BaseAPI { * Validate a customer\'s identity * Validate Customer */ - async validatte(requestParameters: ValidatteRequest): Promise { + async validate(requestParameters: ValidateRequest): Promise { if (requestParameters.code === null || requestParameters.code === undefined) { - throw new RequiredError('code','Required parameter code was null or undefined when calling validatte.'); + throw new RequiredError('code','Required parameter code was null or undefined when calling validate.'); } if (requestParameters.first_name === null || requestParameters.first_name === undefined) { - throw new RequiredError('first_name','Required parameter first_name was null or undefined when calling validatte.'); + throw new RequiredError('first_name','Required parameter first_name was null or undefined when calling validate.'); } if (requestParameters.last_name === null || requestParameters.last_name === undefined) { - throw new RequiredError('last_name','Required parameter last_name was null or undefined when calling validatte.'); + throw new RequiredError('last_name','Required parameter last_name was null or undefined when calling validate.'); } if (requestParameters.type === null || requestParameters.type === undefined) { - throw new RequiredError('type','Required parameter type was null or undefined when calling validatte.'); + throw new RequiredError('type','Required parameter type was null or undefined when calling validate.'); } if (requestParameters.country === null || requestParameters.country === undefined) { - throw new RequiredError('country','Required parameter country was null or undefined when calling validatte.'); + throw new RequiredError('country','Required parameter country was null or undefined when calling validate.'); } if (requestParameters.bvn === null || requestParameters.bvn === undefined) { - throw new RequiredError('bvn','Required parameter bvn was null or undefined when calling validatte.'); + throw new RequiredError('bvn','Required parameter bvn was null or undefined when calling validate.'); } if (requestParameters.bank_code === null || requestParameters.bank_code === undefined) { - throw new RequiredError('bank_code','Required parameter bank_code was null or undefined when calling validatte.'); + throw new RequiredError('bank_code','Required parameter bank_code was null or undefined when calling validate.'); } if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new RequiredError('account_number','Required parameter account_number was null or undefined when calling validatte.'); + throw new RequiredError('account_number','Required parameter account_number was null or undefined when calling validate.'); } const queryParameters: any = {}; diff --git a/src/index.ts b/src/index.ts index 5600aef..db2e1bf 100644 --- a/src/index.ts +++ b/src/index.ts @@ -30,4 +30,5 @@ class Paystack { } -module.exports = Paystack \ No newline at end of file +module.exports = Paystack; +module.exports.default = Paystack; \ No newline at end of file diff --git a/src/runtime.ts b/src/runtime.ts index 6067bdb..0f9ac2b 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.6` + "user-agent": `@paystack/paystack-sdk - 1.0.0` } } From b17425de25b9792f76a03b697c325f1dd635a182 Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Tue, 27 Sep 2022 16:50:45 +0100 Subject: [PATCH 06/13] Chore: Tag code snippet in readme --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 7600c75..d06a79c 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ npm install @paystack/paystack-sdk --save ## Usage Import and initialize the library: -``` +```javascript const Paystack = require('@paystack/paystack-sdk') const paystack = new Paystack("sk_test_xxxxxx") @@ -23,7 +23,7 @@ paystack.transaction.initialize({email: "test@example.com", amount: 20000}) ``` Import and initialize the library using ES module with `async/await`: -``` +```javascript import Paystack from '@paystack/paystack-sdk' const paystack = new Paystack("sk_test_xxxxxx") @@ -42,7 +42,7 @@ initialize(email, amount) ``` ### Typescript -``` +```typescript import Paystack from '@paystack/paystack-sdk'; const paystack = new Paystack("sk_test_xxxxxx"); From 416cc50fc71bec5e69a539ed8bbd8f0868ad27a9 Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Tue, 27 Sep 2022 17:02:14 +0100 Subject: [PATCH 07/13] Lib generation --- lib/apis/Customer.d.ts | 4 ++-- lib/apis/Customer.js | 18 +++++++++--------- lib/apis/index.js | 1 - lib/index.js | 1 + lib/models/index.js | 2 +- lib/runtime.js | 2 +- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/lib/apis/Customer.d.ts b/lib/apis/Customer.d.ts index 5214e90..9170627 100644 --- a/lib/apis/Customer.d.ts +++ b/lib/apis/Customer.d.ts @@ -44,7 +44,7 @@ export interface UpdateRequest { phone?: string; metadata?: string; } -export interface ValidatteRequest { +export interface ValidateRequest { code: string; first_name: string; last_name: string; @@ -90,5 +90,5 @@ export declare class Customer extends BaseAPI { * Validate a customer\'s identity * Validate Customer */ - validatte(requestParameters: ValidatteRequest): Promise; + validate(requestParameters: ValidateRequest): Promise; } diff --git a/lib/apis/Customer.js b/lib/apis/Customer.js index 2638ac2..a9b06a3 100644 --- a/lib/apis/Customer.js +++ b/lib/apis/Customer.js @@ -200,31 +200,31 @@ class Customer extends runtime_1.BaseAPI { * Validate a customer\'s identity * Validate Customer */ - validatte(requestParameters) { + validate(requestParameters) { return __awaiter(this, void 0, void 0, function* () { if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling validate.'); } if (requestParameters.first_name === null || requestParameters.first_name === undefined) { - throw new runtime_1.RequiredError('first_name', 'Required parameter first_name was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('first_name', 'Required parameter first_name was null or undefined when calling validate.'); } if (requestParameters.last_name === null || requestParameters.last_name === undefined) { - throw new runtime_1.RequiredError('last_name', 'Required parameter last_name was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('last_name', 'Required parameter last_name was null or undefined when calling validate.'); } if (requestParameters.type === null || requestParameters.type === undefined) { - throw new runtime_1.RequiredError('type', 'Required parameter type was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('type', 'Required parameter type was null or undefined when calling validate.'); } if (requestParameters.country === null || requestParameters.country === undefined) { - throw new runtime_1.RequiredError('country', 'Required parameter country was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('country', 'Required parameter country was null or undefined when calling validate.'); } if (requestParameters.bvn === null || requestParameters.bvn === undefined) { - throw new runtime_1.RequiredError('bvn', 'Required parameter bvn was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('bvn', 'Required parameter bvn was null or undefined when calling validate.'); } if (requestParameters.bank_code === null || requestParameters.bank_code === undefined) { - throw new runtime_1.RequiredError('bank_code', 'Required parameter bank_code was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('bank_code', 'Required parameter bank_code was null or undefined when calling validate.'); } if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling validatte.'); + throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling validate.'); } const queryParameters = {}; let formParams = {}; diff --git a/lib/apis/index.js b/lib/apis/index.js index 7b00116..1838d2c 100644 --- a/lib/apis/index.js +++ b/lib/apis/index.js @@ -1,6 +1,5 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.Verification = exports.TransferRecipient = exports.Transfer = exports.Transaction = exports.Subscription = exports.Subaccount = exports.Split = exports.Settlement = exports.Refund = exports.Product = exports.Plan = exports.PaymentRequest = exports.Page = exports.Integration = exports.Dispute = exports.DedicatedVirtualAccount = exports.Customer = exports.Charge = exports.BulkCharge = exports.Balance = void 0; exports.Balance = require("./Balance"); exports.BulkCharge = require("./BulkCharge"); exports.Charge = require("./Charge"); diff --git a/lib/index.js b/lib/index.js index 83ac84c..a0107bc 100644 --- a/lib/index.js +++ b/lib/index.js @@ -25,3 +25,4 @@ class Paystack { } } module.exports = Paystack; +module.exports.default = Paystack; diff --git a/lib/models/index.js b/lib/models/index.js index 1839dd2..853e364 100644 --- a/lib/models/index.js +++ b/lib/models/index.js @@ -7,7 +7,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./Accepted"), exports); diff --git a/lib/runtime.js b/lib/runtime.js index b0c0f9c..dfb989a 100644 --- a/lib/runtime.js +++ b/lib/runtime.js @@ -51,7 +51,7 @@ class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "paystack-version": `@paystack/paystack-sdk - 1.0.0-beta.6` + "user-agent": `@paystack/paystack-sdk - 1.0.0` } }; return new Promise((resolve, reject) => { From f551f42722fd6709085ad776233e5d73e1e1f3ca Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Tue, 1 Nov 2022 10:40:40 +0000 Subject: [PATCH 08/13] Patch: Fix TS constructor error --- lib/apis/Subscription.js | 2 +- lib/apis/Transaction.js | 5 ++ lib/apis/index.js | 60 ++++++++++++------- lib/index.d.ts | 1 - lib/index.js | 23 ++++++- lib/models/index.js | 2 +- lib/runtime.js | 2 +- lib/{ => types}/apis/Balance.d.ts | 0 lib/{ => types}/apis/BulkCharge.d.ts | 0 lib/{ => types}/apis/Charge.d.ts | 0 lib/{ => types}/apis/Customer.d.ts | 0 .../apis/DedicatedVirtualAccount.d.ts | 0 lib/{ => types}/apis/Dispute.d.ts | 0 lib/{ => types}/apis/Integration.d.ts | 0 lib/{ => types}/apis/Page.d.ts | 0 lib/{ => types}/apis/PaymentRequest.d.ts | 0 lib/{ => types}/apis/Plan.d.ts | 0 lib/{ => types}/apis/Product.d.ts | 0 lib/{ => types}/apis/Refund.d.ts | 0 lib/{ => types}/apis/Settlement.d.ts | 0 lib/{ => types}/apis/Split.d.ts | 0 lib/{ => types}/apis/Subaccount.d.ts | 0 lib/{ => types}/apis/Subscription.d.ts | 0 lib/{ => types}/apis/Transaction.d.ts | 5 ++ lib/{ => types}/apis/Transfer.d.ts | 0 lib/{ => types}/apis/TransferRecipient.d.ts | 0 lib/{ => types}/apis/Verification.d.ts | 0 lib/{ => types}/apis/index.d.ts | 0 lib/types/index.d.ts | 7 +++ lib/{ => types}/models/Accepted.d.ts | 0 lib/{ => types}/models/Bank.d.ts | 0 .../models/BulkChargeInitiate.d.ts | 0 lib/{ => types}/models/ChargeCreate.d.ts | 0 .../models/ChargeSubmitAddress.d.ts | 0 .../models/ChargeSubmitBirthday.d.ts | 0 lib/{ => types}/models/ChargeSubmitOTP.d.ts | 0 lib/{ => types}/models/ChargeSubmitPhone.d.ts | 0 lib/{ => types}/models/ChargeSubmitPin.d.ts | 0 lib/{ => types}/models/CustomerCreate.d.ts | 0 .../CustomerDeactivateAuthorization.d.ts | 0 .../models/CustomerRiskAction.d.ts | 0 lib/{ => types}/models/CustomerUpdate.d.ts | 0 lib/{ => types}/models/CustomerValidate.d.ts | 0 .../models/CustomerValidation.d.ts | 0 .../models/DedicatedVirtualAccountCreate.d.ts | 0 .../models/DedicatedVirtualAccountSplit.d.ts | 0 lib/{ => types}/models/DisputeEvidence.d.ts | 0 lib/{ => types}/models/DisputeResolve.d.ts | 0 lib/{ => types}/models/DisputeUpdate.d.ts | 0 lib/{ => types}/models/EFT.d.ts | 0 lib/{ => types}/models/MobileMoney.d.ts | 0 lib/{ => types}/models/ModelError.d.ts | 0 lib/{ => types}/models/PageCreate.d.ts | 0 lib/{ => types}/models/PageProduct.d.ts | 0 lib/{ => types}/models/PageUpdate.d.ts | 0 .../models/PaymentRequestCreate.d.ts | 0 .../models/PaymentRequestUpdate.d.ts | 0 lib/{ => types}/models/PlanCreate.d.ts | 0 lib/{ => types}/models/PlanUpdate.d.ts | 0 lib/{ => types}/models/ProductCreate.d.ts | 0 lib/{ => types}/models/ProductUpdate.d.ts | 0 lib/{ => types}/models/RefundCreate.d.ts | 0 lib/{ => types}/models/Response.d.ts | 0 lib/{ => types}/models/SplitCreate.d.ts | 0 lib/{ => types}/models/SplitSubaccounts.d.ts | 0 lib/{ => types}/models/SplitUpdate.d.ts | 0 lib/{ => types}/models/SubaccountCreate.d.ts | 0 lib/{ => types}/models/SubaccountUpdate.d.ts | 0 .../models/SubscriptionCreate.d.ts | 0 .../models/SubscriptionToggle.d.ts | 0 .../TransactionChargeAuthorization.d.ts | 0 .../models/TransactionCheckAuthorization.d.ts | 0 .../models/TransactionInitialize.d.ts | 0 .../models/TransactionPartialDebit.d.ts | 0 lib/{ => types}/models/TransferBulk.d.ts | 0 lib/{ => types}/models/TransferFinalize.d.ts | 0 .../models/TransferFinalizeDisableOTP.d.ts | 0 lib/{ => types}/models/TransferInitiate.d.ts | 0 .../models/TransferRecipientBulk.d.ts | 0 .../models/TransferRecipientCreate.d.ts | 0 .../models/TransferRecipientUpdate.d.ts | 0 lib/{ => types}/models/TransferResendOTP.d.ts | 0 lib/{ => types}/models/USSD.d.ts | 0 .../models/VerificationBVNMatch.d.ts | 0 lib/{ => types}/models/index.d.ts | 0 lib/{ => types}/runtime.d.ts | 0 package.json | 2 +- src/apis/Subscription.ts | 2 +- src/apis/Transaction.ts | 5 ++ src/index.ts | 2 +- src/runtime.ts | 2 +- tsconfig.json | 10 +--- 92 files changed, 94 insertions(+), 36 deletions(-) delete mode 100644 lib/index.d.ts rename lib/{ => types}/apis/Balance.d.ts (100%) rename lib/{ => types}/apis/BulkCharge.d.ts (100%) rename lib/{ => types}/apis/Charge.d.ts (100%) rename lib/{ => types}/apis/Customer.d.ts (100%) rename lib/{ => types}/apis/DedicatedVirtualAccount.d.ts (100%) rename lib/{ => types}/apis/Dispute.d.ts (100%) rename lib/{ => types}/apis/Integration.d.ts (100%) rename lib/{ => types}/apis/Page.d.ts (100%) rename lib/{ => types}/apis/PaymentRequest.d.ts (100%) rename lib/{ => types}/apis/Plan.d.ts (100%) rename lib/{ => types}/apis/Product.d.ts (100%) rename lib/{ => types}/apis/Refund.d.ts (100%) rename lib/{ => types}/apis/Settlement.d.ts (100%) rename lib/{ => types}/apis/Split.d.ts (100%) rename lib/{ => types}/apis/Subaccount.d.ts (100%) rename lib/{ => types}/apis/Subscription.d.ts (100%) rename lib/{ => types}/apis/Transaction.d.ts (91%) rename lib/{ => types}/apis/Transfer.d.ts (100%) rename lib/{ => types}/apis/TransferRecipient.d.ts (100%) rename lib/{ => types}/apis/Verification.d.ts (100%) rename lib/{ => types}/apis/index.d.ts (100%) create mode 100644 lib/types/index.d.ts rename lib/{ => types}/models/Accepted.d.ts (100%) rename lib/{ => types}/models/Bank.d.ts (100%) rename lib/{ => types}/models/BulkChargeInitiate.d.ts (100%) rename lib/{ => types}/models/ChargeCreate.d.ts (100%) rename lib/{ => types}/models/ChargeSubmitAddress.d.ts (100%) rename lib/{ => types}/models/ChargeSubmitBirthday.d.ts (100%) rename lib/{ => types}/models/ChargeSubmitOTP.d.ts (100%) rename lib/{ => types}/models/ChargeSubmitPhone.d.ts (100%) rename lib/{ => types}/models/ChargeSubmitPin.d.ts (100%) rename lib/{ => types}/models/CustomerCreate.d.ts (100%) rename lib/{ => types}/models/CustomerDeactivateAuthorization.d.ts (100%) rename lib/{ => types}/models/CustomerRiskAction.d.ts (100%) rename lib/{ => types}/models/CustomerUpdate.d.ts (100%) rename lib/{ => types}/models/CustomerValidate.d.ts (100%) rename lib/{ => types}/models/CustomerValidation.d.ts (100%) rename lib/{ => types}/models/DedicatedVirtualAccountCreate.d.ts (100%) rename lib/{ => types}/models/DedicatedVirtualAccountSplit.d.ts (100%) rename lib/{ => types}/models/DisputeEvidence.d.ts (100%) rename lib/{ => types}/models/DisputeResolve.d.ts (100%) rename lib/{ => types}/models/DisputeUpdate.d.ts (100%) rename lib/{ => types}/models/EFT.d.ts (100%) rename lib/{ => types}/models/MobileMoney.d.ts (100%) rename lib/{ => types}/models/ModelError.d.ts (100%) rename lib/{ => types}/models/PageCreate.d.ts (100%) rename lib/{ => types}/models/PageProduct.d.ts (100%) rename lib/{ => types}/models/PageUpdate.d.ts (100%) rename lib/{ => types}/models/PaymentRequestCreate.d.ts (100%) rename lib/{ => types}/models/PaymentRequestUpdate.d.ts (100%) rename lib/{ => types}/models/PlanCreate.d.ts (100%) rename lib/{ => types}/models/PlanUpdate.d.ts (100%) rename lib/{ => types}/models/ProductCreate.d.ts (100%) rename lib/{ => types}/models/ProductUpdate.d.ts (100%) rename lib/{ => types}/models/RefundCreate.d.ts (100%) rename lib/{ => types}/models/Response.d.ts (100%) rename lib/{ => types}/models/SplitCreate.d.ts (100%) rename lib/{ => types}/models/SplitSubaccounts.d.ts (100%) rename lib/{ => types}/models/SplitUpdate.d.ts (100%) rename lib/{ => types}/models/SubaccountCreate.d.ts (100%) rename lib/{ => types}/models/SubaccountUpdate.d.ts (100%) rename lib/{ => types}/models/SubscriptionCreate.d.ts (100%) rename lib/{ => types}/models/SubscriptionToggle.d.ts (100%) rename lib/{ => types}/models/TransactionChargeAuthorization.d.ts (100%) rename lib/{ => types}/models/TransactionCheckAuthorization.d.ts (100%) rename lib/{ => types}/models/TransactionInitialize.d.ts (100%) rename lib/{ => types}/models/TransactionPartialDebit.d.ts (100%) rename lib/{ => types}/models/TransferBulk.d.ts (100%) rename lib/{ => types}/models/TransferFinalize.d.ts (100%) rename lib/{ => types}/models/TransferFinalizeDisableOTP.d.ts (100%) rename lib/{ => types}/models/TransferInitiate.d.ts (100%) rename lib/{ => types}/models/TransferRecipientBulk.d.ts (100%) rename lib/{ => types}/models/TransferRecipientCreate.d.ts (100%) rename lib/{ => types}/models/TransferRecipientUpdate.d.ts (100%) rename lib/{ => types}/models/TransferResendOTP.d.ts (100%) rename lib/{ => types}/models/USSD.d.ts (100%) rename lib/{ => types}/models/VerificationBVNMatch.d.ts (100%) rename lib/{ => types}/models/index.d.ts (100%) rename lib/{ => types}/runtime.d.ts (100%) diff --git a/lib/apis/Subscription.js b/lib/apis/Subscription.js index 678f4b2..6400986 100644 --- a/lib/apis/Subscription.js +++ b/lib/apis/Subscription.js @@ -196,7 +196,7 @@ class Subscription extends runtime_1.BaseAPI { const queryParameters = {}; const response = yield this.request({ path: `/subscription/{code}/manage/link`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'POST', + method: 'GET', query: queryParameters, }); return models_1.ResponseFromJSON(response); diff --git a/lib/apis/Transaction.js b/lib/apis/Transaction.js index e5acc7a..7122076 100644 --- a/lib/apis/Transaction.js +++ b/lib/apis/Transaction.js @@ -165,6 +165,7 @@ class Transaction extends runtime_1.BaseAPI { }); } /** + * Fetch a transaction to get its details * Fetch Transaction */ fetch(requestParameters) { @@ -244,6 +245,7 @@ class Transaction extends runtime_1.BaseAPI { }); } /** + * List transactions that has occurred on your integration * List Transactions */ list(requestParameters) { @@ -333,6 +335,7 @@ class Transaction extends runtime_1.BaseAPI { }); } /** + * Get the details about the lifecycle of a transaction from initiation to completion * Fetch Transaction Timeline */ timeline(requestParameters) { @@ -350,6 +353,7 @@ class Transaction extends runtime_1.BaseAPI { }); } /** + * Get the total amount of all transactions * Transaction Totals */ totals(requestParameters) { @@ -376,6 +380,7 @@ class Transaction extends runtime_1.BaseAPI { }); } /** + * Verify a previously initiated transaction using it\'s reference * Verify Transaction */ verify(requestParameters) { diff --git a/lib/apis/index.js b/lib/apis/index.js index 1838d2c..b5d5220 100644 --- a/lib/apis/index.js +++ b/lib/apis/index.js @@ -1,22 +1,42 @@ "use strict"; +var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +})); +var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}); +var __importStar = (this && this.__importStar) || function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +}; Object.defineProperty(exports, "__esModule", { value: true }); -exports.Balance = require("./Balance"); -exports.BulkCharge = require("./BulkCharge"); -exports.Charge = require("./Charge"); -exports.Customer = require("./Customer"); -exports.DedicatedVirtualAccount = require("./DedicatedVirtualAccount"); -exports.Dispute = require("./Dispute"); -exports.Integration = require("./Integration"); -exports.Page = require("./Page"); -exports.PaymentRequest = require("./PaymentRequest"); -exports.Plan = require("./Plan"); -exports.Product = require("./Product"); -exports.Refund = require("./Refund"); -exports.Settlement = require("./Settlement"); -exports.Split = require("./Split"); -exports.Subaccount = require("./Subaccount"); -exports.Subscription = require("./Subscription"); -exports.Transaction = require("./Transaction"); -exports.Transfer = require("./Transfer"); -exports.TransferRecipient = require("./TransferRecipient"); -exports.Verification = require("./Verification"); +exports.Verification = exports.TransferRecipient = exports.Transfer = exports.Transaction = exports.Subscription = exports.Subaccount = exports.Split = exports.Settlement = exports.Refund = exports.Product = exports.Plan = exports.PaymentRequest = exports.Page = exports.Integration = exports.Dispute = exports.DedicatedVirtualAccount = exports.Customer = exports.Charge = exports.BulkCharge = exports.Balance = void 0; +exports.Balance = __importStar(require("./Balance")); +exports.BulkCharge = __importStar(require("./BulkCharge")); +exports.Charge = __importStar(require("./Charge")); +exports.Customer = __importStar(require("./Customer")); +exports.DedicatedVirtualAccount = __importStar(require("./DedicatedVirtualAccount")); +exports.Dispute = __importStar(require("./Dispute")); +exports.Integration = __importStar(require("./Integration")); +exports.Page = __importStar(require("./Page")); +exports.PaymentRequest = __importStar(require("./PaymentRequest")); +exports.Plan = __importStar(require("./Plan")); +exports.Product = __importStar(require("./Product")); +exports.Refund = __importStar(require("./Refund")); +exports.Settlement = __importStar(require("./Settlement")); +exports.Split = __importStar(require("./Split")); +exports.Subaccount = __importStar(require("./Subaccount")); +exports.Subscription = __importStar(require("./Subscription")); +exports.Transaction = __importStar(require("./Transaction")); +exports.Transfer = __importStar(require("./Transfer")); +exports.TransferRecipient = __importStar(require("./TransferRecipient")); +exports.Verification = __importStar(require("./Verification")); diff --git a/lib/index.d.ts b/lib/index.d.ts deleted file mode 100644 index cb0ff5c..0000000 --- a/lib/index.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/lib/index.js b/lib/index.js index a0107bc..c09fd58 100644 --- a/lib/index.js +++ b/lib/index.js @@ -1,6 +1,26 @@ "use strict"; +var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +})); +var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}); +var __importStar = (this && this.__importStar) || function (mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +}; Object.defineProperty(exports, "__esModule", { value: true }); -const Resources = require("./apis"); +exports.Paystack = void 0; +const Resources = __importStar(require("./apis")); class Paystack { constructor(apiKey) { this.extend(apiKey); @@ -24,5 +44,6 @@ class Paystack { return resource.toLowerCase().replace("api", ""); } } +exports.Paystack = Paystack; module.exports = Paystack; module.exports.default = Paystack; diff --git a/lib/models/index.js b/lib/models/index.js index 853e364..1839dd2 100644 --- a/lib/models/index.js +++ b/lib/models/index.js @@ -7,7 +7,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./Accepted"), exports); diff --git a/lib/runtime.js b/lib/runtime.js index dfb989a..2837621 100644 --- a/lib/runtime.js +++ b/lib/runtime.js @@ -51,7 +51,7 @@ class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "user-agent": `@paystack/paystack-sdk - 1.0.0` + "user-agent": `@paystack/paystack-sdk - 1.0.1` } }; return new Promise((resolve, reject) => { diff --git a/lib/apis/Balance.d.ts b/lib/types/apis/Balance.d.ts similarity index 100% rename from lib/apis/Balance.d.ts rename to lib/types/apis/Balance.d.ts diff --git a/lib/apis/BulkCharge.d.ts b/lib/types/apis/BulkCharge.d.ts similarity index 100% rename from lib/apis/BulkCharge.d.ts rename to lib/types/apis/BulkCharge.d.ts diff --git a/lib/apis/Charge.d.ts b/lib/types/apis/Charge.d.ts similarity index 100% rename from lib/apis/Charge.d.ts rename to lib/types/apis/Charge.d.ts diff --git a/lib/apis/Customer.d.ts b/lib/types/apis/Customer.d.ts similarity index 100% rename from lib/apis/Customer.d.ts rename to lib/types/apis/Customer.d.ts diff --git a/lib/apis/DedicatedVirtualAccount.d.ts b/lib/types/apis/DedicatedVirtualAccount.d.ts similarity index 100% rename from lib/apis/DedicatedVirtualAccount.d.ts rename to lib/types/apis/DedicatedVirtualAccount.d.ts diff --git a/lib/apis/Dispute.d.ts b/lib/types/apis/Dispute.d.ts similarity index 100% rename from lib/apis/Dispute.d.ts rename to lib/types/apis/Dispute.d.ts diff --git a/lib/apis/Integration.d.ts b/lib/types/apis/Integration.d.ts similarity index 100% rename from lib/apis/Integration.d.ts rename to lib/types/apis/Integration.d.ts diff --git a/lib/apis/Page.d.ts b/lib/types/apis/Page.d.ts similarity index 100% rename from lib/apis/Page.d.ts rename to lib/types/apis/Page.d.ts diff --git a/lib/apis/PaymentRequest.d.ts b/lib/types/apis/PaymentRequest.d.ts similarity index 100% rename from lib/apis/PaymentRequest.d.ts rename to lib/types/apis/PaymentRequest.d.ts diff --git a/lib/apis/Plan.d.ts b/lib/types/apis/Plan.d.ts similarity index 100% rename from lib/apis/Plan.d.ts rename to lib/types/apis/Plan.d.ts diff --git a/lib/apis/Product.d.ts b/lib/types/apis/Product.d.ts similarity index 100% rename from lib/apis/Product.d.ts rename to lib/types/apis/Product.d.ts diff --git a/lib/apis/Refund.d.ts b/lib/types/apis/Refund.d.ts similarity index 100% rename from lib/apis/Refund.d.ts rename to lib/types/apis/Refund.d.ts diff --git a/lib/apis/Settlement.d.ts b/lib/types/apis/Settlement.d.ts similarity index 100% rename from lib/apis/Settlement.d.ts rename to lib/types/apis/Settlement.d.ts diff --git a/lib/apis/Split.d.ts b/lib/types/apis/Split.d.ts similarity index 100% rename from lib/apis/Split.d.ts rename to lib/types/apis/Split.d.ts diff --git a/lib/apis/Subaccount.d.ts b/lib/types/apis/Subaccount.d.ts similarity index 100% rename from lib/apis/Subaccount.d.ts rename to lib/types/apis/Subaccount.d.ts diff --git a/lib/apis/Subscription.d.ts b/lib/types/apis/Subscription.d.ts similarity index 100% rename from lib/apis/Subscription.d.ts rename to lib/types/apis/Subscription.d.ts diff --git a/lib/apis/Transaction.d.ts b/lib/types/apis/Transaction.d.ts similarity index 91% rename from lib/apis/Transaction.d.ts rename to lib/types/apis/Transaction.d.ts index 7b48336..b3c7c5f 100644 --- a/lib/apis/Transaction.d.ts +++ b/lib/types/apis/Transaction.d.ts @@ -107,6 +107,7 @@ export declare class Transaction extends BaseAPI { */ event(requestParameters: EventRequest): Promise; /** + * Fetch a transaction to get its details * Fetch Transaction */ fetch(requestParameters: FetchRequest): Promise; @@ -116,6 +117,7 @@ export declare class Transaction extends BaseAPI { */ initialize(requestParameters: InitializeRequest): Promise; /** + * List transactions that has occurred on your integration * List Transactions */ list(requestParameters: ListRequest): Promise; @@ -128,14 +130,17 @@ export declare class Transaction extends BaseAPI { */ session(requestParameters: SessionRequest): Promise; /** + * Get the details about the lifecycle of a transaction from initiation to completion * Fetch Transaction Timeline */ timeline(requestParameters: TimelineRequest): Promise; /** + * Get the total amount of all transactions * Transaction Totals */ totals(requestParameters: TotalsRequest): Promise; /** + * Verify a previously initiated transaction using it\'s reference * Verify Transaction */ verify(requestParameters: VerifyRequest): Promise; diff --git a/lib/apis/Transfer.d.ts b/lib/types/apis/Transfer.d.ts similarity index 100% rename from lib/apis/Transfer.d.ts rename to lib/types/apis/Transfer.d.ts diff --git a/lib/apis/TransferRecipient.d.ts b/lib/types/apis/TransferRecipient.d.ts similarity index 100% rename from lib/apis/TransferRecipient.d.ts rename to lib/types/apis/TransferRecipient.d.ts diff --git a/lib/apis/Verification.d.ts b/lib/types/apis/Verification.d.ts similarity index 100% rename from lib/apis/Verification.d.ts rename to lib/types/apis/Verification.d.ts diff --git a/lib/apis/index.d.ts b/lib/types/apis/index.d.ts similarity index 100% rename from lib/apis/index.d.ts rename to lib/types/apis/index.d.ts diff --git a/lib/types/index.d.ts b/lib/types/index.d.ts new file mode 100644 index 0000000..86d587c --- /dev/null +++ b/lib/types/index.d.ts @@ -0,0 +1,7 @@ +export declare class Paystack { + [index: string]: any; + constructor(apiKey: string); + private extend; + private toCamelCase; + private cleanResourceKey; +} diff --git a/lib/models/Accepted.d.ts b/lib/types/models/Accepted.d.ts similarity index 100% rename from lib/models/Accepted.d.ts rename to lib/types/models/Accepted.d.ts diff --git a/lib/models/Bank.d.ts b/lib/types/models/Bank.d.ts similarity index 100% rename from lib/models/Bank.d.ts rename to lib/types/models/Bank.d.ts diff --git a/lib/models/BulkChargeInitiate.d.ts b/lib/types/models/BulkChargeInitiate.d.ts similarity index 100% rename from lib/models/BulkChargeInitiate.d.ts rename to lib/types/models/BulkChargeInitiate.d.ts diff --git a/lib/models/ChargeCreate.d.ts b/lib/types/models/ChargeCreate.d.ts similarity index 100% rename from lib/models/ChargeCreate.d.ts rename to lib/types/models/ChargeCreate.d.ts diff --git a/lib/models/ChargeSubmitAddress.d.ts b/lib/types/models/ChargeSubmitAddress.d.ts similarity index 100% rename from lib/models/ChargeSubmitAddress.d.ts rename to lib/types/models/ChargeSubmitAddress.d.ts diff --git a/lib/models/ChargeSubmitBirthday.d.ts b/lib/types/models/ChargeSubmitBirthday.d.ts similarity index 100% rename from lib/models/ChargeSubmitBirthday.d.ts rename to lib/types/models/ChargeSubmitBirthday.d.ts diff --git a/lib/models/ChargeSubmitOTP.d.ts b/lib/types/models/ChargeSubmitOTP.d.ts similarity index 100% rename from lib/models/ChargeSubmitOTP.d.ts rename to lib/types/models/ChargeSubmitOTP.d.ts diff --git a/lib/models/ChargeSubmitPhone.d.ts b/lib/types/models/ChargeSubmitPhone.d.ts similarity index 100% rename from lib/models/ChargeSubmitPhone.d.ts rename to lib/types/models/ChargeSubmitPhone.d.ts diff --git a/lib/models/ChargeSubmitPin.d.ts b/lib/types/models/ChargeSubmitPin.d.ts similarity index 100% rename from lib/models/ChargeSubmitPin.d.ts rename to lib/types/models/ChargeSubmitPin.d.ts diff --git a/lib/models/CustomerCreate.d.ts b/lib/types/models/CustomerCreate.d.ts similarity index 100% rename from lib/models/CustomerCreate.d.ts rename to lib/types/models/CustomerCreate.d.ts diff --git a/lib/models/CustomerDeactivateAuthorization.d.ts b/lib/types/models/CustomerDeactivateAuthorization.d.ts similarity index 100% rename from lib/models/CustomerDeactivateAuthorization.d.ts rename to lib/types/models/CustomerDeactivateAuthorization.d.ts diff --git a/lib/models/CustomerRiskAction.d.ts b/lib/types/models/CustomerRiskAction.d.ts similarity index 100% rename from lib/models/CustomerRiskAction.d.ts rename to lib/types/models/CustomerRiskAction.d.ts diff --git a/lib/models/CustomerUpdate.d.ts b/lib/types/models/CustomerUpdate.d.ts similarity index 100% rename from lib/models/CustomerUpdate.d.ts rename to lib/types/models/CustomerUpdate.d.ts diff --git a/lib/models/CustomerValidate.d.ts b/lib/types/models/CustomerValidate.d.ts similarity index 100% rename from lib/models/CustomerValidate.d.ts rename to lib/types/models/CustomerValidate.d.ts diff --git a/lib/models/CustomerValidation.d.ts b/lib/types/models/CustomerValidation.d.ts similarity index 100% rename from lib/models/CustomerValidation.d.ts rename to lib/types/models/CustomerValidation.d.ts diff --git a/lib/models/DedicatedVirtualAccountCreate.d.ts b/lib/types/models/DedicatedVirtualAccountCreate.d.ts similarity index 100% rename from lib/models/DedicatedVirtualAccountCreate.d.ts rename to lib/types/models/DedicatedVirtualAccountCreate.d.ts diff --git a/lib/models/DedicatedVirtualAccountSplit.d.ts b/lib/types/models/DedicatedVirtualAccountSplit.d.ts similarity index 100% rename from lib/models/DedicatedVirtualAccountSplit.d.ts rename to lib/types/models/DedicatedVirtualAccountSplit.d.ts diff --git a/lib/models/DisputeEvidence.d.ts b/lib/types/models/DisputeEvidence.d.ts similarity index 100% rename from lib/models/DisputeEvidence.d.ts rename to lib/types/models/DisputeEvidence.d.ts diff --git a/lib/models/DisputeResolve.d.ts b/lib/types/models/DisputeResolve.d.ts similarity index 100% rename from lib/models/DisputeResolve.d.ts rename to lib/types/models/DisputeResolve.d.ts diff --git a/lib/models/DisputeUpdate.d.ts b/lib/types/models/DisputeUpdate.d.ts similarity index 100% rename from lib/models/DisputeUpdate.d.ts rename to lib/types/models/DisputeUpdate.d.ts diff --git a/lib/models/EFT.d.ts b/lib/types/models/EFT.d.ts similarity index 100% rename from lib/models/EFT.d.ts rename to lib/types/models/EFT.d.ts diff --git a/lib/models/MobileMoney.d.ts b/lib/types/models/MobileMoney.d.ts similarity index 100% rename from lib/models/MobileMoney.d.ts rename to lib/types/models/MobileMoney.d.ts diff --git a/lib/models/ModelError.d.ts b/lib/types/models/ModelError.d.ts similarity index 100% rename from lib/models/ModelError.d.ts rename to lib/types/models/ModelError.d.ts diff --git a/lib/models/PageCreate.d.ts b/lib/types/models/PageCreate.d.ts similarity index 100% rename from lib/models/PageCreate.d.ts rename to lib/types/models/PageCreate.d.ts diff --git a/lib/models/PageProduct.d.ts b/lib/types/models/PageProduct.d.ts similarity index 100% rename from lib/models/PageProduct.d.ts rename to lib/types/models/PageProduct.d.ts diff --git a/lib/models/PageUpdate.d.ts b/lib/types/models/PageUpdate.d.ts similarity index 100% rename from lib/models/PageUpdate.d.ts rename to lib/types/models/PageUpdate.d.ts diff --git a/lib/models/PaymentRequestCreate.d.ts b/lib/types/models/PaymentRequestCreate.d.ts similarity index 100% rename from lib/models/PaymentRequestCreate.d.ts rename to lib/types/models/PaymentRequestCreate.d.ts diff --git a/lib/models/PaymentRequestUpdate.d.ts b/lib/types/models/PaymentRequestUpdate.d.ts similarity index 100% rename from lib/models/PaymentRequestUpdate.d.ts rename to lib/types/models/PaymentRequestUpdate.d.ts diff --git a/lib/models/PlanCreate.d.ts b/lib/types/models/PlanCreate.d.ts similarity index 100% rename from lib/models/PlanCreate.d.ts rename to lib/types/models/PlanCreate.d.ts diff --git a/lib/models/PlanUpdate.d.ts b/lib/types/models/PlanUpdate.d.ts similarity index 100% rename from lib/models/PlanUpdate.d.ts rename to lib/types/models/PlanUpdate.d.ts diff --git a/lib/models/ProductCreate.d.ts b/lib/types/models/ProductCreate.d.ts similarity index 100% rename from lib/models/ProductCreate.d.ts rename to lib/types/models/ProductCreate.d.ts diff --git a/lib/models/ProductUpdate.d.ts b/lib/types/models/ProductUpdate.d.ts similarity index 100% rename from lib/models/ProductUpdate.d.ts rename to lib/types/models/ProductUpdate.d.ts diff --git a/lib/models/RefundCreate.d.ts b/lib/types/models/RefundCreate.d.ts similarity index 100% rename from lib/models/RefundCreate.d.ts rename to lib/types/models/RefundCreate.d.ts diff --git a/lib/models/Response.d.ts b/lib/types/models/Response.d.ts similarity index 100% rename from lib/models/Response.d.ts rename to lib/types/models/Response.d.ts diff --git a/lib/models/SplitCreate.d.ts b/lib/types/models/SplitCreate.d.ts similarity index 100% rename from lib/models/SplitCreate.d.ts rename to lib/types/models/SplitCreate.d.ts diff --git a/lib/models/SplitSubaccounts.d.ts b/lib/types/models/SplitSubaccounts.d.ts similarity index 100% rename from lib/models/SplitSubaccounts.d.ts rename to lib/types/models/SplitSubaccounts.d.ts diff --git a/lib/models/SplitUpdate.d.ts b/lib/types/models/SplitUpdate.d.ts similarity index 100% rename from lib/models/SplitUpdate.d.ts rename to lib/types/models/SplitUpdate.d.ts diff --git a/lib/models/SubaccountCreate.d.ts b/lib/types/models/SubaccountCreate.d.ts similarity index 100% rename from lib/models/SubaccountCreate.d.ts rename to lib/types/models/SubaccountCreate.d.ts diff --git a/lib/models/SubaccountUpdate.d.ts b/lib/types/models/SubaccountUpdate.d.ts similarity index 100% rename from lib/models/SubaccountUpdate.d.ts rename to lib/types/models/SubaccountUpdate.d.ts diff --git a/lib/models/SubscriptionCreate.d.ts b/lib/types/models/SubscriptionCreate.d.ts similarity index 100% rename from lib/models/SubscriptionCreate.d.ts rename to lib/types/models/SubscriptionCreate.d.ts diff --git a/lib/models/SubscriptionToggle.d.ts b/lib/types/models/SubscriptionToggle.d.ts similarity index 100% rename from lib/models/SubscriptionToggle.d.ts rename to lib/types/models/SubscriptionToggle.d.ts diff --git a/lib/models/TransactionChargeAuthorization.d.ts b/lib/types/models/TransactionChargeAuthorization.d.ts similarity index 100% rename from lib/models/TransactionChargeAuthorization.d.ts rename to lib/types/models/TransactionChargeAuthorization.d.ts diff --git a/lib/models/TransactionCheckAuthorization.d.ts b/lib/types/models/TransactionCheckAuthorization.d.ts similarity index 100% rename from lib/models/TransactionCheckAuthorization.d.ts rename to lib/types/models/TransactionCheckAuthorization.d.ts diff --git a/lib/models/TransactionInitialize.d.ts b/lib/types/models/TransactionInitialize.d.ts similarity index 100% rename from lib/models/TransactionInitialize.d.ts rename to lib/types/models/TransactionInitialize.d.ts diff --git a/lib/models/TransactionPartialDebit.d.ts b/lib/types/models/TransactionPartialDebit.d.ts similarity index 100% rename from lib/models/TransactionPartialDebit.d.ts rename to lib/types/models/TransactionPartialDebit.d.ts diff --git a/lib/models/TransferBulk.d.ts b/lib/types/models/TransferBulk.d.ts similarity index 100% rename from lib/models/TransferBulk.d.ts rename to lib/types/models/TransferBulk.d.ts diff --git a/lib/models/TransferFinalize.d.ts b/lib/types/models/TransferFinalize.d.ts similarity index 100% rename from lib/models/TransferFinalize.d.ts rename to lib/types/models/TransferFinalize.d.ts diff --git a/lib/models/TransferFinalizeDisableOTP.d.ts b/lib/types/models/TransferFinalizeDisableOTP.d.ts similarity index 100% rename from lib/models/TransferFinalizeDisableOTP.d.ts rename to lib/types/models/TransferFinalizeDisableOTP.d.ts diff --git a/lib/models/TransferInitiate.d.ts b/lib/types/models/TransferInitiate.d.ts similarity index 100% rename from lib/models/TransferInitiate.d.ts rename to lib/types/models/TransferInitiate.d.ts diff --git a/lib/models/TransferRecipientBulk.d.ts b/lib/types/models/TransferRecipientBulk.d.ts similarity index 100% rename from lib/models/TransferRecipientBulk.d.ts rename to lib/types/models/TransferRecipientBulk.d.ts diff --git a/lib/models/TransferRecipientCreate.d.ts b/lib/types/models/TransferRecipientCreate.d.ts similarity index 100% rename from lib/models/TransferRecipientCreate.d.ts rename to lib/types/models/TransferRecipientCreate.d.ts diff --git a/lib/models/TransferRecipientUpdate.d.ts b/lib/types/models/TransferRecipientUpdate.d.ts similarity index 100% rename from lib/models/TransferRecipientUpdate.d.ts rename to lib/types/models/TransferRecipientUpdate.d.ts diff --git a/lib/models/TransferResendOTP.d.ts b/lib/types/models/TransferResendOTP.d.ts similarity index 100% rename from lib/models/TransferResendOTP.d.ts rename to lib/types/models/TransferResendOTP.d.ts diff --git a/lib/models/USSD.d.ts b/lib/types/models/USSD.d.ts similarity index 100% rename from lib/models/USSD.d.ts rename to lib/types/models/USSD.d.ts diff --git a/lib/models/VerificationBVNMatch.d.ts b/lib/types/models/VerificationBVNMatch.d.ts similarity index 100% rename from lib/models/VerificationBVNMatch.d.ts rename to lib/types/models/VerificationBVNMatch.d.ts diff --git a/lib/models/index.d.ts b/lib/types/models/index.d.ts similarity index 100% rename from lib/models/index.d.ts rename to lib/types/models/index.d.ts diff --git a/lib/runtime.d.ts b/lib/types/runtime.d.ts similarity index 100% rename from lib/runtime.d.ts rename to lib/types/runtime.d.ts diff --git a/package.json b/package.json index 3643821..73e9fa4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@paystack/paystack-sdk", - "version": "1.0.0", + "version": "1.0.1", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", "keywords": [ diff --git a/src/apis/Subscription.ts b/src/apis/Subscription.ts index 2006334..352f72f 100644 --- a/src/apis/Subscription.ts +++ b/src/apis/Subscription.ts @@ -259,7 +259,7 @@ export class Subscription extends BaseAPI { const response = await this.request({ path: `/subscription/{code}/manage/link`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'POST', + method: 'GET', query: queryParameters, }); diff --git a/src/apis/Transaction.ts b/src/apis/Transaction.ts index cb4d0ff..dd31b51 100644 --- a/src/apis/Transaction.ts +++ b/src/apis/Transaction.ts @@ -276,6 +276,7 @@ export class Transaction extends BaseAPI { } /** + * Fetch a transaction to get its details * Fetch Transaction */ async fetch(requestParameters: FetchRequest): Promise { @@ -373,6 +374,7 @@ export class Transaction extends BaseAPI { } /** + * List transactions that has occurred on your integration * List Transactions */ async list(requestParameters: ListRequest): Promise { @@ -479,6 +481,7 @@ export class Transaction extends BaseAPI { } /** + * Get the details about the lifecycle of a transaction from initiation to completion * Fetch Transaction Timeline */ async timeline(requestParameters: TimelineRequest): Promise { @@ -498,6 +501,7 @@ export class Transaction extends BaseAPI { } /** + * Get the total amount of all transactions * Transaction Totals */ async totals(requestParameters: TotalsRequest): Promise { @@ -530,6 +534,7 @@ export class Transaction extends BaseAPI { } /** + * Verify a previously initiated transaction using it\'s reference * Verify Transaction */ async verify(requestParameters: VerifyRequest): Promise { diff --git a/src/index.ts b/src/index.ts index db2e1bf..4de79fc 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,6 +1,6 @@ import * as Resources from './apis' -class Paystack { +export class Paystack { [index: string]: any constructor(apiKey: string) { diff --git a/src/runtime.ts b/src/runtime.ts index 0f9ac2b..2e36751 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "user-agent": `@paystack/paystack-sdk - 1.0.0` + "user-agent": `@paystack/paystack-sdk - 1.0.1` } } diff --git a/tsconfig.json b/tsconfig.json index 13de6e6..71b1e7b 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,16 +1,12 @@ { "compilerOptions": { "declaration": true, + "declarationDir": "./lib/types", "target": "es6", "module": "commonjs", "moduleResolution": "node", + "esModuleInterop": true, "outDir": "lib", - "typeRoots": [ - "node_modules/@types" - ] }, - "exclude": [ - "lib", - "node_modules" - ] + "include": ["src"] } From bdf9b3d181c307eb078313642a7f86cdc116e686 Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Tue, 1 Nov 2022 11:10:18 +0000 Subject: [PATCH 09/13] V1 cleanup --- lib/apis/index.js | 3 +-- lib/index.js | 2 +- lib/models/index.js | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/lib/apis/index.js b/lib/apis/index.js index b5d5220..3078ed5 100644 --- a/lib/apis/index.js +++ b/lib/apis/index.js @@ -14,12 +14,11 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; Object.defineProperty(exports, "__esModule", { value: true }); -exports.Verification = exports.TransferRecipient = exports.Transfer = exports.Transaction = exports.Subscription = exports.Subaccount = exports.Split = exports.Settlement = exports.Refund = exports.Product = exports.Plan = exports.PaymentRequest = exports.Page = exports.Integration = exports.Dispute = exports.DedicatedVirtualAccount = exports.Customer = exports.Charge = exports.BulkCharge = exports.Balance = void 0; exports.Balance = __importStar(require("./Balance")); exports.BulkCharge = __importStar(require("./BulkCharge")); exports.Charge = __importStar(require("./Charge")); diff --git a/lib/index.js b/lib/index.js index c09fd58..068664f 100644 --- a/lib/index.js +++ b/lib/index.js @@ -14,7 +14,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? ( var __importStar = (this && this.__importStar) || function (mod) { if (mod && mod.__esModule) return mod; var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); __setModuleDefault(result, mod); return result; }; diff --git a/lib/models/index.js b/lib/models/index.js index 1839dd2..853e364 100644 --- a/lib/models/index.js +++ b/lib/models/index.js @@ -7,7 +7,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi o[k2] = m[k]; })); var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); + for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); }; Object.defineProperty(exports, "__esModule", { value: true }); __exportStar(require("./Accepted"), exports); From cb8ff059fe0b88d7c87099018fdbd05b11122f36 Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Mon, 24 Jun 2024 12:55:23 +0100 Subject: [PATCH 10/13] Patch: Module resolution bug --- .openapi-generator/FILES | 3 + lib/apis/Balance.js | 74 ---- lib/apis/BulkCharge.js | 141 ------ lib/apis/Charge.js | 260 ------------ lib/apis/Customer.js | 265 ------------ lib/apis/DedicatedVirtualAccount.js | 206 --------- lib/apis/Dispute.js | 268 ------------ lib/apis/Integration.js | 62 --- lib/apis/Page.js | 189 --------- lib/apis/PaymentRequest.js | 277 ------------ lib/apis/Plan.js | 174 -------- lib/apis/Product.js | 179 -------- lib/apis/Refund.js | 110 ----- lib/apis/Settlement.js | 70 --- lib/apis/Split.js | 212 --------- lib/apis/Subaccount.js | 180 -------- lib/apis/Subscription.js | 206 --------- lib/apis/Transaction.js | 401 ------------------ lib/apis/Transfer.js | 296 ------------- lib/apis/TransferRecipient.js | 192 --------- lib/apis/Verification.js | 142 ------- lib/apis/index.js | 41 -- lib/index.js | 49 --- lib/models/Accepted.js | 44 -- lib/models/Bank.js | 44 -- lib/models/BulkChargeInitiate.js | 43 -- lib/models/ChargeCreate.js | 56 --- lib/models/ChargeSubmitAddress.js | 49 --- lib/models/ChargeSubmitBirthday.js | 43 -- lib/models/ChargeSubmitOTP.js | 43 -- lib/models/ChargeSubmitPhone.js | 43 -- lib/models/ChargeSubmitPin.js | 43 -- lib/models/CustomerCreate.js | 50 --- lib/models/CustomerDeactivateAuthorization.js | 41 -- lib/models/CustomerRiskAction.js | 44 -- lib/models/CustomerUpdate.js | 48 --- lib/models/CustomerValidate.js | 49 --- lib/models/CustomerValidation.js | 56 --- lib/models/DedicatedVirtualAccountCreate.js | 48 --- lib/models/DedicatedVirtualAccountSplit.js | 46 -- lib/models/DisputeEvidence.js | 52 --- lib/models/DisputeResolve.js | 50 --- lib/models/DisputeUpdate.js | 44 -- lib/models/EFT.js | 42 -- lib/models/MobileMoney.js | 44 -- lib/models/ModelError.js | 44 -- lib/models/PageCreate.js | 54 --- lib/models/PageProduct.js | 41 -- lib/models/PageUpdate.js | 48 --- lib/models/PaymentRequestCreate.js | 64 --- lib/models/PaymentRequestUpdate.js | 64 --- lib/models/PlanCreate.js | 56 --- lib/models/PlanUpdate.js | 56 --- lib/models/ProductCreate.js | 52 --- lib/models/ProductUpdate.js | 52 --- lib/models/RefundCreate.js | 50 --- lib/models/Response.js | 46 -- lib/models/SplitCreate.js | 53 --- lib/models/SplitSubaccounts.js | 44 -- lib/models/SplitUpdate.js | 48 --- lib/models/SubaccountCreate.js | 58 --- lib/models/SubaccountUpdate.js | 60 --- lib/models/SubscriptionCreate.js | 48 --- lib/models/SubscriptionToggle.js | 43 -- lib/models/TransactionChargeAuthorization.js | 62 --- lib/models/TransactionCheckAuthorization.js | 48 --- lib/models/TransactionInitialize.js | 66 --- lib/models/TransactionPartialDebit.js | 52 --- lib/models/TransferBulk.js | 45 -- lib/models/TransferFinalize.js | 43 -- lib/models/TransferFinalizeDisableOTP.js | 41 -- lib/models/TransferInitiate.js | 52 --- lib/models/TransferRecipientBulk.js | 42 -- lib/models/TransferRecipientCreate.js | 56 --- lib/models/TransferRecipientUpdate.js | 44 -- lib/models/TransferResendOTP.js | 43 -- lib/models/USSD.js | 42 -- lib/models/VerificationBVNMatch.js | 52 --- lib/models/index.js | 67 --- lib/runtime.js | 106 ----- lib/types/apis/Balance.d.ts | 33 -- lib/types/apis/BulkCharge.d.ts | 60 --- lib/types/apis/Charge.d.ts | 86 ---- lib/types/apis/Customer.d.ts | 94 ---- lib/types/apis/DedicatedVirtualAccount.d.ts | 78 ---- lib/types/apis/Dispute.d.ts | 96 ----- lib/types/apis/Integration.d.ts | 29 -- lib/types/apis/Page.d.ts | 74 ---- lib/types/apis/PaymentRequest.d.ts | 107 ----- lib/types/apis/Plan.d.ts | 66 --- lib/types/apis/Product.d.ts | 68 --- lib/types/apis/Refund.d.ts | 46 -- lib/types/apis/Settlement.d.ts | 33 -- lib/types/apis/Split.d.ts | 79 ---- lib/types/apis/Subaccount.d.ts | 67 --- lib/types/apis/Subscription.d.ts | 77 ---- lib/types/apis/Transaction.d.ts | 147 ------- lib/types/apis/Transfer.d.ts | 105 ----- lib/types/apis/TransferRecipient.d.ts | 72 ---- lib/types/apis/Verification.d.ts | 59 --- lib/types/apis/index.d.ts | 20 - lib/types/index.d.ts | 7 - lib/types/models/Accepted.d.ts | 33 -- lib/types/models/Bank.d.ts | 33 -- lib/types/models/BulkChargeInitiate.d.ts | 33 -- lib/types/models/ChargeCreate.d.ts | 70 --- lib/types/models/ChargeSubmitAddress.d.ts | 51 --- lib/types/models/ChargeSubmitBirthday.d.ts | 33 -- lib/types/models/ChargeSubmitOTP.d.ts | 33 -- lib/types/models/ChargeSubmitPhone.d.ts | 33 -- lib/types/models/ChargeSubmitPin.d.ts | 33 -- lib/types/models/CustomerCreate.d.ts | 51 --- .../CustomerDeactivateAuthorization.d.ts | 27 -- lib/types/models/CustomerRiskAction.d.ts | 34 -- lib/types/models/CustomerUpdate.d.ts | 45 -- lib/types/models/CustomerValidate.d.ts | 51 --- lib/types/models/CustomerValidation.d.ts | 69 --- .../models/DedicatedVirtualAccountCreate.d.ts | 45 -- .../models/DedicatedVirtualAccountSplit.d.ts | 39 -- lib/types/models/DisputeEvidence.d.ts | 57 --- lib/types/models/DisputeResolve.d.ts | 51 --- lib/types/models/DisputeUpdate.d.ts | 33 -- lib/types/models/EFT.d.ts | 27 -- lib/types/models/MobileMoney.d.ts | 33 -- lib/types/models/ModelError.d.ts | 33 -- lib/types/models/PageCreate.d.ts | 63 --- lib/types/models/PageProduct.d.ts | 27 -- lib/types/models/PageUpdate.d.ts | 45 -- lib/types/models/PaymentRequestCreate.d.ts | 96 ----- lib/types/models/PaymentRequestUpdate.d.ts | 96 ----- lib/types/models/PlanCreate.d.ts | 70 --- lib/types/models/PlanUpdate.d.ts | 70 --- lib/types/models/ProductCreate.d.ts | 57 --- lib/types/models/ProductUpdate.d.ts | 57 --- lib/types/models/RefundCreate.d.ts | 52 --- lib/types/models/Response.d.ts | 39 -- lib/types/models/SplitCreate.d.ts | 58 --- lib/types/models/SplitSubaccounts.d.ts | 33 -- lib/types/models/SplitUpdate.d.ts | 45 -- lib/types/models/SubaccountCreate.d.ts | 75 ---- lib/types/models/SubaccountUpdate.d.ts | 81 ---- lib/types/models/SubscriptionCreate.d.ts | 46 -- lib/types/models/SubscriptionToggle.d.ts | 33 -- .../TransactionChargeAuthorization.d.ts | 88 ---- .../models/TransactionCheckAuthorization.d.ts | 45 -- lib/types/models/TransactionInitialize.d.ts | 101 ----- lib/types/models/TransactionPartialDebit.d.ts | 57 --- lib/types/models/TransferBulk.d.ts | 34 -- lib/types/models/TransferFinalize.d.ts | 33 -- .../models/TransferFinalizeDisableOTP.d.ts | 27 -- lib/types/models/TransferInitiate.d.ts | 58 --- lib/types/models/TransferRecipientBulk.d.ts | 29 -- lib/types/models/TransferRecipientCreate.d.ts | 69 --- lib/types/models/TransferRecipientUpdate.d.ts | 33 -- lib/types/models/TransferResendOTP.d.ts | 33 -- lib/types/models/USSD.d.ts | 27 -- lib/types/models/VerificationBVNMatch.d.ts | 57 --- lib/types/models/index.d.ts | 55 --- lib/types/runtime.d.ts | 44 -- package.json | 19 +- src/apis/Plan.ts | 2 +- src/index.ts | 13 +- src/models/PlanCreate.ts | 4 +- src/runtime.ts | 4 +- tsconfig.cjs.json | 7 + tsconfig.esm.json | 8 + tsconfig.json | 7 +- tsconfig.types.json | 8 + 168 files changed, 52 insertions(+), 11164 deletions(-) delete mode 100644 lib/apis/Balance.js delete mode 100644 lib/apis/BulkCharge.js delete mode 100644 lib/apis/Charge.js delete mode 100644 lib/apis/Customer.js delete mode 100644 lib/apis/DedicatedVirtualAccount.js delete mode 100644 lib/apis/Dispute.js delete mode 100644 lib/apis/Integration.js delete mode 100644 lib/apis/Page.js delete mode 100644 lib/apis/PaymentRequest.js delete mode 100644 lib/apis/Plan.js delete mode 100644 lib/apis/Product.js delete mode 100644 lib/apis/Refund.js delete mode 100644 lib/apis/Settlement.js delete mode 100644 lib/apis/Split.js delete mode 100644 lib/apis/Subaccount.js delete mode 100644 lib/apis/Subscription.js delete mode 100644 lib/apis/Transaction.js delete mode 100644 lib/apis/Transfer.js delete mode 100644 lib/apis/TransferRecipient.js delete mode 100644 lib/apis/Verification.js delete mode 100644 lib/apis/index.js delete mode 100644 lib/index.js delete mode 100644 lib/models/Accepted.js delete mode 100644 lib/models/Bank.js delete mode 100644 lib/models/BulkChargeInitiate.js delete mode 100644 lib/models/ChargeCreate.js delete mode 100644 lib/models/ChargeSubmitAddress.js delete mode 100644 lib/models/ChargeSubmitBirthday.js delete mode 100644 lib/models/ChargeSubmitOTP.js delete mode 100644 lib/models/ChargeSubmitPhone.js delete mode 100644 lib/models/ChargeSubmitPin.js delete mode 100644 lib/models/CustomerCreate.js delete mode 100644 lib/models/CustomerDeactivateAuthorization.js delete mode 100644 lib/models/CustomerRiskAction.js delete mode 100644 lib/models/CustomerUpdate.js delete mode 100644 lib/models/CustomerValidate.js delete mode 100644 lib/models/CustomerValidation.js delete mode 100644 lib/models/DedicatedVirtualAccountCreate.js delete mode 100644 lib/models/DedicatedVirtualAccountSplit.js delete mode 100644 lib/models/DisputeEvidence.js delete mode 100644 lib/models/DisputeResolve.js delete mode 100644 lib/models/DisputeUpdate.js delete mode 100644 lib/models/EFT.js delete mode 100644 lib/models/MobileMoney.js delete mode 100644 lib/models/ModelError.js delete mode 100644 lib/models/PageCreate.js delete mode 100644 lib/models/PageProduct.js delete mode 100644 lib/models/PageUpdate.js delete mode 100644 lib/models/PaymentRequestCreate.js delete mode 100644 lib/models/PaymentRequestUpdate.js delete mode 100644 lib/models/PlanCreate.js delete mode 100644 lib/models/PlanUpdate.js delete mode 100644 lib/models/ProductCreate.js delete mode 100644 lib/models/ProductUpdate.js delete mode 100644 lib/models/RefundCreate.js delete mode 100644 lib/models/Response.js delete mode 100644 lib/models/SplitCreate.js delete mode 100644 lib/models/SplitSubaccounts.js delete mode 100644 lib/models/SplitUpdate.js delete mode 100644 lib/models/SubaccountCreate.js delete mode 100644 lib/models/SubaccountUpdate.js delete mode 100644 lib/models/SubscriptionCreate.js delete mode 100644 lib/models/SubscriptionToggle.js delete mode 100644 lib/models/TransactionChargeAuthorization.js delete mode 100644 lib/models/TransactionCheckAuthorization.js delete mode 100644 lib/models/TransactionInitialize.js delete mode 100644 lib/models/TransactionPartialDebit.js delete mode 100644 lib/models/TransferBulk.js delete mode 100644 lib/models/TransferFinalize.js delete mode 100644 lib/models/TransferFinalizeDisableOTP.js delete mode 100644 lib/models/TransferInitiate.js delete mode 100644 lib/models/TransferRecipientBulk.js delete mode 100644 lib/models/TransferRecipientCreate.js delete mode 100644 lib/models/TransferRecipientUpdate.js delete mode 100644 lib/models/TransferResendOTP.js delete mode 100644 lib/models/USSD.js delete mode 100644 lib/models/VerificationBVNMatch.js delete mode 100644 lib/models/index.js delete mode 100644 lib/runtime.js delete mode 100644 lib/types/apis/Balance.d.ts delete mode 100644 lib/types/apis/BulkCharge.d.ts delete mode 100644 lib/types/apis/Charge.d.ts delete mode 100644 lib/types/apis/Customer.d.ts delete mode 100644 lib/types/apis/DedicatedVirtualAccount.d.ts delete mode 100644 lib/types/apis/Dispute.d.ts delete mode 100644 lib/types/apis/Integration.d.ts delete mode 100644 lib/types/apis/Page.d.ts delete mode 100644 lib/types/apis/PaymentRequest.d.ts delete mode 100644 lib/types/apis/Plan.d.ts delete mode 100644 lib/types/apis/Product.d.ts delete mode 100644 lib/types/apis/Refund.d.ts delete mode 100644 lib/types/apis/Settlement.d.ts delete mode 100644 lib/types/apis/Split.d.ts delete mode 100644 lib/types/apis/Subaccount.d.ts delete mode 100644 lib/types/apis/Subscription.d.ts delete mode 100644 lib/types/apis/Transaction.d.ts delete mode 100644 lib/types/apis/Transfer.d.ts delete mode 100644 lib/types/apis/TransferRecipient.d.ts delete mode 100644 lib/types/apis/Verification.d.ts delete mode 100644 lib/types/apis/index.d.ts delete mode 100644 lib/types/index.d.ts delete mode 100644 lib/types/models/Accepted.d.ts delete mode 100644 lib/types/models/Bank.d.ts delete mode 100644 lib/types/models/BulkChargeInitiate.d.ts delete mode 100644 lib/types/models/ChargeCreate.d.ts delete mode 100644 lib/types/models/ChargeSubmitAddress.d.ts delete mode 100644 lib/types/models/ChargeSubmitBirthday.d.ts delete mode 100644 lib/types/models/ChargeSubmitOTP.d.ts delete mode 100644 lib/types/models/ChargeSubmitPhone.d.ts delete mode 100644 lib/types/models/ChargeSubmitPin.d.ts delete mode 100644 lib/types/models/CustomerCreate.d.ts delete mode 100644 lib/types/models/CustomerDeactivateAuthorization.d.ts delete mode 100644 lib/types/models/CustomerRiskAction.d.ts delete mode 100644 lib/types/models/CustomerUpdate.d.ts delete mode 100644 lib/types/models/CustomerValidate.d.ts delete mode 100644 lib/types/models/CustomerValidation.d.ts delete mode 100644 lib/types/models/DedicatedVirtualAccountCreate.d.ts delete mode 100644 lib/types/models/DedicatedVirtualAccountSplit.d.ts delete mode 100644 lib/types/models/DisputeEvidence.d.ts delete mode 100644 lib/types/models/DisputeResolve.d.ts delete mode 100644 lib/types/models/DisputeUpdate.d.ts delete mode 100644 lib/types/models/EFT.d.ts delete mode 100644 lib/types/models/MobileMoney.d.ts delete mode 100644 lib/types/models/ModelError.d.ts delete mode 100644 lib/types/models/PageCreate.d.ts delete mode 100644 lib/types/models/PageProduct.d.ts delete mode 100644 lib/types/models/PageUpdate.d.ts delete mode 100644 lib/types/models/PaymentRequestCreate.d.ts delete mode 100644 lib/types/models/PaymentRequestUpdate.d.ts delete mode 100644 lib/types/models/PlanCreate.d.ts delete mode 100644 lib/types/models/PlanUpdate.d.ts delete mode 100644 lib/types/models/ProductCreate.d.ts delete mode 100644 lib/types/models/ProductUpdate.d.ts delete mode 100644 lib/types/models/RefundCreate.d.ts delete mode 100644 lib/types/models/Response.d.ts delete mode 100644 lib/types/models/SplitCreate.d.ts delete mode 100644 lib/types/models/SplitSubaccounts.d.ts delete mode 100644 lib/types/models/SplitUpdate.d.ts delete mode 100644 lib/types/models/SubaccountCreate.d.ts delete mode 100644 lib/types/models/SubaccountUpdate.d.ts delete mode 100644 lib/types/models/SubscriptionCreate.d.ts delete mode 100644 lib/types/models/SubscriptionToggle.d.ts delete mode 100644 lib/types/models/TransactionChargeAuthorization.d.ts delete mode 100644 lib/types/models/TransactionCheckAuthorization.d.ts delete mode 100644 lib/types/models/TransactionInitialize.d.ts delete mode 100644 lib/types/models/TransactionPartialDebit.d.ts delete mode 100644 lib/types/models/TransferBulk.d.ts delete mode 100644 lib/types/models/TransferFinalize.d.ts delete mode 100644 lib/types/models/TransferFinalizeDisableOTP.d.ts delete mode 100644 lib/types/models/TransferInitiate.d.ts delete mode 100644 lib/types/models/TransferRecipientBulk.d.ts delete mode 100644 lib/types/models/TransferRecipientCreate.d.ts delete mode 100644 lib/types/models/TransferRecipientUpdate.d.ts delete mode 100644 lib/types/models/TransferResendOTP.d.ts delete mode 100644 lib/types/models/USSD.d.ts delete mode 100644 lib/types/models/VerificationBVNMatch.d.ts delete mode 100644 lib/types/models/index.d.ts delete mode 100644 lib/types/runtime.d.ts create mode 100644 tsconfig.cjs.json create mode 100644 tsconfig.esm.json create mode 100644 tsconfig.types.json diff --git a/.openapi-generator/FILES b/.openapi-generator/FILES index 34c768f..9b62513 100644 --- a/.openapi-generator/FILES +++ b/.openapi-generator/FILES @@ -81,4 +81,7 @@ src/models/USSD.ts src/models/VerificationBVNMatch.ts src/models/index.ts src/runtime.ts +tsconfig.cjs.json +tsconfig.esm.json tsconfig.json +tsconfig.types.json diff --git a/lib/apis/Balance.js b/lib/apis/Balance.js deleted file mode 100644 index f72ed8f..0000000 --- a/lib/apis/Balance.js +++ /dev/null @@ -1,74 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Balance = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Balance extends runtime_1.BaseAPI { - /** - * You can only transfer from what you have - * Fetch Balance - */ - fetch() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/balance`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Balance Ledger - */ - ledger(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/balance/ledger`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Balance = Balance; diff --git a/lib/apis/BulkCharge.js b/lib/apis/BulkCharge.js deleted file mode 100644 index 968f8b1..0000000 --- a/lib/apis/BulkCharge.js +++ /dev/null @@ -1,141 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.BulkCharge = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class BulkCharge extends runtime_1.BaseAPI { - /** - * Fetch Charges in a Batch - */ - charges(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling charges.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/bulkcharge/{code}/charges`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Bulk Charge Batch - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/bulkcharge/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Initiate Bulk Charge - */ - initiate() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/bulkcharge`, - method: 'POST', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Bulk Charge Batches - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/bulkcharge`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Pause Bulk Charge Batch - */ - pause(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling pause.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/bulkcharge/pause/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Resume Bulk Charge Batch - */ - resume(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling resume.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/bulkcharge/resume/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.BulkCharge = BulkCharge; diff --git a/lib/apis/Charge.js b/lib/apis/Charge.js deleted file mode 100644 index ff993d8..0000000 --- a/lib/apis/Charge.js +++ /dev/null @@ -1,260 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Charge = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Charge extends runtime_1.BaseAPI { - /** - * Check pending charge - */ - check(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling check.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/charge/{reference}`.replace(`{${"reference"}}`, encodeURIComponent(String(requestParameters.reference))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create Charge - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - let formParams = {}; - if (requestParameters.email !== undefined) { - formParams['email'] = requestParameters.email; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.authorization_code !== undefined) { - formParams['authorization_code'] = requestParameters.authorization_code; - } - if (requestParameters.pin !== undefined) { - formParams['pin'] = requestParameters.pin; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - if (requestParameters.birthday !== undefined) { - formParams['birthday'] = requestParameters.birthday; - } - if (requestParameters.device_id !== undefined) { - formParams['device_id'] = requestParameters.device_id; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - if (requestParameters.bank !== undefined) { - formParams['bank'] = requestParameters.bank; - } - if (requestParameters.mobile_money !== undefined) { - formParams['mobile_money'] = requestParameters.mobile_money; - } - if (requestParameters.ussd !== undefined) { - formParams['ussd'] = requestParameters.ussd; - } - if (requestParameters.eft !== undefined) { - formParams['eft'] = requestParameters.eft; - } - const response = yield this.request({ - path: `/charge`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Submit Address - */ - submitAddress(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.address === null || requestParameters.address === undefined) { - throw new runtime_1.RequiredError('address', 'Required parameter address was null or undefined when calling submitAddress.'); - } - if (requestParameters.city === null || requestParameters.city === undefined) { - throw new runtime_1.RequiredError('city', 'Required parameter city was null or undefined when calling submitAddress.'); - } - if (requestParameters.state === null || requestParameters.state === undefined) { - throw new runtime_1.RequiredError('state', 'Required parameter state was null or undefined when calling submitAddress.'); - } - if (requestParameters.zipcode === null || requestParameters.zipcode === undefined) { - throw new runtime_1.RequiredError('zipcode', 'Required parameter zipcode was null or undefined when calling submitAddress.'); - } - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling submitAddress.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.address !== undefined) { - formParams['address'] = requestParameters.address; - } - if (requestParameters.city !== undefined) { - formParams['city'] = requestParameters.city; - } - if (requestParameters.state !== undefined) { - formParams['state'] = requestParameters.state; - } - if (requestParameters.zipcode !== undefined) { - formParams['zipcode'] = requestParameters.zipcode; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - const response = yield this.request({ - path: `/charge/submit_address`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Submit Birthday - */ - submitBirthday(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.birthday === null || requestParameters.birthday === undefined) { - throw new runtime_1.RequiredError('birthday', 'Required parameter birthday was null or undefined when calling submitBirthday.'); - } - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling submitBirthday.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.birthday !== undefined) { - formParams['birthday'] = requestParameters.birthday; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - const response = yield this.request({ - path: `/charge/submit_birthday`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Submit OTP - */ - submitOtp(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.otp === null || requestParameters.otp === undefined) { - throw new runtime_1.RequiredError('otp', 'Required parameter otp was null or undefined when calling submitOtp.'); - } - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling submitOtp.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.otp !== undefined) { - formParams['otp'] = requestParameters.otp; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - const response = yield this.request({ - path: `/charge/submit_otp`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Submit Phone - */ - submitPhone(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.phone === null || requestParameters.phone === undefined) { - throw new runtime_1.RequiredError('phone', 'Required parameter phone was null or undefined when calling submitPhone.'); - } - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling submitPhone.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.phone !== undefined) { - formParams['phone'] = requestParameters.phone; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - const response = yield this.request({ - path: `/charge/submit_phone`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Submit PIN - */ - submitPin(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.pin === null || requestParameters.pin === undefined) { - throw new runtime_1.RequiredError('pin', 'Required parameter pin was null or undefined when calling submitPin.'); - } - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling submitPin.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.pin !== undefined) { - formParams['pin'] = requestParameters.pin; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - const response = yield this.request({ - path: `/charge/submit_pin`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Charge = Charge; diff --git a/lib/apis/Customer.js b/lib/apis/Customer.js deleted file mode 100644 index a9b06a3..0000000 --- a/lib/apis/Customer.js +++ /dev/null @@ -1,265 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Customer = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Customer extends runtime_1.BaseAPI { - /** - * Create Customer - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.email === null || requestParameters.email === undefined) { - throw new runtime_1.RequiredError('email', 'Required parameter email was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.email !== undefined) { - formParams['email'] = requestParameters.email; - } - if (requestParameters.first_name !== undefined) { - formParams['first_name'] = requestParameters.first_name; - } - if (requestParameters.last_name !== undefined) { - formParams['last_name'] = requestParameters.last_name; - } - if (requestParameters.phone !== undefined) { - formParams['phone'] = requestParameters.phone; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - const response = yield this.request({ - path: `/customer`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Deactivate a customer\'s card - * Deactivate Authorization - */ - deactivateAuthorization(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.authorization_code === null || requestParameters.authorization_code === undefined) { - throw new runtime_1.RequiredError('authorization_code', 'Required parameter authorization_code was null or undefined when calling deactivateAuthorization.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.authorization_code !== undefined) { - formParams['authorization_code'] = requestParameters.authorization_code; - } - const response = yield this.request({ - path: `/customer/deactivate_authorization`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Customer - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/customer/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List customers on your integration - * List Customers - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.use_cursor !== undefined) { - queryParameters['use_cursor'] = requestParameters.use_cursor; - } - if (requestParameters.next !== undefined) { - queryParameters['next'] = requestParameters.next; - } - if (requestParameters.previous !== undefined) { - queryParameters['previous'] = requestParameters.previous; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from; - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to; - } - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - const response = yield this.request({ - path: `/customer`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Set customer\'s risk action by whitelisting or blacklisting the customer - * White/blacklist Customer - */ - riskAction(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.customer === null || requestParameters.customer === undefined) { - throw new runtime_1.RequiredError('customer', 'Required parameter customer was null or undefined when calling riskAction.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.customer !== undefined) { - formParams['customer'] = requestParameters.customer; - } - if (requestParameters.risk_action !== undefined) { - formParams['risk_action'] = requestParameters.risk_action; - } - const response = yield this.request({ - path: `/customer/set_risk_action`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Customer - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.first_name !== undefined) { - formParams['first_name'] = requestParameters.first_name; - } - if (requestParameters.last_name !== undefined) { - formParams['last_name'] = requestParameters.last_name; - } - if (requestParameters.phone !== undefined) { - formParams['phone'] = requestParameters.phone; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - const response = yield this.request({ - path: `/customer/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Validate a customer\'s identity - * Validate Customer - */ - validate(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling validate.'); - } - if (requestParameters.first_name === null || requestParameters.first_name === undefined) { - throw new runtime_1.RequiredError('first_name', 'Required parameter first_name was null or undefined when calling validate.'); - } - if (requestParameters.last_name === null || requestParameters.last_name === undefined) { - throw new runtime_1.RequiredError('last_name', 'Required parameter last_name was null or undefined when calling validate.'); - } - if (requestParameters.type === null || requestParameters.type === undefined) { - throw new runtime_1.RequiredError('type', 'Required parameter type was null or undefined when calling validate.'); - } - if (requestParameters.country === null || requestParameters.country === undefined) { - throw new runtime_1.RequiredError('country', 'Required parameter country was null or undefined when calling validate.'); - } - if (requestParameters.bvn === null || requestParameters.bvn === undefined) { - throw new runtime_1.RequiredError('bvn', 'Required parameter bvn was null or undefined when calling validate.'); - } - if (requestParameters.bank_code === null || requestParameters.bank_code === undefined) { - throw new runtime_1.RequiredError('bank_code', 'Required parameter bank_code was null or undefined when calling validate.'); - } - if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling validate.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.first_name !== undefined) { - formParams['first_name'] = requestParameters.first_name; - } - if (requestParameters.last_name !== undefined) { - formParams['last_name'] = requestParameters.last_name; - } - if (requestParameters.type !== undefined) { - formParams['type'] = requestParameters.type; - } - if (requestParameters.country !== undefined) { - formParams['country'] = requestParameters.country; - } - if (requestParameters.bvn !== undefined) { - formParams['bvn'] = requestParameters.bvn; - } - if (requestParameters.bank_code !== undefined) { - formParams['bank_code'] = requestParameters.bank_code; - } - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - if (requestParameters.value !== undefined) { - formParams['value'] = requestParameters.value; - } - const response = yield this.request({ - path: `/customer/{code}/identification`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Customer = Customer; diff --git a/lib/apis/DedicatedVirtualAccount.js b/lib/apis/DedicatedVirtualAccount.js deleted file mode 100644 index 755c1ea..0000000 --- a/lib/apis/DedicatedVirtualAccount.js +++ /dev/null @@ -1,206 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.DedicatedVirtualAccount = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class DedicatedVirtualAccount extends runtime_1.BaseAPI { - /** - * Split Dedicated Account Transaction - */ - addSplit(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling addSplit.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - if (requestParameters.subaccount !== undefined) { - formParams['subaccount'] = requestParameters.subaccount; - } - if (requestParameters.split_code !== undefined) { - formParams['split_code'] = requestParameters.split_code; - } - const response = yield this.request({ - path: `/dedicated_account/split`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Bank Providers - */ - availableProviders() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/dedicated_account/available_providers`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create Dedicated Account - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.customer === null || requestParameters.customer === undefined) { - throw new runtime_1.RequiredError('customer', 'Required parameter customer was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.customer !== undefined) { - formParams['customer'] = requestParameters.customer; - } - if (requestParameters.preferred_bank !== undefined) { - formParams['preferred_bank'] = requestParameters.preferred_bank; - } - if (requestParameters.subaccount !== undefined) { - formParams['subaccount'] = requestParameters.subaccount; - } - if (requestParameters.split_code !== undefined) { - formParams['split_code'] = requestParameters.split_code; - } - const response = yield this.request({ - path: `/dedicated_account`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Deactivate Dedicated Account - */ - deactivate(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.account_id === null || requestParameters.account_id === undefined) { - throw new runtime_1.RequiredError('account_id', 'Required parameter account_id was null or undefined when calling deactivate.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/dedicated_account/{account_id}`.replace(`{${"account_id"}}`, encodeURIComponent(String(requestParameters.account_id))), - method: 'DELETE', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Dedicated Account - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.account_id === null || requestParameters.account_id === undefined) { - throw new runtime_1.RequiredError('account_id', 'Required parameter account_id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/dedicated_account/{account_id}`.replace(`{${"account_id"}}`, encodeURIComponent(String(requestParameters.account_id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Dedicated Accounts - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.account_number !== undefined) { - queryParameters['account_number'] = requestParameters.account_number; - } - if (requestParameters.customer !== undefined) { - queryParameters['customer'] = requestParameters.customer; - } - if (requestParameters.active !== undefined) { - queryParameters['active'] = requestParameters.active; - } - if (requestParameters.currency !== undefined) { - queryParameters['currency'] = requestParameters.currency; - } - if (requestParameters.provider_slug !== undefined) { - queryParameters['provider_slug'] = requestParameters.provider_slug; - } - if (requestParameters.bank_id !== undefined) { - queryParameters['bank_id'] = requestParameters.bank_id; - } - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - const response = yield this.request({ - path: `/dedicated_account`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Remove Split from Dedicated Account - */ - removeSplit(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling removeSplit.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - if (requestParameters.subaccount !== undefined) { - formParams['subaccount'] = requestParameters.subaccount; - } - if (requestParameters.split_code !== undefined) { - formParams['split_code'] = requestParameters.split_code; - } - const response = yield this.request({ - path: `/dedicated_account/split`, - method: 'DELETE', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.DedicatedVirtualAccount = DedicatedVirtualAccount; diff --git a/lib/apis/Dispute.js b/lib/apis/Dispute.js deleted file mode 100644 index 96c2e65..0000000 --- a/lib/apis/Dispute.js +++ /dev/null @@ -1,268 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Dispute = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Dispute extends runtime_1.BaseAPI { - /** - * Export Disputes - */ - download(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.status !== undefined) { - queryParameters['status'] = requestParameters.status; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/dispute/export`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Add Evidence - */ - evidence(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling evidence.'); - } - if (requestParameters.customer_email === null || requestParameters.customer_email === undefined) { - throw new runtime_1.RequiredError('customer_email', 'Required parameter customer_email was null or undefined when calling evidence.'); - } - if (requestParameters.customer_name === null || requestParameters.customer_name === undefined) { - throw new runtime_1.RequiredError('customer_name', 'Required parameter customer_name was null or undefined when calling evidence.'); - } - if (requestParameters.customer_phone === null || requestParameters.customer_phone === undefined) { - throw new runtime_1.RequiredError('customer_phone', 'Required parameter customer_phone was null or undefined when calling evidence.'); - } - if (requestParameters.service_details === null || requestParameters.service_details === undefined) { - throw new runtime_1.RequiredError('service_details', 'Required parameter service_details was null or undefined when calling evidence.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.customer_email !== undefined) { - formParams['customer_email'] = requestParameters.customer_email; - } - if (requestParameters.customer_name !== undefined) { - formParams['customer_name'] = requestParameters.customer_name; - } - if (requestParameters.customer_phone !== undefined) { - formParams['customer_phone'] = requestParameters.customer_phone; - } - if (requestParameters.service_details !== undefined) { - formParams['service_details'] = requestParameters.service_details; - } - if (requestParameters.delivery_address !== undefined) { - formParams['delivery_address'] = requestParameters.delivery_address; - } - if (requestParameters.delivery_date !== undefined) { - formParams['delivery_date'] = requestParameters.delivery_date; - } - const response = yield this.request({ - path: `/dispute/{id}/evidence`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Dispute - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/dispute/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Disputes - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.status !== undefined) { - queryParameters['status'] = requestParameters.status; - } - if (requestParameters.transaction !== undefined) { - queryParameters['transaction'] = requestParameters.transaction; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/dispute`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Resolve a Dispute - */ - resolve(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling resolve.'); - } - if (requestParameters.resolution === null || requestParameters.resolution === undefined) { - throw new runtime_1.RequiredError('resolution', 'Required parameter resolution was null or undefined when calling resolve.'); - } - if (requestParameters.message === null || requestParameters.message === undefined) { - throw new runtime_1.RequiredError('message', 'Required parameter message was null or undefined when calling resolve.'); - } - if (requestParameters.refund_amount === null || requestParameters.refund_amount === undefined) { - throw new runtime_1.RequiredError('refund_amount', 'Required parameter refund_amount was null or undefined when calling resolve.'); - } - if (requestParameters.uploaded_filename === null || requestParameters.uploaded_filename === undefined) { - throw new runtime_1.RequiredError('uploaded_filename', 'Required parameter uploaded_filename was null or undefined when calling resolve.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.resolution !== undefined) { - formParams['resolution'] = requestParameters.resolution; - } - if (requestParameters.message !== undefined) { - formParams['message'] = requestParameters.message; - } - if (requestParameters.refund_amount !== undefined) { - formParams['refund_amount'] = requestParameters.refund_amount; - } - if (requestParameters.uploaded_filename !== undefined) { - formParams['uploaded_filename'] = requestParameters.uploaded_filename; - } - if (requestParameters.evidence !== undefined) { - formParams['evidence'] = requestParameters.evidence; - } - const response = yield this.request({ - path: `/dispute/{id}/resolve`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Transaction Disputes - */ - transaction(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling transaction.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/dispute/transaction/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Dispute - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling update.'); - } - if (requestParameters.refund_amount === null || requestParameters.refund_amount === undefined) { - throw new runtime_1.RequiredError('refund_amount', 'Required parameter refund_amount was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.refund_amount !== undefined) { - formParams['refund_amount'] = requestParameters.refund_amount; - } - if (requestParameters.uploaded_filename !== undefined) { - formParams['uploaded_filename'] = requestParameters.uploaded_filename; - } - const response = yield this.request({ - path: `/dispute/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Get Upload URL - */ - uploadUrl(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling uploadUrl.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/dispute/{id}/upload_url`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Dispute = Dispute; diff --git a/lib/apis/Integration.js b/lib/apis/Integration.js deleted file mode 100644 index 100a688..0000000 --- a/lib/apis/Integration.js +++ /dev/null @@ -1,62 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Integration = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Integration extends runtime_1.BaseAPI { - /** - * Fetch Payment Session Timeout - */ - fetchPaymentSessionTimeout() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/integration/payment_session_timeout`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Payment Session Timeout - */ - updatePaymentSessionTimeout(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/integration/payment_session_timeout`, - method: 'PUT', - query: queryParameters, - body: requestParameters.body, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Integration = Integration; diff --git a/lib/apis/Page.js b/lib/apis/Page.js deleted file mode 100644 index 4b6aedf..0000000 --- a/lib/apis/Page.js +++ /dev/null @@ -1,189 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Page = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Page extends runtime_1.BaseAPI { - /** - * Add Products - */ - addProducts(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling addProducts.'); - } - if (requestParameters.product === null || requestParameters.product === undefined) { - throw new runtime_1.RequiredError('product', 'Required parameter product was null or undefined when calling addProducts.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.product) { - formParams['product'] = requestParameters.product; - } - const response = yield this.request({ - path: `/page/{id}/product`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Check Slug Availability - */ - checkSlugAvailability(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.slug === null || requestParameters.slug === undefined) { - throw new runtime_1.RequiredError('slug', 'Required parameter slug was null or undefined when calling checkSlugAvailability.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/page/check_slug_availability/{slug}`.replace(`{${"slug"}}`, encodeURIComponent(String(requestParameters.slug))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create Page - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.name === null || requestParameters.name === undefined) { - throw new runtime_1.RequiredError('name', 'Required parameter name was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.slug !== undefined) { - formParams['slug'] = requestParameters.slug; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - if (requestParameters.redirect_url !== undefined) { - formParams['redirect_url'] = requestParameters.redirect_url; - } - if (requestParameters.custom_fields) { - formParams['custom_fields'] = requestParameters.custom_fields; - } - const response = yield this.request({ - path: `/page`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Page - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/page/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Pages - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/page`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Page - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.active !== undefined) { - formParams['active'] = requestParameters.active; - } - const response = yield this.request({ - path: `/page/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Page = Page; diff --git a/lib/apis/PaymentRequest.js b/lib/apis/PaymentRequest.js deleted file mode 100644 index ae4061a..0000000 --- a/lib/apis/PaymentRequest.js +++ /dev/null @@ -1,277 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PaymentRequest = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class PaymentRequest extends runtime_1.BaseAPI { - /** - * Archive Payment Request - */ - archive(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling archive.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/paymentrequest/archive/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create Payment Request - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.customer === null || requestParameters.customer === undefined) { - throw new runtime_1.RequiredError('customer', 'Required parameter customer was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.customer !== undefined) { - formParams['customer'] = requestParameters.customer; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.due_date !== undefined) { - formParams['due_date'] = requestParameters.due_date; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.line_items) { - formParams['line_items'] = requestParameters.line_items; - } - if (requestParameters.tax) { - formParams['tax'] = requestParameters.tax; - } - if (requestParameters.send_notification) { - formParams['send_notification'] = requestParameters.send_notification; - } - if (requestParameters.draft) { - formParams['draft'] = requestParameters.draft; - } - if (requestParameters.has_invoice) { - formParams['has_invoice'] = requestParameters.has_invoice; - } - if (requestParameters.invoice_number !== undefined) { - formParams['invoice_number'] = requestParameters.invoice_number; - } - if (requestParameters.split_code !== undefined) { - formParams['split_code'] = requestParameters.split_code; - } - const response = yield this.request({ - path: `/paymentrequest`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Payment Request - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/paymentrequest/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Finalize Payment Request - */ - finalize(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling finalize.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/paymentrequest/finalize/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Payment Request - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.customer !== undefined) { - queryParameters['customer'] = requestParameters.customer; - } - if (requestParameters.status !== undefined) { - queryParameters['status'] = requestParameters.status; - } - if (requestParameters.currency !== undefined) { - queryParameters['currency'] = requestParameters.currency; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/paymentrequest`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Send Notification - */ - notify(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling notify.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/paymentrequest/notify/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Payment Request Total - */ - totals() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/paymentrequest/totals`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Payment Request - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.customer !== undefined) { - formParams['customer'] = requestParameters.customer; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.due_date !== undefined) { - formParams['due_date'] = requestParameters.due_date; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.line_items) { - formParams['line_items'] = requestParameters.line_items; - } - if (requestParameters.tax) { - formParams['tax'] = requestParameters.tax; - } - if (requestParameters.send_notification) { - formParams['send_notification'] = requestParameters.send_notification; - } - if (requestParameters.draft) { - formParams['draft'] = requestParameters.draft; - } - if (requestParameters.has_invoice) { - formParams['has_invoice'] = requestParameters.has_invoice; - } - if (requestParameters.invoice_number !== undefined) { - formParams['invoice_number'] = requestParameters.invoice_number; - } - if (requestParameters.split_code !== undefined) { - formParams['split_code'] = requestParameters.split_code; - } - const response = yield this.request({ - path: `/paymentrequest/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Verify Payment Request - */ - verify(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling verify.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/paymentrequest/verify/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.PaymentRequest = PaymentRequest; diff --git a/lib/apis/Plan.js b/lib/apis/Plan.js deleted file mode 100644 index 39d7cde..0000000 --- a/lib/apis/Plan.js +++ /dev/null @@ -1,174 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Plan = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Plan extends runtime_1.BaseAPI { - /** - * Create Plan - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.name === null || requestParameters.name === undefined) { - throw new runtime_1.RequiredError('name', 'Required parameter name was null or undefined when calling create.'); - } - if (requestParameters.amount === null || requestParameters.amount === undefined) { - throw new runtime_1.RequiredError('amount', 'Required parameter amount was null or undefined when calling create.'); - } - if (requestParameters.interval === null || requestParameters.interval === undefined) { - throw new runtime_1.RequiredError('interval', 'Required parameter interval was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.interval !== undefined) { - formParams['interval'] = requestParameters.interval; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.send_invoices !== undefined) { - formParams['send_invoices'] = requestParameters.send_invoices; - } - if (requestParameters.send_sms !== undefined) { - formParams['send_sms'] = requestParameters.send_sms; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.invoice_limit !== undefined) { - formParams['invoice_limit'] = requestParameters.invoice_limit; - } - const response = yield this.request({ - path: `/plan`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Plan - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/plan/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Plans - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.interval !== undefined) { - queryParameters['interval'] = requestParameters.interval; - } - if (requestParameters.amount !== undefined) { - queryParameters['amount'] = requestParameters.amount; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/plan`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Plan - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.interval !== undefined) { - formParams['interval'] = requestParameters.interval; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.send_invoices !== undefined) { - formParams['send_invoices'] = requestParameters.send_invoices; - } - if (requestParameters.send_sms !== undefined) { - formParams['send_sms'] = requestParameters.send_sms; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.invoice_limit !== undefined) { - formParams['invoice_limit'] = requestParameters.invoice_limit; - } - const response = yield this.request({ - path: `/plan/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Plan = Plan; diff --git a/lib/apis/Product.js b/lib/apis/Product.js deleted file mode 100644 index 8ea2e73..0000000 --- a/lib/apis/Product.js +++ /dev/null @@ -1,179 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Product = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Product extends runtime_1.BaseAPI { - /** - * Delete Product - */ - _delete(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling _delete.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/product/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create Product - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.name === null || requestParameters.name === undefined) { - throw new runtime_1.RequiredError('name', 'Required parameter name was null or undefined when calling create.'); - } - if (requestParameters.description === null || requestParameters.description === undefined) { - throw new runtime_1.RequiredError('description', 'Required parameter description was null or undefined when calling create.'); - } - if (requestParameters.price === null || requestParameters.price === undefined) { - throw new runtime_1.RequiredError('price', 'Required parameter price was null or undefined when calling create.'); - } - if (requestParameters.currency === null || requestParameters.currency === undefined) { - throw new runtime_1.RequiredError('currency', 'Required parameter currency was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.price !== undefined) { - formParams['price'] = requestParameters.price; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.limited !== undefined) { - formParams['limited'] = requestParameters.limited; - } - if (requestParameters.quantity !== undefined) { - formParams['quantity'] = requestParameters.quantity; - } - const response = yield this.request({ - path: `/product`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Product - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/product/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Products - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.active !== undefined) { - queryParameters['active'] = requestParameters.active; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/product`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update product - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.price !== undefined) { - formParams['price'] = requestParameters.price; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.limited !== undefined) { - formParams['limited'] = requestParameters.limited; - } - if (requestParameters.quantity !== undefined) { - formParams['quantity'] = requestParameters.quantity; - } - const response = yield this.request({ - path: `/product/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Product = Product; diff --git a/lib/apis/Refund.js b/lib/apis/Refund.js deleted file mode 100644 index ebed95a..0000000 --- a/lib/apis/Refund.js +++ /dev/null @@ -1,110 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Refund = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Refund extends runtime_1.BaseAPI { - /** - * Create Refund - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.transaction === null || requestParameters.transaction === undefined) { - throw new runtime_1.RequiredError('transaction', 'Required parameter transaction was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.transaction !== undefined) { - formParams['transaction'] = requestParameters.transaction; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.customer_note !== undefined) { - formParams['customer_note'] = requestParameters.customer_note; - } - if (requestParameters.merchant_note !== undefined) { - formParams['merchant_note'] = requestParameters.merchant_note; - } - const response = yield this.request({ - path: `/refund`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Refund - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/refund/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Refunds - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/refund`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Refund = Refund; diff --git a/lib/apis/Settlement.js b/lib/apis/Settlement.js deleted file mode 100644 index c2ee64b..0000000 --- a/lib/apis/Settlement.js +++ /dev/null @@ -1,70 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Settlement = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Settlement extends runtime_1.BaseAPI { - /** - * Fetch Settlements - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - const response = yield this.request({ - path: `/settlement`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Settlement Transactions - */ - transaction(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling transaction.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/settlement/{id}/transaction`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Settlement = Settlement; diff --git a/lib/apis/Split.js b/lib/apis/Split.js deleted file mode 100644 index 1813c6d..0000000 --- a/lib/apis/Split.js +++ /dev/null @@ -1,212 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Split = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Split extends runtime_1.BaseAPI { - /** - * Add Subaccount to Split - */ - addSubaccount(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling addSubaccount.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.subaccount !== undefined) { - formParams['subaccount'] = requestParameters.subaccount; - } - if (requestParameters.share !== undefined) { - formParams['share'] = requestParameters.share; - } - const response = yield this.request({ - path: `/split/{id}/subaccount/add`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create Split - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.name === null || requestParameters.name === undefined) { - throw new runtime_1.RequiredError('name', 'Required parameter name was null or undefined when calling create.'); - } - if (requestParameters.type === null || requestParameters.type === undefined) { - throw new runtime_1.RequiredError('type', 'Required parameter type was null or undefined when calling create.'); - } - if (requestParameters.subaccounts === null || requestParameters.subaccounts === undefined) { - throw new runtime_1.RequiredError('subaccounts', 'Required parameter subaccounts was null or undefined when calling create.'); - } - if (requestParameters.currency === null || requestParameters.currency === undefined) { - throw new runtime_1.RequiredError('currency', 'Required parameter currency was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.type !== undefined) { - formParams['type'] = requestParameters.type; - } - if (requestParameters.subaccounts) { - formParams['subaccounts'] = requestParameters.subaccounts; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.bearer_type !== undefined) { - formParams['bearer_type'] = requestParameters.bearer_type; - } - if (requestParameters.bearer_subaccount !== undefined) { - formParams['bearer_subaccount'] = requestParameters.bearer_subaccount; - } - const response = yield this.request({ - path: `/split`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Split - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/split/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List/Search Splits - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.name !== undefined) { - queryParameters['name'] = requestParameters.name; - } - if (requestParameters.active !== undefined) { - queryParameters['active'] = requestParameters.active; - } - if (requestParameters.sort_by !== undefined) { - queryParameters['sort_by'] = requestParameters.sort_by; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from; - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to; - } - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - const response = yield this.request({ - path: `/split`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Remove Subaccount from split - */ - removeSubaccount(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling removeSubaccount.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.subaccount !== undefined) { - formParams['subaccount'] = requestParameters.subaccount; - } - if (requestParameters.share !== undefined) { - formParams['share'] = requestParameters.share; - } - const response = yield this.request({ - path: `/split/{id}/subaccount/remove`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Split - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.active !== undefined) { - formParams['active'] = requestParameters.active; - } - if (requestParameters.bearer_type !== undefined) { - formParams['bearer_type'] = requestParameters.bearer_type; - } - if (requestParameters.bearer_subaccount !== undefined) { - formParams['bearer_subaccount'] = requestParameters.bearer_subaccount; - } - const response = yield this.request({ - path: `/split/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Split = Split; diff --git a/lib/apis/Subaccount.js b/lib/apis/Subaccount.js deleted file mode 100644 index 0b757a9..0000000 --- a/lib/apis/Subaccount.js +++ /dev/null @@ -1,180 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Subaccount = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Subaccount extends runtime_1.BaseAPI { - /** - * Create Subaccount - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.business_name === null || requestParameters.business_name === undefined) { - throw new runtime_1.RequiredError('business_name', 'Required parameter business_name was null or undefined when calling create.'); - } - if (requestParameters.settlement_bank === null || requestParameters.settlement_bank === undefined) { - throw new runtime_1.RequiredError('settlement_bank', 'Required parameter settlement_bank was null or undefined when calling create.'); - } - if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling create.'); - } - if (requestParameters.percentage_charge === null || requestParameters.percentage_charge === undefined) { - throw new runtime_1.RequiredError('percentage_charge', 'Required parameter percentage_charge was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.business_name !== undefined) { - formParams['business_name'] = requestParameters.business_name; - } - if (requestParameters.settlement_bank !== undefined) { - formParams['settlement_bank'] = requestParameters.settlement_bank; - } - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - if (requestParameters.percentage_charge !== undefined) { - formParams['percentage_charge'] = requestParameters.percentage_charge; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.primary_contact_email !== undefined) { - formParams['primary_contact_email'] = requestParameters.primary_contact_email; - } - if (requestParameters.primary_contact_name !== undefined) { - formParams['primary_contact_name'] = requestParameters.primary_contact_name; - } - if (requestParameters.primary_contact_phone !== undefined) { - formParams['primary_contact_phone'] = requestParameters.primary_contact_phone; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - const response = yield this.request({ - path: `/subaccount`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Subaccount - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/subaccount/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Subaccounts - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/subaccount`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Subaccount - */ - update(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling update.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.business_name !== undefined) { - formParams['business_name'] = requestParameters.business_name; - } - if (requestParameters.settlement_bank !== undefined) { - formParams['settlement_bank'] = requestParameters.settlement_bank; - } - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - if (requestParameters.active !== undefined) { - formParams['active'] = requestParameters.active; - } - if (requestParameters.percentage_charge !== undefined) { - formParams['percentage_charge'] = requestParameters.percentage_charge; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.primary_contact_email !== undefined) { - formParams['primary_contact_email'] = requestParameters.primary_contact_email; - } - if (requestParameters.primary_contact_name !== undefined) { - formParams['primary_contact_name'] = requestParameters.primary_contact_name; - } - if (requestParameters.primary_contact_phone !== undefined) { - formParams['primary_contact_phone'] = requestParameters.primary_contact_phone; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - const response = yield this.request({ - path: `/subaccount/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Subaccount = Subaccount; diff --git a/lib/apis/Subscription.js b/lib/apis/Subscription.js deleted file mode 100644 index 6400986..0000000 --- a/lib/apis/Subscription.js +++ /dev/null @@ -1,206 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Subscription = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Subscription extends runtime_1.BaseAPI { - /** - * Create Subscription - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.customer === null || requestParameters.customer === undefined) { - throw new runtime_1.RequiredError('customer', 'Required parameter customer was null or undefined when calling create.'); - } - if (requestParameters.plan === null || requestParameters.plan === undefined) { - throw new runtime_1.RequiredError('plan', 'Required parameter plan was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.customer !== undefined) { - formParams['customer'] = requestParameters.customer; - } - if (requestParameters.plan !== undefined) { - formParams['plan'] = requestParameters.plan; - } - if (requestParameters.authorization !== undefined) { - formParams['authorization'] = requestParameters.authorization; - } - if (requestParameters.start_date !== undefined) { - formParams['start_date'] = requestParameters.start_date; - } - const response = yield this.request({ - path: `/subscription`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Disable Subscription - */ - disable(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling disable.'); - } - if (requestParameters.token === null || requestParameters.token === undefined) { - throw new runtime_1.RequiredError('token', 'Required parameter token was null or undefined when calling disable.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.code !== undefined) { - formParams['code'] = requestParameters.code; - } - if (requestParameters.token !== undefined) { - formParams['token'] = requestParameters.token; - } - const response = yield this.request({ - path: `/subscription/disable`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Enable Subscription - */ - enable(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling enable.'); - } - if (requestParameters.token === null || requestParameters.token === undefined) { - throw new runtime_1.RequiredError('token', 'Required parameter token was null or undefined when calling enable.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.code !== undefined) { - formParams['code'] = requestParameters.code; - } - if (requestParameters.token !== undefined) { - formParams['token'] = requestParameters.token; - } - const response = yield this.request({ - path: `/subscription/enable`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Subscription - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/subscription/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Subscriptions - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.plan !== undefined) { - queryParameters['plan'] = requestParameters.plan; - } - if (requestParameters.customer !== undefined) { - queryParameters['customer'] = requestParameters.customer; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/subscription`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Send Update Subscription Link - */ - manageEmail(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling manageEmail.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/subscription/{code}/manage/email`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'POST', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Generate Update Subscription Link - */ - manageLink(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling manageLink.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/subscription/{code}/manage/link`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Subscription = Subscription; diff --git a/lib/apis/Transaction.js b/lib/apis/Transaction.js deleted file mode 100644 index 7122076..0000000 --- a/lib/apis/Transaction.js +++ /dev/null @@ -1,401 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Transaction = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Transaction extends runtime_1.BaseAPI { - /** - * Charge Authorization - */ - chargeAuthorization(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.email === null || requestParameters.email === undefined) { - throw new runtime_1.RequiredError('email', 'Required parameter email was null or undefined when calling chargeAuthorization.'); - } - if (requestParameters.amount === null || requestParameters.amount === undefined) { - throw new runtime_1.RequiredError('amount', 'Required parameter amount was null or undefined when calling chargeAuthorization.'); - } - if (requestParameters.authorization_code === null || requestParameters.authorization_code === undefined) { - throw new runtime_1.RequiredError('authorization_code', 'Required parameter authorization_code was null or undefined when calling chargeAuthorization.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.email !== undefined) { - formParams['email'] = requestParameters.email; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.authorization_code !== undefined) { - formParams['authorization_code'] = requestParameters.authorization_code; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - if (requestParameters.split_code !== undefined) { - formParams['split_code'] = requestParameters.split_code; - } - if (requestParameters.subaccount !== undefined) { - formParams['subaccount'] = requestParameters.subaccount; - } - if (requestParameters.transaction_charge !== undefined) { - formParams['transaction_charge'] = requestParameters.transaction_charge; - } - if (requestParameters.bearer !== undefined) { - formParams['bearer'] = requestParameters.bearer; - } - if (requestParameters.queue !== undefined) { - formParams['queue'] = requestParameters.queue; - } - const response = yield this.request({ - path: `/transaction/charge_authorization`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Check Authorization - */ - checkAuthorization(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.email === null || requestParameters.email === undefined) { - throw new runtime_1.RequiredError('email', 'Required parameter email was null or undefined when calling checkAuthorization.'); - } - if (requestParameters.amount === null || requestParameters.amount === undefined) { - throw new runtime_1.RequiredError('amount', 'Required parameter amount was null or undefined when calling checkAuthorization.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.email !== undefined) { - formParams['email'] = requestParameters.email; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.authorization_code !== undefined) { - formParams['authorization_code'] = requestParameters.authorization_code; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - const response = yield this.request({ - path: `/transaction/check_authorization`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Export Transactions - */ - download(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/transaction/export`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Get Transaction Event - */ - event(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling event.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transaction/{id}/event`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch a transaction to get its details - * Fetch Transaction - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transaction/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create a new transaction - * Initialize Transaction - */ - initialize(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.email === null || requestParameters.email === undefined) { - throw new runtime_1.RequiredError('email', 'Required parameter email was null or undefined when calling initialize.'); - } - if (requestParameters.amount === null || requestParameters.amount === undefined) { - throw new runtime_1.RequiredError('amount', 'Required parameter amount was null or undefined when calling initialize.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.email !== undefined) { - formParams['email'] = requestParameters.email; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - if (requestParameters.callback_url !== undefined) { - formParams['callback_url'] = requestParameters.callback_url; - } - if (requestParameters.plan !== undefined) { - formParams['plan'] = requestParameters.plan; - } - if (requestParameters.invoice_limit !== undefined) { - formParams['invoice_limit'] = requestParameters.invoice_limit; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - if (requestParameters.channels) { - formParams['channels'] = requestParameters.channels; - } - if (requestParameters.split_code !== undefined) { - formParams['split_code'] = requestParameters.split_code; - } - if (requestParameters.subaccount !== undefined) { - formParams['subaccount'] = requestParameters.subaccount; - } - if (requestParameters.transaction_charge !== undefined) { - formParams['transaction_charge'] = requestParameters.transaction_charge; - } - if (requestParameters.bearer !== undefined) { - formParams['bearer'] = requestParameters.bearer; - } - const response = yield this.request({ - path: `/transaction/initialize`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List transactions that has occurred on your integration - * List Transactions - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/transaction`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Partial Debit - */ - partialDebit(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.email === null || requestParameters.email === undefined) { - throw new runtime_1.RequiredError('email', 'Required parameter email was null or undefined when calling partialDebit.'); - } - if (requestParameters.amount === null || requestParameters.amount === undefined) { - throw new runtime_1.RequiredError('amount', 'Required parameter amount was null or undefined when calling partialDebit.'); - } - if (requestParameters.authorization_code === null || requestParameters.authorization_code === undefined) { - throw new runtime_1.RequiredError('authorization_code', 'Required parameter authorization_code was null or undefined when calling partialDebit.'); - } - if (requestParameters.currency === null || requestParameters.currency === undefined) { - throw new runtime_1.RequiredError('currency', 'Required parameter currency was null or undefined when calling partialDebit.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.email !== undefined) { - formParams['email'] = requestParameters.email; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.authorization_code !== undefined) { - formParams['authorization_code'] = requestParameters.authorization_code; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - if (requestParameters.at_least !== undefined) { - formParams['at_least'] = requestParameters.at_least; - } - const response = yield this.request({ - path: `/transaction/partial_debit`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Get Transaction Session - */ - session(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime_1.RequiredError('id', 'Required parameter id was null or undefined when calling session.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transaction/{id}/session`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Get the details about the lifecycle of a transaction from initiation to completion - * Fetch Transaction Timeline - */ - timeline(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.id_or_reference === null || requestParameters.id_or_reference === undefined) { - throw new runtime_1.RequiredError('id_or_reference', 'Required parameter id_or_reference was null or undefined when calling timeline.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transaction/timeline/{id_or_reference}`.replace(`{${"id_or_reference"}}`, encodeURIComponent(String(requestParameters.id_or_reference))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Get the total amount of all transactions - * Transaction Totals - */ - totals(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/transaction/totals`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Verify a previously initiated transaction using it\'s reference - * Verify Transaction - */ - verify(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling verify.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transaction/verify/{reference}`.replace(`{${"reference"}}`, encodeURIComponent(String(requestParameters.reference))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Transaction = Transaction; diff --git a/lib/apis/Transfer.js b/lib/apis/Transfer.js deleted file mode 100644 index 9d06708..0000000 --- a/lib/apis/Transfer.js +++ /dev/null @@ -1,296 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Transfer = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Transfer extends runtime_1.BaseAPI { - /** - * Initiate Bulk Transfer - */ - bulk(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - let formParams = {}; - if (requestParameters.source !== undefined) { - formParams['source'] = requestParameters.source; - } - if (requestParameters.transfers) { - formParams['transfers'] = requestParameters.transfers; - } - const response = yield this.request({ - path: `/transfer/bulk`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Disable OTP requirement for Transfers - */ - disableOtp() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/transfer/disable_otp`, - method: 'POST', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Finalize Disabling of OTP requirement for Transfers - */ - disableOtpFinalize(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.otp === null || requestParameters.otp === undefined) { - throw new runtime_1.RequiredError('otp', 'Required parameter otp was null or undefined when calling disableOtpFinalize.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.otp !== undefined) { - formParams['otp'] = requestParameters.otp; - } - const response = yield this.request({ - path: `/transfer/disable_otp_finalize`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Export Transfers - */ - download(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.status !== undefined) { - queryParameters['status'] = requestParameters.status; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/transfer/export`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Enable OTP requirement for Transfers - */ - enableOtp() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/transfer/enable_otp`, - method: 'POST', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Transfer - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transfer/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Finalize Transfer - */ - finalize(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.transfer_code === null || requestParameters.transfer_code === undefined) { - throw new runtime_1.RequiredError('transfer_code', 'Required parameter transfer_code was null or undefined when calling finalize.'); - } - if (requestParameters.otp === null || requestParameters.otp === undefined) { - throw new runtime_1.RequiredError('otp', 'Required parameter otp was null or undefined when calling finalize.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.transfer_code !== undefined) { - formParams['transfer_code'] = requestParameters.transfer_code; - } - if (requestParameters.otp !== undefined) { - formParams['otp'] = requestParameters.otp; - } - const response = yield this.request({ - path: `/transfer/finalize_transfer`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Initiate Transfer - */ - initiate(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.source === null || requestParameters.source === undefined) { - throw new runtime_1.RequiredError('source', 'Required parameter source was null or undefined when calling initiate.'); - } - if (requestParameters.amount === null || requestParameters.amount === undefined) { - throw new runtime_1.RequiredError('amount', 'Required parameter amount was null or undefined when calling initiate.'); - } - if (requestParameters.recipient === null || requestParameters.recipient === undefined) { - throw new runtime_1.RequiredError('recipient', 'Required parameter recipient was null or undefined when calling initiate.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.source !== undefined) { - formParams['source'] = requestParameters.source; - } - if (requestParameters.amount !== undefined) { - formParams['amount'] = requestParameters.amount; - } - if (requestParameters.recipient !== undefined) { - formParams['recipient'] = requestParameters.recipient; - } - if (requestParameters.reason !== undefined) { - formParams['reason'] = requestParameters.reason; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.reference !== undefined) { - formParams['reference'] = requestParameters.reference; - } - const response = yield this.request({ - path: `/transfer`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Transfers - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.status !== undefined) { - queryParameters['status'] = requestParameters.status; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/transfer`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Resend OTP for Transfer - */ - resendOtp(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.transfer_code === null || requestParameters.transfer_code === undefined) { - throw new runtime_1.RequiredError('transfer_code', 'Required parameter transfer_code was null or undefined when calling resendOtp.'); - } - if (requestParameters.reason === null || requestParameters.reason === undefined) { - throw new runtime_1.RequiredError('reason', 'Required parameter reason was null or undefined when calling resendOtp.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.transfer_code !== undefined) { - formParams['transfer_code'] = requestParameters.transfer_code; - } - if (requestParameters.reason !== undefined) { - formParams['reason'] = requestParameters.reason; - } - const response = yield this.request({ - path: `/transfer/resend_otp`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Verify Transfer - */ - verify(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.reference === null || requestParameters.reference === undefined) { - throw new runtime_1.RequiredError('reference', 'Required parameter reference was null or undefined when calling verify.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transfer/verify/{reference}`.replace(`{${"reference"}}`, encodeURIComponent(String(requestParameters.reference))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Transfer = Transfer; diff --git a/lib/apis/TransferRecipient.js b/lib/apis/TransferRecipient.js deleted file mode 100644 index c0a75ee..0000000 --- a/lib/apis/TransferRecipient.js +++ /dev/null @@ -1,192 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferRecipient = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class TransferRecipient extends runtime_1.BaseAPI { - /** - * Bulk Create Transfer Recipient - */ - bulk(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.batch === null || requestParameters.batch === undefined) { - throw new runtime_1.RequiredError('batch', 'Required parameter batch was null or undefined when calling bulk.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.batch) { - formParams['batch'] = requestParameters.batch; - } - const response = yield this.request({ - path: `/transferrecipient/bulk`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Create Transfer Recipient - */ - create(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.type === null || requestParameters.type === undefined) { - throw new runtime_1.RequiredError('type', 'Required parameter type was null or undefined when calling create.'); - } - if (requestParameters.name === null || requestParameters.name === undefined) { - throw new runtime_1.RequiredError('name', 'Required parameter name was null or undefined when calling create.'); - } - if (requestParameters.account_number === null || requestParameters.account_number === undefined) { - throw new runtime_1.RequiredError('account_number', 'Required parameter account_number was null or undefined when calling create.'); - } - if (requestParameters.bank_code === null || requestParameters.bank_code === undefined) { - throw new runtime_1.RequiredError('bank_code', 'Required parameter bank_code was null or undefined when calling create.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.type !== undefined) { - formParams['type'] = requestParameters.type; - } - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.account_number !== undefined) { - formParams['account_number'] = requestParameters.account_number; - } - if (requestParameters.bank_code !== undefined) { - formParams['bank_code'] = requestParameters.bank_code; - } - if (requestParameters.description !== undefined) { - formParams['description'] = requestParameters.description; - } - if (requestParameters.currency !== undefined) { - formParams['currency'] = requestParameters.currency; - } - if (requestParameters.authorization_code !== undefined) { - formParams['authorization_code'] = requestParameters.authorization_code; - } - if (requestParameters.metadata !== undefined) { - formParams['metadata'] = requestParameters.metadata; - } - const response = yield this.request({ - path: `/transferrecipient`, - method: 'POST', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Transfer recipient - */ - fetch(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling fetch.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transferrecipient/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Transfer Recipients - */ - list(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.page !== undefined) { - queryParameters['page'] = requestParameters.page; - } - if (requestParameters.from !== undefined) { - queryParameters['from'] = requestParameters.from.toISOString(); - } - if (requestParameters.to !== undefined) { - queryParameters['to'] = requestParameters.to.toISOString(); - } - const response = yield this.request({ - path: `/transferrecipient`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Delete Transfer Recipient - */ - transferrecipientCodeDelete(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling transferrecipientCodeDelete.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/transferrecipient/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'DELETE', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Update Transfer recipient - */ - transferrecipientCodePut(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.code === null || requestParameters.code === undefined) { - throw new runtime_1.RequiredError('code', 'Required parameter code was null or undefined when calling transferrecipientCodePut.'); - } - const queryParameters = {}; - let formParams = {}; - if (requestParameters.name !== undefined) { - formParams['name'] = requestParameters.name; - } - if (requestParameters.email !== undefined) { - formParams['email'] = requestParameters.email; - } - const response = yield this.request({ - path: `/transferrecipient/{code}`.replace(`{${"code"}}`, encodeURIComponent(String(requestParameters.code))), - method: 'PUT', - query: queryParameters, - body: formParams, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.TransferRecipient = TransferRecipient; diff --git a/lib/apis/Verification.js b/lib/apis/Verification.js deleted file mode 100644 index 490b2ed..0000000 --- a/lib/apis/Verification.js +++ /dev/null @@ -1,142 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Verification = void 0; -const runtime_1 = require("../runtime"); -const models_1 = require("../models"); -/** - * - */ -class Verification extends runtime_1.BaseAPI { - /** - * List States (AVS) - */ - avs(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.type !== undefined) { - queryParameters['type'] = requestParameters.type; - } - if (requestParameters.country !== undefined) { - queryParameters['country'] = requestParameters.country; - } - if (requestParameters.currency !== undefined) { - queryParameters['currency'] = requestParameters.currency; - } - const response = yield this.request({ - path: `/address_verification/states`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Fetch Banks - */ - fetchBanks(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.country !== undefined) { - queryParameters['country'] = requestParameters.country; - } - if (requestParameters.pay_with_bank_transfer !== undefined) { - queryParameters['pay_with_bank_transfer'] = requestParameters.pay_with_bank_transfer; - } - if (requestParameters.use_cursor !== undefined) { - queryParameters['use_cursor'] = requestParameters.use_cursor; - } - if (requestParameters.perPage !== undefined) { - queryParameters['perPage'] = requestParameters.perPage; - } - if (requestParameters.next !== undefined) { - queryParameters['next'] = requestParameters.next; - } - if (requestParameters.previous !== undefined) { - queryParameters['previous'] = requestParameters.previous; - } - if (requestParameters.gateway !== undefined) { - queryParameters['gateway'] = requestParameters.gateway; - } - const response = yield this.request({ - path: `/bank`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * List Countries - */ - listCountries() { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - const response = yield this.request({ - path: `/country`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Resolve Account Number - */ - resolveAccountNumber(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - const queryParameters = {}; - if (requestParameters.account_number !== undefined) { - queryParameters['account_number'] = requestParameters.account_number; - } - if (requestParameters.bank_code !== undefined) { - queryParameters['bank_code'] = requestParameters.bank_code; - } - const response = yield this.request({ - path: `/bank/resolve`, - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } - /** - * Resolve Card BIN - */ - resolveCardBin(requestParameters) { - return __awaiter(this, void 0, void 0, function* () { - if (requestParameters.bin === null || requestParameters.bin === undefined) { - throw new runtime_1.RequiredError('bin', 'Required parameter bin was null or undefined when calling resolveCardBin.'); - } - const queryParameters = {}; - const response = yield this.request({ - path: `/decision/bin/{bin}`.replace(`{${"bin"}}`, encodeURIComponent(String(requestParameters.bin))), - method: 'GET', - query: queryParameters, - }); - return models_1.ResponseFromJSON(response); - }); - } -} -exports.Verification = Verification; diff --git a/lib/apis/index.js b/lib/apis/index.js deleted file mode 100644 index 3078ed5..0000000 --- a/lib/apis/index.js +++ /dev/null @@ -1,41 +0,0 @@ -"use strict"; -var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); -}) : (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - o[k2] = m[k]; -})); -var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { - Object.defineProperty(o, "default", { enumerable: true, value: v }); -}) : function(o, v) { - o["default"] = v; -}); -var __importStar = (this && this.__importStar) || function (mod) { - if (mod && mod.__esModule) return mod; - var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); - __setModuleDefault(result, mod); - return result; -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Balance = __importStar(require("./Balance")); -exports.BulkCharge = __importStar(require("./BulkCharge")); -exports.Charge = __importStar(require("./Charge")); -exports.Customer = __importStar(require("./Customer")); -exports.DedicatedVirtualAccount = __importStar(require("./DedicatedVirtualAccount")); -exports.Dispute = __importStar(require("./Dispute")); -exports.Integration = __importStar(require("./Integration")); -exports.Page = __importStar(require("./Page")); -exports.PaymentRequest = __importStar(require("./PaymentRequest")); -exports.Plan = __importStar(require("./Plan")); -exports.Product = __importStar(require("./Product")); -exports.Refund = __importStar(require("./Refund")); -exports.Settlement = __importStar(require("./Settlement")); -exports.Split = __importStar(require("./Split")); -exports.Subaccount = __importStar(require("./Subaccount")); -exports.Subscription = __importStar(require("./Subscription")); -exports.Transaction = __importStar(require("./Transaction")); -exports.Transfer = __importStar(require("./Transfer")); -exports.TransferRecipient = __importStar(require("./TransferRecipient")); -exports.Verification = __importStar(require("./Verification")); diff --git a/lib/index.js b/lib/index.js deleted file mode 100644 index 068664f..0000000 --- a/lib/index.js +++ /dev/null @@ -1,49 +0,0 @@ -"use strict"; -var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); -}) : (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - o[k2] = m[k]; -})); -var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { - Object.defineProperty(o, "default", { enumerable: true, value: v }); -}) : function(o, v) { - o["default"] = v; -}); -var __importStar = (this && this.__importStar) || function (mod) { - if (mod && mod.__esModule) return mod; - var result = {}; - if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); - __setModuleDefault(result, mod); - return result; -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.Paystack = void 0; -const Resources = __importStar(require("./apis")); -class Paystack { - constructor(apiKey) { - this.extend(apiKey); - } - extend(apiKey) { - for (const resource in Resources) { - if (Resources.hasOwnProperty(resource)) { - this[this.toCamelCase(resource)] = new Resources[resource][resource](apiKey); - } - } - } - toCamelCase(resource) { - const _resource = this.cleanResourceKey(resource); - _resource.toLowerCase() - .replace(/\W+(.)/g, (_, chr) => chr.toUpperCase()); - return _resource; - } - cleanResourceKey(resource) { - if (!resource) - return null; - return resource.toLowerCase().replace("api", ""); - } -} -exports.Paystack = Paystack; -module.exports = Paystack; -module.exports.default = Paystack; diff --git a/lib/models/Accepted.js b/lib/models/Accepted.js deleted file mode 100644 index 5b99daa..0000000 --- a/lib/models/Accepted.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.AcceptedToJSON = exports.AcceptedFromJSONTyped = exports.AcceptedFromJSON = void 0; -const runtime_1 = require("../runtime"); -function AcceptedFromJSON(json) { - return AcceptedFromJSONTyped(json, false); -} -exports.AcceptedFromJSON = AcceptedFromJSON; -function AcceptedFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'status': !runtime_1.exists(json, 'status') ? undefined : json['status'], - 'message': !runtime_1.exists(json, 'message') ? undefined : json['message'], - }; -} -exports.AcceptedFromJSONTyped = AcceptedFromJSONTyped; -function AcceptedToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'status': value.status, - 'message': value.message, - }; -} -exports.AcceptedToJSON = AcceptedToJSON; diff --git a/lib/models/Bank.js b/lib/models/Bank.js deleted file mode 100644 index fb8f8dd..0000000 --- a/lib/models/Bank.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.BankToJSON = exports.BankFromJSONTyped = exports.BankFromJSON = void 0; -const runtime_1 = require("../runtime"); -function BankFromJSON(json) { - return BankFromJSONTyped(json, false); -} -exports.BankFromJSON = BankFromJSON; -function BankFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'code': !runtime_1.exists(json, 'code') ? undefined : json['code'], - 'accountNumber': !runtime_1.exists(json, 'account_number') ? undefined : json['account_number'], - }; -} -exports.BankFromJSONTyped = BankFromJSONTyped; -function BankToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'code': value.code, - 'account_number': value.accountNumber, - }; -} -exports.BankToJSON = BankToJSON; diff --git a/lib/models/BulkChargeInitiate.js b/lib/models/BulkChargeInitiate.js deleted file mode 100644 index 847bfbd..0000000 --- a/lib/models/BulkChargeInitiate.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.BulkChargeInitiateToJSON = exports.BulkChargeInitiateFromJSONTyped = exports.BulkChargeInitiateFromJSON = void 0; -function BulkChargeInitiateFromJSON(json) { - return BulkChargeInitiateFromJSONTyped(json, false); -} -exports.BulkChargeInitiateFromJSON = BulkChargeInitiateFromJSON; -function BulkChargeInitiateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'authorization': json['authorization'], - 'amount': json['amount'], - }; -} -exports.BulkChargeInitiateFromJSONTyped = BulkChargeInitiateFromJSONTyped; -function BulkChargeInitiateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'authorization': value.authorization, - 'amount': value.amount, - }; -} -exports.BulkChargeInitiateToJSON = BulkChargeInitiateToJSON; diff --git a/lib/models/ChargeCreate.js b/lib/models/ChargeCreate.js deleted file mode 100644 index 0df1b99..0000000 --- a/lib/models/ChargeCreate.js +++ /dev/null @@ -1,56 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ChargeCreateToJSON = exports.ChargeCreateFromJSONTyped = exports.ChargeCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function ChargeCreateFromJSON(json) { - return ChargeCreateFromJSONTyped(json, false); -} -exports.ChargeCreateFromJSON = ChargeCreateFromJSON; -function ChargeCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'email': json['email'], - 'amount': json['amount'], - 'authorizationCode': !runtime_1.exists(json, 'authorization_code') ? undefined : json['authorization_code'], - 'pin': !runtime_1.exists(json, 'pin') ? undefined : json['pin'], - 'reference': !runtime_1.exists(json, 'reference') ? undefined : json['reference'], - 'birthday': !runtime_1.exists(json, 'birthday') ? undefined : (new Date(json['birthday'])), - 'deviceId': !runtime_1.exists(json, 'device_id') ? undefined : json['device_id'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - }; -} -exports.ChargeCreateFromJSONTyped = ChargeCreateFromJSONTyped; -function ChargeCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'email': value.email, - 'amount': value.amount, - 'authorization_code': value.authorizationCode, - 'pin': value.pin, - 'reference': value.reference, - 'birthday': value.birthday === undefined ? undefined : (value.birthday.toISOString()), - 'device_id': value.deviceId, - 'metadata': value.metadata, - }; -} -exports.ChargeCreateToJSON = ChargeCreateToJSON; diff --git a/lib/models/ChargeSubmitAddress.js b/lib/models/ChargeSubmitAddress.js deleted file mode 100644 index e273550..0000000 --- a/lib/models/ChargeSubmitAddress.js +++ /dev/null @@ -1,49 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ChargeSubmitAddressToJSON = exports.ChargeSubmitAddressFromJSONTyped = exports.ChargeSubmitAddressFromJSON = void 0; -function ChargeSubmitAddressFromJSON(json) { - return ChargeSubmitAddressFromJSONTyped(json, false); -} -exports.ChargeSubmitAddressFromJSON = ChargeSubmitAddressFromJSON; -function ChargeSubmitAddressFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'address': json['address'], - 'city': json['city'], - 'state': json['state'], - 'zipcode': json['zipcode'], - 'reference': json['reference'], - }; -} -exports.ChargeSubmitAddressFromJSONTyped = ChargeSubmitAddressFromJSONTyped; -function ChargeSubmitAddressToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'address': value.address, - 'city': value.city, - 'state': value.state, - 'zipcode': value.zipcode, - 'reference': value.reference, - }; -} -exports.ChargeSubmitAddressToJSON = ChargeSubmitAddressToJSON; diff --git a/lib/models/ChargeSubmitBirthday.js b/lib/models/ChargeSubmitBirthday.js deleted file mode 100644 index f193ff0..0000000 --- a/lib/models/ChargeSubmitBirthday.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ChargeSubmitBirthdayToJSON = exports.ChargeSubmitBirthdayFromJSONTyped = exports.ChargeSubmitBirthdayFromJSON = void 0; -function ChargeSubmitBirthdayFromJSON(json) { - return ChargeSubmitBirthdayFromJSONTyped(json, false); -} -exports.ChargeSubmitBirthdayFromJSON = ChargeSubmitBirthdayFromJSON; -function ChargeSubmitBirthdayFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'birthday': json['birthday'], - 'reference': json['reference'], - }; -} -exports.ChargeSubmitBirthdayFromJSONTyped = ChargeSubmitBirthdayFromJSONTyped; -function ChargeSubmitBirthdayToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'birthday': value.birthday, - 'reference': value.reference, - }; -} -exports.ChargeSubmitBirthdayToJSON = ChargeSubmitBirthdayToJSON; diff --git a/lib/models/ChargeSubmitOTP.js b/lib/models/ChargeSubmitOTP.js deleted file mode 100644 index 4037dbf..0000000 --- a/lib/models/ChargeSubmitOTP.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ChargeSubmitOTPToJSON = exports.ChargeSubmitOTPFromJSONTyped = exports.ChargeSubmitOTPFromJSON = void 0; -function ChargeSubmitOTPFromJSON(json) { - return ChargeSubmitOTPFromJSONTyped(json, false); -} -exports.ChargeSubmitOTPFromJSON = ChargeSubmitOTPFromJSON; -function ChargeSubmitOTPFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'otp': json['otp'], - 'reference': json['reference'], - }; -} -exports.ChargeSubmitOTPFromJSONTyped = ChargeSubmitOTPFromJSONTyped; -function ChargeSubmitOTPToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'otp': value.otp, - 'reference': value.reference, - }; -} -exports.ChargeSubmitOTPToJSON = ChargeSubmitOTPToJSON; diff --git a/lib/models/ChargeSubmitPhone.js b/lib/models/ChargeSubmitPhone.js deleted file mode 100644 index 34f74c5..0000000 --- a/lib/models/ChargeSubmitPhone.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ChargeSubmitPhoneToJSON = exports.ChargeSubmitPhoneFromJSONTyped = exports.ChargeSubmitPhoneFromJSON = void 0; -function ChargeSubmitPhoneFromJSON(json) { - return ChargeSubmitPhoneFromJSONTyped(json, false); -} -exports.ChargeSubmitPhoneFromJSON = ChargeSubmitPhoneFromJSON; -function ChargeSubmitPhoneFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'phone': json['phone'], - 'reference': json['reference'], - }; -} -exports.ChargeSubmitPhoneFromJSONTyped = ChargeSubmitPhoneFromJSONTyped; -function ChargeSubmitPhoneToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'phone': value.phone, - 'reference': value.reference, - }; -} -exports.ChargeSubmitPhoneToJSON = ChargeSubmitPhoneToJSON; diff --git a/lib/models/ChargeSubmitPin.js b/lib/models/ChargeSubmitPin.js deleted file mode 100644 index d0809ba..0000000 --- a/lib/models/ChargeSubmitPin.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ChargeSubmitPinToJSON = exports.ChargeSubmitPinFromJSONTyped = exports.ChargeSubmitPinFromJSON = void 0; -function ChargeSubmitPinFromJSON(json) { - return ChargeSubmitPinFromJSONTyped(json, false); -} -exports.ChargeSubmitPinFromJSON = ChargeSubmitPinFromJSON; -function ChargeSubmitPinFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'pin': json['pin'], - 'reference': json['reference'], - }; -} -exports.ChargeSubmitPinFromJSONTyped = ChargeSubmitPinFromJSONTyped; -function ChargeSubmitPinToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'pin': value.pin, - 'reference': value.reference, - }; -} -exports.ChargeSubmitPinToJSON = ChargeSubmitPinToJSON; diff --git a/lib/models/CustomerCreate.js b/lib/models/CustomerCreate.js deleted file mode 100644 index 4f7a410..0000000 --- a/lib/models/CustomerCreate.js +++ /dev/null @@ -1,50 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.CustomerCreateToJSON = exports.CustomerCreateFromJSONTyped = exports.CustomerCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function CustomerCreateFromJSON(json) { - return CustomerCreateFromJSONTyped(json, false); -} -exports.CustomerCreateFromJSON = CustomerCreateFromJSON; -function CustomerCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'email': json['email'], - 'firstName': !runtime_1.exists(json, 'first_name') ? undefined : json['first_name'], - 'lastName': !runtime_1.exists(json, 'last_name') ? undefined : json['last_name'], - 'phone': !runtime_1.exists(json, 'phone') ? undefined : json['phone'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - }; -} -exports.CustomerCreateFromJSONTyped = CustomerCreateFromJSONTyped; -function CustomerCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'email': value.email, - 'first_name': value.firstName, - 'last_name': value.lastName, - 'phone': value.phone, - 'metadata': value.metadata, - }; -} -exports.CustomerCreateToJSON = CustomerCreateToJSON; diff --git a/lib/models/CustomerDeactivateAuthorization.js b/lib/models/CustomerDeactivateAuthorization.js deleted file mode 100644 index 748360e..0000000 --- a/lib/models/CustomerDeactivateAuthorization.js +++ /dev/null @@ -1,41 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.CustomerDeactivateAuthorizationToJSON = exports.CustomerDeactivateAuthorizationFromJSONTyped = exports.CustomerDeactivateAuthorizationFromJSON = void 0; -function CustomerDeactivateAuthorizationFromJSON(json) { - return CustomerDeactivateAuthorizationFromJSONTyped(json, false); -} -exports.CustomerDeactivateAuthorizationFromJSON = CustomerDeactivateAuthorizationFromJSON; -function CustomerDeactivateAuthorizationFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'authorizationCode': json['authorization_code'], - }; -} -exports.CustomerDeactivateAuthorizationFromJSONTyped = CustomerDeactivateAuthorizationFromJSONTyped; -function CustomerDeactivateAuthorizationToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'authorization_code': value.authorizationCode, - }; -} -exports.CustomerDeactivateAuthorizationToJSON = CustomerDeactivateAuthorizationToJSON; diff --git a/lib/models/CustomerRiskAction.js b/lib/models/CustomerRiskAction.js deleted file mode 100644 index 75ec79f..0000000 --- a/lib/models/CustomerRiskAction.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.CustomerRiskActionToJSON = exports.CustomerRiskActionFromJSONTyped = exports.CustomerRiskActionFromJSON = void 0; -const runtime_1 = require("../runtime"); -function CustomerRiskActionFromJSON(json) { - return CustomerRiskActionFromJSONTyped(json, false); -} -exports.CustomerRiskActionFromJSON = CustomerRiskActionFromJSON; -function CustomerRiskActionFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'customer': json['customer'], - 'riskAction': !runtime_1.exists(json, 'risk_action') ? undefined : json['risk_action'], - }; -} -exports.CustomerRiskActionFromJSONTyped = CustomerRiskActionFromJSONTyped; -function CustomerRiskActionToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'customer': value.customer, - 'risk_action': value.riskAction, - }; -} -exports.CustomerRiskActionToJSON = CustomerRiskActionToJSON; diff --git a/lib/models/CustomerUpdate.js b/lib/models/CustomerUpdate.js deleted file mode 100644 index e27f66b..0000000 --- a/lib/models/CustomerUpdate.js +++ /dev/null @@ -1,48 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.CustomerUpdateToJSON = exports.CustomerUpdateFromJSONTyped = exports.CustomerUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function CustomerUpdateFromJSON(json) { - return CustomerUpdateFromJSONTyped(json, false); -} -exports.CustomerUpdateFromJSON = CustomerUpdateFromJSON; -function CustomerUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'firstName': !runtime_1.exists(json, 'first_name') ? undefined : json['first_name'], - 'lastName': !runtime_1.exists(json, 'last_name') ? undefined : json['last_name'], - 'phone': !runtime_1.exists(json, 'phone') ? undefined : json['phone'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - }; -} -exports.CustomerUpdateFromJSONTyped = CustomerUpdateFromJSONTyped; -function CustomerUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'first_name': value.firstName, - 'last_name': value.lastName, - 'phone': value.phone, - 'metadata': value.metadata, - }; -} -exports.CustomerUpdateToJSON = CustomerUpdateToJSON; diff --git a/lib/models/CustomerValidate.js b/lib/models/CustomerValidate.js deleted file mode 100644 index 307a814..0000000 --- a/lib/models/CustomerValidate.js +++ /dev/null @@ -1,49 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.CustomerValidateToJSON = exports.CustomerValidateFromJSONTyped = exports.CustomerValidateFromJSON = void 0; -function CustomerValidateFromJSON(json) { - return CustomerValidateFromJSONTyped(json, false); -} -exports.CustomerValidateFromJSON = CustomerValidateFromJSON; -function CustomerValidateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'firstName': json['first_name'], - 'lastName': json['last_name'], - 'type': json['type'], - 'value': json['value'], - 'country': json['country'], - }; -} -exports.CustomerValidateFromJSONTyped = CustomerValidateFromJSONTyped; -function CustomerValidateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'first_name': value.firstName, - 'last_name': value.lastName, - 'type': value.type, - 'value': value.value, - 'country': value.country, - }; -} -exports.CustomerValidateToJSON = CustomerValidateToJSON; diff --git a/lib/models/CustomerValidation.js b/lib/models/CustomerValidation.js deleted file mode 100644 index 958ee83..0000000 --- a/lib/models/CustomerValidation.js +++ /dev/null @@ -1,56 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.CustomerValidationToJSON = exports.CustomerValidationFromJSONTyped = exports.CustomerValidationFromJSON = void 0; -const runtime_1 = require("../runtime"); -function CustomerValidationFromJSON(json) { - return CustomerValidationFromJSONTyped(json, false); -} -exports.CustomerValidationFromJSON = CustomerValidationFromJSON; -function CustomerValidationFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'firstName': json['first_name'], - 'lastName': json['last_name'], - 'type': json['type'], - 'country': json['country'], - 'bvn': json['bvn'], - 'bankCode': json['bank_code'], - 'accountNumber': json['account_number'], - 'value': !runtime_1.exists(json, 'value') ? undefined : json['value'], - }; -} -exports.CustomerValidationFromJSONTyped = CustomerValidationFromJSONTyped; -function CustomerValidationToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'first_name': value.firstName, - 'last_name': value.lastName, - 'type': value.type, - 'country': value.country, - 'bvn': value.bvn, - 'bank_code': value.bankCode, - 'account_number': value.accountNumber, - 'value': value.value, - }; -} -exports.CustomerValidationToJSON = CustomerValidationToJSON; diff --git a/lib/models/DedicatedVirtualAccountCreate.js b/lib/models/DedicatedVirtualAccountCreate.js deleted file mode 100644 index 9493834..0000000 --- a/lib/models/DedicatedVirtualAccountCreate.js +++ /dev/null @@ -1,48 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.DedicatedVirtualAccountCreateToJSON = exports.DedicatedVirtualAccountCreateFromJSONTyped = exports.DedicatedVirtualAccountCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function DedicatedVirtualAccountCreateFromJSON(json) { - return DedicatedVirtualAccountCreateFromJSONTyped(json, false); -} -exports.DedicatedVirtualAccountCreateFromJSON = DedicatedVirtualAccountCreateFromJSON; -function DedicatedVirtualAccountCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'customer': json['customer'], - 'preferredBank': !runtime_1.exists(json, 'preferred_bank') ? undefined : json['preferred_bank'], - 'subaccount': !runtime_1.exists(json, 'subaccount') ? undefined : json['subaccount'], - 'splitCode': !runtime_1.exists(json, 'split_code') ? undefined : json['split_code'], - }; -} -exports.DedicatedVirtualAccountCreateFromJSONTyped = DedicatedVirtualAccountCreateFromJSONTyped; -function DedicatedVirtualAccountCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'customer': value.customer, - 'preferred_bank': value.preferredBank, - 'subaccount': value.subaccount, - 'split_code': value.splitCode, - }; -} -exports.DedicatedVirtualAccountCreateToJSON = DedicatedVirtualAccountCreateToJSON; diff --git a/lib/models/DedicatedVirtualAccountSplit.js b/lib/models/DedicatedVirtualAccountSplit.js deleted file mode 100644 index 9aa7d1a..0000000 --- a/lib/models/DedicatedVirtualAccountSplit.js +++ /dev/null @@ -1,46 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.DedicatedVirtualAccountSplitToJSON = exports.DedicatedVirtualAccountSplitFromJSONTyped = exports.DedicatedVirtualAccountSplitFromJSON = void 0; -const runtime_1 = require("../runtime"); -function DedicatedVirtualAccountSplitFromJSON(json) { - return DedicatedVirtualAccountSplitFromJSONTyped(json, false); -} -exports.DedicatedVirtualAccountSplitFromJSON = DedicatedVirtualAccountSplitFromJSON; -function DedicatedVirtualAccountSplitFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'accountNumber': json['account_number'], - 'subaccount': !runtime_1.exists(json, 'subaccount') ? undefined : json['subaccount'], - 'splitCode': !runtime_1.exists(json, 'split_code') ? undefined : json['split_code'], - }; -} -exports.DedicatedVirtualAccountSplitFromJSONTyped = DedicatedVirtualAccountSplitFromJSONTyped; -function DedicatedVirtualAccountSplitToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'account_number': value.accountNumber, - 'subaccount': value.subaccount, - 'split_code': value.splitCode, - }; -} -exports.DedicatedVirtualAccountSplitToJSON = DedicatedVirtualAccountSplitToJSON; diff --git a/lib/models/DisputeEvidence.js b/lib/models/DisputeEvidence.js deleted file mode 100644 index b40c5d4..0000000 --- a/lib/models/DisputeEvidence.js +++ /dev/null @@ -1,52 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.DisputeEvidenceToJSON = exports.DisputeEvidenceFromJSONTyped = exports.DisputeEvidenceFromJSON = void 0; -const runtime_1 = require("../runtime"); -function DisputeEvidenceFromJSON(json) { - return DisputeEvidenceFromJSONTyped(json, false); -} -exports.DisputeEvidenceFromJSON = DisputeEvidenceFromJSON; -function DisputeEvidenceFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'customerEmail': json['customer_email'], - 'customerName': json['customer_name'], - 'customerPhone': json['customer_phone'], - 'serviceDetails': json['service_details'], - 'deliveryAddress': !runtime_1.exists(json, 'delivery_address') ? undefined : json['delivery_address'], - 'deliveryDate': !runtime_1.exists(json, 'delivery_date') ? undefined : (new Date(json['delivery_date'])), - }; -} -exports.DisputeEvidenceFromJSONTyped = DisputeEvidenceFromJSONTyped; -function DisputeEvidenceToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'customer_email': value.customerEmail, - 'customer_name': value.customerName, - 'customer_phone': value.customerPhone, - 'service_details': value.serviceDetails, - 'delivery_address': value.deliveryAddress, - 'delivery_date': value.deliveryDate === undefined ? undefined : (value.deliveryDate.toISOString()), - }; -} -exports.DisputeEvidenceToJSON = DisputeEvidenceToJSON; diff --git a/lib/models/DisputeResolve.js b/lib/models/DisputeResolve.js deleted file mode 100644 index d2aa597..0000000 --- a/lib/models/DisputeResolve.js +++ /dev/null @@ -1,50 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.DisputeResolveToJSON = exports.DisputeResolveFromJSONTyped = exports.DisputeResolveFromJSON = void 0; -const runtime_1 = require("../runtime"); -function DisputeResolveFromJSON(json) { - return DisputeResolveFromJSONTyped(json, false); -} -exports.DisputeResolveFromJSON = DisputeResolveFromJSON; -function DisputeResolveFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'resolution': json['resolution'], - 'message': json['message'], - 'refundAmount': json['refund_amount'], - 'uploadedFilename': json['uploaded_filename'], - 'evidence': !runtime_1.exists(json, 'evidence') ? undefined : json['evidence'], - }; -} -exports.DisputeResolveFromJSONTyped = DisputeResolveFromJSONTyped; -function DisputeResolveToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'resolution': value.resolution, - 'message': value.message, - 'refund_amount': value.refundAmount, - 'uploaded_filename': value.uploadedFilename, - 'evidence': value.evidence, - }; -} -exports.DisputeResolveToJSON = DisputeResolveToJSON; diff --git a/lib/models/DisputeUpdate.js b/lib/models/DisputeUpdate.js deleted file mode 100644 index 6fe4325..0000000 --- a/lib/models/DisputeUpdate.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.DisputeUpdateToJSON = exports.DisputeUpdateFromJSONTyped = exports.DisputeUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function DisputeUpdateFromJSON(json) { - return DisputeUpdateFromJSONTyped(json, false); -} -exports.DisputeUpdateFromJSON = DisputeUpdateFromJSON; -function DisputeUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'refundAmount': json['refund_amount'], - 'uploadedFilename': !runtime_1.exists(json, 'uploaded_filename') ? undefined : json['uploaded_filename'], - }; -} -exports.DisputeUpdateFromJSONTyped = DisputeUpdateFromJSONTyped; -function DisputeUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'refund_amount': value.refundAmount, - 'uploaded_filename': value.uploadedFilename, - }; -} -exports.DisputeUpdateToJSON = DisputeUpdateToJSON; diff --git a/lib/models/EFT.js b/lib/models/EFT.js deleted file mode 100644 index 496f705..0000000 --- a/lib/models/EFT.js +++ /dev/null @@ -1,42 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.EFTToJSON = exports.EFTFromJSONTyped = exports.EFTFromJSON = void 0; -const runtime_1 = require("../runtime"); -function EFTFromJSON(json) { - return EFTFromJSONTyped(json, false); -} -exports.EFTFromJSON = EFTFromJSON; -function EFTFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'provider': !runtime_1.exists(json, 'provider') ? undefined : json['provider'], - }; -} -exports.EFTFromJSONTyped = EFTFromJSONTyped; -function EFTToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'provider': value.provider, - }; -} -exports.EFTToJSON = EFTToJSON; diff --git a/lib/models/MobileMoney.js b/lib/models/MobileMoney.js deleted file mode 100644 index 0cecd5d..0000000 --- a/lib/models/MobileMoney.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.MobileMoneyToJSON = exports.MobileMoneyFromJSONTyped = exports.MobileMoneyFromJSON = void 0; -const runtime_1 = require("../runtime"); -function MobileMoneyFromJSON(json) { - return MobileMoneyFromJSONTyped(json, false); -} -exports.MobileMoneyFromJSON = MobileMoneyFromJSON; -function MobileMoneyFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'phone': !runtime_1.exists(json, 'phone') ? undefined : json['phone'], - 'provider': !runtime_1.exists(json, 'provider') ? undefined : json['provider'], - }; -} -exports.MobileMoneyFromJSONTyped = MobileMoneyFromJSONTyped; -function MobileMoneyToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'phone': value.phone, - 'provider': value.provider, - }; -} -exports.MobileMoneyToJSON = MobileMoneyToJSON; diff --git a/lib/models/ModelError.js b/lib/models/ModelError.js deleted file mode 100644 index d0848b7..0000000 --- a/lib/models/ModelError.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ModelErrorToJSON = exports.ModelErrorFromJSONTyped = exports.ModelErrorFromJSON = void 0; -const runtime_1 = require("../runtime"); -function ModelErrorFromJSON(json) { - return ModelErrorFromJSONTyped(json, false); -} -exports.ModelErrorFromJSON = ModelErrorFromJSON; -function ModelErrorFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'status': !runtime_1.exists(json, 'status') ? undefined : json['status'], - 'message': !runtime_1.exists(json, 'message') ? undefined : json['message'], - }; -} -exports.ModelErrorFromJSONTyped = ModelErrorFromJSONTyped; -function ModelErrorToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'status': value.status, - 'message': value.message, - }; -} -exports.ModelErrorToJSON = ModelErrorToJSON; diff --git a/lib/models/PageCreate.js b/lib/models/PageCreate.js deleted file mode 100644 index c6fc950..0000000 --- a/lib/models/PageCreate.js +++ /dev/null @@ -1,54 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PageCreateToJSON = exports.PageCreateFromJSONTyped = exports.PageCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function PageCreateFromJSON(json) { - return PageCreateFromJSONTyped(json, false); -} -exports.PageCreateFromJSON = PageCreateFromJSON; -function PageCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': json['name'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'amount': !runtime_1.exists(json, 'amount') ? undefined : json['amount'], - 'slug': !runtime_1.exists(json, 'slug') ? undefined : json['slug'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - 'redirectUrl': !runtime_1.exists(json, 'redirect_url') ? undefined : json['redirect_url'], - 'customFields': !runtime_1.exists(json, 'custom_fields') ? undefined : json['custom_fields'], - }; -} -exports.PageCreateFromJSONTyped = PageCreateFromJSONTyped; -function PageCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'description': value.description, - 'amount': value.amount, - 'slug': value.slug, - 'metadata': value.metadata, - 'redirect_url': value.redirectUrl, - 'custom_fields': value.customFields, - }; -} -exports.PageCreateToJSON = PageCreateToJSON; diff --git a/lib/models/PageProduct.js b/lib/models/PageProduct.js deleted file mode 100644 index f04d057..0000000 --- a/lib/models/PageProduct.js +++ /dev/null @@ -1,41 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PageProductToJSON = exports.PageProductFromJSONTyped = exports.PageProductFromJSON = void 0; -function PageProductFromJSON(json) { - return PageProductFromJSONTyped(json, false); -} -exports.PageProductFromJSON = PageProductFromJSON; -function PageProductFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'product': json['product'], - }; -} -exports.PageProductFromJSONTyped = PageProductFromJSONTyped; -function PageProductToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'product': value.product, - }; -} -exports.PageProductToJSON = PageProductToJSON; diff --git a/lib/models/PageUpdate.js b/lib/models/PageUpdate.js deleted file mode 100644 index 45fc7cc..0000000 --- a/lib/models/PageUpdate.js +++ /dev/null @@ -1,48 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PageUpdateToJSON = exports.PageUpdateFromJSONTyped = exports.PageUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function PageUpdateFromJSON(json) { - return PageUpdateFromJSONTyped(json, false); -} -exports.PageUpdateFromJSON = PageUpdateFromJSON; -function PageUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': !runtime_1.exists(json, 'name') ? undefined : json['name'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'amount': !runtime_1.exists(json, 'amount') ? undefined : json['amount'], - 'active': !runtime_1.exists(json, 'active') ? undefined : json['active'], - }; -} -exports.PageUpdateFromJSONTyped = PageUpdateFromJSONTyped; -function PageUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'description': value.description, - 'amount': value.amount, - 'active': value.active, - }; -} -exports.PageUpdateToJSON = PageUpdateToJSON; diff --git a/lib/models/PaymentRequestCreate.js b/lib/models/PaymentRequestCreate.js deleted file mode 100644 index 5e8a461..0000000 --- a/lib/models/PaymentRequestCreate.js +++ /dev/null @@ -1,64 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PaymentRequestCreateToJSON = exports.PaymentRequestCreateFromJSONTyped = exports.PaymentRequestCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function PaymentRequestCreateFromJSON(json) { - return PaymentRequestCreateFromJSONTyped(json, false); -} -exports.PaymentRequestCreateFromJSON = PaymentRequestCreateFromJSON; -function PaymentRequestCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'customer': json['customer'], - 'amount': !runtime_1.exists(json, 'amount') ? undefined : json['amount'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'dueDate': !runtime_1.exists(json, 'due_date') ? undefined : (new Date(json['due_date'])), - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'lineItems': !runtime_1.exists(json, 'line_items') ? undefined : json['line_items'], - 'tax': !runtime_1.exists(json, 'tax') ? undefined : json['tax'], - 'sendNotification': !runtime_1.exists(json, 'send_notification') ? undefined : json['send_notification'], - 'draft': !runtime_1.exists(json, 'draft') ? undefined : json['draft'], - 'hasInvoice': !runtime_1.exists(json, 'has_invoice') ? undefined : json['has_invoice'], - 'invoiceNumber': !runtime_1.exists(json, 'invoice_number') ? undefined : json['invoice_number'], - 'splitCode': !runtime_1.exists(json, 'split_code') ? undefined : json['split_code'], - }; -} -exports.PaymentRequestCreateFromJSONTyped = PaymentRequestCreateFromJSONTyped; -function PaymentRequestCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'customer': value.customer, - 'amount': value.amount, - 'currency': value.currency, - 'due_date': value.dueDate === undefined ? undefined : (value.dueDate.toISOString()), - 'description': value.description, - 'line_items': value.lineItems, - 'tax': value.tax, - 'send_notification': value.sendNotification, - 'draft': value.draft, - 'has_invoice': value.hasInvoice, - 'invoice_number': value.invoiceNumber, - 'split_code': value.splitCode, - }; -} -exports.PaymentRequestCreateToJSON = PaymentRequestCreateToJSON; diff --git a/lib/models/PaymentRequestUpdate.js b/lib/models/PaymentRequestUpdate.js deleted file mode 100644 index 1703d96..0000000 --- a/lib/models/PaymentRequestUpdate.js +++ /dev/null @@ -1,64 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PaymentRequestUpdateToJSON = exports.PaymentRequestUpdateFromJSONTyped = exports.PaymentRequestUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function PaymentRequestUpdateFromJSON(json) { - return PaymentRequestUpdateFromJSONTyped(json, false); -} -exports.PaymentRequestUpdateFromJSON = PaymentRequestUpdateFromJSON; -function PaymentRequestUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'customer': !runtime_1.exists(json, 'customer') ? undefined : json['customer'], - 'amount': !runtime_1.exists(json, 'amount') ? undefined : json['amount'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'dueDate': !runtime_1.exists(json, 'due_date') ? undefined : (new Date(json['due_date'])), - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'lineItems': !runtime_1.exists(json, 'line_items') ? undefined : json['line_items'], - 'tax': !runtime_1.exists(json, 'tax') ? undefined : json['tax'], - 'sendNotification': !runtime_1.exists(json, 'send_notification') ? undefined : json['send_notification'], - 'draft': !runtime_1.exists(json, 'draft') ? undefined : json['draft'], - 'hasInvoice': !runtime_1.exists(json, 'has_invoice') ? undefined : json['has_invoice'], - 'invoiceNumber': !runtime_1.exists(json, 'invoice_number') ? undefined : json['invoice_number'], - 'splitCode': !runtime_1.exists(json, 'split_code') ? undefined : json['split_code'], - }; -} -exports.PaymentRequestUpdateFromJSONTyped = PaymentRequestUpdateFromJSONTyped; -function PaymentRequestUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'customer': value.customer, - 'amount': value.amount, - 'currency': value.currency, - 'due_date': value.dueDate === undefined ? undefined : (value.dueDate.toISOString()), - 'description': value.description, - 'line_items': value.lineItems, - 'tax': value.tax, - 'send_notification': value.sendNotification, - 'draft': value.draft, - 'has_invoice': value.hasInvoice, - 'invoice_number': value.invoiceNumber, - 'split_code': value.splitCode, - }; -} -exports.PaymentRequestUpdateToJSON = PaymentRequestUpdateToJSON; diff --git a/lib/models/PlanCreate.js b/lib/models/PlanCreate.js deleted file mode 100644 index dcc6a8f..0000000 --- a/lib/models/PlanCreate.js +++ /dev/null @@ -1,56 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PlanCreateToJSON = exports.PlanCreateFromJSONTyped = exports.PlanCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function PlanCreateFromJSON(json) { - return PlanCreateFromJSONTyped(json, false); -} -exports.PlanCreateFromJSON = PlanCreateFromJSON; -function PlanCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': json['name'], - 'amount': json['amount'], - 'interval': json['interval'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'sendInvoices': !runtime_1.exists(json, 'send_invoices') ? undefined : json['send_invoices'], - 'sendSms': !runtime_1.exists(json, 'send_sms') ? undefined : json['send_sms'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'invoiceLimit': !runtime_1.exists(json, 'invoice_limit') ? undefined : json['invoice_limit'], - }; -} -exports.PlanCreateFromJSONTyped = PlanCreateFromJSONTyped; -function PlanCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'amount': value.amount, - 'interval': value.interval, - 'description': value.description, - 'send_invoices': value.sendInvoices, - 'send_sms': value.sendSms, - 'currency': value.currency, - 'invoice_limit': value.invoiceLimit, - }; -} -exports.PlanCreateToJSON = PlanCreateToJSON; diff --git a/lib/models/PlanUpdate.js b/lib/models/PlanUpdate.js deleted file mode 100644 index fb43a82..0000000 --- a/lib/models/PlanUpdate.js +++ /dev/null @@ -1,56 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.PlanUpdateToJSON = exports.PlanUpdateFromJSONTyped = exports.PlanUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function PlanUpdateFromJSON(json) { - return PlanUpdateFromJSONTyped(json, false); -} -exports.PlanUpdateFromJSON = PlanUpdateFromJSON; -function PlanUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': !runtime_1.exists(json, 'name') ? undefined : json['name'], - 'amount': !runtime_1.exists(json, 'amount') ? undefined : json['amount'], - 'interval': !runtime_1.exists(json, 'interval') ? undefined : json['interval'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'sendInvoices': !runtime_1.exists(json, 'send_invoices') ? undefined : json['send_invoices'], - 'sendSms': !runtime_1.exists(json, 'send_sms') ? undefined : json['send_sms'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'invoiceLimit': !runtime_1.exists(json, 'invoice_limit') ? undefined : json['invoice_limit'], - }; -} -exports.PlanUpdateFromJSONTyped = PlanUpdateFromJSONTyped; -function PlanUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'amount': value.amount, - 'interval': value.interval, - 'description': value.description, - 'send_invoices': value.sendInvoices, - 'send_sms': value.sendSms, - 'currency': value.currency, - 'invoice_limit': value.invoiceLimit, - }; -} -exports.PlanUpdateToJSON = PlanUpdateToJSON; diff --git a/lib/models/ProductCreate.js b/lib/models/ProductCreate.js deleted file mode 100644 index d257afa..0000000 --- a/lib/models/ProductCreate.js +++ /dev/null @@ -1,52 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ProductCreateToJSON = exports.ProductCreateFromJSONTyped = exports.ProductCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function ProductCreateFromJSON(json) { - return ProductCreateFromJSONTyped(json, false); -} -exports.ProductCreateFromJSON = ProductCreateFromJSON; -function ProductCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': json['name'], - 'description': json['description'], - 'price': json['price'], - 'currency': json['currency'], - 'limited': !runtime_1.exists(json, 'limited') ? undefined : json['limited'], - 'quantity': !runtime_1.exists(json, 'quantity') ? undefined : json['quantity'], - }; -} -exports.ProductCreateFromJSONTyped = ProductCreateFromJSONTyped; -function ProductCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'description': value.description, - 'price': value.price, - 'currency': value.currency, - 'limited': value.limited, - 'quantity': value.quantity, - }; -} -exports.ProductCreateToJSON = ProductCreateToJSON; diff --git a/lib/models/ProductUpdate.js b/lib/models/ProductUpdate.js deleted file mode 100644 index 917d203..0000000 --- a/lib/models/ProductUpdate.js +++ /dev/null @@ -1,52 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ProductUpdateToJSON = exports.ProductUpdateFromJSONTyped = exports.ProductUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function ProductUpdateFromJSON(json) { - return ProductUpdateFromJSONTyped(json, false); -} -exports.ProductUpdateFromJSON = ProductUpdateFromJSON; -function ProductUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': !runtime_1.exists(json, 'name') ? undefined : json['name'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'price': !runtime_1.exists(json, 'price') ? undefined : json['price'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'limited': !runtime_1.exists(json, 'limited') ? undefined : json['limited'], - 'quantity': !runtime_1.exists(json, 'quantity') ? undefined : json['quantity'], - }; -} -exports.ProductUpdateFromJSONTyped = ProductUpdateFromJSONTyped; -function ProductUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'description': value.description, - 'price': value.price, - 'currency': value.currency, - 'limited': value.limited, - 'quantity': value.quantity, - }; -} -exports.ProductUpdateToJSON = ProductUpdateToJSON; diff --git a/lib/models/RefundCreate.js b/lib/models/RefundCreate.js deleted file mode 100644 index d07cbdc..0000000 --- a/lib/models/RefundCreate.js +++ /dev/null @@ -1,50 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.RefundCreateToJSON = exports.RefundCreateFromJSONTyped = exports.RefundCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function RefundCreateFromJSON(json) { - return RefundCreateFromJSONTyped(json, false); -} -exports.RefundCreateFromJSON = RefundCreateFromJSON; -function RefundCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'transaction': json['transaction'], - 'amount': !runtime_1.exists(json, 'amount') ? undefined : json['amount'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'customerNote': !runtime_1.exists(json, 'customer_note') ? undefined : json['customer_note'], - 'merchantNote': !runtime_1.exists(json, 'merchant_note') ? undefined : json['merchant_note'], - }; -} -exports.RefundCreateFromJSONTyped = RefundCreateFromJSONTyped; -function RefundCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'transaction': value.transaction, - 'amount': value.amount, - 'currency': value.currency, - 'customer_note': value.customerNote, - 'merchant_note': value.merchantNote, - }; -} -exports.RefundCreateToJSON = RefundCreateToJSON; diff --git a/lib/models/Response.js b/lib/models/Response.js deleted file mode 100644 index 55fb985..0000000 --- a/lib/models/Response.js +++ /dev/null @@ -1,46 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ResponseToJSON = exports.ResponseFromJSONTyped = exports.ResponseFromJSON = void 0; -const runtime_1 = require("../runtime"); -function ResponseFromJSON(json) { - return ResponseFromJSONTyped(json, false); -} -exports.ResponseFromJSON = ResponseFromJSON; -function ResponseFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'status': !runtime_1.exists(json, 'status') ? undefined : json['status'], - 'message': !runtime_1.exists(json, 'message') ? undefined : json['message'], - 'data': !runtime_1.exists(json, 'data') ? undefined : json['data'], - }; -} -exports.ResponseFromJSONTyped = ResponseFromJSONTyped; -function ResponseToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'status': value.status, - 'message': value.message, - 'data': value.data, - }; -} -exports.ResponseToJSON = ResponseToJSON; diff --git a/lib/models/SplitCreate.js b/lib/models/SplitCreate.js deleted file mode 100644 index d3cd9ff..0000000 --- a/lib/models/SplitCreate.js +++ /dev/null @@ -1,53 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SplitCreateToJSON = exports.SplitCreateFromJSONTyped = exports.SplitCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -const _1 = require("./"); -function SplitCreateFromJSON(json) { - return SplitCreateFromJSONTyped(json, false); -} -exports.SplitCreateFromJSON = SplitCreateFromJSON; -function SplitCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': json['name'], - 'type': json['type'], - 'subaccounts': (json['subaccounts'].map(_1.SplitSubaccountsFromJSON)), - 'currency': json['currency'], - 'bearerType': !runtime_1.exists(json, 'bearer_type') ? undefined : json['bearer_type'], - 'bearerSubaccount': !runtime_1.exists(json, 'bearer_subaccount') ? undefined : json['bearer_subaccount'], - }; -} -exports.SplitCreateFromJSONTyped = SplitCreateFromJSONTyped; -function SplitCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'type': value.type, - 'subaccounts': (value.subaccounts.map(_1.SplitSubaccountsToJSON)), - 'currency': value.currency, - 'bearer_type': value.bearerType, - 'bearer_subaccount': value.bearerSubaccount, - }; -} -exports.SplitCreateToJSON = SplitCreateToJSON; diff --git a/lib/models/SplitSubaccounts.js b/lib/models/SplitSubaccounts.js deleted file mode 100644 index d69f9f1..0000000 --- a/lib/models/SplitSubaccounts.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SplitSubaccountsToJSON = exports.SplitSubaccountsFromJSONTyped = exports.SplitSubaccountsFromJSON = void 0; -const runtime_1 = require("../runtime"); -function SplitSubaccountsFromJSON(json) { - return SplitSubaccountsFromJSONTyped(json, false); -} -exports.SplitSubaccountsFromJSON = SplitSubaccountsFromJSON; -function SplitSubaccountsFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'subaccount': !runtime_1.exists(json, 'subaccount') ? undefined : json['subaccount'], - 'share': !runtime_1.exists(json, 'share') ? undefined : json['share'], - }; -} -exports.SplitSubaccountsFromJSONTyped = SplitSubaccountsFromJSONTyped; -function SplitSubaccountsToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'subaccount': value.subaccount, - 'share': value.share, - }; -} -exports.SplitSubaccountsToJSON = SplitSubaccountsToJSON; diff --git a/lib/models/SplitUpdate.js b/lib/models/SplitUpdate.js deleted file mode 100644 index f62fc3a..0000000 --- a/lib/models/SplitUpdate.js +++ /dev/null @@ -1,48 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SplitUpdateToJSON = exports.SplitUpdateFromJSONTyped = exports.SplitUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function SplitUpdateFromJSON(json) { - return SplitUpdateFromJSONTyped(json, false); -} -exports.SplitUpdateFromJSON = SplitUpdateFromJSON; -function SplitUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': !runtime_1.exists(json, 'name') ? undefined : json['name'], - 'active': !runtime_1.exists(json, 'active') ? undefined : json['active'], - 'bearerType': !runtime_1.exists(json, 'bearer_type') ? undefined : json['bearer_type'], - 'bearerSubaccount': !runtime_1.exists(json, 'bearer_subaccount') ? undefined : json['bearer_subaccount'], - }; -} -exports.SplitUpdateFromJSONTyped = SplitUpdateFromJSONTyped; -function SplitUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'active': value.active, - 'bearer_type': value.bearerType, - 'bearer_subaccount': value.bearerSubaccount, - }; -} -exports.SplitUpdateToJSON = SplitUpdateToJSON; diff --git a/lib/models/SubaccountCreate.js b/lib/models/SubaccountCreate.js deleted file mode 100644 index 2a6ab45..0000000 --- a/lib/models/SubaccountCreate.js +++ /dev/null @@ -1,58 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SubaccountCreateToJSON = exports.SubaccountCreateFromJSONTyped = exports.SubaccountCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function SubaccountCreateFromJSON(json) { - return SubaccountCreateFromJSONTyped(json, false); -} -exports.SubaccountCreateFromJSON = SubaccountCreateFromJSON; -function SubaccountCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'businessName': json['business_name'], - 'settlementBank': json['settlement_bank'], - 'accountNumber': json['account_number'], - 'percentageCharge': json['percentage_charge'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'primaryContactEmail': !runtime_1.exists(json, 'primary_contact_email') ? undefined : json['primary_contact_email'], - 'primaryContactName': !runtime_1.exists(json, 'primary_contact_name') ? undefined : json['primary_contact_name'], - 'primaryContactPhone': !runtime_1.exists(json, 'primary_contact_phone') ? undefined : json['primary_contact_phone'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - }; -} -exports.SubaccountCreateFromJSONTyped = SubaccountCreateFromJSONTyped; -function SubaccountCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'business_name': value.businessName, - 'settlement_bank': value.settlementBank, - 'account_number': value.accountNumber, - 'percentage_charge': value.percentageCharge, - 'description': value.description, - 'primary_contact_email': value.primaryContactEmail, - 'primary_contact_name': value.primaryContactName, - 'primary_contact_phone': value.primaryContactPhone, - 'metadata': value.metadata, - }; -} -exports.SubaccountCreateToJSON = SubaccountCreateToJSON; diff --git a/lib/models/SubaccountUpdate.js b/lib/models/SubaccountUpdate.js deleted file mode 100644 index 4ac6753..0000000 --- a/lib/models/SubaccountUpdate.js +++ /dev/null @@ -1,60 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SubaccountUpdateToJSON = exports.SubaccountUpdateFromJSONTyped = exports.SubaccountUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function SubaccountUpdateFromJSON(json) { - return SubaccountUpdateFromJSONTyped(json, false); -} -exports.SubaccountUpdateFromJSON = SubaccountUpdateFromJSON; -function SubaccountUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'businessName': !runtime_1.exists(json, 'business_name') ? undefined : json['business_name'], - 'settlementBank': !runtime_1.exists(json, 'settlement_bank') ? undefined : json['settlement_bank'], - 'accountNumber': !runtime_1.exists(json, 'account_number') ? undefined : json['account_number'], - 'active': !runtime_1.exists(json, 'active') ? undefined : json['active'], - 'percentageCharge': !runtime_1.exists(json, 'percentage_charge') ? undefined : json['percentage_charge'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'primaryContactEmail': !runtime_1.exists(json, 'primary_contact_email') ? undefined : json['primary_contact_email'], - 'primaryContactName': !runtime_1.exists(json, 'primary_contact_name') ? undefined : json['primary_contact_name'], - 'primaryContactPhone': !runtime_1.exists(json, 'primary_contact_phone') ? undefined : json['primary_contact_phone'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - }; -} -exports.SubaccountUpdateFromJSONTyped = SubaccountUpdateFromJSONTyped; -function SubaccountUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'business_name': value.businessName, - 'settlement_bank': value.settlementBank, - 'account_number': value.accountNumber, - 'active': value.active, - 'percentage_charge': value.percentageCharge, - 'description': value.description, - 'primary_contact_email': value.primaryContactEmail, - 'primary_contact_name': value.primaryContactName, - 'primary_contact_phone': value.primaryContactPhone, - 'metadata': value.metadata, - }; -} -exports.SubaccountUpdateToJSON = SubaccountUpdateToJSON; diff --git a/lib/models/SubscriptionCreate.js b/lib/models/SubscriptionCreate.js deleted file mode 100644 index 9c4c187..0000000 --- a/lib/models/SubscriptionCreate.js +++ /dev/null @@ -1,48 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SubscriptionCreateToJSON = exports.SubscriptionCreateFromJSONTyped = exports.SubscriptionCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function SubscriptionCreateFromJSON(json) { - return SubscriptionCreateFromJSONTyped(json, false); -} -exports.SubscriptionCreateFromJSON = SubscriptionCreateFromJSON; -function SubscriptionCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'customer': json['customer'], - 'plan': json['plan'], - 'authorization': !runtime_1.exists(json, 'authorization') ? undefined : json['authorization'], - 'startDate': !runtime_1.exists(json, 'start_date') ? undefined : (new Date(json['start_date'])), - }; -} -exports.SubscriptionCreateFromJSONTyped = SubscriptionCreateFromJSONTyped; -function SubscriptionCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'customer': value.customer, - 'plan': value.plan, - 'authorization': value.authorization, - 'start_date': value.startDate === undefined ? undefined : (value.startDate.toISOString()), - }; -} -exports.SubscriptionCreateToJSON = SubscriptionCreateToJSON; diff --git a/lib/models/SubscriptionToggle.js b/lib/models/SubscriptionToggle.js deleted file mode 100644 index 2ad190f..0000000 --- a/lib/models/SubscriptionToggle.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SubscriptionToggleToJSON = exports.SubscriptionToggleFromJSONTyped = exports.SubscriptionToggleFromJSON = void 0; -function SubscriptionToggleFromJSON(json) { - return SubscriptionToggleFromJSONTyped(json, false); -} -exports.SubscriptionToggleFromJSON = SubscriptionToggleFromJSON; -function SubscriptionToggleFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'code': json['code'], - 'token': json['token'], - }; -} -exports.SubscriptionToggleFromJSONTyped = SubscriptionToggleFromJSONTyped; -function SubscriptionToggleToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'code': value.code, - 'token': value.token, - }; -} -exports.SubscriptionToggleToJSON = SubscriptionToggleToJSON; diff --git a/lib/models/TransactionChargeAuthorization.js b/lib/models/TransactionChargeAuthorization.js deleted file mode 100644 index 7899b05..0000000 --- a/lib/models/TransactionChargeAuthorization.js +++ /dev/null @@ -1,62 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransactionChargeAuthorizationToJSON = exports.TransactionChargeAuthorizationFromJSONTyped = exports.TransactionChargeAuthorizationFromJSON = void 0; -const runtime_1 = require("../runtime"); -function TransactionChargeAuthorizationFromJSON(json) { - return TransactionChargeAuthorizationFromJSONTyped(json, false); -} -exports.TransactionChargeAuthorizationFromJSON = TransactionChargeAuthorizationFromJSON; -function TransactionChargeAuthorizationFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'email': json['email'], - 'amount': json['amount'], - 'authorizationCode': json['authorization_code'], - 'reference': !runtime_1.exists(json, 'reference') ? undefined : json['reference'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - 'splitCode': !runtime_1.exists(json, 'split_code') ? undefined : json['split_code'], - 'subaccount': !runtime_1.exists(json, 'subaccount') ? undefined : json['subaccount'], - 'transactionCharge': !runtime_1.exists(json, 'transaction_charge') ? undefined : json['transaction_charge'], - 'bearer': !runtime_1.exists(json, 'bearer') ? undefined : json['bearer'], - 'queue': !runtime_1.exists(json, 'queue') ? undefined : json['queue'], - }; -} -exports.TransactionChargeAuthorizationFromJSONTyped = TransactionChargeAuthorizationFromJSONTyped; -function TransactionChargeAuthorizationToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'email': value.email, - 'amount': value.amount, - 'authorization_code': value.authorizationCode, - 'reference': value.reference, - 'currency': value.currency, - 'metadata': value.metadata, - 'split_code': value.splitCode, - 'subaccount': value.subaccount, - 'transaction_charge': value.transactionCharge, - 'bearer': value.bearer, - 'queue': value.queue, - }; -} -exports.TransactionChargeAuthorizationToJSON = TransactionChargeAuthorizationToJSON; diff --git a/lib/models/TransactionCheckAuthorization.js b/lib/models/TransactionCheckAuthorization.js deleted file mode 100644 index 51d95d1..0000000 --- a/lib/models/TransactionCheckAuthorization.js +++ /dev/null @@ -1,48 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransactionCheckAuthorizationToJSON = exports.TransactionCheckAuthorizationFromJSONTyped = exports.TransactionCheckAuthorizationFromJSON = void 0; -const runtime_1 = require("../runtime"); -function TransactionCheckAuthorizationFromJSON(json) { - return TransactionCheckAuthorizationFromJSONTyped(json, false); -} -exports.TransactionCheckAuthorizationFromJSON = TransactionCheckAuthorizationFromJSON; -function TransactionCheckAuthorizationFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'email': json['email'], - 'amount': json['amount'], - 'authorizationCode': !runtime_1.exists(json, 'authorization_code') ? undefined : json['authorization_code'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - }; -} -exports.TransactionCheckAuthorizationFromJSONTyped = TransactionCheckAuthorizationFromJSONTyped; -function TransactionCheckAuthorizationToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'email': value.email, - 'amount': value.amount, - 'authorization_code': value.authorizationCode, - 'currency': value.currency, - }; -} -exports.TransactionCheckAuthorizationToJSON = TransactionCheckAuthorizationToJSON; diff --git a/lib/models/TransactionInitialize.js b/lib/models/TransactionInitialize.js deleted file mode 100644 index 2fe3e82..0000000 --- a/lib/models/TransactionInitialize.js +++ /dev/null @@ -1,66 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransactionInitializeToJSON = exports.TransactionInitializeFromJSONTyped = exports.TransactionInitializeFromJSON = void 0; -const runtime_1 = require("../runtime"); -function TransactionInitializeFromJSON(json) { - return TransactionInitializeFromJSONTyped(json, false); -} -exports.TransactionInitializeFromJSON = TransactionInitializeFromJSON; -function TransactionInitializeFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'email': json['email'], - 'amount': json['amount'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'reference': !runtime_1.exists(json, 'reference') ? undefined : json['reference'], - 'callbackUrl': !runtime_1.exists(json, 'callback_url') ? undefined : json['callback_url'], - 'plan': !runtime_1.exists(json, 'plan') ? undefined : json['plan'], - 'invoiceLimit': !runtime_1.exists(json, 'invoice_limit') ? undefined : json['invoice_limit'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - 'channels': !runtime_1.exists(json, 'channels') ? undefined : json['channels'], - 'splitCode': !runtime_1.exists(json, 'split_code') ? undefined : json['split_code'], - 'subaccount': !runtime_1.exists(json, 'subaccount') ? undefined : json['subaccount'], - 'transactionCharge': !runtime_1.exists(json, 'transaction_charge') ? undefined : json['transaction_charge'], - 'bearer': !runtime_1.exists(json, 'bearer') ? undefined : json['bearer'], - }; -} -exports.TransactionInitializeFromJSONTyped = TransactionInitializeFromJSONTyped; -function TransactionInitializeToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'email': value.email, - 'amount': value.amount, - 'currency': value.currency, - 'reference': value.reference, - 'callback_url': value.callbackUrl, - 'plan': value.plan, - 'invoice_limit': value.invoiceLimit, - 'metadata': value.metadata, - 'channels': value.channels, - 'split_code': value.splitCode, - 'subaccount': value.subaccount, - 'transaction_charge': value.transactionCharge, - 'bearer': value.bearer, - }; -} -exports.TransactionInitializeToJSON = TransactionInitializeToJSON; diff --git a/lib/models/TransactionPartialDebit.js b/lib/models/TransactionPartialDebit.js deleted file mode 100644 index 5786c52..0000000 --- a/lib/models/TransactionPartialDebit.js +++ /dev/null @@ -1,52 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransactionPartialDebitToJSON = exports.TransactionPartialDebitFromJSONTyped = exports.TransactionPartialDebitFromJSON = void 0; -const runtime_1 = require("../runtime"); -function TransactionPartialDebitFromJSON(json) { - return TransactionPartialDebitFromJSONTyped(json, false); -} -exports.TransactionPartialDebitFromJSON = TransactionPartialDebitFromJSON; -function TransactionPartialDebitFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'email': json['email'], - 'amount': json['amount'], - 'authorizationCode': json['authorization_code'], - 'currency': json['currency'], - 'reference': !runtime_1.exists(json, 'reference') ? undefined : json['reference'], - 'atLeast': !runtime_1.exists(json, 'at_least') ? undefined : json['at_least'], - }; -} -exports.TransactionPartialDebitFromJSONTyped = TransactionPartialDebitFromJSONTyped; -function TransactionPartialDebitToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'email': value.email, - 'amount': value.amount, - 'authorization_code': value.authorizationCode, - 'currency': value.currency, - 'reference': value.reference, - 'at_least': value.atLeast, - }; -} -exports.TransactionPartialDebitToJSON = TransactionPartialDebitToJSON; diff --git a/lib/models/TransferBulk.js b/lib/models/TransferBulk.js deleted file mode 100644 index c37633f..0000000 --- a/lib/models/TransferBulk.js +++ /dev/null @@ -1,45 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferBulkToJSON = exports.TransferBulkFromJSONTyped = exports.TransferBulkFromJSON = void 0; -const runtime_1 = require("../runtime"); -const _1 = require("./"); -function TransferBulkFromJSON(json) { - return TransferBulkFromJSONTyped(json, false); -} -exports.TransferBulkFromJSON = TransferBulkFromJSON; -function TransferBulkFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'source': !runtime_1.exists(json, 'source') ? undefined : json['source'], - 'transfers': !runtime_1.exists(json, 'transfers') ? undefined : (json['transfers'].map(_1.TransferInitiateFromJSON)), - }; -} -exports.TransferBulkFromJSONTyped = TransferBulkFromJSONTyped; -function TransferBulkToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'source': value.source, - 'transfers': value.transfers === undefined ? undefined : (value.transfers.map(_1.TransferInitiateToJSON)), - }; -} -exports.TransferBulkToJSON = TransferBulkToJSON; diff --git a/lib/models/TransferFinalize.js b/lib/models/TransferFinalize.js deleted file mode 100644 index 082ca27..0000000 --- a/lib/models/TransferFinalize.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferFinalizeToJSON = exports.TransferFinalizeFromJSONTyped = exports.TransferFinalizeFromJSON = void 0; -function TransferFinalizeFromJSON(json) { - return TransferFinalizeFromJSONTyped(json, false); -} -exports.TransferFinalizeFromJSON = TransferFinalizeFromJSON; -function TransferFinalizeFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'transferCode': json['transfer_code'], - 'otp': json['otp'], - }; -} -exports.TransferFinalizeFromJSONTyped = TransferFinalizeFromJSONTyped; -function TransferFinalizeToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'transfer_code': value.transferCode, - 'otp': value.otp, - }; -} -exports.TransferFinalizeToJSON = TransferFinalizeToJSON; diff --git a/lib/models/TransferFinalizeDisableOTP.js b/lib/models/TransferFinalizeDisableOTP.js deleted file mode 100644 index 140748a..0000000 --- a/lib/models/TransferFinalizeDisableOTP.js +++ /dev/null @@ -1,41 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferFinalizeDisableOTPToJSON = exports.TransferFinalizeDisableOTPFromJSONTyped = exports.TransferFinalizeDisableOTPFromJSON = void 0; -function TransferFinalizeDisableOTPFromJSON(json) { - return TransferFinalizeDisableOTPFromJSONTyped(json, false); -} -exports.TransferFinalizeDisableOTPFromJSON = TransferFinalizeDisableOTPFromJSON; -function TransferFinalizeDisableOTPFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'otp': json['otp'], - }; -} -exports.TransferFinalizeDisableOTPFromJSONTyped = TransferFinalizeDisableOTPFromJSONTyped; -function TransferFinalizeDisableOTPToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'otp': value.otp, - }; -} -exports.TransferFinalizeDisableOTPToJSON = TransferFinalizeDisableOTPToJSON; diff --git a/lib/models/TransferInitiate.js b/lib/models/TransferInitiate.js deleted file mode 100644 index 8639c8d..0000000 --- a/lib/models/TransferInitiate.js +++ /dev/null @@ -1,52 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferInitiateToJSON = exports.TransferInitiateFromJSONTyped = exports.TransferInitiateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function TransferInitiateFromJSON(json) { - return TransferInitiateFromJSONTyped(json, false); -} -exports.TransferInitiateFromJSON = TransferInitiateFromJSON; -function TransferInitiateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'source': json['source'], - 'amount': json['amount'], - 'recipient': json['recipient'], - 'reason': !runtime_1.exists(json, 'reason') ? undefined : json['reason'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'reference': !runtime_1.exists(json, 'reference') ? undefined : json['reference'], - }; -} -exports.TransferInitiateFromJSONTyped = TransferInitiateFromJSONTyped; -function TransferInitiateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'source': value.source, - 'amount': value.amount, - 'recipient': value.recipient, - 'reason': value.reason, - 'currency': value.currency, - 'reference': value.reference, - }; -} -exports.TransferInitiateToJSON = TransferInitiateToJSON; diff --git a/lib/models/TransferRecipientBulk.js b/lib/models/TransferRecipientBulk.js deleted file mode 100644 index 6f05a9c..0000000 --- a/lib/models/TransferRecipientBulk.js +++ /dev/null @@ -1,42 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferRecipientBulkToJSON = exports.TransferRecipientBulkFromJSONTyped = exports.TransferRecipientBulkFromJSON = void 0; -const _1 = require("./"); -function TransferRecipientBulkFromJSON(json) { - return TransferRecipientBulkFromJSONTyped(json, false); -} -exports.TransferRecipientBulkFromJSON = TransferRecipientBulkFromJSON; -function TransferRecipientBulkFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'batch': (json['batch'].map(_1.TransferRecipientCreateFromJSON)), - }; -} -exports.TransferRecipientBulkFromJSONTyped = TransferRecipientBulkFromJSONTyped; -function TransferRecipientBulkToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'batch': (value.batch.map(_1.TransferRecipientCreateToJSON)), - }; -} -exports.TransferRecipientBulkToJSON = TransferRecipientBulkToJSON; diff --git a/lib/models/TransferRecipientCreate.js b/lib/models/TransferRecipientCreate.js deleted file mode 100644 index 72cc2e1..0000000 --- a/lib/models/TransferRecipientCreate.js +++ /dev/null @@ -1,56 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferRecipientCreateToJSON = exports.TransferRecipientCreateFromJSONTyped = exports.TransferRecipientCreateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function TransferRecipientCreateFromJSON(json) { - return TransferRecipientCreateFromJSONTyped(json, false); -} -exports.TransferRecipientCreateFromJSON = TransferRecipientCreateFromJSON; -function TransferRecipientCreateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'type': json['type'], - 'name': json['name'], - 'accountNumber': json['account_number'], - 'bankCode': json['bank_code'], - 'description': !runtime_1.exists(json, 'description') ? undefined : json['description'], - 'currency': !runtime_1.exists(json, 'currency') ? undefined : json['currency'], - 'authorizationCode': !runtime_1.exists(json, 'authorization_code') ? undefined : json['authorization_code'], - 'metadata': !runtime_1.exists(json, 'metadata') ? undefined : json['metadata'], - }; -} -exports.TransferRecipientCreateFromJSONTyped = TransferRecipientCreateFromJSONTyped; -function TransferRecipientCreateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'type': value.type, - 'name': value.name, - 'account_number': value.accountNumber, - 'bank_code': value.bankCode, - 'description': value.description, - 'currency': value.currency, - 'authorization_code': value.authorizationCode, - 'metadata': value.metadata, - }; -} -exports.TransferRecipientCreateToJSON = TransferRecipientCreateToJSON; diff --git a/lib/models/TransferRecipientUpdate.js b/lib/models/TransferRecipientUpdate.js deleted file mode 100644 index 4b29706..0000000 --- a/lib/models/TransferRecipientUpdate.js +++ /dev/null @@ -1,44 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferRecipientUpdateToJSON = exports.TransferRecipientUpdateFromJSONTyped = exports.TransferRecipientUpdateFromJSON = void 0; -const runtime_1 = require("../runtime"); -function TransferRecipientUpdateFromJSON(json) { - return TransferRecipientUpdateFromJSONTyped(json, false); -} -exports.TransferRecipientUpdateFromJSON = TransferRecipientUpdateFromJSON; -function TransferRecipientUpdateFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'name': !runtime_1.exists(json, 'name') ? undefined : json['name'], - 'email': !runtime_1.exists(json, 'email') ? undefined : json['email'], - }; -} -exports.TransferRecipientUpdateFromJSONTyped = TransferRecipientUpdateFromJSONTyped; -function TransferRecipientUpdateToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'name': value.name, - 'email': value.email, - }; -} -exports.TransferRecipientUpdateToJSON = TransferRecipientUpdateToJSON; diff --git a/lib/models/TransferResendOTP.js b/lib/models/TransferResendOTP.js deleted file mode 100644 index 3a11f59..0000000 --- a/lib/models/TransferResendOTP.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TransferResendOTPToJSON = exports.TransferResendOTPFromJSONTyped = exports.TransferResendOTPFromJSON = void 0; -function TransferResendOTPFromJSON(json) { - return TransferResendOTPFromJSONTyped(json, false); -} -exports.TransferResendOTPFromJSON = TransferResendOTPFromJSON; -function TransferResendOTPFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'transferCode': json['transfer_code'], - 'reason': json['reason'], - }; -} -exports.TransferResendOTPFromJSONTyped = TransferResendOTPFromJSONTyped; -function TransferResendOTPToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'transfer_code': value.transferCode, - 'reason': value.reason, - }; -} -exports.TransferResendOTPToJSON = TransferResendOTPToJSON; diff --git a/lib/models/USSD.js b/lib/models/USSD.js deleted file mode 100644 index 2dde740..0000000 --- a/lib/models/USSD.js +++ /dev/null @@ -1,42 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.USSDToJSON = exports.USSDFromJSONTyped = exports.USSDFromJSON = void 0; -const runtime_1 = require("../runtime"); -function USSDFromJSON(json) { - return USSDFromJSONTyped(json, false); -} -exports.USSDFromJSON = USSDFromJSON; -function USSDFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'type': !runtime_1.exists(json, 'type') ? undefined : json['type'], - }; -} -exports.USSDFromJSONTyped = USSDFromJSONTyped; -function USSDToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'type': value.type, - }; -} -exports.USSDToJSON = USSDToJSON; diff --git a/lib/models/VerificationBVNMatch.js b/lib/models/VerificationBVNMatch.js deleted file mode 100644 index c9e43d9..0000000 --- a/lib/models/VerificationBVNMatch.js +++ /dev/null @@ -1,52 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -Object.defineProperty(exports, "__esModule", { value: true }); -exports.VerificationBVNMatchToJSON = exports.VerificationBVNMatchFromJSONTyped = exports.VerificationBVNMatchFromJSON = void 0; -const runtime_1 = require("../runtime"); -function VerificationBVNMatchFromJSON(json) { - return VerificationBVNMatchFromJSONTyped(json, false); -} -exports.VerificationBVNMatchFromJSON = VerificationBVNMatchFromJSON; -function VerificationBVNMatchFromJSONTyped(json, ignoreDiscriminator) { - if ((json === undefined) || (json === null)) { - return json; - } - return { - 'accountNumber': json['account_number'], - 'bankCode': json['bank_code'], - 'bvn': json['bvn'], - 'firstName': !runtime_1.exists(json, 'first_name') ? undefined : json['first_name'], - 'middleName': !runtime_1.exists(json, 'middle_name') ? undefined : json['middle_name'], - 'lastName': !runtime_1.exists(json, 'last_name') ? undefined : json['last_name'], - }; -} -exports.VerificationBVNMatchFromJSONTyped = VerificationBVNMatchFromJSONTyped; -function VerificationBVNMatchToJSON(value) { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - 'account_number': value.accountNumber, - 'bank_code': value.bankCode, - 'bvn': value.bvn, - 'first_name': value.firstName, - 'middle_name': value.middleName, - 'last_name': value.lastName, - }; -} -exports.VerificationBVNMatchToJSON = VerificationBVNMatchToJSON; diff --git a/lib/models/index.js b/lib/models/index.js deleted file mode 100644 index 853e364..0000000 --- a/lib/models/index.js +++ /dev/null @@ -1,67 +0,0 @@ -"use strict"; -var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); -}) : (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - o[k2] = m[k]; -})); -var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -__exportStar(require("./Accepted"), exports); -__exportStar(require("./Bank"), exports); -__exportStar(require("./BulkChargeInitiate"), exports); -__exportStar(require("./ChargeCreate"), exports); -__exportStar(require("./ChargeSubmitAddress"), exports); -__exportStar(require("./ChargeSubmitBirthday"), exports); -__exportStar(require("./ChargeSubmitOTP"), exports); -__exportStar(require("./ChargeSubmitPhone"), exports); -__exportStar(require("./ChargeSubmitPin"), exports); -__exportStar(require("./CustomerCreate"), exports); -__exportStar(require("./CustomerDeactivateAuthorization"), exports); -__exportStar(require("./CustomerRiskAction"), exports); -__exportStar(require("./CustomerUpdate"), exports); -__exportStar(require("./CustomerValidate"), exports); -__exportStar(require("./CustomerValidation"), exports); -__exportStar(require("./DedicatedVirtualAccountCreate"), exports); -__exportStar(require("./DedicatedVirtualAccountSplit"), exports); -__exportStar(require("./DisputeEvidence"), exports); -__exportStar(require("./DisputeResolve"), exports); -__exportStar(require("./DisputeUpdate"), exports); -__exportStar(require("./EFT"), exports); -__exportStar(require("./MobileMoney"), exports); -__exportStar(require("./ModelError"), exports); -__exportStar(require("./PageCreate"), exports); -__exportStar(require("./PageProduct"), exports); -__exportStar(require("./PageUpdate"), exports); -__exportStar(require("./PaymentRequestCreate"), exports); -__exportStar(require("./PaymentRequestUpdate"), exports); -__exportStar(require("./PlanCreate"), exports); -__exportStar(require("./PlanUpdate"), exports); -__exportStar(require("./ProductCreate"), exports); -__exportStar(require("./ProductUpdate"), exports); -__exportStar(require("./RefundCreate"), exports); -__exportStar(require("./Response"), exports); -__exportStar(require("./SplitCreate"), exports); -__exportStar(require("./SplitSubaccounts"), exports); -__exportStar(require("./SplitUpdate"), exports); -__exportStar(require("./SubaccountCreate"), exports); -__exportStar(require("./SubaccountUpdate"), exports); -__exportStar(require("./SubscriptionCreate"), exports); -__exportStar(require("./SubscriptionToggle"), exports); -__exportStar(require("./TransactionChargeAuthorization"), exports); -__exportStar(require("./TransactionCheckAuthorization"), exports); -__exportStar(require("./TransactionInitialize"), exports); -__exportStar(require("./TransactionPartialDebit"), exports); -__exportStar(require("./TransferBulk"), exports); -__exportStar(require("./TransferFinalize"), exports); -__exportStar(require("./TransferFinalizeDisableOTP"), exports); -__exportStar(require("./TransferInitiate"), exports); -__exportStar(require("./TransferRecipientBulk"), exports); -__exportStar(require("./TransferRecipientCreate"), exports); -__exportStar(require("./TransferRecipientUpdate"), exports); -__exportStar(require("./TransferResendOTP"), exports); -__exportStar(require("./USSD"), exports); -__exportStar(require("./VerificationBVNMatch"), exports); diff --git a/lib/runtime.js b/lib/runtime.js deleted file mode 100644 index 2837621..0000000 --- a/lib/runtime.js +++ /dev/null @@ -1,106 +0,0 @@ -"use strict"; -/* tslint:disable */ -/* eslint-disable */ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { - function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } - return new (P || (P = Promise))(function (resolve, reject) { - function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } - function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } - function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } - step((generator = generator.apply(thisArg, _arguments || [])).next()); - }); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.mapValues = exports.exists = exports.RequiredError = exports.BaseAPI = void 0; -const https = require("https"); -const BASE_PATH = "https://api.paystack.co".replace(/\/+$/, ""); -/** - * This is the base class for all generated API classes. - */ -class BaseAPI { - constructor(apiKey) { - this.apiKey = apiKey; - } - request(params) { - return __awaiter(this, void 0, void 0, function* () { - // TODO: Do checks on params - const response = yield this.makeRequest(params); - // if (response.status >= 200 && response.status < 300) { - // return response; - // } - // throw response; - return response; - }); - } - makeRequest(request) { - const query = this.parseQueryParams(request.query); - const tempPath = query.length === 0 ? request.path : `${request.path}?${query}`; - const options = { - method: request.method, - path: tempPath, - headers: { - "authorization": `Bearer ${this.apiKey}`, - "user-agent": `@paystack/paystack-sdk - 1.0.1` - } - }; - return new Promise((resolve, reject) => { - const req = https.request(BASE_PATH, options, (res) => { - let data = []; - res.on('data', (chunk) => { - data.push(chunk); - }); - res.on('end', () => { - try { - resolve(JSON.parse(Buffer.concat(data).toString())); - } - catch (e) { - reject(e); - } - }); - }); - req.on('error', (e) => { - reject(e); - }); - if (request.body && Object.keys(request.body).length > 0) { - req.write(JSON.stringify(request.body)); - } - req.end(); - }); - } - parseQueryParams(queryParameters) { - if (queryParameters && Object.keys(queryParameters).length === 0) { - return ""; - } - return new URLSearchParams(queryParameters).toString(); - } -} -exports.BaseAPI = BaseAPI; -; -class RequiredError extends Error { - constructor(field, msg) { - super(msg); - this.field = field; - this.name = "RequiredError"; - } -} -exports.RequiredError = RequiredError; -function exists(json, key) { - const value = json[key]; - return value !== null && value !== undefined; -} -exports.exists = exists; -function mapValues(data, fn) { - return Object.keys(data).reduce((acc, key) => (Object.assign(Object.assign({}, acc), { [key]: fn(data[key]) })), {}); -} -exports.mapValues = mapValues; diff --git a/lib/types/apis/Balance.d.ts b/lib/types/apis/Balance.d.ts deleted file mode 100644 index 15fa176..0000000 --- a/lib/types/apis/Balance.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface LedgerRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -/** - * - */ -export declare class Balance extends BaseAPI { - /** - * You can only transfer from what you have - * Fetch Balance - */ - fetch(): Promise; - /** - * Balance Ledger - */ - ledger(requestParameters: LedgerRequest): Promise; -} diff --git a/lib/types/apis/BulkCharge.d.ts b/lib/types/apis/BulkCharge.d.ts deleted file mode 100644 index 1d6b284..0000000 --- a/lib/types/apis/BulkCharge.d.ts +++ /dev/null @@ -1,60 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface ChargesRequest { - code: string; -} -export interface FetchRequest { - code: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -export interface PauseRequest { - code: string; -} -export interface ResumeRequest { - code: string; -} -/** - * - */ -export declare class BulkCharge extends BaseAPI { - /** - * Fetch Charges in a Batch - */ - charges(requestParameters: ChargesRequest): Promise; - /** - * Fetch Bulk Charge Batch - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * Initiate Bulk Charge - */ - initiate(): Promise; - /** - * List Bulk Charge Batches - */ - list(requestParameters: ListRequest): Promise; - /** - * Pause Bulk Charge Batch - */ - pause(requestParameters: PauseRequest): Promise; - /** - * Resume Bulk Charge Batch - */ - resume(requestParameters: ResumeRequest): Promise; -} diff --git a/lib/types/apis/Charge.d.ts b/lib/types/apis/Charge.d.ts deleted file mode 100644 index 27dfb25..0000000 --- a/lib/types/apis/Charge.d.ts +++ /dev/null @@ -1,86 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Bank, EFT, MobileMoney, Response, USSD } from '../models'; -export interface CheckRequest { - reference: string; -} -export interface CreateRequest { - email?: string; - amount?: string; - authorization_code?: string; - pin?: string; - reference?: string; - birthday?: Date; - device_id?: string; - metadata?: string; - bank?: Bank; - mobile_money?: MobileMoney; - ussd?: USSD; - eft?: EFT; -} -export interface SubmitAddressRequest { - address: string; - city: string; - state: string; - zipcode: string; - reference: string; -} -export interface SubmitBirthdayRequest { - birthday: string; - reference: string; -} -export interface SubmitOtpRequest { - otp: string; - reference: string; -} -export interface SubmitPhoneRequest { - phone: string; - reference: string; -} -export interface SubmitPinRequest { - pin: string; - reference: string; -} -/** - * - */ -export declare class Charge extends BaseAPI { - /** - * Check pending charge - */ - check(requestParameters: CheckRequest): Promise; - /** - * Create Charge - */ - create(requestParameters: CreateRequest): Promise; - /** - * Submit Address - */ - submitAddress(requestParameters: SubmitAddressRequest): Promise; - /** - * Submit Birthday - */ - submitBirthday(requestParameters: SubmitBirthdayRequest): Promise; - /** - * Submit OTP - */ - submitOtp(requestParameters: SubmitOtpRequest): Promise; - /** - * Submit Phone - */ - submitPhone(requestParameters: SubmitPhoneRequest): Promise; - /** - * Submit PIN - */ - submitPin(requestParameters: SubmitPinRequest): Promise; -} diff --git a/lib/types/apis/Customer.d.ts b/lib/types/apis/Customer.d.ts deleted file mode 100644 index 9170627..0000000 --- a/lib/types/apis/Customer.d.ts +++ /dev/null @@ -1,94 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Accepted, Response } from '../models'; -export interface CreateRequest { - email: string; - first_name?: string; - last_name?: string; - phone?: string; - metadata?: string; -} -export interface DeactivateAuthorizationRequest { - authorization_code: string; -} -export interface FetchRequest { - code: string; -} -export interface ListRequest { - use_cursor?: boolean; - next?: string; - previous?: string; - from?: string; - to?: string; - perPage?: string; - page?: string; -} -export interface RiskActionRequest { - customer: string; - risk_action?: string; -} -export interface UpdateRequest { - code: string; - first_name?: string; - last_name?: string; - phone?: string; - metadata?: string; -} -export interface ValidateRequest { - code: string; - first_name: string; - last_name: string; - type: string; - country: string; - bvn: string; - bank_code: string; - account_number: string; - value?: string; -} -/** - * - */ -export declare class Customer extends BaseAPI { - /** - * Create Customer - */ - create(requestParameters: CreateRequest): Promise; - /** - * Deactivate a customer\'s card - * Deactivate Authorization - */ - deactivateAuthorization(requestParameters: DeactivateAuthorizationRequest): Promise; - /** - * Fetch Customer - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List customers on your integration - * List Customers - */ - list(requestParameters: ListRequest): Promise; - /** - * Set customer\'s risk action by whitelisting or blacklisting the customer - * White/blacklist Customer - */ - riskAction(requestParameters: RiskActionRequest): Promise; - /** - * Update Customer - */ - update(requestParameters: UpdateRequest): Promise; - /** - * Validate a customer\'s identity - * Validate Customer - */ - validate(requestParameters: ValidateRequest): Promise; -} diff --git a/lib/types/apis/DedicatedVirtualAccount.d.ts b/lib/types/apis/DedicatedVirtualAccount.d.ts deleted file mode 100644 index 9469616..0000000 --- a/lib/types/apis/DedicatedVirtualAccount.d.ts +++ /dev/null @@ -1,78 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface AddSplitRequest { - account_number: string; - subaccount?: string; - split_code?: string; -} -export interface CreateRequest { - customer: string; - preferred_bank?: string; - subaccount?: string; - split_code?: string; -} -export interface DeactivateRequest { - account_id: string; -} -export interface FetchRequest { - account_id: string; -} -export interface ListRequest { - account_number?: string; - customer?: string; - active?: boolean; - currency?: string; - provider_slug?: string; - bank_id?: string; - perPage?: string; - page?: string; -} -export interface RemoveSplitRequest { - account_number: string; - subaccount?: string; - split_code?: string; -} -/** - * - */ -export declare class DedicatedVirtualAccount extends BaseAPI { - /** - * Split Dedicated Account Transaction - */ - addSplit(requestParameters: AddSplitRequest): Promise; - /** - * Fetch Bank Providers - */ - availableProviders(): Promise; - /** - * Create Dedicated Account - */ - create(requestParameters: CreateRequest): Promise; - /** - * Deactivate Dedicated Account - */ - deactivate(requestParameters: DeactivateRequest): Promise; - /** - * Fetch Dedicated Account - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Dedicated Accounts - */ - list(requestParameters: ListRequest): Promise; - /** - * Remove Split from Dedicated Account - */ - removeSplit(requestParameters: RemoveSplitRequest): Promise; -} diff --git a/lib/types/apis/Dispute.d.ts b/lib/types/apis/Dispute.d.ts deleted file mode 100644 index cd760bc..0000000 --- a/lib/types/apis/Dispute.d.ts +++ /dev/null @@ -1,96 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface DownloadRequest { - perPage?: number; - page?: number; - status?: string; - from?: Date; - to?: Date; -} -export interface EvidenceRequest { - id: string; - customer_email: string; - customer_name: string; - customer_phone: string; - service_details: string; - delivery_address?: string; - delivery_date?: Date; -} -export interface FetchRequest { - id: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - status?: string; - transaction?: string; - from?: Date; - to?: Date; -} -export interface ResolveRequest { - id: string; - resolution: string; - message: string; - refund_amount: string; - uploaded_filename: string; - evidence?: number; -} -export interface TransactionRequest { - id: string; -} -export interface UpdateRequest { - id: string; - refund_amount: string; - uploaded_filename?: string; -} -export interface UploadUrlRequest { - id: string; -} -/** - * - */ -export declare class Dispute extends BaseAPI { - /** - * Export Disputes - */ - download(requestParameters: DownloadRequest): Promise; - /** - * Add Evidence - */ - evidence(requestParameters: EvidenceRequest): Promise; - /** - * Fetch Dispute - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Disputes - */ - list(requestParameters: ListRequest): Promise; - /** - * Resolve a Dispute - */ - resolve(requestParameters: ResolveRequest): Promise; - /** - * List Transaction Disputes - */ - transaction(requestParameters: TransactionRequest): Promise; - /** - * Update Dispute - */ - update(requestParameters: UpdateRequest): Promise; - /** - * Get Upload URL - */ - uploadUrl(requestParameters: UploadUrlRequest): Promise; -} diff --git a/lib/types/apis/Integration.d.ts b/lib/types/apis/Integration.d.ts deleted file mode 100644 index c4111e9..0000000 --- a/lib/types/apis/Integration.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface UpdatePaymentSessionTimeoutRequest { - body?: object; -} -/** - * - */ -export declare class Integration extends BaseAPI { - /** - * Fetch Payment Session Timeout - */ - fetchPaymentSessionTimeout(): Promise; - /** - * Update Payment Session Timeout - */ - updatePaymentSessionTimeout(requestParameters: UpdatePaymentSessionTimeoutRequest): Promise; -} diff --git a/lib/types/apis/Page.d.ts b/lib/types/apis/Page.d.ts deleted file mode 100644 index 8957510..0000000 --- a/lib/types/apis/Page.d.ts +++ /dev/null @@ -1,74 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface AddProductsRequest { - id: string; - product: Array; -} -export interface CheckSlugAvailabilityRequest { - slug: string; -} -export interface CreateRequest { - name: string; - description?: string; - amount?: number; - slug?: string; - metadata?: string; - redirect_url?: string; - custom_fields?: Array; -} -export interface FetchRequest { - id: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -export interface UpdateRequest { - id: string; - name?: string; - description?: string; - amount?: number; - active?: boolean; -} -/** - * - */ -export declare class Page extends BaseAPI { - /** - * Add Products - */ - addProducts(requestParameters: AddProductsRequest): Promise; - /** - * Check Slug Availability - */ - checkSlugAvailability(requestParameters: CheckSlugAvailabilityRequest): Promise; - /** - * Create Page - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Page - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Pages - */ - list(requestParameters: ListRequest): Promise; - /** - * Update Page - */ - update(requestParameters: UpdateRequest): Promise; -} diff --git a/lib/types/apis/PaymentRequest.d.ts b/lib/types/apis/PaymentRequest.d.ts deleted file mode 100644 index 16f2610..0000000 --- a/lib/types/apis/PaymentRequest.d.ts +++ /dev/null @@ -1,107 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface ArchiveRequest { - id: string; -} -export interface CreateRequest { - customer: string; - amount?: number; - currency?: string; - due_date?: Date; - description?: string; - line_items?: Array; - tax?: Array; - send_notification?: Array; - draft?: Array; - has_invoice?: Array; - invoice_number?: number; - split_code?: string; -} -export interface FetchRequest { - id: string; -} -export interface FinalizeRequest { - id: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - customer?: string; - status?: string; - currency?: string; - from?: Date; - to?: Date; -} -export interface NotifyRequest { - id: string; -} -export interface UpdateRequest { - id: string; - customer?: string; - amount?: number; - currency?: string; - due_date?: Date; - description?: string; - line_items?: Array; - tax?: Array; - send_notification?: Array; - draft?: Array; - has_invoice?: Array; - invoice_number?: number; - split_code?: string; -} -export interface VerifyRequest { - id: string; -} -/** - * - */ -export declare class PaymentRequest extends BaseAPI { - /** - * Archive Payment Request - */ - archive(requestParameters: ArchiveRequest): Promise; - /** - * Create Payment Request - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Payment Request - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * Finalize Payment Request - */ - finalize(requestParameters: FinalizeRequest): Promise; - /** - * List Payment Request - */ - list(requestParameters: ListRequest): Promise; - /** - * Send Notification - */ - notify(requestParameters: NotifyRequest): Promise; - /** - * Payment Request Total - */ - totals(): Promise; - /** - * Update Payment Request - */ - update(requestParameters: UpdateRequest): Promise; - /** - * Verify Payment Request - */ - verify(requestParameters: VerifyRequest): Promise; -} diff --git a/lib/types/apis/Plan.d.ts b/lib/types/apis/Plan.d.ts deleted file mode 100644 index 4eb15a2..0000000 --- a/lib/types/apis/Plan.d.ts +++ /dev/null @@ -1,66 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface CreateRequest { - name: string; - amount: number; - interval: string; - description?: boolean; - send_invoices?: boolean; - send_sms?: boolean; - currency?: string; - invoice_limit?: number; -} -export interface FetchRequest { - code: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - interval?: string; - amount?: number; - from?: Date; - to?: Date; -} -export interface UpdateRequest { - code: string; - name?: string; - amount?: number; - interval?: string; - description?: boolean; - send_invoices?: boolean; - send_sms?: boolean; - currency?: string; - invoice_limit?: number; -} -/** - * - */ -export declare class Plan extends BaseAPI { - /** - * Create Plan - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Plan - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Plans - */ - list(requestParameters: ListRequest): Promise; - /** - * Update Plan - */ - update(requestParameters: UpdateRequest): Promise; -} diff --git a/lib/types/apis/Product.d.ts b/lib/types/apis/Product.d.ts deleted file mode 100644 index 0f0a597..0000000 --- a/lib/types/apis/Product.d.ts +++ /dev/null @@ -1,68 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface DeleteRequest { - id: string; -} -export interface CreateRequest { - name: string; - description: string; - price: number; - currency: string; - limited?: boolean; - quantity?: number; -} -export interface FetchRequest { - id: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - active?: boolean; - from?: Date; - to?: Date; -} -export interface UpdateRequest { - id: string; - name?: string; - description?: string; - price?: number; - currency?: string; - limited?: boolean; - quantity?: number; -} -/** - * - */ -export declare class Product extends BaseAPI { - /** - * Delete Product - */ - _delete(requestParameters: DeleteRequest): Promise; - /** - * Create Product - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Product - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Products - */ - list(requestParameters: ListRequest): Promise; - /** - * Update product - */ - update(requestParameters: UpdateRequest): Promise; -} diff --git a/lib/types/apis/Refund.d.ts b/lib/types/apis/Refund.d.ts deleted file mode 100644 index 373615a..0000000 --- a/lib/types/apis/Refund.d.ts +++ /dev/null @@ -1,46 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface CreateRequest { - transaction: string; - amount?: number; - currency?: string; - customer_note?: string; - merchant_note?: string; -} -export interface FetchRequest { - id: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -/** - * - */ -export declare class Refund extends BaseAPI { - /** - * Create Refund - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Refund - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Refunds - */ - list(requestParameters: ListRequest): Promise; -} diff --git a/lib/types/apis/Settlement.d.ts b/lib/types/apis/Settlement.d.ts deleted file mode 100644 index eaca315..0000000 --- a/lib/types/apis/Settlement.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface FetchRequest { - perPage?: number; - page?: number; -} -export interface TransactionRequest { - id: string; -} -/** - * - */ -export declare class Settlement extends BaseAPI { - /** - * Fetch Settlements - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * Settlement Transactions - */ - transaction(requestParameters: TransactionRequest): Promise; -} diff --git a/lib/types/apis/Split.d.ts b/lib/types/apis/Split.d.ts deleted file mode 100644 index b1d1a68..0000000 --- a/lib/types/apis/Split.d.ts +++ /dev/null @@ -1,79 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response, SplitSubaccounts } from '../models'; -export interface AddSubaccountRequest { - id: string; - subaccount?: string; - share?: string; -} -export interface CreateRequest { - name: string; - type: string; - subaccounts: Array; - currency: string; - bearer_type?: string; - bearer_subaccount?: string; -} -export interface FetchRequest { - id: string; -} -export interface ListRequest { - name?: string; - active?: string; - sort_by?: string; - from?: string; - to?: string; - perPage?: string; - page?: string; -} -export interface RemoveSubaccountRequest { - id: string; - subaccount?: string; - share?: string; -} -export interface UpdateRequest { - id: string; - name?: string; - active?: boolean; - bearer_type?: string; - bearer_subaccount?: string; -} -/** - * - */ -export declare class Split extends BaseAPI { - /** - * Add Subaccount to Split - */ - addSubaccount(requestParameters: AddSubaccountRequest): Promise; - /** - * Create Split - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Split - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List/Search Splits - */ - list(requestParameters: ListRequest): Promise; - /** - * Remove Subaccount from split - */ - removeSubaccount(requestParameters: RemoveSubaccountRequest): Promise; - /** - * Update Split - */ - update(requestParameters: UpdateRequest): Promise; -} diff --git a/lib/types/apis/Subaccount.d.ts b/lib/types/apis/Subaccount.d.ts deleted file mode 100644 index 375c1de..0000000 --- a/lib/types/apis/Subaccount.d.ts +++ /dev/null @@ -1,67 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface CreateRequest { - business_name: string; - settlement_bank: string; - account_number: string; - percentage_charge: number; - description?: string; - primary_contact_email?: string; - primary_contact_name?: string; - primary_contact_phone?: string; - metadata?: string; -} -export interface FetchRequest { - code: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -export interface UpdateRequest { - code: string; - business_name?: string; - settlement_bank?: string; - account_number?: string; - active?: boolean; - percentage_charge?: number; - description?: string; - primary_contact_email?: string; - primary_contact_name?: string; - primary_contact_phone?: string; - metadata?: string; -} -/** - * - */ -export declare class Subaccount extends BaseAPI { - /** - * Create Subaccount - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Subaccount - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Subaccounts - */ - list(requestParameters: ListRequest): Promise; - /** - * Update Subaccount - */ - update(requestParameters: UpdateRequest): Promise; -} diff --git a/lib/types/apis/Subscription.d.ts b/lib/types/apis/Subscription.d.ts deleted file mode 100644 index 7684244..0000000 --- a/lib/types/apis/Subscription.d.ts +++ /dev/null @@ -1,77 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface CreateRequest { - customer: string; - plan: string; - authorization?: string; - start_date?: Date; -} -export interface DisableRequest { - code: string; - token: string; -} -export interface EnableRequest { - code: string; - token: string; -} -export interface FetchRequest { - code: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - plan?: string; - customer?: string; - from?: Date; - to?: Date; -} -export interface ManageEmailRequest { - code: string; -} -export interface ManageLinkRequest { - code: string; -} -/** - * - */ -export declare class Subscription extends BaseAPI { - /** - * Create Subscription - */ - create(requestParameters: CreateRequest): Promise; - /** - * Disable Subscription - */ - disable(requestParameters: DisableRequest): Promise; - /** - * Enable Subscription - */ - enable(requestParameters: EnableRequest): Promise; - /** - * Fetch Subscription - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Subscriptions - */ - list(requestParameters: ListRequest): Promise; - /** - * Send Update Subscription Link - */ - manageEmail(requestParameters: ManageEmailRequest): Promise; - /** - * Generate Update Subscription Link - */ - manageLink(requestParameters: ManageLinkRequest): Promise; -} diff --git a/lib/types/apis/Transaction.d.ts b/lib/types/apis/Transaction.d.ts deleted file mode 100644 index b3c7c5f..0000000 --- a/lib/types/apis/Transaction.d.ts +++ /dev/null @@ -1,147 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface ChargeAuthorizationRequest { - email: string; - amount: number; - authorization_code: string; - reference?: string; - currency?: string; - metadata?: string; - split_code?: string; - subaccount?: string; - transaction_charge?: string; - bearer?: string; - queue?: boolean; -} -export interface CheckAuthorizationRequest { - email: string; - amount: number; - authorization_code?: string; - currency?: string; -} -export interface DownloadRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -export interface EventRequest { - id: string; -} -export interface FetchRequest { - id: string; -} -export interface InitializeRequest { - email: string; - amount: number; - currency?: string; - reference?: string; - callback_url?: string; - plan?: string; - invoice_limit?: number; - metadata?: string; - channels?: Array; - split_code?: string; - subaccount?: string; - transaction_charge?: string; - bearer?: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -export interface PartialDebitRequest { - email: string; - amount: number; - authorization_code: string; - currency: string; - reference?: string; - at_least?: string; -} -export interface SessionRequest { - id: string; -} -export interface TimelineRequest { - id_or_reference: string; -} -export interface TotalsRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -export interface VerifyRequest { - reference: string; -} -/** - * - */ -export declare class Transaction extends BaseAPI { - /** - * Charge Authorization - */ - chargeAuthorization(requestParameters: ChargeAuthorizationRequest): Promise; - /** - * Check Authorization - */ - checkAuthorization(requestParameters: CheckAuthorizationRequest): Promise; - /** - * Export Transactions - */ - download(requestParameters: DownloadRequest): Promise; - /** - * Get Transaction Event - */ - event(requestParameters: EventRequest): Promise; - /** - * Fetch a transaction to get its details - * Fetch Transaction - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * Create a new transaction - * Initialize Transaction - */ - initialize(requestParameters: InitializeRequest): Promise; - /** - * List transactions that has occurred on your integration - * List Transactions - */ - list(requestParameters: ListRequest): Promise; - /** - * Partial Debit - */ - partialDebit(requestParameters: PartialDebitRequest): Promise; - /** - * Get Transaction Session - */ - session(requestParameters: SessionRequest): Promise; - /** - * Get the details about the lifecycle of a transaction from initiation to completion - * Fetch Transaction Timeline - */ - timeline(requestParameters: TimelineRequest): Promise; - /** - * Get the total amount of all transactions - * Transaction Totals - */ - totals(requestParameters: TotalsRequest): Promise; - /** - * Verify a previously initiated transaction using it\'s reference - * Verify Transaction - */ - verify(requestParameters: VerifyRequest): Promise; -} diff --git a/lib/types/apis/Transfer.d.ts b/lib/types/apis/Transfer.d.ts deleted file mode 100644 index bd24d88..0000000 --- a/lib/types/apis/Transfer.d.ts +++ /dev/null @@ -1,105 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response, TransferInitiate } from '../models'; -export interface BulkRequest { - source?: string; - transfers?: Array; -} -export interface DisableOtpFinalizeRequest { - otp: string; -} -export interface DownloadRequest { - perPage?: number; - page?: number; - status?: string; - from?: Date; - to?: Date; -} -export interface FetchRequest { - code: string; -} -export interface FinalizeRequest { - transfer_code: string; - otp: string; -} -export interface InitiateRequest { - source: string; - amount: string; - recipient: string; - reason?: string; - currency?: string; - reference?: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - status?: string; - from?: Date; - to?: Date; -} -export interface ResendOtpRequest { - transfer_code: string; - reason: string; -} -export interface VerifyRequest { - reference: string; -} -/** - * - */ -export declare class Transfer extends BaseAPI { - /** - * Initiate Bulk Transfer - */ - bulk(requestParameters: BulkRequest): Promise; - /** - * Disable OTP requirement for Transfers - */ - disableOtp(): Promise; - /** - * Finalize Disabling of OTP requirement for Transfers - */ - disableOtpFinalize(requestParameters: DisableOtpFinalizeRequest): Promise; - /** - * Export Transfers - */ - download(requestParameters: DownloadRequest): Promise; - /** - * Enable OTP requirement for Transfers - */ - enableOtp(): Promise; - /** - * Fetch Transfer - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * Finalize Transfer - */ - finalize(requestParameters: FinalizeRequest): Promise; - /** - * Initiate Transfer - */ - initiate(requestParameters: InitiateRequest): Promise; - /** - * List Transfers - */ - list(requestParameters: ListRequest): Promise; - /** - * Resend OTP for Transfer - */ - resendOtp(requestParameters: ResendOtpRequest): Promise; - /** - * Verify Transfer - */ - verify(requestParameters: VerifyRequest): Promise; -} diff --git a/lib/types/apis/TransferRecipient.d.ts b/lib/types/apis/TransferRecipient.d.ts deleted file mode 100644 index b8a2a44..0000000 --- a/lib/types/apis/TransferRecipient.d.ts +++ /dev/null @@ -1,72 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response, TransferRecipientCreate } from '../models'; -export interface BulkRequest { - batch: Array; -} -export interface CreateRequest { - type: string; - name: string; - account_number: string; - bank_code: string; - description?: string; - currency?: string; - authorization_code?: string; - metadata?: string; -} -export interface FetchRequest { - code: string; -} -export interface ListRequest { - perPage?: number; - page?: number; - from?: Date; - to?: Date; -} -export interface TransferrecipientCodeDeleteRequest { - code: string; -} -export interface TransferrecipientCodePutRequest { - code: string; - name?: string; - email?: string; -} -/** - * - */ -export declare class TransferRecipient extends BaseAPI { - /** - * Bulk Create Transfer Recipient - */ - bulk(requestParameters: BulkRequest): Promise; - /** - * Create Transfer Recipient - */ - create(requestParameters: CreateRequest): Promise; - /** - * Fetch Transfer recipient - */ - fetch(requestParameters: FetchRequest): Promise; - /** - * List Transfer Recipients - */ - list(requestParameters: ListRequest): Promise; - /** - * Delete Transfer Recipient - */ - transferrecipientCodeDelete(requestParameters: TransferrecipientCodeDeleteRequest): Promise; - /** - * Update Transfer recipient - */ - transferrecipientCodePut(requestParameters: TransferrecipientCodePutRequest): Promise; -} diff --git a/lib/types/apis/Verification.d.ts b/lib/types/apis/Verification.d.ts deleted file mode 100644 index d722245..0000000 --- a/lib/types/apis/Verification.d.ts +++ /dev/null @@ -1,59 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { BaseAPI } from '../runtime'; -import { Response } from '../models'; -export interface AvsRequest { - type?: string; - country?: string; - currency?: string; -} -export interface FetchBanksRequest { - country?: string; - pay_with_bank_transfer?: boolean; - use_cursor?: boolean; - perPage?: number; - next?: string; - previous?: string; - gateway?: string; -} -export interface ResolveAccountNumberRequest { - account_number?: number; - bank_code?: number; -} -export interface ResolveCardBinRequest { - bin: string; -} -/** - * - */ -export declare class Verification extends BaseAPI { - /** - * List States (AVS) - */ - avs(requestParameters: AvsRequest): Promise; - /** - * Fetch Banks - */ - fetchBanks(requestParameters: FetchBanksRequest): Promise; - /** - * List Countries - */ - listCountries(): Promise; - /** - * Resolve Account Number - */ - resolveAccountNumber(requestParameters: ResolveAccountNumberRequest): Promise; - /** - * Resolve Card BIN - */ - resolveCardBin(requestParameters: ResolveCardBinRequest): Promise; -} diff --git a/lib/types/apis/index.d.ts b/lib/types/apis/index.d.ts deleted file mode 100644 index 51d0f44..0000000 --- a/lib/types/apis/index.d.ts +++ /dev/null @@ -1,20 +0,0 @@ -export * as Balance from './Balance'; -export * as BulkCharge from './BulkCharge'; -export * as Charge from './Charge'; -export * as Customer from './Customer'; -export * as DedicatedVirtualAccount from './DedicatedVirtualAccount'; -export * as Dispute from './Dispute'; -export * as Integration from './Integration'; -export * as Page from './Page'; -export * as PaymentRequest from './PaymentRequest'; -export * as Plan from './Plan'; -export * as Product from './Product'; -export * as Refund from './Refund'; -export * as Settlement from './Settlement'; -export * as Split from './Split'; -export * as Subaccount from './Subaccount'; -export * as Subscription from './Subscription'; -export * as Transaction from './Transaction'; -export * as Transfer from './Transfer'; -export * as TransferRecipient from './TransferRecipient'; -export * as Verification from './Verification'; diff --git a/lib/types/index.d.ts b/lib/types/index.d.ts deleted file mode 100644 index 86d587c..0000000 --- a/lib/types/index.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -export declare class Paystack { - [index: string]: any; - constructor(apiKey: string); - private extend; - private toCamelCase; - private cleanResourceKey; -} diff --git a/lib/types/models/Accepted.d.ts b/lib/types/models/Accepted.d.ts deleted file mode 100644 index 7b15c0e..0000000 --- a/lib/types/models/Accepted.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface Accepted - */ -export interface Accepted { - /** - * - * @type {boolean} - * @memberof Accepted - */ - status?: boolean; - /** - * - * @type {string} - * @memberof Accepted - */ - message?: string; -} -export declare function AcceptedFromJSON(json: any): Accepted; -export declare function AcceptedFromJSONTyped(json: any, ignoreDiscriminator: boolean): Accepted; -export declare function AcceptedToJSON(value?: Accepted | null): any; diff --git a/lib/types/models/Bank.d.ts b/lib/types/models/Bank.d.ts deleted file mode 100644 index cb3fa2e..0000000 --- a/lib/types/models/Bank.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface Bank - */ -export interface Bank { - /** - * Customer's bank code - * @type {string} - * @memberof Bank - */ - code?: string; - /** - * Customer's account number - * @type {string} - * @memberof Bank - */ - accountNumber?: string; -} -export declare function BankFromJSON(json: any): Bank; -export declare function BankFromJSONTyped(json: any, ignoreDiscriminator: boolean): Bank; -export declare function BankToJSON(value?: Bank | null): any; diff --git a/lib/types/models/BulkChargeInitiate.d.ts b/lib/types/models/BulkChargeInitiate.d.ts deleted file mode 100644 index 2e92f42..0000000 --- a/lib/types/models/BulkChargeInitiate.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface BulkChargeInitiate - */ -export interface BulkChargeInitiate { - /** - * Customer's card authorization code - * @type {string} - * @memberof BulkChargeInitiate - */ - authorization: string; - /** - * Amount to charge on the authorization - * @type {string} - * @memberof BulkChargeInitiate - */ - amount: string; -} -export declare function BulkChargeInitiateFromJSON(json: any): BulkChargeInitiate; -export declare function BulkChargeInitiateFromJSONTyped(json: any, ignoreDiscriminator: boolean): BulkChargeInitiate; -export declare function BulkChargeInitiateToJSON(value?: BulkChargeInitiate | null): any; diff --git a/lib/types/models/ChargeCreate.d.ts b/lib/types/models/ChargeCreate.d.ts deleted file mode 100644 index 56f591b..0000000 --- a/lib/types/models/ChargeCreate.d.ts +++ /dev/null @@ -1,70 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ChargeCreate - */ -export interface ChargeCreate { - /** - * Customer's email address - * @type {string} - * @memberof ChargeCreate - */ - email: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {string} - * @memberof ChargeCreate - */ - amount: string; - /** - * An authorization code to charge. - * @type {string} - * @memberof ChargeCreate - */ - authorizationCode?: string; - /** - * 4-digit PIN (send with a non-reusable authorization code) - * @type {string} - * @memberof ChargeCreate - */ - pin?: string; - /** - * Unique transaction reference. Only -, .`, = and alphanumeric characters allowed. - * @type {string} - * @memberof ChargeCreate - */ - reference?: string; - /** - * The customer's birthday in the format YYYY-MM-DD e.g 2017-05-16 - * @type {Date} - * @memberof ChargeCreate - */ - birthday?: Date; - /** - * This is the unique identifier of the device a user uses in making payment. - * Only -, .`, = and alphanumeric characters are allowed. - * @type {string} - * @memberof ChargeCreate - */ - deviceId?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof ChargeCreate - */ - metadata?: string; -} -export declare function ChargeCreateFromJSON(json: any): ChargeCreate; -export declare function ChargeCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): ChargeCreate; -export declare function ChargeCreateToJSON(value?: ChargeCreate | null): any; diff --git a/lib/types/models/ChargeSubmitAddress.d.ts b/lib/types/models/ChargeSubmitAddress.d.ts deleted file mode 100644 index 28d3dc5..0000000 --- a/lib/types/models/ChargeSubmitAddress.d.ts +++ /dev/null @@ -1,51 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ChargeSubmitAddress - */ -export interface ChargeSubmitAddress { - /** - * Customer's address - * @type {string} - * @memberof ChargeSubmitAddress - */ - address: string; - /** - * Customer's city - * @type {string} - * @memberof ChargeSubmitAddress - */ - city: string; - /** - * Customer's state - * @type {string} - * @memberof ChargeSubmitAddress - */ - state: string; - /** - * Customer's zipcode - * @type {string} - * @memberof ChargeSubmitAddress - */ - zipcode: string; - /** - * The reference of the ongoing transaction - * @type {string} - * @memberof ChargeSubmitAddress - */ - reference: string; -} -export declare function ChargeSubmitAddressFromJSON(json: any): ChargeSubmitAddress; -export declare function ChargeSubmitAddressFromJSONTyped(json: any, ignoreDiscriminator: boolean): ChargeSubmitAddress; -export declare function ChargeSubmitAddressToJSON(value?: ChargeSubmitAddress | null): any; diff --git a/lib/types/models/ChargeSubmitBirthday.d.ts b/lib/types/models/ChargeSubmitBirthday.d.ts deleted file mode 100644 index 38af0a3..0000000 --- a/lib/types/models/ChargeSubmitBirthday.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ChargeSubmitBirthday - */ -export interface ChargeSubmitBirthday { - /** - * Customer's birthday in the format YYYY-MM-DD e.g 2016-09-21 - * @type {string} - * @memberof ChargeSubmitBirthday - */ - birthday: string; - /** - * The reference of the ongoing transaction - * @type {string} - * @memberof ChargeSubmitBirthday - */ - reference: string; -} -export declare function ChargeSubmitBirthdayFromJSON(json: any): ChargeSubmitBirthday; -export declare function ChargeSubmitBirthdayFromJSONTyped(json: any, ignoreDiscriminator: boolean): ChargeSubmitBirthday; -export declare function ChargeSubmitBirthdayToJSON(value?: ChargeSubmitBirthday | null): any; diff --git a/lib/types/models/ChargeSubmitOTP.d.ts b/lib/types/models/ChargeSubmitOTP.d.ts deleted file mode 100644 index 6f1be4d..0000000 --- a/lib/types/models/ChargeSubmitOTP.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ChargeSubmitOTP - */ -export interface ChargeSubmitOTP { - /** - * Customer's OTP - * @type {string} - * @memberof ChargeSubmitOTP - */ - otp: string; - /** - * The reference of the ongoing transaction - * @type {string} - * @memberof ChargeSubmitOTP - */ - reference: string; -} -export declare function ChargeSubmitOTPFromJSON(json: any): ChargeSubmitOTP; -export declare function ChargeSubmitOTPFromJSONTyped(json: any, ignoreDiscriminator: boolean): ChargeSubmitOTP; -export declare function ChargeSubmitOTPToJSON(value?: ChargeSubmitOTP | null): any; diff --git a/lib/types/models/ChargeSubmitPhone.d.ts b/lib/types/models/ChargeSubmitPhone.d.ts deleted file mode 100644 index 5b1608b..0000000 --- a/lib/types/models/ChargeSubmitPhone.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ChargeSubmitPhone - */ -export interface ChargeSubmitPhone { - /** - * Customer's mobile number - * @type {string} - * @memberof ChargeSubmitPhone - */ - phone: string; - /** - * The reference of the ongoing transaction - * @type {string} - * @memberof ChargeSubmitPhone - */ - reference: string; -} -export declare function ChargeSubmitPhoneFromJSON(json: any): ChargeSubmitPhone; -export declare function ChargeSubmitPhoneFromJSONTyped(json: any, ignoreDiscriminator: boolean): ChargeSubmitPhone; -export declare function ChargeSubmitPhoneToJSON(value?: ChargeSubmitPhone | null): any; diff --git a/lib/types/models/ChargeSubmitPin.d.ts b/lib/types/models/ChargeSubmitPin.d.ts deleted file mode 100644 index d75ec3e..0000000 --- a/lib/types/models/ChargeSubmitPin.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ChargeSubmitPin - */ -export interface ChargeSubmitPin { - /** - * Customer's PIN - * @type {string} - * @memberof ChargeSubmitPin - */ - pin: string; - /** - * Transaction reference that requires the PIN - * @type {string} - * @memberof ChargeSubmitPin - */ - reference: string; -} -export declare function ChargeSubmitPinFromJSON(json: any): ChargeSubmitPin; -export declare function ChargeSubmitPinFromJSONTyped(json: any, ignoreDiscriminator: boolean): ChargeSubmitPin; -export declare function ChargeSubmitPinToJSON(value?: ChargeSubmitPin | null): any; diff --git a/lib/types/models/CustomerCreate.d.ts b/lib/types/models/CustomerCreate.d.ts deleted file mode 100644 index f310b02..0000000 --- a/lib/types/models/CustomerCreate.d.ts +++ /dev/null @@ -1,51 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface CustomerCreate - */ -export interface CustomerCreate { - /** - * Customer's email address - * @type {string} - * @memberof CustomerCreate - */ - email: string; - /** - * Customer's first name - * @type {string} - * @memberof CustomerCreate - */ - firstName?: string; - /** - * Customer's last name - * @type {string} - * @memberof CustomerCreate - */ - lastName?: string; - /** - * Customer's phone number - * @type {string} - * @memberof CustomerCreate - */ - phone?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof CustomerCreate - */ - metadata?: string; -} -export declare function CustomerCreateFromJSON(json: any): CustomerCreate; -export declare function CustomerCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): CustomerCreate; -export declare function CustomerCreateToJSON(value?: CustomerCreate | null): any; diff --git a/lib/types/models/CustomerDeactivateAuthorization.d.ts b/lib/types/models/CustomerDeactivateAuthorization.d.ts deleted file mode 100644 index 858fb42..0000000 --- a/lib/types/models/CustomerDeactivateAuthorization.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface CustomerDeactivateAuthorization - */ -export interface CustomerDeactivateAuthorization { - /** - * Authorization code to be deactivated - * @type {string} - * @memberof CustomerDeactivateAuthorization - */ - authorizationCode: string; -} -export declare function CustomerDeactivateAuthorizationFromJSON(json: any): CustomerDeactivateAuthorization; -export declare function CustomerDeactivateAuthorizationFromJSONTyped(json: any, ignoreDiscriminator: boolean): CustomerDeactivateAuthorization; -export declare function CustomerDeactivateAuthorizationToJSON(value?: CustomerDeactivateAuthorization | null): any; diff --git a/lib/types/models/CustomerRiskAction.d.ts b/lib/types/models/CustomerRiskAction.d.ts deleted file mode 100644 index 88010a9..0000000 --- a/lib/types/models/CustomerRiskAction.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface CustomerRiskAction - */ -export interface CustomerRiskAction { - /** - * Customer's code, or email address - * @type {string} - * @memberof CustomerRiskAction - */ - customer: string; - /** - * One of the possible risk actions [ default, allow, deny ]. allow to whitelist. - * deny to blacklist. Customers start with a default risk action. - * @type {string} - * @memberof CustomerRiskAction - */ - riskAction?: string; -} -export declare function CustomerRiskActionFromJSON(json: any): CustomerRiskAction; -export declare function CustomerRiskActionFromJSONTyped(json: any, ignoreDiscriminator: boolean): CustomerRiskAction; -export declare function CustomerRiskActionToJSON(value?: CustomerRiskAction | null): any; diff --git a/lib/types/models/CustomerUpdate.d.ts b/lib/types/models/CustomerUpdate.d.ts deleted file mode 100644 index 8f5bbf9..0000000 --- a/lib/types/models/CustomerUpdate.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface CustomerUpdate - */ -export interface CustomerUpdate { - /** - * Customer's first name - * @type {string} - * @memberof CustomerUpdate - */ - firstName?: string; - /** - * Customer's last name - * @type {string} - * @memberof CustomerUpdate - */ - lastName?: string; - /** - * Customer's phone number - * @type {string} - * @memberof CustomerUpdate - */ - phone?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof CustomerUpdate - */ - metadata?: string; -} -export declare function CustomerUpdateFromJSON(json: any): CustomerUpdate; -export declare function CustomerUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): CustomerUpdate; -export declare function CustomerUpdateToJSON(value?: CustomerUpdate | null): any; diff --git a/lib/types/models/CustomerValidate.d.ts b/lib/types/models/CustomerValidate.d.ts deleted file mode 100644 index 039132c..0000000 --- a/lib/types/models/CustomerValidate.d.ts +++ /dev/null @@ -1,51 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface CustomerValidate - */ -export interface CustomerValidate { - /** - * Customer's first name - * @type {string} - * @memberof CustomerValidate - */ - firstName: string; - /** - * Customer's last name - * @type {string} - * @memberof CustomerValidate - */ - lastName: string; - /** - * Predefined types of identification. e.g. (BVN) - * @type {string} - * @memberof CustomerValidate - */ - type: string; - /** - * Customer's identification number - * @type {string} - * @memberof CustomerValidate - */ - value: string; - /** - * 2 letter country code of identification issuer - * @type {string} - * @memberof CustomerValidate - */ - country: string; -} -export declare function CustomerValidateFromJSON(json: any): CustomerValidate; -export declare function CustomerValidateFromJSONTyped(json: any, ignoreDiscriminator: boolean): CustomerValidate; -export declare function CustomerValidateToJSON(value?: CustomerValidate | null): any; diff --git a/lib/types/models/CustomerValidation.d.ts b/lib/types/models/CustomerValidation.d.ts deleted file mode 100644 index d3df455..0000000 --- a/lib/types/models/CustomerValidation.d.ts +++ /dev/null @@ -1,69 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface CustomerValidation - */ -export interface CustomerValidation { - /** - * Customer's first name - * @type {string} - * @memberof CustomerValidation - */ - firstName: string; - /** - * Customer's last name - * @type {string} - * @memberof CustomerValidation - */ - lastName: string; - /** - * Predefined types of identification. - * @type {string} - * @memberof CustomerValidation - */ - type: string; - /** - * Two-letter country code of identification issuer - * @type {string} - * @memberof CustomerValidation - */ - country: string; - /** - * Customer's Bank Verification Number - * @type {string} - * @memberof CustomerValidation - */ - bvn: string; - /** - * You can get the list of bank codes by calling the List Banks endpoint (https://api.paystack.co/bank). - * @type {string} - * @memberof CustomerValidation - */ - bankCode: string; - /** - * Customer's bank account number. - * @type {string} - * @memberof CustomerValidation - */ - accountNumber: string; - /** - * Customer's identification number. Required if type is bvn - * @type {string} - * @memberof CustomerValidation - */ - value?: string; -} -export declare function CustomerValidationFromJSON(json: any): CustomerValidation; -export declare function CustomerValidationFromJSONTyped(json: any, ignoreDiscriminator: boolean): CustomerValidation; -export declare function CustomerValidationToJSON(value?: CustomerValidation | null): any; diff --git a/lib/types/models/DedicatedVirtualAccountCreate.d.ts b/lib/types/models/DedicatedVirtualAccountCreate.d.ts deleted file mode 100644 index 012071f..0000000 --- a/lib/types/models/DedicatedVirtualAccountCreate.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface DedicatedVirtualAccountCreate - */ -export interface DedicatedVirtualAccountCreate { - /** - * Customer ID or code - * @type {string} - * @memberof DedicatedVirtualAccountCreate - */ - customer: string; - /** - * The bank slug for preferred bank. To get a list of available banks, use the List Providers endpoint - * @type {string} - * @memberof DedicatedVirtualAccountCreate - */ - preferredBank?: string; - /** - * Subaccount code of the account you want to split the transaction with - * @type {string} - * @memberof DedicatedVirtualAccountCreate - */ - subaccount?: string; - /** - * Split code consisting of the lists of accounts you want to split the transaction with - * @type {string} - * @memberof DedicatedVirtualAccountCreate - */ - splitCode?: string; -} -export declare function DedicatedVirtualAccountCreateFromJSON(json: any): DedicatedVirtualAccountCreate; -export declare function DedicatedVirtualAccountCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): DedicatedVirtualAccountCreate; -export declare function DedicatedVirtualAccountCreateToJSON(value?: DedicatedVirtualAccountCreate | null): any; diff --git a/lib/types/models/DedicatedVirtualAccountSplit.d.ts b/lib/types/models/DedicatedVirtualAccountSplit.d.ts deleted file mode 100644 index 86d28d7..0000000 --- a/lib/types/models/DedicatedVirtualAccountSplit.d.ts +++ /dev/null @@ -1,39 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface DedicatedVirtualAccountSplit - */ -export interface DedicatedVirtualAccountSplit { - /** - * Valid Dedicated virtual account - * @type {string} - * @memberof DedicatedVirtualAccountSplit - */ - accountNumber: string; - /** - * Subaccount code of the account you want to split the transaction with - * @type {string} - * @memberof DedicatedVirtualAccountSplit - */ - subaccount?: string; - /** - * Split code consisting of the lists of accounts you want to split the transaction with - * @type {string} - * @memberof DedicatedVirtualAccountSplit - */ - splitCode?: string; -} -export declare function DedicatedVirtualAccountSplitFromJSON(json: any): DedicatedVirtualAccountSplit; -export declare function DedicatedVirtualAccountSplitFromJSONTyped(json: any, ignoreDiscriminator: boolean): DedicatedVirtualAccountSplit; -export declare function DedicatedVirtualAccountSplitToJSON(value?: DedicatedVirtualAccountSplit | null): any; diff --git a/lib/types/models/DisputeEvidence.d.ts b/lib/types/models/DisputeEvidence.d.ts deleted file mode 100644 index 7bc6a3c..0000000 --- a/lib/types/models/DisputeEvidence.d.ts +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface DisputeEvidence - */ -export interface DisputeEvidence { - /** - * Customer email - * @type {string} - * @memberof DisputeEvidence - */ - customerEmail: string; - /** - * Customer name - * @type {string} - * @memberof DisputeEvidence - */ - customerName: string; - /** - * Customer mobile number - * @type {string} - * @memberof DisputeEvidence - */ - customerPhone: string; - /** - * Details of service offered - * @type {string} - * @memberof DisputeEvidence - */ - serviceDetails: string; - /** - * Delivery address - * @type {string} - * @memberof DisputeEvidence - */ - deliveryAddress?: string; - /** - * ISO 8601 representation of delivery date (YYYY-MM-DD) - * @type {Date} - * @memberof DisputeEvidence - */ - deliveryDate?: Date; -} -export declare function DisputeEvidenceFromJSON(json: any): DisputeEvidence; -export declare function DisputeEvidenceFromJSONTyped(json: any, ignoreDiscriminator: boolean): DisputeEvidence; -export declare function DisputeEvidenceToJSON(value?: DisputeEvidence | null): any; diff --git a/lib/types/models/DisputeResolve.d.ts b/lib/types/models/DisputeResolve.d.ts deleted file mode 100644 index 54e8ba8..0000000 --- a/lib/types/models/DisputeResolve.d.ts +++ /dev/null @@ -1,51 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface DisputeResolve - */ -export interface DisputeResolve { - /** - * Dispute resolution. Accepted values, merchant-accepted, declined - * @type {string} - * @memberof DisputeResolve - */ - resolution: string; - /** - * Reason for resolving - * @type {string} - * @memberof DisputeResolve - */ - message: string; - /** - * The amount to refund, in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {string} - * @memberof DisputeResolve - */ - refundAmount: string; - /** - * Filename of attachment returned via response from the Dispute upload URL - * @type {string} - * @memberof DisputeResolve - */ - uploadedFilename: string; - /** - * Evidence Id for fraud claims - * @type {number} - * @memberof DisputeResolve - */ - evidence?: number; -} -export declare function DisputeResolveFromJSON(json: any): DisputeResolve; -export declare function DisputeResolveFromJSONTyped(json: any, ignoreDiscriminator: boolean): DisputeResolve; -export declare function DisputeResolveToJSON(value?: DisputeResolve | null): any; diff --git a/lib/types/models/DisputeUpdate.d.ts b/lib/types/models/DisputeUpdate.d.ts deleted file mode 100644 index d73a018..0000000 --- a/lib/types/models/DisputeUpdate.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface DisputeUpdate - */ -export interface DisputeUpdate { - /** - * The amount to refund, in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {string} - * @memberof DisputeUpdate - */ - refundAmount: string; - /** - * Filename of attachment returned via response from the Dispute upload URL - * @type {string} - * @memberof DisputeUpdate - */ - uploadedFilename?: string; -} -export declare function DisputeUpdateFromJSON(json: any): DisputeUpdate; -export declare function DisputeUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): DisputeUpdate; -export declare function DisputeUpdateToJSON(value?: DisputeUpdate | null): any; diff --git a/lib/types/models/EFT.d.ts b/lib/types/models/EFT.d.ts deleted file mode 100644 index d377295..0000000 --- a/lib/types/models/EFT.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface EFT - */ -export interface EFT { - /** - * The EFT provider - * @type {string} - * @memberof EFT - */ - provider?: string; -} -export declare function EFTFromJSON(json: any): EFT; -export declare function EFTFromJSONTyped(json: any, ignoreDiscriminator: boolean): EFT; -export declare function EFTToJSON(value?: EFT | null): any; diff --git a/lib/types/models/MobileMoney.d.ts b/lib/types/models/MobileMoney.d.ts deleted file mode 100644 index 43cf9dd..0000000 --- a/lib/types/models/MobileMoney.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface MobileMoney - */ -export interface MobileMoney { - /** - * Customer's phone number - * @type {string} - * @memberof MobileMoney - */ - phone?: string; - /** - * The telco provider of customer's phone number. This can be fetched from the List Bank endpoint - * @type {string} - * @memberof MobileMoney - */ - provider?: string; -} -export declare function MobileMoneyFromJSON(json: any): MobileMoney; -export declare function MobileMoneyFromJSONTyped(json: any, ignoreDiscriminator: boolean): MobileMoney; -export declare function MobileMoneyToJSON(value?: MobileMoney | null): any; diff --git a/lib/types/models/ModelError.d.ts b/lib/types/models/ModelError.d.ts deleted file mode 100644 index a412b1c..0000000 --- a/lib/types/models/ModelError.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ModelError - */ -export interface ModelError { - /** - * - * @type {boolean} - * @memberof ModelError - */ - status?: boolean; - /** - * - * @type {string} - * @memberof ModelError - */ - message?: string; -} -export declare function ModelErrorFromJSON(json: any): ModelError; -export declare function ModelErrorFromJSONTyped(json: any, ignoreDiscriminator: boolean): ModelError; -export declare function ModelErrorToJSON(value?: ModelError | null): any; diff --git a/lib/types/models/PageCreate.d.ts b/lib/types/models/PageCreate.d.ts deleted file mode 100644 index d1a6511..0000000 --- a/lib/types/models/PageCreate.d.ts +++ /dev/null @@ -1,63 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface PageCreate - */ -export interface PageCreate { - /** - * Name of page - * @type {string} - * @memberof PageCreate - */ - name: string; - /** - * The description of the page - * @type {string} - * @memberof PageCreate - */ - description?: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof PageCreate - */ - amount?: number; - /** - * URL slug you would like to be associated with this page. Page will be accessible at https://paystack.com/pay/[slug] - * @type {string} - * @memberof PageCreate - */ - slug?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof PageCreate - */ - metadata?: string; - /** - * If you would like Paystack to redirect to a URL upon successful payment, specify the URL here. - * @type {string} - * @memberof PageCreate - */ - redirectUrl?: string; - /** - * If you would like to accept custom fields, specify them here. - * @type {Array} - * @memberof PageCreate - */ - customFields?: Array; -} -export declare function PageCreateFromJSON(json: any): PageCreate; -export declare function PageCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PageCreate; -export declare function PageCreateToJSON(value?: PageCreate | null): any; diff --git a/lib/types/models/PageProduct.d.ts b/lib/types/models/PageProduct.d.ts deleted file mode 100644 index 842c760..0000000 --- a/lib/types/models/PageProduct.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface PageProduct - */ -export interface PageProduct { - /** - * IDs of all products to add to a page - * @type {Array} - * @memberof PageProduct - */ - product: Array; -} -export declare function PageProductFromJSON(json: any): PageProduct; -export declare function PageProductFromJSONTyped(json: any, ignoreDiscriminator: boolean): PageProduct; -export declare function PageProductToJSON(value?: PageProduct | null): any; diff --git a/lib/types/models/PageUpdate.d.ts b/lib/types/models/PageUpdate.d.ts deleted file mode 100644 index 20fbe34..0000000 --- a/lib/types/models/PageUpdate.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface PageUpdate - */ -export interface PageUpdate { - /** - * Name of page - * @type {string} - * @memberof PageUpdate - */ - name?: string; - /** - * The description of the page - * @type {string} - * @memberof PageUpdate - */ - description?: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof PageUpdate - */ - amount?: number; - /** - * Set to false to deactivate page url - * @type {boolean} - * @memberof PageUpdate - */ - active?: boolean; -} -export declare function PageUpdateFromJSON(json: any): PageUpdate; -export declare function PageUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PageUpdate; -export declare function PageUpdateToJSON(value?: PageUpdate | null): any; diff --git a/lib/types/models/PaymentRequestCreate.d.ts b/lib/types/models/PaymentRequestCreate.d.ts deleted file mode 100644 index e8121cf..0000000 --- a/lib/types/models/PaymentRequestCreate.d.ts +++ /dev/null @@ -1,96 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface PaymentRequestCreate - */ -export interface PaymentRequestCreate { - /** - * Customer id or code - * @type {string} - * @memberof PaymentRequestCreate - */ - customer: string; - /** - * Payment request amount. Only useful if line items and tax values are ignored. - * The endpoint will throw a friendly warning if neither is available. - * @type {number} - * @memberof PaymentRequestCreate - */ - amount?: number; - /** - * Specify the currency of the invoice. Allowed values are NGN, GHS, ZAR and USD. Defaults to NGN - * @type {string} - * @memberof PaymentRequestCreate - */ - currency?: string; - /** - * ISO 8601 representation of request due date - * @type {Date} - * @memberof PaymentRequestCreate - */ - dueDate?: Date; - /** - * A short description of the payment request - * @type {string} - * @memberof PaymentRequestCreate - */ - description?: string; - /** - * Array of line items - * @type {Array} - * @memberof PaymentRequestCreate - */ - lineItems?: Array; - /** - * Array of taxes - * @type {Array} - * @memberof PaymentRequestCreate - */ - tax?: Array; - /** - * Indicates whether Paystack sends an email notification to customer. Defaults to true - * @type {Array} - * @memberof PaymentRequestCreate - */ - sendNotification?: Array; - /** - * Indicate if request should be saved as draft. Defaults to false and overrides send_notification - * @type {Array} - * @memberof PaymentRequestCreate - */ - draft?: Array; - /** - * Set to true to create a draft invoice (adds an auto incrementing invoice number if none is provided) - * even if there are no line_items or tax passed - * @type {Array} - * @memberof PaymentRequestCreate - */ - hasInvoice?: Array; - /** - * Numeric value of invoice. Invoice will start from 1 and auto increment from there. This field is to help - * override whatever value Paystack decides. Auto increment for subsequent invoices continue from this point. - * @type {number} - * @memberof PaymentRequestCreate - */ - invoiceNumber?: number; - /** - * The split code of the transaction split. - * @type {string} - * @memberof PaymentRequestCreate - */ - splitCode?: string; -} -export declare function PaymentRequestCreateFromJSON(json: any): PaymentRequestCreate; -export declare function PaymentRequestCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentRequestCreate; -export declare function PaymentRequestCreateToJSON(value?: PaymentRequestCreate | null): any; diff --git a/lib/types/models/PaymentRequestUpdate.d.ts b/lib/types/models/PaymentRequestUpdate.d.ts deleted file mode 100644 index a45ac16..0000000 --- a/lib/types/models/PaymentRequestUpdate.d.ts +++ /dev/null @@ -1,96 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface PaymentRequestUpdate - */ -export interface PaymentRequestUpdate { - /** - * Customer id or code - * @type {string} - * @memberof PaymentRequestUpdate - */ - customer?: string; - /** - * Payment request amount. Only useful if line items and tax values are ignored. - * The endpoint will throw a friendly warning if neither is available. - * @type {number} - * @memberof PaymentRequestUpdate - */ - amount?: number; - /** - * Specify the currency of the invoice. Allowed values are NGN, GHS, ZAR and USD. Defaults to NGN - * @type {string} - * @memberof PaymentRequestUpdate - */ - currency?: string; - /** - * ISO 8601 representation of request due date - * @type {Date} - * @memberof PaymentRequestUpdate - */ - dueDate?: Date; - /** - * A short description of the payment request - * @type {string} - * @memberof PaymentRequestUpdate - */ - description?: string; - /** - * Array of line items - * @type {Array} - * @memberof PaymentRequestUpdate - */ - lineItems?: Array; - /** - * Array of taxes - * @type {Array} - * @memberof PaymentRequestUpdate - */ - tax?: Array; - /** - * Indicates whether Paystack sends an email notification to customer. Defaults to true - * @type {Array} - * @memberof PaymentRequestUpdate - */ - sendNotification?: Array; - /** - * Indicate if request should be saved as draft. Defaults to false and overrides send_notification - * @type {Array} - * @memberof PaymentRequestUpdate - */ - draft?: Array; - /** - * Set to true to create a draft invoice (adds an auto incrementing invoice number if none is provided) - * even if there are no line_items or tax passed - * @type {Array} - * @memberof PaymentRequestUpdate - */ - hasInvoice?: Array; - /** - * Numeric value of invoice. Invoice will start from 1 and auto increment from there. This field is to help - * override whatever value Paystack decides. Auto increment for subsequent invoices continue from this point. - * @type {number} - * @memberof PaymentRequestUpdate - */ - invoiceNumber?: number; - /** - * The split code of the transaction split. - * @type {string} - * @memberof PaymentRequestUpdate - */ - splitCode?: string; -} -export declare function PaymentRequestUpdateFromJSON(json: any): PaymentRequestUpdate; -export declare function PaymentRequestUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaymentRequestUpdate; -export declare function PaymentRequestUpdateToJSON(value?: PaymentRequestUpdate | null): any; diff --git a/lib/types/models/PlanCreate.d.ts b/lib/types/models/PlanCreate.d.ts deleted file mode 100644 index cdec1e1..0000000 --- a/lib/types/models/PlanCreate.d.ts +++ /dev/null @@ -1,70 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface PlanCreate - */ -export interface PlanCreate { - /** - * Name of plan - * @type {string} - * @memberof PlanCreate - */ - name: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof PlanCreate - */ - amount: number; - /** - * Interval in words. Valid intervals are daily, weekly, monthly,biannually, annually - * @type {string} - * @memberof PlanCreate - */ - interval: string; - /** - * A description for this plan - * @type {boolean} - * @memberof PlanCreate - */ - description?: boolean; - /** - * Set to false if you don't want invoices to be sent to your customers - * @type {boolean} - * @memberof PlanCreate - */ - sendInvoices?: boolean; - /** - * Set to false if you don't want text messages to be sent to your customers - * @type {boolean} - * @memberof PlanCreate - */ - sendSms?: boolean; - /** - * Currency in which amount is set. Allowed values are NGN, GHS, ZAR or USD - * @type {string} - * @memberof PlanCreate - */ - currency?: string; - /** - * Number of invoices to raise during subscription to this plan. - * Can be overridden by specifying an invoice_limit while subscribing. - * @type {number} - * @memberof PlanCreate - */ - invoiceLimit?: number; -} -export declare function PlanCreateFromJSON(json: any): PlanCreate; -export declare function PlanCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PlanCreate; -export declare function PlanCreateToJSON(value?: PlanCreate | null): any; diff --git a/lib/types/models/PlanUpdate.d.ts b/lib/types/models/PlanUpdate.d.ts deleted file mode 100644 index f0afb8d..0000000 --- a/lib/types/models/PlanUpdate.d.ts +++ /dev/null @@ -1,70 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface PlanUpdate - */ -export interface PlanUpdate { - /** - * Name of plan - * @type {string} - * @memberof PlanUpdate - */ - name?: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof PlanUpdate - */ - amount?: number; - /** - * Interval in words. Valid intervals are daily, weekly, monthly,biannually, annually - * @type {string} - * @memberof PlanUpdate - */ - interval?: string; - /** - * A description for this plan - * @type {boolean} - * @memberof PlanUpdate - */ - description?: boolean; - /** - * Set to false if you don't want invoices to be sent to your customers - * @type {boolean} - * @memberof PlanUpdate - */ - sendInvoices?: boolean; - /** - * Set to false if you don't want text messages to be sent to your customers - * @type {boolean} - * @memberof PlanUpdate - */ - sendSms?: boolean; - /** - * Currency in which amount is set. Allowed values are NGN, GHS, ZAR or USD - * @type {string} - * @memberof PlanUpdate - */ - currency?: string; - /** - * Number of invoices to raise during subscription to this plan. - * Can be overridden by specifying an invoice_limit while subscribing. - * @type {number} - * @memberof PlanUpdate - */ - invoiceLimit?: number; -} -export declare function PlanUpdateFromJSON(json: any): PlanUpdate; -export declare function PlanUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): PlanUpdate; -export declare function PlanUpdateToJSON(value?: PlanUpdate | null): any; diff --git a/lib/types/models/ProductCreate.d.ts b/lib/types/models/ProductCreate.d.ts deleted file mode 100644 index b4391dc..0000000 --- a/lib/types/models/ProductCreate.d.ts +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ProductCreate - */ -export interface ProductCreate { - /** - * Name of product - * @type {string} - * @memberof ProductCreate - */ - name: string; - /** - * The description of the product - * @type {string} - * @memberof ProductCreate - */ - description: string; - /** - * Price should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof ProductCreate - */ - price: number; - /** - * Currency in which price is set. Allowed values are: NGN, GHS, ZAR or USD - * @type {string} - * @memberof ProductCreate - */ - currency: string; - /** - * Set to true if the product has limited stock. Leave as false if the product has unlimited stock - * @type {boolean} - * @memberof ProductCreate - */ - limited?: boolean; - /** - * Number of products in stock. Use if limited is true - * @type {number} - * @memberof ProductCreate - */ - quantity?: number; -} -export declare function ProductCreateFromJSON(json: any): ProductCreate; -export declare function ProductCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductCreate; -export declare function ProductCreateToJSON(value?: ProductCreate | null): any; diff --git a/lib/types/models/ProductUpdate.d.ts b/lib/types/models/ProductUpdate.d.ts deleted file mode 100644 index ae8d167..0000000 --- a/lib/types/models/ProductUpdate.d.ts +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface ProductUpdate - */ -export interface ProductUpdate { - /** - * Name of product - * @type {string} - * @memberof ProductUpdate - */ - name?: string; - /** - * The description of the product - * @type {string} - * @memberof ProductUpdate - */ - description?: string; - /** - * Price should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof ProductUpdate - */ - price?: number; - /** - * Currency in which price is set. Allowed values are: NGN, GHS, ZAR or USD - * @type {string} - * @memberof ProductUpdate - */ - currency?: string; - /** - * Set to true if the product has limited stock. Leave as false if the product has unlimited stock - * @type {boolean} - * @memberof ProductUpdate - */ - limited?: boolean; - /** - * Number of products in stock. Use if limited is true - * @type {number} - * @memberof ProductUpdate - */ - quantity?: number; -} -export declare function ProductUpdateFromJSON(json: any): ProductUpdate; -export declare function ProductUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductUpdate; -export declare function ProductUpdateToJSON(value?: ProductUpdate | null): any; diff --git a/lib/types/models/RefundCreate.d.ts b/lib/types/models/RefundCreate.d.ts deleted file mode 100644 index 2dbb349..0000000 --- a/lib/types/models/RefundCreate.d.ts +++ /dev/null @@ -1,52 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface RefundCreate - */ -export interface RefundCreate { - /** - * Transaction reference or id - * @type {string} - * @memberof RefundCreate - */ - transaction: string; - /** - * Amount ( in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR ) to be refunded to the customer. - * Amount cannot be more than the original transaction amount - * @type {number} - * @memberof RefundCreate - */ - amount?: number; - /** - * Three-letter ISO currency. Allowed values are NGN, GHS, ZAR or USD - * @type {string} - * @memberof RefundCreate - */ - currency?: string; - /** - * Customer reason - * @type {string} - * @memberof RefundCreate - */ - customerNote?: string; - /** - * Merchant reason - * @type {string} - * @memberof RefundCreate - */ - merchantNote?: string; -} -export declare function RefundCreateFromJSON(json: any): RefundCreate; -export declare function RefundCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): RefundCreate; -export declare function RefundCreateToJSON(value?: RefundCreate | null): any; diff --git a/lib/types/models/Response.d.ts b/lib/types/models/Response.d.ts deleted file mode 100644 index ff4dd47..0000000 --- a/lib/types/models/Response.d.ts +++ /dev/null @@ -1,39 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface Response - */ -export interface Response { - /** - * - * @type {boolean} - * @memberof Response - */ - status?: boolean; - /** - * - * @type {string} - * @memberof Response - */ - message?: string; - /** - * - * @type {object} - * @memberof Response - */ - data?: object; -} -export declare function ResponseFromJSON(json: any): Response; -export declare function ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): Response; -export declare function ResponseToJSON(value?: Response | null): any; diff --git a/lib/types/models/SplitCreate.d.ts b/lib/types/models/SplitCreate.d.ts deleted file mode 100644 index fd260b7..0000000 --- a/lib/types/models/SplitCreate.d.ts +++ /dev/null @@ -1,58 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { SplitSubaccounts } from './'; -/** - * - * @export - * @interface SplitCreate - */ -export interface SplitCreate { - /** - * Name of the transaction split - * @type {string} - * @memberof SplitCreate - */ - name: string; - /** - * The type of transaction split you want to create. - * @type {string} - * @memberof SplitCreate - */ - type: string; - /** - * A list of object containing subaccount code and number of shares - * @type {Array} - * @memberof SplitCreate - */ - subaccounts: Array; - /** - * The transaction currency - * @type {string} - * @memberof SplitCreate - */ - currency: string; - /** - * This allows you specify how the transaction charge should be processed - * @type {string} - * @memberof SplitCreate - */ - bearerType?: string; - /** - * This is the subaccount code of the customer or partner that would bear the transaction charge if you specified subaccount as the bearer type - * @type {string} - * @memberof SplitCreate - */ - bearerSubaccount?: string; -} -export declare function SplitCreateFromJSON(json: any): SplitCreate; -export declare function SplitCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): SplitCreate; -export declare function SplitCreateToJSON(value?: SplitCreate | null): any; diff --git a/lib/types/models/SplitSubaccounts.d.ts b/lib/types/models/SplitSubaccounts.d.ts deleted file mode 100644 index d97023c..0000000 --- a/lib/types/models/SplitSubaccounts.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface SplitSubaccounts - */ -export interface SplitSubaccounts { - /** - * Subaccount code of the customer or partner - * @type {string} - * @memberof SplitSubaccounts - */ - subaccount?: string; - /** - * The percentage or flat quota of the customer or partner - * @type {string} - * @memberof SplitSubaccounts - */ - share?: string; -} -export declare function SplitSubaccountsFromJSON(json: any): SplitSubaccounts; -export declare function SplitSubaccountsFromJSONTyped(json: any, ignoreDiscriminator: boolean): SplitSubaccounts; -export declare function SplitSubaccountsToJSON(value?: SplitSubaccounts | null): any; diff --git a/lib/types/models/SplitUpdate.d.ts b/lib/types/models/SplitUpdate.d.ts deleted file mode 100644 index ce6921c..0000000 --- a/lib/types/models/SplitUpdate.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface SplitUpdate - */ -export interface SplitUpdate { - /** - * Name of the transaction split - * @type {string} - * @memberof SplitUpdate - */ - name?: string; - /** - * Toggle status of split. When true, the split is active, else it's inactive - * @type {boolean} - * @memberof SplitUpdate - */ - active?: boolean; - /** - * This allows you specify how the transaction charge should be processed - * @type {string} - * @memberof SplitUpdate - */ - bearerType?: string; - /** - * This is the subaccount code of the customer or partner that would bear the transaction charge if you specified subaccount as the bearer type - * @type {string} - * @memberof SplitUpdate - */ - bearerSubaccount?: string; -} -export declare function SplitUpdateFromJSON(json: any): SplitUpdate; -export declare function SplitUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): SplitUpdate; -export declare function SplitUpdateToJSON(value?: SplitUpdate | null): any; diff --git a/lib/types/models/SubaccountCreate.d.ts b/lib/types/models/SubaccountCreate.d.ts deleted file mode 100644 index a3fec07..0000000 --- a/lib/types/models/SubaccountCreate.d.ts +++ /dev/null @@ -1,75 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface SubaccountCreate - */ -export interface SubaccountCreate { - /** - * Name of business for subaccount - * @type {string} - * @memberof SubaccountCreate - */ - businessName: string; - /** - * Bank code for the bank. You can get the list of Bank Codes by calling the List Banks endpoint. - * @type {string} - * @memberof SubaccountCreate - */ - settlementBank: string; - /** - * Bank account number - * @type {string} - * @memberof SubaccountCreate - */ - accountNumber: string; - /** - * Customer's phone number - * @type {number} - * @memberof SubaccountCreate - */ - percentageCharge: number; - /** - * A description for this subaccount - * @type {string} - * @memberof SubaccountCreate - */ - description?: string; - /** - * A contact email for the subaccount - * @type {string} - * @memberof SubaccountCreate - */ - primaryContactEmail?: string; - /** - * The name of the contact person for this subaccount - * @type {string} - * @memberof SubaccountCreate - */ - primaryContactName?: string; - /** - * A phone number to call for this subaccount - * @type {string} - * @memberof SubaccountCreate - */ - primaryContactPhone?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof SubaccountCreate - */ - metadata?: string; -} -export declare function SubaccountCreateFromJSON(json: any): SubaccountCreate; -export declare function SubaccountCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): SubaccountCreate; -export declare function SubaccountCreateToJSON(value?: SubaccountCreate | null): any; diff --git a/lib/types/models/SubaccountUpdate.d.ts b/lib/types/models/SubaccountUpdate.d.ts deleted file mode 100644 index 3d958ad..0000000 --- a/lib/types/models/SubaccountUpdate.d.ts +++ /dev/null @@ -1,81 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface SubaccountUpdate - */ -export interface SubaccountUpdate { - /** - * Name of business for subaccount - * @type {string} - * @memberof SubaccountUpdate - */ - businessName?: string; - /** - * Bank code for the bank. You can get the list of Bank Codes by calling the List Banks endpoint. - * @type {string} - * @memberof SubaccountUpdate - */ - settlementBank?: string; - /** - * Bank account number - * @type {string} - * @memberof SubaccountUpdate - */ - accountNumber?: string; - /** - * Activate or deactivate a subaccount - * @type {boolean} - * @memberof SubaccountUpdate - */ - active?: boolean; - /** - * Customer's phone number - * @type {number} - * @memberof SubaccountUpdate - */ - percentageCharge?: number; - /** - * A description for this subaccount - * @type {string} - * @memberof SubaccountUpdate - */ - description?: string; - /** - * A contact email for the subaccount - * @type {string} - * @memberof SubaccountUpdate - */ - primaryContactEmail?: string; - /** - * The name of the contact person for this subaccount - * @type {string} - * @memberof SubaccountUpdate - */ - primaryContactName?: string; - /** - * A phone number to call for this subaccount - * @type {string} - * @memberof SubaccountUpdate - */ - primaryContactPhone?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof SubaccountUpdate - */ - metadata?: string; -} -export declare function SubaccountUpdateFromJSON(json: any): SubaccountUpdate; -export declare function SubaccountUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): SubaccountUpdate; -export declare function SubaccountUpdateToJSON(value?: SubaccountUpdate | null): any; diff --git a/lib/types/models/SubscriptionCreate.d.ts b/lib/types/models/SubscriptionCreate.d.ts deleted file mode 100644 index 49a20cd..0000000 --- a/lib/types/models/SubscriptionCreate.d.ts +++ /dev/null @@ -1,46 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface SubscriptionCreate - */ -export interface SubscriptionCreate { - /** - * Customer's email address or customer code - * @type {string} - * @memberof SubscriptionCreate - */ - customer: string; - /** - * Plan code - * @type {string} - * @memberof SubscriptionCreate - */ - plan: string; - /** - * If customer has multiple authorizations, you can set the desired authorization you wish to use for this subscription here. - * If this is not supplied, the customer's most recent authorization would be used - * @type {string} - * @memberof SubscriptionCreate - */ - authorization?: string; - /** - * Set the date for the first debit. (ISO 8601 format) e.g. 2017-05-16T00:30:13+01:00 - * @type {Date} - * @memberof SubscriptionCreate - */ - startDate?: Date; -} -export declare function SubscriptionCreateFromJSON(json: any): SubscriptionCreate; -export declare function SubscriptionCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): SubscriptionCreate; -export declare function SubscriptionCreateToJSON(value?: SubscriptionCreate | null): any; diff --git a/lib/types/models/SubscriptionToggle.d.ts b/lib/types/models/SubscriptionToggle.d.ts deleted file mode 100644 index dfd7338..0000000 --- a/lib/types/models/SubscriptionToggle.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface SubscriptionToggle - */ -export interface SubscriptionToggle { - /** - * Subscription code - * @type {string} - * @memberof SubscriptionToggle - */ - code: string; - /** - * Email token - * @type {string} - * @memberof SubscriptionToggle - */ - token: string; -} -export declare function SubscriptionToggleFromJSON(json: any): SubscriptionToggle; -export declare function SubscriptionToggleFromJSONTyped(json: any, ignoreDiscriminator: boolean): SubscriptionToggle; -export declare function SubscriptionToggleToJSON(value?: SubscriptionToggle | null): any; diff --git a/lib/types/models/TransactionChargeAuthorization.d.ts b/lib/types/models/TransactionChargeAuthorization.d.ts deleted file mode 100644 index b8271a4..0000000 --- a/lib/types/models/TransactionChargeAuthorization.d.ts +++ /dev/null @@ -1,88 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransactionChargeAuthorization - */ -export interface TransactionChargeAuthorization { - /** - * Customer's email address - * @type {string} - * @memberof TransactionChargeAuthorization - */ - email: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof TransactionChargeAuthorization - */ - amount: number; - /** - * Valid authorization code to charge - * @type {string} - * @memberof TransactionChargeAuthorization - */ - authorizationCode: string; - /** - * Unique transaction reference. Only -, ., = and alphanumeric characters allowed. - * @type {string} - * @memberof TransactionChargeAuthorization - */ - reference?: string; - /** - * The transaction currency - * @type {string} - * @memberof TransactionChargeAuthorization - */ - currency?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof TransactionChargeAuthorization - */ - metadata?: string; - /** - * The split code of the transaction split - * @type {string} - * @memberof TransactionChargeAuthorization - */ - splitCode?: string; - /** - * The code for the subaccount that owns the payment - * @type {string} - * @memberof TransactionChargeAuthorization - */ - subaccount?: string; - /** - * A flat fee to charge the subaccount for a transaction. - * This overrides the split percentage set when the subaccount was created - * @type {string} - * @memberof TransactionChargeAuthorization - */ - transactionCharge?: string; - /** - * The beare of the transaction charge - * @type {string} - * @memberof TransactionChargeAuthorization - */ - bearer?: string; - /** - * If you are making a scheduled charge call, it is a good idea to queue them so the processing system does not get overloaded causing transaction processing errors. - * @type {boolean} - * @memberof TransactionChargeAuthorization - */ - queue?: boolean; -} -export declare function TransactionChargeAuthorizationFromJSON(json: any): TransactionChargeAuthorization; -export declare function TransactionChargeAuthorizationFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionChargeAuthorization; -export declare function TransactionChargeAuthorizationToJSON(value?: TransactionChargeAuthorization | null): any; diff --git a/lib/types/models/TransactionCheckAuthorization.d.ts b/lib/types/models/TransactionCheckAuthorization.d.ts deleted file mode 100644 index ed43e9a..0000000 --- a/lib/types/models/TransactionCheckAuthorization.d.ts +++ /dev/null @@ -1,45 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransactionCheckAuthorization - */ -export interface TransactionCheckAuthorization { - /** - * Customer's email address - * @type {string} - * @memberof TransactionCheckAuthorization - */ - email: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof TransactionCheckAuthorization - */ - amount: number; - /** - * Valid authorization code to charge - * @type {string} - * @memberof TransactionCheckAuthorization - */ - authorizationCode?: string; - /** - * The transaction currency - * @type {string} - * @memberof TransactionCheckAuthorization - */ - currency?: string; -} -export declare function TransactionCheckAuthorizationFromJSON(json: any): TransactionCheckAuthorization; -export declare function TransactionCheckAuthorizationFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionCheckAuthorization; -export declare function TransactionCheckAuthorizationToJSON(value?: TransactionCheckAuthorization | null): any; diff --git a/lib/types/models/TransactionInitialize.d.ts b/lib/types/models/TransactionInitialize.d.ts deleted file mode 100644 index c164fca..0000000 --- a/lib/types/models/TransactionInitialize.d.ts +++ /dev/null @@ -1,101 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransactionInitialize - */ -export interface TransactionInitialize { - /** - * Customer's email address - * @type {string} - * @memberof TransactionInitialize - */ - email: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof TransactionInitialize - */ - amount: number; - /** - * The transaction currency - * @type {string} - * @memberof TransactionInitialize - */ - currency?: string; - /** - * Unique transaction reference. Only -, ., = and alphanumeric characters allowed. - * @type {string} - * @memberof TransactionInitialize - */ - reference?: string; - /** - * Fully qualified url, e.g. https://example.com/ . Use this to override the callback url provided on the dashboard for this transaction - * @type {string} - * @memberof TransactionInitialize - */ - callbackUrl?: string; - /** - * If transaction is to create a subscription to a predefined plan, provide plan code here. - * This would invalidate the value provided in amount - * @type {string} - * @memberof TransactionInitialize - */ - plan?: string; - /** - * Number of times to charge customer during subscription to plan - * @type {number} - * @memberof TransactionInitialize - */ - invoiceLimit?: number; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof TransactionInitialize - */ - metadata?: string; - /** - * An array of payment channels to control what channels you want to make available to the user to make a payment with - * @type {Array} - * @memberof TransactionInitialize - */ - channels?: Array; - /** - * The split code of the transaction split - * @type {string} - * @memberof TransactionInitialize - */ - splitCode?: string; - /** - * The code for the subaccount that owns the payment - * @type {string} - * @memberof TransactionInitialize - */ - subaccount?: string; - /** - * A flat fee to charge the subaccount for a transaction. - * This overrides the split percentage set when the subaccount was created - * @type {string} - * @memberof TransactionInitialize - */ - transactionCharge?: string; - /** - * The beare of the transaction charge - * @type {string} - * @memberof TransactionInitialize - */ - bearer?: string; -} -export declare function TransactionInitializeFromJSON(json: any): TransactionInitialize; -export declare function TransactionInitializeFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionInitialize; -export declare function TransactionInitializeToJSON(value?: TransactionInitialize | null): any; diff --git a/lib/types/models/TransactionPartialDebit.d.ts b/lib/types/models/TransactionPartialDebit.d.ts deleted file mode 100644 index e5858a0..0000000 --- a/lib/types/models/TransactionPartialDebit.d.ts +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransactionPartialDebit - */ -export interface TransactionPartialDebit { - /** - * Customer's email address - * @type {string} - * @memberof TransactionPartialDebit - */ - email: string; - /** - * Amount should be in kobo if currency is NGN, pesewas, if currency is GHS, and cents, if currency is ZAR - * @type {number} - * @memberof TransactionPartialDebit - */ - amount: number; - /** - * Valid authorization code to charge - * @type {string} - * @memberof TransactionPartialDebit - */ - authorizationCode: string; - /** - * The transaction currency - * @type {string} - * @memberof TransactionPartialDebit - */ - currency: string; - /** - * Unique transaction reference. Only -, ., = and alphanumeric characters allowed. - * @type {string} - * @memberof TransactionPartialDebit - */ - reference?: string; - /** - * Minimum amount to charge - * @type {string} - * @memberof TransactionPartialDebit - */ - atLeast?: string; -} -export declare function TransactionPartialDebitFromJSON(json: any): TransactionPartialDebit; -export declare function TransactionPartialDebitFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionPartialDebit; -export declare function TransactionPartialDebitToJSON(value?: TransactionPartialDebit | null): any; diff --git a/lib/types/models/TransferBulk.d.ts b/lib/types/models/TransferBulk.d.ts deleted file mode 100644 index 229be26..0000000 --- a/lib/types/models/TransferBulk.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { TransferInitiate } from './'; -/** - * - * @export - * @interface TransferBulk - */ -export interface TransferBulk { - /** - * Where should we transfer from? Only balance is allowed for now - * @type {string} - * @memberof TransferBulk - */ - source?: string; - /** - * A list of transfer object. Each object should contain amount, recipient, and reference - * @type {Array} - * @memberof TransferBulk - */ - transfers?: Array; -} -export declare function TransferBulkFromJSON(json: any): TransferBulk; -export declare function TransferBulkFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferBulk; -export declare function TransferBulkToJSON(value?: TransferBulk | null): any; diff --git a/lib/types/models/TransferFinalize.d.ts b/lib/types/models/TransferFinalize.d.ts deleted file mode 100644 index 7b4e6bb..0000000 --- a/lib/types/models/TransferFinalize.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransferFinalize - */ -export interface TransferFinalize { - /** - * The transfer code you want to finalize - * @type {string} - * @memberof TransferFinalize - */ - transferCode: string; - /** - * OTP sent to business phone to verify transfer - * @type {string} - * @memberof TransferFinalize - */ - otp: string; -} -export declare function TransferFinalizeFromJSON(json: any): TransferFinalize; -export declare function TransferFinalizeFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferFinalize; -export declare function TransferFinalizeToJSON(value?: TransferFinalize | null): any; diff --git a/lib/types/models/TransferFinalizeDisableOTP.d.ts b/lib/types/models/TransferFinalizeDisableOTP.d.ts deleted file mode 100644 index 4df76e6..0000000 --- a/lib/types/models/TransferFinalizeDisableOTP.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransferFinalizeDisableOTP - */ -export interface TransferFinalizeDisableOTP { - /** - * OTP sent to business phone to verify disabling OTP requirement - * @type {string} - * @memberof TransferFinalizeDisableOTP - */ - otp: string; -} -export declare function TransferFinalizeDisableOTPFromJSON(json: any): TransferFinalizeDisableOTP; -export declare function TransferFinalizeDisableOTPFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferFinalizeDisableOTP; -export declare function TransferFinalizeDisableOTPToJSON(value?: TransferFinalizeDisableOTP | null): any; diff --git a/lib/types/models/TransferInitiate.d.ts b/lib/types/models/TransferInitiate.d.ts deleted file mode 100644 index 640664b..0000000 --- a/lib/types/models/TransferInitiate.d.ts +++ /dev/null @@ -1,58 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransferInitiate - */ -export interface TransferInitiate { - /** - * Where should we transfer from? Only balance is allowed for now - * @type {string} - * @memberof TransferInitiate - */ - source: string; - /** - * Amount to transfer in kobo if currency is NGN and pesewas if currency is GHS. - * @type {string} - * @memberof TransferInitiate - */ - amount: string; - /** - * The transfer recipient's code - * @type {string} - * @memberof TransferInitiate - */ - recipient: string; - /** - * The reason or narration for the transfer. - * @type {string} - * @memberof TransferInitiate - */ - reason?: string; - /** - * Specify the currency of the transfer. Defaults to NGN. - * @type {string} - * @memberof TransferInitiate - */ - currency?: string; - /** - * If specified, the field should be a unique identifier (in lowercase) for the object. - * Only -,_ and alphanumeric characters are allowed. - * @type {string} - * @memberof TransferInitiate - */ - reference?: string; -} -export declare function TransferInitiateFromJSON(json: any): TransferInitiate; -export declare function TransferInitiateFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferInitiate; -export declare function TransferInitiateToJSON(value?: TransferInitiate | null): any; diff --git a/lib/types/models/TransferRecipientBulk.d.ts b/lib/types/models/TransferRecipientBulk.d.ts deleted file mode 100644 index 15ff0e4..0000000 --- a/lib/types/models/TransferRecipientBulk.d.ts +++ /dev/null @@ -1,29 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { TransferRecipientCreate } from './'; -/** - * - * @export - * @interface TransferRecipientBulk - */ -export interface TransferRecipientBulk { - /** - * A list of transfer recipient object. Each object should contain type, name, and bank_code. - * Any Create Transfer Recipient param can also be passed. - * @type {Array} - * @memberof TransferRecipientBulk - */ - batch: Array; -} -export declare function TransferRecipientBulkFromJSON(json: any): TransferRecipientBulk; -export declare function TransferRecipientBulkFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferRecipientBulk; -export declare function TransferRecipientBulkToJSON(value?: TransferRecipientBulk | null): any; diff --git a/lib/types/models/TransferRecipientCreate.d.ts b/lib/types/models/TransferRecipientCreate.d.ts deleted file mode 100644 index 3280624..0000000 --- a/lib/types/models/TransferRecipientCreate.d.ts +++ /dev/null @@ -1,69 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransferRecipientCreate - */ -export interface TransferRecipientCreate { - /** - * Recipient Type (Only nuban at this time) - * @type {string} - * @memberof TransferRecipientCreate - */ - type: string; - /** - * Recipient's name - * @type {string} - * @memberof TransferRecipientCreate - */ - name: string; - /** - * Recipient's bank account number - * @type {string} - * @memberof TransferRecipientCreate - */ - accountNumber: string; - /** - * Recipient's bank code. You can get the list of Bank Codes by calling the List Banks endpoint - * @type {string} - * @memberof TransferRecipientCreate - */ - bankCode: string; - /** - * A description for this recipient - * @type {string} - * @memberof TransferRecipientCreate - */ - description?: string; - /** - * Currency for the account receiving the transfer - * @type {string} - * @memberof TransferRecipientCreate - */ - currency?: string; - /** - * An authorization code from a previous transaction - * @type {string} - * @memberof TransferRecipientCreate - */ - authorizationCode?: string; - /** - * Stringified JSON object of custom data - * @type {string} - * @memberof TransferRecipientCreate - */ - metadata?: string; -} -export declare function TransferRecipientCreateFromJSON(json: any): TransferRecipientCreate; -export declare function TransferRecipientCreateFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferRecipientCreate; -export declare function TransferRecipientCreateToJSON(value?: TransferRecipientCreate | null): any; diff --git a/lib/types/models/TransferRecipientUpdate.d.ts b/lib/types/models/TransferRecipientUpdate.d.ts deleted file mode 100644 index 9e34055..0000000 --- a/lib/types/models/TransferRecipientUpdate.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransferRecipientUpdate - */ -export interface TransferRecipientUpdate { - /** - * Recipient's name - * @type {string} - * @memberof TransferRecipientUpdate - */ - name?: string; - /** - * Recipient's email address - * @type {string} - * @memberof TransferRecipientUpdate - */ - email?: string; -} -export declare function TransferRecipientUpdateFromJSON(json: any): TransferRecipientUpdate; -export declare function TransferRecipientUpdateFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferRecipientUpdate; -export declare function TransferRecipientUpdateToJSON(value?: TransferRecipientUpdate | null): any; diff --git a/lib/types/models/TransferResendOTP.d.ts b/lib/types/models/TransferResendOTP.d.ts deleted file mode 100644 index 9761eed..0000000 --- a/lib/types/models/TransferResendOTP.d.ts +++ /dev/null @@ -1,33 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface TransferResendOTP - */ -export interface TransferResendOTP { - /** - * The transfer code that requires an OTP validation - * @type {string} - * @memberof TransferResendOTP - */ - transferCode: string; - /** - * Either resend_otp or transfer - * @type {string} - * @memberof TransferResendOTP - */ - reason: string; -} -export declare function TransferResendOTPFromJSON(json: any): TransferResendOTP; -export declare function TransferResendOTPFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransferResendOTP; -export declare function TransferResendOTPToJSON(value?: TransferResendOTP | null): any; diff --git a/lib/types/models/USSD.d.ts b/lib/types/models/USSD.d.ts deleted file mode 100644 index 3c2337f..0000000 --- a/lib/types/models/USSD.d.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface USSD - */ -export interface USSD { - /** - * The three-digit USSD code. One of, 737, 919, 822, 966 - * @type {string} - * @memberof USSD - */ - type?: string; -} -export declare function USSDFromJSON(json: any): USSD; -export declare function USSDFromJSONTyped(json: any, ignoreDiscriminator: boolean): USSD; -export declare function USSDToJSON(value?: USSD | null): any; diff --git a/lib/types/models/VerificationBVNMatch.d.ts b/lib/types/models/VerificationBVNMatch.d.ts deleted file mode 100644 index 70b9fae..0000000 --- a/lib/types/models/VerificationBVNMatch.d.ts +++ /dev/null @@ -1,57 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/** - * - * @export - * @interface VerificationBVNMatch - */ -export interface VerificationBVNMatch { - /** - * Bank Account Number - * @type {string} - * @memberof VerificationBVNMatch - */ - accountNumber: string; - /** - * You can get the list of banks codes by calling the List Bank endpoint - * @type {number} - * @memberof VerificationBVNMatch - */ - bankCode: number; - /** - * 11 digits Bank Verification Number - * @type {string} - * @memberof VerificationBVNMatch - */ - bvn: string; - /** - * Customer's first name - * @type {string} - * @memberof VerificationBVNMatch - */ - firstName?: string; - /** - * Customer's middle name - * @type {string} - * @memberof VerificationBVNMatch - */ - middleName?: string; - /** - * Customer's last name - * @type {string} - * @memberof VerificationBVNMatch - */ - lastName?: string; -} -export declare function VerificationBVNMatchFromJSON(json: any): VerificationBVNMatch; -export declare function VerificationBVNMatchFromJSONTyped(json: any, ignoreDiscriminator: boolean): VerificationBVNMatch; -export declare function VerificationBVNMatchToJSON(value?: VerificationBVNMatch | null): any; diff --git a/lib/types/models/index.d.ts b/lib/types/models/index.d.ts deleted file mode 100644 index 8680e5b..0000000 --- a/lib/types/models/index.d.ts +++ /dev/null @@ -1,55 +0,0 @@ -export * from './Accepted'; -export * from './Bank'; -export * from './BulkChargeInitiate'; -export * from './ChargeCreate'; -export * from './ChargeSubmitAddress'; -export * from './ChargeSubmitBirthday'; -export * from './ChargeSubmitOTP'; -export * from './ChargeSubmitPhone'; -export * from './ChargeSubmitPin'; -export * from './CustomerCreate'; -export * from './CustomerDeactivateAuthorization'; -export * from './CustomerRiskAction'; -export * from './CustomerUpdate'; -export * from './CustomerValidate'; -export * from './CustomerValidation'; -export * from './DedicatedVirtualAccountCreate'; -export * from './DedicatedVirtualAccountSplit'; -export * from './DisputeEvidence'; -export * from './DisputeResolve'; -export * from './DisputeUpdate'; -export * from './EFT'; -export * from './MobileMoney'; -export * from './ModelError'; -export * from './PageCreate'; -export * from './PageProduct'; -export * from './PageUpdate'; -export * from './PaymentRequestCreate'; -export * from './PaymentRequestUpdate'; -export * from './PlanCreate'; -export * from './PlanUpdate'; -export * from './ProductCreate'; -export * from './ProductUpdate'; -export * from './RefundCreate'; -export * from './Response'; -export * from './SplitCreate'; -export * from './SplitSubaccounts'; -export * from './SplitUpdate'; -export * from './SubaccountCreate'; -export * from './SubaccountUpdate'; -export * from './SubscriptionCreate'; -export * from './SubscriptionToggle'; -export * from './TransactionChargeAuthorization'; -export * from './TransactionCheckAuthorization'; -export * from './TransactionInitialize'; -export * from './TransactionPartialDebit'; -export * from './TransferBulk'; -export * from './TransferFinalize'; -export * from './TransferFinalizeDisableOTP'; -export * from './TransferInitiate'; -export * from './TransferRecipientBulk'; -export * from './TransferRecipientCreate'; -export * from './TransferRecipientUpdate'; -export * from './TransferResendOTP'; -export * from './USSD'; -export * from './VerificationBVNMatch'; diff --git a/lib/types/runtime.d.ts b/lib/types/runtime.d.ts deleted file mode 100644 index 8ab319d..0000000 --- a/lib/types/runtime.d.ts +++ /dev/null @@ -1,44 +0,0 @@ -/** - * Paystack - * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa. - * - * The version of the Paystack Node library: 1.0.0 - * Contact: techsupport@paystack.com - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -declare type HTTPMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD'; -declare type HTTPHeaders = { - [key: string]: string; -}; -declare type HTTPBody = any; -declare type HTTPQuery = { - [key: string]: string | number | null | boolean | Array | HTTPQuery; -}; -interface Request { - path: string; - method: HTTPMethod; - headers?: HTTPHeaders; - body?: HTTPBody; - query?: HTTPQuery; -} -/** - * This is the base class for all generated API classes. - */ -export declare class BaseAPI { - readonly apiKey: string; - constructor(apiKey: string); - protected request(params: Request): Promise; - private makeRequest; - private parseQueryParams; -} -export declare class RequiredError extends Error { - field: string; - name: "RequiredError"; - constructor(field: string, msg?: string); -} -export declare function exists(json: any, key: string): boolean; -export declare function mapValues(data: any, fn: (item: any) => any): {}; -export {}; diff --git a/package.json b/package.json index 73e9fa4..b0f626c 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,9 @@ { "name": "@paystack/paystack-sdk", - "version": "1.0.1", + "version": "1.2.0", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", + "type": "module", "keywords": [ "paystack", "payment", @@ -19,11 +20,19 @@ "homepage": "https://github.com/PaystackOSS/paystack-node", "bugs": "https://github.com/PaystackOSS/paystack-node/issues", "license": "MIT", - "main": "./lib/index.js", - "typings": "./lib/index.d.ts", + "exports": { + "types": "./dist/types/index.d.ts", + "require": "./dist/cjs/index.js", + "import": "./dist/esm/index.js", + "default": "./dist/esm/index.js" + }, + "main": "./dist/index.js", + "module": "./dist/esm/index.js", + "types": "./dist/types/index.d.ts", "scripts": { - "build": "tsc", - "prepare": "npm run build" + "build": "npm run clean && npm run compile", + "clean": "rm -rf ./dist", + "compile": "tsc -p tsconfig.esm.json && tsc -p ./tsconfig.cjs.json && tsc -p ./tsconfig.types.json" }, "devDependencies": { "@types/node": "^15.0.3", diff --git a/src/apis/Plan.ts b/src/apis/Plan.ts index 1d049de..0a729c9 100644 --- a/src/apis/Plan.ts +++ b/src/apis/Plan.ts @@ -23,7 +23,7 @@ export interface CreateRequest { name: string; amount: number; interval: string; - description?: boolean; + description?: string; send_invoices?: boolean; send_sms?: boolean; currency?: string; diff --git a/src/index.ts b/src/index.ts index 4de79fc..96aec52 100644 --- a/src/index.ts +++ b/src/index.ts @@ -9,9 +9,11 @@ export class Paystack { private extend(apiKey: string) { for (const resource in Resources) { - if (Resources.hasOwnProperty(resource)) { - this[this.toCamelCase(resource)] = new Resources[resource][resource](apiKey); - } + if (Resources[resource]) { + this[this.toCamelCase(resource)] = new Resources[resource][resource]( + apiKey + ); + } } } @@ -28,7 +30,4 @@ export class Paystack { return resource.toLowerCase().replace("api", "") } -} - -module.exports = Paystack; -module.exports.default = Paystack; \ No newline at end of file +} \ No newline at end of file diff --git a/src/models/PlanCreate.ts b/src/models/PlanCreate.ts index 7c73566..3fd49d6 100644 --- a/src/models/PlanCreate.ts +++ b/src/models/PlanCreate.ts @@ -39,10 +39,10 @@ export interface PlanCreate { interval: string; /** * A description for this plan - * @type {boolean} + * @type {string} * @memberof PlanCreate */ - description?: boolean; + description?: string; /** * Set to false if you don't want invoices to be sent to your customers * @type {boolean} diff --git a/src/runtime.ts b/src/runtime.ts index 2e36751..19ef628 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -13,7 +13,7 @@ */ -import https = require('https'); +import * as https from 'https'; const BASE_PATH = "https://api.paystack.co".replace(/\/+$/, ""); type HTTPMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD'; @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "user-agent": `@paystack/paystack-sdk - 1.0.1` + "user-agent": `@paystack/paystack-sdk - 1.2.0` } } diff --git a/tsconfig.cjs.json b/tsconfig.cjs.json new file mode 100644 index 0000000..122805c --- /dev/null +++ b/tsconfig.cjs.json @@ -0,0 +1,7 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "module": "CommonJS", + "outDir": "dist/cjs" + }, +} \ No newline at end of file diff --git a/tsconfig.esm.json b/tsconfig.esm.json new file mode 100644 index 0000000..903dd7f --- /dev/null +++ b/tsconfig.esm.json @@ -0,0 +1,8 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "target": "ES2015", + "module": "ES2020", + "outDir": "dist/esm", + }, +} diff --git a/tsconfig.json b/tsconfig.json index 71b1e7b..4a71f90 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,12 +1,7 @@ { "compilerOptions": { - "declaration": true, - "declarationDir": "./lib/types", - "target": "es6", - "module": "commonjs", "moduleResolution": "node", - "esModuleInterop": true, - "outDir": "lib", + "esModuleInterop": false, }, "include": ["src"] } diff --git a/tsconfig.types.json b/tsconfig.types.json new file mode 100644 index 0000000..51b6138 --- /dev/null +++ b/tsconfig.types.json @@ -0,0 +1,8 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "outDir": "dist/types", + "declaration": true, + "emitDeclarationOnly": true + } +} \ No newline at end of file From edcd260c8c71198e78dd728a80a776511d68fb4e Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Tue, 25 Jun 2024 10:20:51 +0100 Subject: [PATCH 11/13] Patch: Compilation from TS to JS with support for ESM and CJS --- README.md | 6 +- package-lock.json | 2058 ++++++++++++++++++++++++++++++++++++++++++++- package.json | 26 +- src/runtime.ts | 2 +- 4 files changed, 2055 insertions(+), 37 deletions(-) diff --git a/README.md b/README.md index d06a79c..179e2df 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ npm install @paystack/paystack-sdk --save ## Usage Import and initialize the library: ```javascript -const Paystack = require('@paystack/paystack-sdk') +const { Paystack } = require('@paystack/paystack-sdk') const paystack = new Paystack("sk_test_xxxxxx") paystack.transaction.initialize({email: "test@example.com", amount: 20000}) @@ -24,7 +24,7 @@ paystack.transaction.initialize({email: "test@example.com", amount: 20000}) Import and initialize the library using ES module with `async/await`: ```javascript -import Paystack from '@paystack/paystack-sdk' +import { Paystack } from '@paystack/paystack-sdk' const paystack = new Paystack("sk_test_xxxxxx") const initialize = async(email, amount) => { @@ -43,7 +43,7 @@ initialize(email, amount) ### Typescript ```typescript -import Paystack from '@paystack/paystack-sdk'; +import { Paystack } from '@paystack/paystack-sdk'; const paystack = new Paystack("sk_test_xxxxxx"); const initialize = async(email, amount) => { diff --git a/package-lock.json b/package-lock.json index 338a9d8..c621531 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,50 +1,2066 @@ { - "name": "paystack", - "version": "1.0.0-beta.1", - "lockfileVersion": 2, + "name": "@paystack/paystack-sdk", + "version": "1.2.1-beta.1", + "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "paystack", - "version": "1.0.0-beta.1", + "name": "@paystack/paystack-sdk", + "version": "1.2.1-beta.1", "license": "MIT", "devDependencies": { "@types/node": "^15.0.3", - "typescript": "^3.6" + "tsup": "^8.1.0", + "typescript": "^5.5.2" } }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz", + "integrity": "sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.21.5.tgz", + "integrity": "sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.21.5.tgz", + "integrity": "sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.21.5.tgz", + "integrity": "sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.21.5.tgz", + "integrity": "sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.21.5.tgz", + "integrity": "sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.21.5.tgz", + "integrity": "sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.21.5.tgz", + "integrity": "sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.21.5.tgz", + "integrity": "sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.21.5.tgz", + "integrity": "sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.21.5.tgz", + "integrity": "sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.21.5.tgz", + "integrity": "sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.21.5.tgz", + "integrity": "sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.21.5.tgz", + "integrity": "sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.21.5.tgz", + "integrity": "sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.21.5.tgz", + "integrity": "sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.21.5.tgz", + "integrity": "sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.21.5.tgz", + "integrity": "sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.21.5.tgz", + "integrity": "sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.21.5.tgz", + "integrity": "sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.21.5.tgz", + "integrity": "sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.21.5.tgz", + "integrity": "sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@isaacs/cliui": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", + "integrity": "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==", + "dev": true, + "dependencies": { + "string-width": "^5.1.2", + "string-width-cjs": "npm:string-width@^4.2.0", + "strip-ansi": "^7.0.1", + "strip-ansi-cjs": "npm:strip-ansi@^6.0.1", + "wrap-ansi": "^8.1.0", + "wrap-ansi-cjs": "npm:wrap-ansi@^7.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", + "dev": true, + "dependencies": { + "@jridgewell/set-array": "^1.2.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.24" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/set-array": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", + "dev": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.4.15", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", + "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", + "dev": true + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", + "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "dev": true, + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", + "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "dev": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", + "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "dev": true, + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@pkgjs/parseargs": { + "version": "0.11.0", + "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", + "integrity": "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==", + "dev": true, + "optional": true, + "engines": { + "node": ">=14" + } + }, + "node_modules/@rollup/rollup-android-arm-eabi": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.18.0.tgz", + "integrity": "sha512-Tya6xypR10giZV1XzxmH5wr25VcZSncG0pZIjfePT0OVBvqNEurzValetGNarVrGiq66EBVAFn15iYX4w6FKgQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-android-arm64": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.18.0.tgz", + "integrity": "sha512-avCea0RAP03lTsDhEyfy+hpfr85KfyTctMADqHVhLAF3MlIkq83CP8UfAHUssgXTYd+6er6PaAhx/QGv4L1EiA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.18.0.tgz", + "integrity": "sha512-IWfdwU7KDSm07Ty0PuA/W2JYoZ4iTj3TUQjkVsO/6U+4I1jN5lcR71ZEvRh52sDOERdnNhhHU57UITXz5jC1/w==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-darwin-x64": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.18.0.tgz", + "integrity": "sha512-n2LMsUz7Ynu7DoQrSQkBf8iNrjOGyPLrdSg802vk6XT3FtsgX6JbE8IHRvposskFm9SNxzkLYGSq9QdpLYpRNA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.18.0.tgz", + "integrity": "sha512-C/zbRYRXFjWvz9Z4haRxcTdnkPt1BtCkz+7RtBSuNmKzMzp3ZxdM28Mpccn6pt28/UWUCTXa+b0Mx1k3g6NOMA==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm-musleabihf": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.18.0.tgz", + "integrity": "sha512-l3m9ewPgjQSXrUMHg93vt0hYCGnrMOcUpTz6FLtbwljo2HluS4zTXFy2571YQbisTnfTKPZ01u/ukJdQTLGh9A==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-gnu": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.18.0.tgz", + "integrity": "sha512-rJ5D47d8WD7J+7STKdCUAgmQk49xuFrRi9pZkWoRD1UeSMakbcepWXPF8ycChBoAqs1pb2wzvbY6Q33WmN2ftw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-musl": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.18.0.tgz", + "integrity": "sha512-be6Yx37b24ZwxQ+wOQXXLZqpq4jTckJhtGlWGZs68TgdKXJgw54lUUoFYrg6Zs/kjzAQwEwYbp8JxZVzZLRepQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.18.0.tgz", + "integrity": "sha512-hNVMQK+qrA9Todu9+wqrXOHxFiD5YmdEi3paj6vP02Kx1hjd2LLYR2eaN7DsEshg09+9uzWi2W18MJDlG0cxJA==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-gnu": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.18.0.tgz", + "integrity": "sha512-ROCM7i+m1NfdrsmvwSzoxp9HFtmKGHEqu5NNDiZWQtXLA8S5HBCkVvKAxJ8U+CVctHwV2Gb5VUaK7UAkzhDjlg==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-s390x-gnu": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.18.0.tgz", + "integrity": "sha512-0UyyRHyDN42QL+NbqevXIIUnKA47A+45WyasO+y2bGJ1mhQrfrtXUpTxCOrfxCR4esV3/RLYyucGVPiUsO8xjg==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-gnu": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.18.0.tgz", + "integrity": "sha512-xuglR2rBVHA5UsI8h8UbX4VJ470PtGCf5Vpswh7p2ukaqBGFTnsfzxUBetoWBWymHMxbIG0Cmx7Y9qDZzr648w==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-musl": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.18.0.tgz", + "integrity": "sha512-LKaqQL9osY/ir2geuLVvRRs+utWUNilzdE90TpyoX0eNqPzWjRm14oMEE+YLve4k/NAqCdPkGYDaDF5Sw+xBfg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-win32-arm64-msvc": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.18.0.tgz", + "integrity": "sha512-7J6TkZQFGo9qBKH0pk2cEVSRhJbL6MtfWxth7Y5YmZs57Pi+4x6c2dStAUvaQkHQLnEQv1jzBUW43GvZW8OFqA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-ia32-msvc": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.18.0.tgz", + "integrity": "sha512-Txjh+IxBPbkUB9+SXZMpv+b/vnTEtFyfWZgJ6iyCmt2tdx0OF5WhFowLmnh8ENGNpfUlUZkdI//4IEmhwPieNg==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-msvc": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.18.0.tgz", + "integrity": "sha512-UOo5FdvOL0+eIVTgS4tIdbW+TtnBLWg1YBCcU2KWM7nuNwRz9bksDX1bekJJCpu25N1DVWaCwnT39dVQxzqS8g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@types/estree": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", + "dev": true + }, "node_modules/@types/node": { "version": "15.14.9", "resolved": "https://registry.npmjs.org/@types/node/-/node-15.14.9.tgz", "integrity": "sha512-qjd88DrCxupx/kJD5yQgZdcYKZKSIGBVDIBE1/LTGcNm3d2Np/jxojkdePDdfnBHJc5W7vSMpbJ1aB7p/Py69A==", "dev": true }, + "node_modules/ansi-regex": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.0.1.tgz", + "integrity": "sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-regex?sponsor=1" + } + }, + "node_modules/ansi-styles": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", + "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", + "dev": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/any-promise": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz", + "integrity": "sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==", + "dev": true + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/array-union": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", + "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true + }, + "node_modules/binary-extensions": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz", + "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/brace-expansion": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", + "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", + "dev": true, + "dependencies": { + "balanced-match": "^1.0.0" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/bundle-require": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/bundle-require/-/bundle-require-4.2.1.tgz", + "integrity": "sha512-7Q/6vkyYAwOmQNRw75x+4yRtZCZJXUDmHHlFdkiV0wgv/reNjtJwpu1jPJ0w2kbEpIM0uoKI3S4/f39dU7AjSA==", + "dev": true, + "dependencies": { + "load-tsconfig": "^0.2.3" + }, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "peerDependencies": { + "esbuild": ">=0.17" + } + }, + "node_modules/cac": { + "version": "6.7.14", + "resolved": "https://registry.npmjs.org/cac/-/cac-6.7.14.tgz", + "integrity": "sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/chokidar": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz", + "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==", + "dev": true, + "dependencies": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/commander": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", + "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/cross-spawn": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "dev": true, + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/debug": { + "version": "4.3.5", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.5.tgz", + "integrity": "sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/dir-glob": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", + "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", + "dev": true, + "dependencies": { + "path-type": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/eastasianwidth": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", + "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", + "dev": true + }, + "node_modules/emoji-regex": { + "version": "9.2.2", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", + "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", + "dev": true + }, + "node_modules/esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, + "node_modules/execa": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "dev": true, + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/fast-glob": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.2.tgz", + "integrity": "sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==", + "dev": true, + "dependencies": { + "@nodelib/fs.stat": "^2.0.2", + "@nodelib/fs.walk": "^1.2.3", + "glob-parent": "^5.1.2", + "merge2": "^1.3.0", + "micromatch": "^4.0.4" + }, + "engines": { + "node": ">=8.6.0" + } + }, + "node_modules/fastq": { + "version": "1.17.1", + "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.17.1.tgz", + "integrity": "sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==", + "dev": true, + "dependencies": { + "reusify": "^1.0.4" + } + }, + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/foreground-child": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.2.1.tgz", + "integrity": "sha512-PXUUyLqrR2XCWICfv6ukppP96sdFwWbNEnfEMt7jNsISjMsvaLNinAHNDYyvkyU+SZG2BTSbT5NjG+vZslfGTA==", + "dev": true, + "dependencies": { + "cross-spawn": "^7.0.0", + "signal-exit": "^4.0.1" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/foreground-child/node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/glob": { + "version": "10.4.2", + "resolved": "https://registry.npmjs.org/glob/-/glob-10.4.2.tgz", + "integrity": "sha512-GwMlUF6PkPo3Gk21UxkCohOv0PLcIXVtKyLlpEI28R/cO/4eNOdmLk3CMW1wROV/WR/EsZOWAfBbBOqYvs88/w==", + "dev": true, + "dependencies": { + "foreground-child": "^3.1.0", + "jackspeak": "^3.1.2", + "minimatch": "^9.0.4", + "minipass": "^7.1.2", + "package-json-from-dist": "^1.0.0", + "path-scurry": "^1.11.1" + }, + "bin": { + "glob": "dist/esm/bin.mjs" + }, + "engines": { + "node": ">=16 || 14 >=14.18" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/globby": { + "version": "11.1.0", + "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", + "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", + "dev": true, + "dependencies": { + "array-union": "^2.1.0", + "dir-glob": "^3.0.1", + "fast-glob": "^3.2.9", + "ignore": "^5.2.0", + "merge2": "^1.4.1", + "slash": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/human-signals": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==", + "dev": true, + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/ignore": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.1.tgz", + "integrity": "sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw==", + "dev": true, + "engines": { + "node": ">= 4" + } + }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "dev": true, + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "dev": true, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true + }, + "node_modules/jackspeak": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.0.tgz", + "integrity": "sha512-JVYhQnN59LVPFCEcVa2C3CrEKYacvjRfqIQl+h8oi91aLYQVWRYbxjPcv1bUiUy/kLmQaANrYfNMCO3kuEDHfw==", + "dev": true, + "dependencies": { + "@isaacs/cliui": "^8.0.2" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + }, + "optionalDependencies": { + "@pkgjs/parseargs": "^0.11.0" + } + }, + "node_modules/joycon": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/joycon/-/joycon-3.1.1.tgz", + "integrity": "sha512-34wB/Y7MW7bzjKRjUKTa46I2Z7eV62Rkhva+KkopW7Qvv/OSWBqvkSY7vusOPrNuZcUG3tApvdVgNB8POj3SPw==", + "dev": true, + "engines": { + "node": ">=10" + } + }, + "node_modules/lilconfig": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-3.1.2.tgz", + "integrity": "sha512-eop+wDAvpItUys0FWkHIKeC9ybYrTGbU41U5K7+bttZZeohvnY7M9dZ5kB21GNWiFT2q1OoPTvncPCgSOVO5ow==", + "dev": true, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/antonk52" + } + }, + "node_modules/lines-and-columns": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz", + "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==", + "dev": true + }, + "node_modules/load-tsconfig": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/load-tsconfig/-/load-tsconfig-0.2.5.tgz", + "integrity": "sha512-IXO6OCs9yg8tMKzfPZ1YmheJbZCiEsnBdcB03l0OcfK9prKnJb96siuHCr5Fl37/yo9DnKU+TLpxzTUspw9shg==", + "dev": true, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + } + }, + "node_modules/lodash.sortby": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash.sortby/-/lodash.sortby-4.7.0.tgz", + "integrity": "sha512-HDWXG8isMntAyRF5vZ7xKuEvOhT4AhlRt/3czTSjvGUxjYCBVRQY48ViDHyfYz9VIoBkW4TMGQNapx+l3RUwdA==", + "dev": true + }, + "node_modules/lru-cache": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.2.2.tgz", + "integrity": "sha512-9hp3Vp2/hFQUiIwKo8XCeFVnrg8Pk3TYNPIR7tJADKi5YfcF7vEaK7avFHTlSy3kOKYaJQaalfEo6YuXdceBOQ==", + "dev": true, + "engines": { + "node": "14 || >=16.14" + } + }, + "node_modules/merge-stream": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", + "dev": true + }, + "node_modules/merge2": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", + "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", + "dev": true, + "engines": { + "node": ">= 8" + } + }, + "node_modules/micromatch": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.7.tgz", + "integrity": "sha512-LPP/3KorzCwBxfeUuZmaR6bG2kdeHSbe0P2tY3FLRU4vYrjYz5hI4QZwV0njUx3jeuKe67YukQ1LSPZBKDqO/Q==", + "dev": true, + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/minimatch": { + "version": "9.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.4.tgz", + "integrity": "sha512-KqWh+VchfxcMNRAJjj2tnsSJdNbHsVgnkBhTNrW7AjVo6OvLtxw8zfT9oLw1JSohlFzJ8jCoTgaoXvJ+kHt6fw==", + "dev": true, + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=16 || 14 >=14.17" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/minipass": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", + "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", + "dev": true, + "engines": { + "node": ">=16 || 14 >=14.17" + } + }, + "node_modules/ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", + "dev": true + }, + "node_modules/mz": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/mz/-/mz-2.7.0.tgz", + "integrity": "sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==", + "dev": true, + "dependencies": { + "any-promise": "^1.0.0", + "object-assign": "^4.0.1", + "thenify-all": "^1.0.0" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "dev": true, + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/onetime": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "dev": true, + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/package-json-from-dist": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/package-json-from-dist/-/package-json-from-dist-1.0.0.tgz", + "integrity": "sha512-dATvCeZN/8wQsGywez1mzHtTlP22H8OEfPrVMLNr4/eGa+ijtLn/6M5f0dY8UKNrC2O9UCU6SSoG3qRKnt7STw==", + "dev": true + }, + "node_modules/path-key": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/path-scurry": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.11.1.tgz", + "integrity": "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==", + "dev": true, + "dependencies": { + "lru-cache": "^10.2.0", + "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" + }, + "engines": { + "node": ">=16 || 14 >=14.18" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/path-type": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", + "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pirates": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.6.tgz", + "integrity": "sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg==", + "dev": true, + "engines": { + "node": ">= 6" + } + }, + "node_modules/postcss-load-config": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/postcss-load-config/-/postcss-load-config-4.0.2.tgz", + "integrity": "sha512-bSVhyJGL00wMVoPUzAVAnbEoWyqRxkjv64tUl427SKnPrENtq6hJwUojroMz2VB+Q1edmi4IfrAPpami5VVgMQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "lilconfig": "^3.0.0", + "yaml": "^2.3.4" + }, + "engines": { + "node": ">= 14" + }, + "peerDependencies": { + "postcss": ">=8.0.9", + "ts-node": ">=9.0.0" + }, + "peerDependenciesMeta": { + "postcss": { + "optional": true + }, + "ts-node": { + "optional": true + } + } + }, + "node_modules/punycode": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", + "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "dependencies": { + "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" + } + }, + "node_modules/resolve-from": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", + "integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/reusify": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", + "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", + "dev": true, + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } + }, + "node_modules/rollup": { + "version": "4.18.0", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.18.0.tgz", + "integrity": "sha512-QmJz14PX3rzbJCN1SG4Xe/bAAX2a6NpCP8ab2vfu2GiUr8AQcr2nCV/oEO3yneFarB67zk8ShlIyWb2LGTb3Sg==", + "dev": true, + "dependencies": { + "@types/estree": "1.0.5" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.18.0", + "@rollup/rollup-android-arm64": "4.18.0", + "@rollup/rollup-darwin-arm64": "4.18.0", + "@rollup/rollup-darwin-x64": "4.18.0", + "@rollup/rollup-linux-arm-gnueabihf": "4.18.0", + "@rollup/rollup-linux-arm-musleabihf": "4.18.0", + "@rollup/rollup-linux-arm64-gnu": "4.18.0", + "@rollup/rollup-linux-arm64-musl": "4.18.0", + "@rollup/rollup-linux-powerpc64le-gnu": "4.18.0", + "@rollup/rollup-linux-riscv64-gnu": "4.18.0", + "@rollup/rollup-linux-s390x-gnu": "4.18.0", + "@rollup/rollup-linux-x64-gnu": "4.18.0", + "@rollup/rollup-linux-x64-musl": "4.18.0", + "@rollup/rollup-win32-arm64-msvc": "4.18.0", + "@rollup/rollup-win32-ia32-msvc": "4.18.0", + "@rollup/rollup-win32-x64-msvc": "4.18.0", + "fsevents": "~2.3.2" + } + }, + "node_modules/run-parallel": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", + "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "queue-microtask": "^1.2.2" + } + }, + "node_modules/shebang-command": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "dev": true, + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shebang-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true + }, + "node_modules/slash": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", + "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/source-map": { + "version": "0.8.0-beta.0", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.8.0-beta.0.tgz", + "integrity": "sha512-2ymg6oRBpebeZi9UUNsgQ89bhx01TcTkmNTGnNO88imTmbSgy4nfujrgVEFKWpMTEGA11EDkTt7mqObTPdigIA==", + "dev": true, + "dependencies": { + "whatwg-url": "^7.0.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/string-width": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", + "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", + "dev": true, + "dependencies": { + "eastasianwidth": "^0.2.0", + "emoji-regex": "^9.2.2", + "strip-ansi": "^7.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/string-width-cjs": { + "name": "string-width", + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/string-width-cjs/node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/string-width-cjs/node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true + }, + "node_modules/string-width-cjs/node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", + "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", + "dev": true, + "dependencies": { + "ansi-regex": "^6.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/strip-ansi?sponsor=1" + } + }, + "node_modules/strip-ansi-cjs": { + "name": "strip-ansi", + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi-cjs/node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/sucrase": { + "version": "3.35.0", + "resolved": "https://registry.npmjs.org/sucrase/-/sucrase-3.35.0.tgz", + "integrity": "sha512-8EbVDiu9iN/nESwxeSxDKe0dunta1GOlHufmSSXxMD2z2/tMZpDMpvXQGsc+ajGo8y2uYUmixaSRUc/QPoQ0GA==", + "dev": true, + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.2", + "commander": "^4.0.0", + "glob": "^10.3.10", + "lines-and-columns": "^1.1.6", + "mz": "^2.7.0", + "pirates": "^4.0.1", + "ts-interface-checker": "^0.1.9" + }, + "bin": { + "sucrase": "bin/sucrase", + "sucrase-node": "bin/sucrase-node" + }, + "engines": { + "node": ">=16 || 14 >=14.17" + } + }, + "node_modules/thenify": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/thenify/-/thenify-3.3.1.tgz", + "integrity": "sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==", + "dev": true, + "dependencies": { + "any-promise": "^1.0.0" + } + }, + "node_modules/thenify-all": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/thenify-all/-/thenify-all-1.6.0.tgz", + "integrity": "sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==", + "dev": true, + "dependencies": { + "thenify": ">= 3.1.0 < 4" + }, + "engines": { + "node": ">=0.8" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/tr46": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-1.0.1.tgz", + "integrity": "sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==", + "dev": true, + "dependencies": { + "punycode": "^2.1.0" + } + }, + "node_modules/tree-kill": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz", + "integrity": "sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==", + "dev": true, + "bin": { + "tree-kill": "cli.js" + } + }, + "node_modules/ts-interface-checker": { + "version": "0.1.13", + "resolved": "https://registry.npmjs.org/ts-interface-checker/-/ts-interface-checker-0.1.13.tgz", + "integrity": "sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==", + "dev": true + }, + "node_modules/tsup": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/tsup/-/tsup-8.1.0.tgz", + "integrity": "sha512-UFdfCAXukax+U6KzeTNO2kAARHcWxmKsnvSPXUcfA1D+kU05XDccCrkffCQpFaWDsZfV0jMyTsxU39VfCp6EOg==", + "dev": true, + "dependencies": { + "bundle-require": "^4.0.0", + "cac": "^6.7.12", + "chokidar": "^3.5.1", + "debug": "^4.3.1", + "esbuild": "^0.21.4", + "execa": "^5.0.0", + "globby": "^11.0.3", + "joycon": "^3.0.1", + "postcss-load-config": "^4.0.1", + "resolve-from": "^5.0.0", + "rollup": "^4.0.2", + "source-map": "0.8.0-beta.0", + "sucrase": "^3.20.3", + "tree-kill": "^1.2.2" + }, + "bin": { + "tsup": "dist/cli-default.js", + "tsup-node": "dist/cli-node.js" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "@microsoft/api-extractor": "^7.36.0", + "@swc/core": "^1", + "postcss": "^8.4.12", + "typescript": ">=4.5.0" + }, + "peerDependenciesMeta": { + "@microsoft/api-extractor": { + "optional": true + }, + "@swc/core": { + "optional": true + }, + "postcss": { + "optional": true + }, + "typescript": { + "optional": true + } + } + }, "node_modules/typescript": { - "version": "3.9.10", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.10.tgz", - "integrity": "sha512-w6fIxVE/H1PkLKcCPsFqKE7Kv7QUwhU8qQY2MueZXWx5cPZdwFupLgKK3vntcK98BtNHZtAF4LA/yl2a7k8R6Q==", + "version": "5.5.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.5.2.tgz", + "integrity": "sha512-NcRtPEOsPFFWjobJEtfihkLCZCXZt/os3zf8nTxjVH3RvTSxjrCamJpbExGvYOF+tFHc3pA65qpdwPbzjohhew==", "dev": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" }, "engines": { - "node": ">=4.2.0" + "node": ">=14.17" } - } - }, - "dependencies": { - "@types/node": { - "version": "15.14.9", - "resolved": "https://registry.npmjs.org/@types/node/-/node-15.14.9.tgz", - "integrity": "sha512-qjd88DrCxupx/kJD5yQgZdcYKZKSIGBVDIBE1/LTGcNm3d2Np/jxojkdePDdfnBHJc5W7vSMpbJ1aB7p/Py69A==", + }, + "node_modules/webidl-conversions": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-4.0.2.tgz", + "integrity": "sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==", "dev": true }, - "typescript": { - "version": "3.9.10", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.10.tgz", - "integrity": "sha512-w6fIxVE/H1PkLKcCPsFqKE7Kv7QUwhU8qQY2MueZXWx5cPZdwFupLgKK3vntcK98BtNHZtAF4LA/yl2a7k8R6Q==", + "node_modules/whatwg-url": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-7.1.0.tgz", + "integrity": "sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg==", + "dev": true, + "dependencies": { + "lodash.sortby": "^4.7.0", + "tr46": "^1.0.1", + "webidl-conversions": "^4.0.2" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dev": true, + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/wrap-ansi": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", + "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", + "dev": true, + "dependencies": { + "ansi-styles": "^6.1.0", + "string-width": "^5.0.1", + "strip-ansi": "^7.0.1" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrap-ansi-cjs": { + "name": "wrap-ansi", + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrap-ansi-cjs/node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/wrap-ansi-cjs/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/wrap-ansi-cjs/node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true + }, + "node_modules/wrap-ansi-cjs/node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/wrap-ansi-cjs/node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/yaml": { + "version": "2.4.5", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.4.5.tgz", + "integrity": "sha512-aBx2bnqDzVOyNKfsysjA2ms5ZlnjSAW2eG3/L5G/CSujfjLJTJsEw1bGw8kCf04KodQWk1pxlGnZ56CRxiawmg==", + "dev": true, + "bin": { + "yaml": "bin.mjs" + }, + "engines": { + "node": ">= 14" + } } } } diff --git a/package.json b/package.json index b0f626c..c1ca4d4 100644 --- a/package.json +++ b/package.json @@ -1,9 +1,8 @@ { "name": "@paystack/paystack-sdk", - "version": "1.2.0", + "version": "1.2.1-beta.1", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", - "type": "module", "keywords": [ "paystack", "payment", @@ -20,22 +19,25 @@ "homepage": "https://github.com/PaystackOSS/paystack-node", "bugs": "https://github.com/PaystackOSS/paystack-node/issues", "license": "MIT", - "exports": { - "types": "./dist/types/index.d.ts", - "require": "./dist/cjs/index.js", - "import": "./dist/esm/index.js", - "default": "./dist/esm/index.js" - }, "main": "./dist/index.js", - "module": "./dist/esm/index.js", - "types": "./dist/types/index.d.ts", + "module": "./dist/index.mjs", + "types": "./dist/index.d.ts", + "tsup": { + "entry": [ + "src/index.ts" + ], + "splitting": true, + "sourcemap": false, + "clean": true + }, "scripts": { - "build": "npm run clean && npm run compile", + "build": "npm run clean && tsup --format esm,cjs --dts", "clean": "rm -rf ./dist", "compile": "tsc -p tsconfig.esm.json && tsc -p ./tsconfig.cjs.json && tsc -p ./tsconfig.types.json" }, "devDependencies": { "@types/node": "^15.0.3", - "typescript": "^3.6" + "tsup": "^8.1.0", + "typescript": "^5.5.2" } } diff --git a/src/runtime.ts b/src/runtime.ts index 19ef628..9b441a7 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "user-agent": `@paystack/paystack-sdk - 1.2.0` + "user-agent": `@paystack/paystack-sdk - 1.2.1-beta.1` } } From 83964aee0802202c24c03490f7efa6d9f4fea09f Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Tue, 3 Sep 2024 14:58:44 +0100 Subject: [PATCH 12/13] Patch: (DX) Type export for autocomplete --- package.json | 2 +- src/index.ts | 87 ++++++++++++++++++++++++++++++++++---------------- src/runtime.ts | 2 +- 3 files changed, 62 insertions(+), 29 deletions(-) diff --git a/package.json b/package.json index c1ca4d4..f86d7c9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@paystack/paystack-sdk", - "version": "1.2.1-beta.1", + "version": "1.2.1-beta.2", "description": "Paystack API wrapper for Node", "author": "Paystack (https://paystack.com/docs)", "keywords": [ diff --git a/src/index.ts b/src/index.ts index 96aec52..b6be4d6 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,33 +1,66 @@ -import * as Resources from './apis' +import { Balance } from './apis/Balance'; +import { BulkCharge } from './apis/BulkCharge'; +import { Charge } from './apis/Charge'; +import { Customer } from './apis/Customer'; +import { DedicatedVirtualAccount } from './apis/DedicatedVirtualAccount'; +import { Dispute } from './apis/Dispute'; +import { Integration } from './apis/Integration'; +import { Page } from './apis/Page'; +import { PaymentRequest } from './apis/PaymentRequest'; +import { Plan } from './apis/Plan'; +import { Product } from './apis/Product'; +import { Refund } from './apis/Refund'; +import { Settlement } from './apis/Settlement'; +import { Split } from './apis/Split'; +import { Subaccount } from './apis/Subaccount'; +import { Subscription } from './apis/Subscription'; +import { Transaction } from './apis/Transaction'; +import { Transfer } from './apis/Transfer'; +import { TransferRecipient } from './apis/TransferRecipient'; +import { Verification } from './apis/Verification'; export class Paystack { - [index: string]: any + public readonly balance: Balance; + public readonly bulkCharge: BulkCharge; + public readonly charge: Charge; + public readonly customer: Customer; + public readonly dedicatedVirtualAccount: DedicatedVirtualAccount; + public readonly dispute: Dispute; + public readonly integration: Integration; + public readonly page: Page; + public readonly paymentRequest: PaymentRequest; + public readonly plan: Plan; + public readonly product: Product; + public readonly refund: Refund; + public readonly settlement: Settlement; + public readonly split: Split; + public readonly subaccount: Subaccount; + public readonly subscription: Subscription; + public readonly transaction: Transaction; + public readonly transfer: Transfer; + public readonly transferRecipient: TransferRecipient; + public readonly verification: Verification; constructor(apiKey: string) { - this.extend(apiKey) + this.balance = new Balance(apiKey); + this.bulkCharge = new BulkCharge(apiKey); + this.charge = new Charge(apiKey); + this.customer = new Customer(apiKey); + this.dedicatedVirtualAccount = new DedicatedVirtualAccount(apiKey); + this.dispute = new Dispute(apiKey); + this.integration = new Integration(apiKey); + this.page = new Page(apiKey); + this.paymentRequest = new PaymentRequest(apiKey); + this.plan = new Plan(apiKey); + this.product = new Product(apiKey); + this.refund = new Refund(apiKey); + this.settlement = new Settlement(apiKey); + this.split = new Split(apiKey); + this.subaccount = new Subaccount(apiKey); + this.subscription = new Subscription(apiKey); + this.transaction = new Transaction(apiKey); + this.transfer = new Transfer(apiKey); + this.transferRecipient = new TransferRecipient(apiKey); + this.verification = new Verification(apiKey); } - - private extend(apiKey: string) { - for (const resource in Resources) { - if (Resources[resource]) { - this[this.toCamelCase(resource)] = new Resources[resource][resource]( - apiKey - ); - } - } - } - - private toCamelCase(resource: string): string { - const _resource = this.cleanResourceKey(resource) - _resource.toLowerCase() - .replace(/\W+(.)/g, (_, chr) => chr.toUpperCase()); - - return _resource - } - - private cleanResourceKey(resource: string): string { - if(!resource) return null - return resource.toLowerCase().replace("api", "") - } - } \ No newline at end of file diff --git a/src/runtime.ts b/src/runtime.ts index 9b441a7..3f204fb 100644 --- a/src/runtime.ts +++ b/src/runtime.ts @@ -55,7 +55,7 @@ export class BaseAPI { path: tempPath, headers: { "authorization": `Bearer ${this.apiKey}`, - "user-agent": `@paystack/paystack-sdk - 1.2.1-beta.1` + "user-agent": `@paystack/paystack-sdk - 1.2.1-beta.2` } } From a464e7c56eaad74c44a45951cdf8e974b549ab8a Mon Sep 17 00:00:00 2001 From: Damilola Odujoko Date: Wed, 4 Sep 2024 11:06:31 +0100 Subject: [PATCH 13/13] Chore: Update npmignore --- .npmignore | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.npmignore b/.npmignore index 42061c0..b81264f 100644 --- a/.npmignore +++ b/.npmignore @@ -1 +1,2 @@ -README.md \ No newline at end of file +src/ +.openapi-generator \ No newline at end of file