@payabli/sdk-node 0.0.116 → 0.0.123
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +31 -2
- package/dist/cjs/BaseClient.d.ts +13 -4
- package/dist/cjs/BaseClient.js +59 -0
- package/dist/cjs/Client.d.ts +88 -88
- package/dist/cjs/Client.js +31 -72
- package/dist/cjs/api/errors/BadRequestError.js +5 -1
- package/dist/cjs/api/errors/ConflictError.js +5 -1
- package/dist/cjs/api/errors/ForbiddenError.js +5 -1
- package/dist/cjs/api/errors/InternalServerError.js +5 -1
- package/dist/cjs/api/errors/ServiceUnavailableError.js +5 -1
- package/dist/cjs/api/errors/UnauthorizedError.js +5 -1
- package/dist/cjs/api/resources/bill/client/Client.d.ts +34 -35
- package/dist/cjs/api/resources/bill/client/Client.js +69 -216
- package/dist/cjs/api/resources/boarding/client/Client.d.ts +28 -29
- package/dist/cjs/api/resources/boarding/client/Client.js +51 -198
- package/dist/cjs/api/resources/chargeBacks/client/Client.d.ts +18 -17
- package/dist/cjs/api/resources/chargeBacks/client/Client.js +38 -79
- package/dist/cjs/api/resources/checkCapture/client/Client.d.ts +8 -9
- package/dist/cjs/api/resources/checkCapture/client/Client.js +11 -28
- package/dist/cjs/api/resources/cloud/client/Client.d.ts +18 -19
- package/dist/cjs/api/resources/cloud/client/Client.js +33 -89
- package/dist/cjs/api/resources/customer/client/Client.d.ts +18 -19
- package/dist/cjs/api/resources/customer/client/Client.js +31 -113
- package/dist/cjs/api/resources/export/client/Client.d.ts +94 -91
- package/dist/cjs/api/resources/export/client/Client.js +205 -582
- package/dist/cjs/api/resources/hostedPaymentPages/client/Client.d.ts +12 -13
- package/dist/cjs/api/resources/hostedPaymentPages/client/Client.js +19 -62
- package/dist/cjs/api/resources/import/client/Client.d.ts +12 -13
- package/dist/cjs/api/resources/import/client/Client.js +19 -62
- package/dist/cjs/api/resources/invoice/client/Client.d.ts +37 -36
- package/dist/cjs/api/resources/invoice/client/Client.js +67 -212
- package/dist/cjs/api/resources/invoice/client/requests/AddInvoiceRequest.d.ts +5 -3
- package/dist/cjs/api/resources/lineItem/client/Client.d.ts +16 -17
- package/dist/cjs/api/resources/lineItem/client/Client.js +27 -96
- package/dist/cjs/api/resources/moneyIn/client/Client.d.ts +40 -41
- package/dist/cjs/api/resources/moneyIn/client/Client.js +79 -249
- package/dist/cjs/api/resources/moneyIn/errors/CaptureError.js +5 -1
- package/dist/cjs/api/resources/moneyIn/errors/InvalidTransStatusError.js +5 -1
- package/dist/cjs/api/resources/moneyOut/client/Client.d.ts +44 -28
- package/dist/cjs/api/resources/moneyOut/client/Client.js +105 -168
- package/dist/cjs/api/resources/moneyOut/client/requests/MoneyOutTypesRequestOutAuthorize.d.ts +2 -1
- package/dist/cjs/api/resources/moneyOutTypes/types/AuthorizePayoutBody.d.ts +3 -1
- package/dist/cjs/api/resources/notification/client/Client.d.ts +30 -18
- package/dist/cjs/api/resources/notification/client/Client.js +45 -101
- package/dist/cjs/api/resources/notificationlogs/client/Client.d.ts +14 -15
- package/dist/cjs/api/resources/notificationlogs/client/Client.js +23 -79
- package/dist/cjs/api/resources/ocr/client/Client.d.ts +14 -11
- package/dist/cjs/api/resources/ocr/client/Client.js +19 -45
- package/dist/cjs/api/resources/organization/client/Client.d.ts +20 -21
- package/dist/cjs/api/resources/organization/client/Client.js +35 -130
- package/dist/cjs/api/resources/paymentLink/client/Client.d.ts +27 -28
- package/dist/cjs/api/resources/paymentLink/client/Client.js +46 -167
- package/dist/cjs/api/resources/paymentLink/client/requests/PayLinkDataBill.d.ts +1 -1
- package/dist/cjs/api/resources/paymentLink/client/requests/PayLinkDataInvoice.d.ts +1 -1
- package/dist/cjs/api/resources/paymentLink/client/requests/PayLinkDataOut.d.ts +1 -1
- package/dist/cjs/api/resources/paymentLink/types/PaymentPageRequestBody.d.ts +2 -2
- package/dist/cjs/api/resources/paymentMethodDomain/client/Client.d.ts +20 -21
- package/dist/cjs/api/resources/paymentMethodDomain/client/Client.js +35 -130
- package/dist/cjs/api/resources/paypoint/client/Client.d.ts +23 -24
- package/dist/cjs/api/resources/paypoint/client/Client.js +44 -152
- package/dist/cjs/api/resources/query/client/Client.d.ts +72 -73
- package/dist/cjs/api/resources/query/client/Client.js +137 -572
- package/dist/cjs/api/resources/query/client/requests/ListPayoutOrgRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/ListPayoutRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/ListTransactionsRequest.d.ts +1 -0
- package/dist/cjs/api/resources/statistic/client/Client.d.ts +51 -52
- package/dist/cjs/api/resources/statistic/client/Client.js +80 -133
- package/dist/cjs/api/resources/statistic/client/requests/BasicStatsRequest.d.ts +2 -2
- package/dist/cjs/api/resources/statistic/types/StatBasicExtendedQueryRecord.d.ts +76 -0
- package/dist/cjs/api/resources/statistic/types/StatBasicExtendedQueryRecord.js +3 -0
- package/dist/cjs/api/resources/statistic/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/statistic/types/index.js +1 -0
- package/dist/cjs/api/resources/subscription/client/Client.d.ts +14 -15
- package/dist/cjs/api/resources/subscription/client/Client.js +23 -79
- package/dist/cjs/api/resources/templates/client/Client.d.ts +16 -17
- package/dist/cjs/api/resources/templates/client/Client.js +28 -84
- package/dist/cjs/api/resources/tokenStorage/client/Client.d.ts +14 -15
- package/dist/cjs/api/resources/tokenStorage/client/Client.js +23 -79
- package/dist/cjs/api/resources/tokenStorage/types/GetMethodResponse.d.ts +1 -1
- package/dist/cjs/api/resources/user/client/Client.d.ts +55 -34
- package/dist/cjs/api/resources/user/client/Client.js +84 -222
- package/dist/cjs/api/resources/vendor/client/Client.d.ts +14 -15
- package/dist/cjs/api/resources/vendor/client/Client.js +23 -79
- package/dist/cjs/api/resources/wallet/client/Client.d.ts +14 -15
- package/dist/cjs/api/resources/wallet/client/Client.js +23 -79
- package/dist/cjs/api/types/ApplicationDetailsRecord.d.ts +2 -2
- package/dist/cjs/api/types/Frequency.d.ts +1 -1
- package/dist/cjs/api/types/Frequency.js +1 -1
- package/dist/cjs/api/types/FrequencyList.d.ts +1 -1
- package/dist/cjs/api/types/NotificationContent.d.ts +1 -0
- package/dist/cjs/api/types/NotificationContent.js +1 -0
- package/dist/cjs/api/types/NotificationStandardRequest.d.ts +1 -0
- package/dist/cjs/api/types/NotificationStandardRequest.js +1 -0
- package/dist/cjs/api/types/PayorDataResponse.d.ts +1 -1
- package/dist/cjs/api/types/QueryResponseSettlements.d.ts +1 -1
- package/dist/cjs/auth/HeaderAuthProvider.d.ts +16 -0
- package/dist/cjs/auth/HeaderAuthProvider.js +71 -0
- package/dist/cjs/auth/index.d.ts +1 -0
- package/dist/cjs/auth/index.js +5 -0
- package/dist/cjs/core/auth/AuthProvider.d.ts +7 -0
- package/dist/cjs/core/auth/AuthProvider.js +2 -0
- package/dist/cjs/core/auth/AuthRequest.d.ts +9 -0
- package/dist/cjs/core/auth/AuthRequest.js +2 -0
- package/dist/cjs/core/auth/BasicAuth.d.ts +8 -0
- package/dist/cjs/core/auth/BasicAuth.js +27 -0
- package/dist/cjs/core/auth/BearerToken.d.ts +7 -0
- package/dist/cjs/core/auth/BearerToken.js +16 -0
- package/dist/cjs/core/auth/NoOpAuthProvider.d.ts +5 -0
- package/dist/cjs/core/auth/NoOpAuthProvider.js +9 -0
- package/dist/cjs/core/auth/index.d.ts +5 -0
- package/dist/cjs/core/auth/index.js +9 -0
- package/dist/cjs/core/base64.d.ts +2 -0
- package/dist/cjs/core/base64.js +26 -0
- package/dist/cjs/core/fetcher/BinaryResponse.d.ts +6 -7
- package/dist/cjs/core/fetcher/Fetcher.d.ts +5 -1
- package/dist/cjs/core/fetcher/Fetcher.js +42 -24
- package/dist/cjs/core/fetcher/getResponseBody.js +18 -4
- package/dist/cjs/core/fetcher/makeRequest.d.ts +1 -1
- package/dist/cjs/core/fetcher/makeRequest.js +0 -2
- package/dist/cjs/core/fetcher/requestWithRetries.js +0 -9
- package/dist/cjs/core/fetcher/signals.d.ts +1 -7
- package/dist/cjs/core/fetcher/signals.js +0 -12
- package/dist/cjs/core/index.d.ts +2 -0
- package/dist/cjs/core/index.js +2 -0
- package/dist/cjs/core/logging/logger.js +1 -1
- package/dist/cjs/core/runtime/runtime.js +11 -10
- package/dist/cjs/core/url/join.js +0 -1
- package/dist/cjs/errors/PayabliError.js +5 -1
- package/dist/cjs/errors/PayabliTimeoutError.js +5 -1
- package/dist/cjs/errors/handleNonStatusCodeError.d.ts +2 -0
- package/dist/cjs/errors/handleNonStatusCodeError.js +65 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +13 -4
- package/dist/esm/BaseClient.mjs +24 -1
- package/dist/esm/Client.d.mts +88 -88
- package/dist/esm/Client.mjs +59 -67
- package/dist/esm/api/errors/BadRequestError.mjs +5 -1
- package/dist/esm/api/errors/ConflictError.mjs +5 -1
- package/dist/esm/api/errors/ForbiddenError.mjs +5 -1
- package/dist/esm/api/errors/InternalServerError.mjs +5 -1
- package/dist/esm/api/errors/ServiceUnavailableError.mjs +5 -1
- package/dist/esm/api/errors/UnauthorizedError.mjs +5 -1
- package/dist/esm/api/resources/bill/client/Client.d.mts +34 -35
- package/dist/esm/api/resources/bill/client/Client.mjs +67 -214
- package/dist/esm/api/resources/boarding/client/Client.d.mts +28 -29
- package/dist/esm/api/resources/boarding/client/Client.mjs +50 -197
- package/dist/esm/api/resources/chargeBacks/client/Client.d.mts +18 -17
- package/dist/esm/api/resources/chargeBacks/client/Client.mjs +36 -77
- package/dist/esm/api/resources/checkCapture/client/Client.d.mts +8 -9
- package/dist/esm/api/resources/checkCapture/client/Client.mjs +10 -27
- package/dist/esm/api/resources/cloud/client/Client.d.mts +18 -19
- package/dist/esm/api/resources/cloud/client/Client.mjs +31 -87
- package/dist/esm/api/resources/customer/client/Client.d.mts +18 -19
- package/dist/esm/api/resources/customer/client/Client.mjs +29 -111
- package/dist/esm/api/resources/export/client/Client.d.mts +94 -91
- package/dist/esm/api/resources/export/client/Client.mjs +204 -581
- package/dist/esm/api/resources/hostedPaymentPages/client/Client.d.mts +12 -13
- package/dist/esm/api/resources/hostedPaymentPages/client/Client.mjs +17 -60
- package/dist/esm/api/resources/import/client/Client.d.mts +12 -13
- package/dist/esm/api/resources/import/client/Client.mjs +17 -60
- package/dist/esm/api/resources/invoice/client/Client.d.mts +37 -36
- package/dist/esm/api/resources/invoice/client/Client.mjs +65 -210
- package/dist/esm/api/resources/invoice/client/requests/AddInvoiceRequest.d.mts +5 -3
- package/dist/esm/api/resources/lineItem/client/Client.d.mts +16 -17
- package/dist/esm/api/resources/lineItem/client/Client.mjs +25 -94
- package/dist/esm/api/resources/moneyIn/client/Client.d.mts +40 -41
- package/dist/esm/api/resources/moneyIn/client/Client.mjs +77 -247
- package/dist/esm/api/resources/moneyIn/errors/CaptureError.mjs +5 -1
- package/dist/esm/api/resources/moneyIn/errors/InvalidTransStatusError.mjs +5 -1
- package/dist/esm/api/resources/moneyOut/client/Client.d.mts +44 -28
- package/dist/esm/api/resources/moneyOut/client/Client.mjs +103 -166
- package/dist/esm/api/resources/moneyOut/client/requests/MoneyOutTypesRequestOutAuthorize.d.mts +2 -1
- package/dist/esm/api/resources/moneyOutTypes/types/AuthorizePayoutBody.d.mts +3 -1
- package/dist/esm/api/resources/notification/client/Client.d.mts +30 -18
- package/dist/esm/api/resources/notification/client/Client.mjs +44 -100
- package/dist/esm/api/resources/notificationlogs/client/Client.d.mts +14 -15
- package/dist/esm/api/resources/notificationlogs/client/Client.mjs +22 -78
- package/dist/esm/api/resources/ocr/client/Client.d.mts +14 -11
- package/dist/esm/api/resources/ocr/client/Client.mjs +18 -44
- package/dist/esm/api/resources/organization/client/Client.d.mts +20 -21
- package/dist/esm/api/resources/organization/client/Client.mjs +33 -128
- package/dist/esm/api/resources/paymentLink/client/Client.d.mts +27 -28
- package/dist/esm/api/resources/paymentLink/client/Client.mjs +44 -165
- package/dist/esm/api/resources/paymentLink/client/requests/PayLinkDataBill.d.mts +1 -1
- package/dist/esm/api/resources/paymentLink/client/requests/PayLinkDataInvoice.d.mts +1 -1
- package/dist/esm/api/resources/paymentLink/client/requests/PayLinkDataOut.d.mts +1 -1
- package/dist/esm/api/resources/paymentLink/types/PaymentPageRequestBody.d.mts +2 -2
- package/dist/esm/api/resources/paymentMethodDomain/client/Client.d.mts +20 -21
- package/dist/esm/api/resources/paymentMethodDomain/client/Client.mjs +34 -129
- package/dist/esm/api/resources/paypoint/client/Client.d.mts +23 -24
- package/dist/esm/api/resources/paypoint/client/Client.mjs +43 -151
- package/dist/esm/api/resources/query/client/Client.d.mts +72 -73
- package/dist/esm/api/resources/query/client/Client.mjs +136 -571
- package/dist/esm/api/resources/query/client/requests/ListPayoutOrgRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/ListPayoutRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/ListTransactionsRequest.d.mts +1 -0
- package/dist/esm/api/resources/statistic/client/Client.d.mts +51 -52
- package/dist/esm/api/resources/statistic/client/Client.mjs +79 -132
- package/dist/esm/api/resources/statistic/client/requests/BasicStatsRequest.d.mts +2 -2
- package/dist/esm/api/resources/statistic/types/StatBasicExtendedQueryRecord.d.mts +76 -0
- package/dist/esm/api/resources/statistic/types/StatBasicExtendedQueryRecord.mjs +2 -0
- package/dist/esm/api/resources/statistic/types/index.d.mts +1 -0
- package/dist/esm/api/resources/statistic/types/index.mjs +1 -0
- package/dist/esm/api/resources/subscription/client/Client.d.mts +14 -15
- package/dist/esm/api/resources/subscription/client/Client.mjs +21 -77
- package/dist/esm/api/resources/templates/client/Client.d.mts +16 -17
- package/dist/esm/api/resources/templates/client/Client.mjs +27 -83
- package/dist/esm/api/resources/tokenStorage/client/Client.d.mts +14 -15
- package/dist/esm/api/resources/tokenStorage/client/Client.mjs +21 -77
- package/dist/esm/api/resources/tokenStorage/types/GetMethodResponse.d.mts +1 -1
- package/dist/esm/api/resources/user/client/Client.d.mts +55 -34
- package/dist/esm/api/resources/user/client/Client.mjs +83 -221
- package/dist/esm/api/resources/vendor/client/Client.d.mts +14 -15
- package/dist/esm/api/resources/vendor/client/Client.mjs +22 -78
- package/dist/esm/api/resources/wallet/client/Client.d.mts +14 -15
- package/dist/esm/api/resources/wallet/client/Client.mjs +22 -78
- package/dist/esm/api/types/ApplicationDetailsRecord.d.mts +2 -2
- package/dist/esm/api/types/Frequency.d.mts +1 -1
- package/dist/esm/api/types/Frequency.mjs +1 -1
- package/dist/esm/api/types/FrequencyList.d.mts +1 -1
- package/dist/esm/api/types/NotificationContent.d.mts +1 -0
- package/dist/esm/api/types/NotificationContent.mjs +1 -0
- package/dist/esm/api/types/NotificationStandardRequest.d.mts +1 -0
- package/dist/esm/api/types/NotificationStandardRequest.mjs +1 -0
- package/dist/esm/api/types/PayorDataResponse.d.mts +1 -1
- package/dist/esm/api/types/QueryResponseSettlements.d.mts +1 -1
- package/dist/esm/auth/HeaderAuthProvider.d.mts +16 -0
- package/dist/esm/auth/HeaderAuthProvider.mjs +34 -0
- package/dist/esm/auth/index.d.mts +1 -0
- package/dist/esm/auth/index.mjs +1 -0
- package/dist/esm/core/auth/AuthProvider.d.mts +7 -0
- package/dist/esm/core/auth/AuthProvider.mjs +1 -0
- package/dist/esm/core/auth/AuthRequest.d.mts +9 -0
- package/dist/esm/core/auth/AuthRequest.mjs +1 -0
- package/dist/esm/core/auth/BasicAuth.d.mts +8 -0
- package/dist/esm/core/auth/BasicAuth.mjs +24 -0
- package/dist/esm/core/auth/BearerToken.d.mts +7 -0
- package/dist/esm/core/auth/BearerToken.mjs +13 -0
- package/dist/esm/core/auth/NoOpAuthProvider.d.mts +5 -0
- package/dist/esm/core/auth/NoOpAuthProvider.mjs +5 -0
- package/dist/esm/core/auth/index.d.mts +5 -0
- package/dist/esm/core/auth/index.mjs +3 -0
- package/dist/esm/core/base64.d.mts +2 -0
- package/dist/esm/core/base64.mjs +22 -0
- package/dist/esm/core/fetcher/BinaryResponse.d.mts +6 -7
- package/dist/esm/core/fetcher/Fetcher.d.mts +5 -1
- package/dist/esm/core/fetcher/Fetcher.mjs +42 -24
- package/dist/esm/core/fetcher/getResponseBody.mjs +18 -4
- package/dist/esm/core/fetcher/makeRequest.d.mts +1 -1
- package/dist/esm/core/fetcher/makeRequest.mjs +0 -2
- package/dist/esm/core/fetcher/requestWithRetries.mjs +0 -9
- package/dist/esm/core/fetcher/signals.d.mts +1 -7
- package/dist/esm/core/fetcher/signals.mjs +0 -12
- package/dist/esm/core/index.d.mts +2 -0
- package/dist/esm/core/index.mjs +2 -0
- package/dist/esm/core/logging/logger.mjs +1 -1
- package/dist/esm/core/runtime/runtime.mjs +11 -10
- package/dist/esm/core/url/join.mjs +0 -1
- package/dist/esm/errors/PayabliError.mjs +5 -1
- package/dist/esm/errors/PayabliTimeoutError.mjs +5 -1
- package/dist/esm/errors/handleNonStatusCodeError.d.mts +2 -0
- package/dist/esm/errors/handleNonStatusCodeError.mjs +29 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +5 -2
- package/reference.md +768 -478
- package/dist/cjs/core/fetcher/ResponseWithBody.d.ts +0 -4
- package/dist/cjs/core/fetcher/ResponseWithBody.js +0 -6
- package/dist/esm/core/fetcher/ResponseWithBody.d.mts +0 -4
- package/dist/esm/core/fetcher/ResponseWithBody.mjs +0 -3
package/README.md
CHANGED
|
@@ -5,6 +5,26 @@
|
|
|
5
5
|
|
|
6
6
|
The Payabli TypeScript library provides convenient access to the Payabli APIs from TypeScript.
|
|
7
7
|
|
|
8
|
+
## Table of Contents
|
|
9
|
+
|
|
10
|
+
- [Documentation](#documentation)
|
|
11
|
+
- [Installation](#installation)
|
|
12
|
+
- [Reference](#reference)
|
|
13
|
+
- [Usage](#usage)
|
|
14
|
+
- [Request and Response Types](#request-and-response-types)
|
|
15
|
+
- [Exception Handling](#exception-handling)
|
|
16
|
+
- [File Uploads](#file-uploads)
|
|
17
|
+
- [Advanced](#advanced)
|
|
18
|
+
- [Additional Headers](#additional-headers)
|
|
19
|
+
- [Additional Query String Parameters](#additional-query-string-parameters)
|
|
20
|
+
- [Retries](#retries)
|
|
21
|
+
- [Timeouts](#timeouts)
|
|
22
|
+
- [Aborting Requests](#aborting-requests)
|
|
23
|
+
- [Access Raw Response Data](#access-raw-response-data)
|
|
24
|
+
- [Logging](#logging)
|
|
25
|
+
- [Runtime Compatibility](#runtime-compatibility)
|
|
26
|
+
- [Contributing](#contributing)
|
|
27
|
+
|
|
8
28
|
## Documentation
|
|
9
29
|
|
|
10
30
|
API reference documentation is available [here](https://docs.payabli.com).
|
|
@@ -51,7 +71,7 @@ await client.moneyIn.getpaid({
|
|
|
51
71
|
});
|
|
52
72
|
```
|
|
53
73
|
|
|
54
|
-
## Request
|
|
74
|
+
## Request and Response Types
|
|
55
75
|
|
|
56
76
|
The SDK exports all request and response types as TypeScript interfaces. Simply import them with the
|
|
57
77
|
following namespace:
|
|
@@ -90,8 +110,8 @@ You can upload files using the client:
|
|
|
90
110
|
|
|
91
111
|
```typescript
|
|
92
112
|
import { createReadStream } from "fs";
|
|
93
|
-
import { PayabliClient } from "@payabli/sdk-node";
|
|
94
113
|
import * as fs from "fs";
|
|
114
|
+
import { PayabliClient } from "@payabli/sdk-node";
|
|
95
115
|
|
|
96
116
|
const client = new PayabliClient({ apiKey: "YOUR_API_KEY" });
|
|
97
117
|
await client.import.importBills("8cfec329267", {
|
|
@@ -135,6 +155,15 @@ For example, `fs.ReadStream` has a `path` property which the SDK uses to retriev
|
|
|
135
155
|
If you would like to send additional headers as part of the request, use the `headers` request option.
|
|
136
156
|
|
|
137
157
|
```typescript
|
|
158
|
+
import { PayabliClient } from "@payabli/sdk-node";
|
|
159
|
+
|
|
160
|
+
const client = new PayabliClient({
|
|
161
|
+
...
|
|
162
|
+
headers: {
|
|
163
|
+
'X-Custom-Header': 'custom value'
|
|
164
|
+
}
|
|
165
|
+
});
|
|
166
|
+
|
|
138
167
|
const response = await client.moneyIn.getpaid(..., {
|
|
139
168
|
headers: {
|
|
140
169
|
'X-Custom-Header': 'custom value'
|
package/dist/cjs/BaseClient.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { HeaderAuthProvider } from "./auth/HeaderAuthProvider.js";
|
|
2
|
+
import * as core from "./core/index.js";
|
|
2
3
|
import type * as environments from "./environments.js";
|
|
3
|
-
export
|
|
4
|
+
export type BaseClientOptions = {
|
|
4
5
|
environment?: core.Supplier<environments.PayabliEnvironment | string>;
|
|
5
6
|
/** Specify a custom URL to connect the client to. */
|
|
6
7
|
baseUrl?: core.Supplier<string>;
|
|
7
|
-
apiKey?: core.Supplier<string | undefined>;
|
|
8
8
|
/** Additional headers to include in requests. */
|
|
9
9
|
headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
|
|
10
10
|
/** The default maximum time to wait for a response in seconds. */
|
|
@@ -15,7 +15,7 @@ export interface BaseClientOptions {
|
|
|
15
15
|
fetch?: typeof fetch;
|
|
16
16
|
/** Configure logging for the client. */
|
|
17
17
|
logging?: core.logging.LogConfig | core.logging.Logger;
|
|
18
|
-
}
|
|
18
|
+
} & HeaderAuthProvider.AuthOptions;
|
|
19
19
|
export interface BaseRequestOptions {
|
|
20
20
|
/** The maximum time to wait for a response in seconds. */
|
|
21
21
|
timeoutInSeconds?: number;
|
|
@@ -28,3 +28,12 @@ export interface BaseRequestOptions {
|
|
|
28
28
|
/** Additional headers to include in the request. */
|
|
29
29
|
headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
|
|
30
30
|
}
|
|
31
|
+
export type NormalizedClientOptions<T extends BaseClientOptions = BaseClientOptions> = T & {
|
|
32
|
+
logging: core.logging.Logger;
|
|
33
|
+
authProvider?: core.AuthProvider;
|
|
34
|
+
};
|
|
35
|
+
export type NormalizedClientOptionsWithAuth<T extends BaseClientOptions = BaseClientOptions> = NormalizedClientOptions<T> & {
|
|
36
|
+
authProvider: core.AuthProvider;
|
|
37
|
+
};
|
|
38
|
+
export declare function normalizeClientOptions<T extends BaseClientOptions = BaseClientOptions>(options: T): NormalizedClientOptions<T>;
|
|
39
|
+
export declare function normalizeClientOptionsWithAuth<T extends BaseClientOptions = BaseClientOptions>(options: T): NormalizedClientOptionsWithAuth<T>;
|
package/dist/cjs/BaseClient.js
CHANGED
|
@@ -1,3 +1,62 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
3
36
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
|
+
exports.normalizeClientOptions = normalizeClientOptions;
|
|
38
|
+
exports.normalizeClientOptionsWithAuth = normalizeClientOptionsWithAuth;
|
|
39
|
+
const HeaderAuthProvider_js_1 = require("./auth/HeaderAuthProvider.js");
|
|
40
|
+
const headers_js_1 = require("./core/headers.js");
|
|
41
|
+
const core = __importStar(require("./core/index.js"));
|
|
42
|
+
function normalizeClientOptions(options) {
|
|
43
|
+
const headers = (0, headers_js_1.mergeHeaders)({
|
|
44
|
+
"X-Fern-Language": "JavaScript",
|
|
45
|
+
"X-Fern-SDK-Name": "@payabli/sdk-node",
|
|
46
|
+
"X-Fern-SDK-Version": "0.0.123",
|
|
47
|
+
"User-Agent": "@payabli/sdk-node/0.0.123",
|
|
48
|
+
"X-Fern-Runtime": core.RUNTIME.type,
|
|
49
|
+
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
50
|
+
}, options === null || options === void 0 ? void 0 : options.headers);
|
|
51
|
+
return Object.assign(Object.assign({}, options), { logging: core.logging.createLogger(options === null || options === void 0 ? void 0 : options.logging), headers });
|
|
52
|
+
}
|
|
53
|
+
function normalizeClientOptionsWithAuth(options) {
|
|
54
|
+
var _a;
|
|
55
|
+
const normalized = normalizeClientOptions(options);
|
|
56
|
+
const normalizedWithNoOpAuthProvider = withNoOpAuthProvider(normalized);
|
|
57
|
+
(_a = normalized.authProvider) !== null && _a !== void 0 ? _a : (normalized.authProvider = new HeaderAuthProvider_js_1.HeaderAuthProvider(normalizedWithNoOpAuthProvider));
|
|
58
|
+
return normalized;
|
|
59
|
+
}
|
|
60
|
+
function withNoOpAuthProvider(options) {
|
|
61
|
+
return Object.assign(Object.assign({}, options), { authProvider: new core.NoOpAuthProvider() });
|
|
62
|
+
}
|
package/dist/cjs/Client.d.ts
CHANGED
|
@@ -1,95 +1,95 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
1
|
+
import { BillClient } from "./api/resources/bill/client/Client.js";
|
|
2
|
+
import { BoardingClient } from "./api/resources/boarding/client/Client.js";
|
|
3
|
+
import { ChargeBacksClient } from "./api/resources/chargeBacks/client/Client.js";
|
|
4
|
+
import { CheckCaptureClient } from "./api/resources/checkCapture/client/Client.js";
|
|
5
|
+
import { CloudClient } from "./api/resources/cloud/client/Client.js";
|
|
6
|
+
import { CustomerClient } from "./api/resources/customer/client/Client.js";
|
|
7
|
+
import { ExportClient } from "./api/resources/export/client/Client.js";
|
|
8
|
+
import { HostedPaymentPagesClient } from "./api/resources/hostedPaymentPages/client/Client.js";
|
|
9
|
+
import { ImportClient } from "./api/resources/import/client/Client.js";
|
|
10
|
+
import { InvoiceClient } from "./api/resources/invoice/client/Client.js";
|
|
11
|
+
import { LineItemClient } from "./api/resources/lineItem/client/Client.js";
|
|
12
|
+
import { MoneyInClient } from "./api/resources/moneyIn/client/Client.js";
|
|
13
|
+
import { MoneyOutClient } from "./api/resources/moneyOut/client/Client.js";
|
|
14
|
+
import { NotificationClient } from "./api/resources/notification/client/Client.js";
|
|
15
|
+
import { NotificationlogsClient } from "./api/resources/notificationlogs/client/Client.js";
|
|
16
|
+
import { OcrClient } from "./api/resources/ocr/client/Client.js";
|
|
17
|
+
import { OrganizationClient } from "./api/resources/organization/client/Client.js";
|
|
18
|
+
import { PaymentLinkClient } from "./api/resources/paymentLink/client/Client.js";
|
|
19
|
+
import { PaymentMethodDomainClient } from "./api/resources/paymentMethodDomain/client/Client.js";
|
|
20
|
+
import { PaypointClient } from "./api/resources/paypoint/client/Client.js";
|
|
21
|
+
import { QueryClient } from "./api/resources/query/client/Client.js";
|
|
22
|
+
import { StatisticClient } from "./api/resources/statistic/client/Client.js";
|
|
23
|
+
import { SubscriptionClient } from "./api/resources/subscription/client/Client.js";
|
|
24
|
+
import { TemplatesClient } from "./api/resources/templates/client/Client.js";
|
|
25
|
+
import { TokenStorageClient } from "./api/resources/tokenStorage/client/Client.js";
|
|
26
|
+
import { UserClient } from "./api/resources/user/client/Client.js";
|
|
27
|
+
import { VendorClient } from "./api/resources/vendor/client/Client.js";
|
|
28
|
+
import { WalletClient } from "./api/resources/wallet/client/Client.js";
|
|
29
29
|
import type { BaseClientOptions, BaseRequestOptions } from "./BaseClient.js";
|
|
30
|
+
import { type NormalizedClientOptionsWithAuth } from "./BaseClient.js";
|
|
30
31
|
export declare namespace PayabliClient {
|
|
31
|
-
|
|
32
|
-
}
|
|
32
|
+
type Options = BaseClientOptions;
|
|
33
33
|
interface RequestOptions extends BaseRequestOptions {
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
36
|
export declare class PayabliClient {
|
|
37
|
-
protected readonly _options: PayabliClient.Options
|
|
38
|
-
protected _bill:
|
|
39
|
-
protected _boarding:
|
|
40
|
-
protected _chargeBacks:
|
|
41
|
-
protected _checkCapture:
|
|
42
|
-
protected _cloud:
|
|
43
|
-
protected _customer:
|
|
44
|
-
protected _export:
|
|
45
|
-
protected _hostedPaymentPages:
|
|
46
|
-
protected _import:
|
|
47
|
-
protected _invoice:
|
|
48
|
-
protected _lineItem:
|
|
49
|
-
protected _moneyIn:
|
|
50
|
-
protected _moneyOut:
|
|
51
|
-
protected _notification:
|
|
52
|
-
protected _notificationlogs:
|
|
53
|
-
protected _ocr:
|
|
54
|
-
protected _organization:
|
|
55
|
-
protected _paymentLink:
|
|
56
|
-
protected _paymentMethodDomain:
|
|
57
|
-
protected _paypoint:
|
|
58
|
-
protected _query:
|
|
59
|
-
protected _statistic:
|
|
60
|
-
protected _subscription:
|
|
61
|
-
protected _templates:
|
|
62
|
-
protected _tokenStorage:
|
|
63
|
-
protected _user:
|
|
64
|
-
protected _vendor:
|
|
65
|
-
protected _wallet:
|
|
66
|
-
constructor(
|
|
67
|
-
get bill():
|
|
68
|
-
get boarding():
|
|
69
|
-
get chargeBacks():
|
|
70
|
-
get checkCapture():
|
|
71
|
-
get cloud():
|
|
72
|
-
get customer():
|
|
73
|
-
get export():
|
|
74
|
-
get hostedPaymentPages():
|
|
75
|
-
get import():
|
|
76
|
-
get invoice():
|
|
77
|
-
get lineItem():
|
|
78
|
-
get moneyIn():
|
|
79
|
-
get moneyOut():
|
|
80
|
-
get notification():
|
|
81
|
-
get notificationlogs():
|
|
82
|
-
get ocr():
|
|
83
|
-
get organization():
|
|
84
|
-
get paymentLink():
|
|
85
|
-
get paymentMethodDomain():
|
|
86
|
-
get paypoint():
|
|
87
|
-
get query():
|
|
88
|
-
get statistic():
|
|
89
|
-
get subscription():
|
|
90
|
-
get templates():
|
|
91
|
-
get tokenStorage():
|
|
92
|
-
get user():
|
|
93
|
-
get vendor():
|
|
94
|
-
get wallet():
|
|
37
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<PayabliClient.Options>;
|
|
38
|
+
protected _bill: BillClient | undefined;
|
|
39
|
+
protected _boarding: BoardingClient | undefined;
|
|
40
|
+
protected _chargeBacks: ChargeBacksClient | undefined;
|
|
41
|
+
protected _checkCapture: CheckCaptureClient | undefined;
|
|
42
|
+
protected _cloud: CloudClient | undefined;
|
|
43
|
+
protected _customer: CustomerClient | undefined;
|
|
44
|
+
protected _export: ExportClient | undefined;
|
|
45
|
+
protected _hostedPaymentPages: HostedPaymentPagesClient | undefined;
|
|
46
|
+
protected _import: ImportClient | undefined;
|
|
47
|
+
protected _invoice: InvoiceClient | undefined;
|
|
48
|
+
protected _lineItem: LineItemClient | undefined;
|
|
49
|
+
protected _moneyIn: MoneyInClient | undefined;
|
|
50
|
+
protected _moneyOut: MoneyOutClient | undefined;
|
|
51
|
+
protected _notification: NotificationClient | undefined;
|
|
52
|
+
protected _notificationlogs: NotificationlogsClient | undefined;
|
|
53
|
+
protected _ocr: OcrClient | undefined;
|
|
54
|
+
protected _organization: OrganizationClient | undefined;
|
|
55
|
+
protected _paymentLink: PaymentLinkClient | undefined;
|
|
56
|
+
protected _paymentMethodDomain: PaymentMethodDomainClient | undefined;
|
|
57
|
+
protected _paypoint: PaypointClient | undefined;
|
|
58
|
+
protected _query: QueryClient | undefined;
|
|
59
|
+
protected _statistic: StatisticClient | undefined;
|
|
60
|
+
protected _subscription: SubscriptionClient | undefined;
|
|
61
|
+
protected _templates: TemplatesClient | undefined;
|
|
62
|
+
protected _tokenStorage: TokenStorageClient | undefined;
|
|
63
|
+
protected _user: UserClient | undefined;
|
|
64
|
+
protected _vendor: VendorClient | undefined;
|
|
65
|
+
protected _wallet: WalletClient | undefined;
|
|
66
|
+
constructor(options?: PayabliClient.Options);
|
|
67
|
+
get bill(): BillClient;
|
|
68
|
+
get boarding(): BoardingClient;
|
|
69
|
+
get chargeBacks(): ChargeBacksClient;
|
|
70
|
+
get checkCapture(): CheckCaptureClient;
|
|
71
|
+
get cloud(): CloudClient;
|
|
72
|
+
get customer(): CustomerClient;
|
|
73
|
+
get export(): ExportClient;
|
|
74
|
+
get hostedPaymentPages(): HostedPaymentPagesClient;
|
|
75
|
+
get import(): ImportClient;
|
|
76
|
+
get invoice(): InvoiceClient;
|
|
77
|
+
get lineItem(): LineItemClient;
|
|
78
|
+
get moneyIn(): MoneyInClient;
|
|
79
|
+
get moneyOut(): MoneyOutClient;
|
|
80
|
+
get notification(): NotificationClient;
|
|
81
|
+
get notificationlogs(): NotificationlogsClient;
|
|
82
|
+
get ocr(): OcrClient;
|
|
83
|
+
get organization(): OrganizationClient;
|
|
84
|
+
get paymentLink(): PaymentLinkClient;
|
|
85
|
+
get paymentMethodDomain(): PaymentMethodDomainClient;
|
|
86
|
+
get paypoint(): PaypointClient;
|
|
87
|
+
get query(): QueryClient;
|
|
88
|
+
get statistic(): StatisticClient;
|
|
89
|
+
get subscription(): SubscriptionClient;
|
|
90
|
+
get templates(): TemplatesClient;
|
|
91
|
+
get tokenStorage(): TokenStorageClient;
|
|
92
|
+
get user(): UserClient;
|
|
93
|
+
get vendor(): VendorClient;
|
|
94
|
+
get wallet(): WalletClient;
|
|
95
95
|
}
|
package/dist/cjs/Client.js
CHANGED
|
@@ -1,38 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
-
if (k2 === undefined) k2 = k;
|
|
5
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
-
}
|
|
9
|
-
Object.defineProperty(o, k2, desc);
|
|
10
|
-
}) : (function(o, m, k, k2) {
|
|
11
|
-
if (k2 === undefined) k2 = k;
|
|
12
|
-
o[k2] = m[k];
|
|
13
|
-
}));
|
|
14
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
-
}) : function(o, v) {
|
|
17
|
-
o["default"] = v;
|
|
18
|
-
});
|
|
19
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
-
var ownKeys = function(o) {
|
|
21
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
-
var ar = [];
|
|
23
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
-
return ar;
|
|
25
|
-
};
|
|
26
|
-
return ownKeys(o);
|
|
27
|
-
};
|
|
28
|
-
return function (mod) {
|
|
29
|
-
if (mod && mod.__esModule) return mod;
|
|
30
|
-
var result = {};
|
|
31
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
-
__setModuleDefault(result, mod);
|
|
33
|
-
return result;
|
|
34
|
-
};
|
|
35
|
-
})();
|
|
36
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
37
4
|
exports.PayabliClient = void 0;
|
|
38
5
|
const Client_js_1 = require("./api/resources/bill/client/Client.js");
|
|
@@ -63,130 +30,122 @@ const Client_js_25 = require("./api/resources/tokenStorage/client/Client.js");
|
|
|
63
30
|
const Client_js_26 = require("./api/resources/user/client/Client.js");
|
|
64
31
|
const Client_js_27 = require("./api/resources/vendor/client/Client.js");
|
|
65
32
|
const Client_js_28 = require("./api/resources/wallet/client/Client.js");
|
|
66
|
-
const
|
|
67
|
-
const core = __importStar(require("./core/index.js"));
|
|
33
|
+
const BaseClient_js_1 = require("./BaseClient.js");
|
|
68
34
|
class PayabliClient {
|
|
69
|
-
constructor(
|
|
70
|
-
this._options =
|
|
71
|
-
"X-Fern-Language": "JavaScript",
|
|
72
|
-
"X-Fern-SDK-Name": "@payabli/sdk-node",
|
|
73
|
-
"X-Fern-SDK-Version": "0.0.116",
|
|
74
|
-
"User-Agent": "@payabli/sdk-node/0.0.116",
|
|
75
|
-
"X-Fern-Runtime": core.RUNTIME.type,
|
|
76
|
-
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
77
|
-
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
35
|
+
constructor(options = {}) {
|
|
36
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
78
37
|
}
|
|
79
38
|
get bill() {
|
|
80
39
|
var _a;
|
|
81
|
-
return ((_a = this._bill) !== null && _a !== void 0 ? _a : (this._bill = new Client_js_1.
|
|
40
|
+
return ((_a = this._bill) !== null && _a !== void 0 ? _a : (this._bill = new Client_js_1.BillClient(this._options)));
|
|
82
41
|
}
|
|
83
42
|
get boarding() {
|
|
84
43
|
var _a;
|
|
85
|
-
return ((_a = this._boarding) !== null && _a !== void 0 ? _a : (this._boarding = new Client_js_2.
|
|
44
|
+
return ((_a = this._boarding) !== null && _a !== void 0 ? _a : (this._boarding = new Client_js_2.BoardingClient(this._options)));
|
|
86
45
|
}
|
|
87
46
|
get chargeBacks() {
|
|
88
47
|
var _a;
|
|
89
|
-
return ((_a = this._chargeBacks) !== null && _a !== void 0 ? _a : (this._chargeBacks = new Client_js_3.
|
|
48
|
+
return ((_a = this._chargeBacks) !== null && _a !== void 0 ? _a : (this._chargeBacks = new Client_js_3.ChargeBacksClient(this._options)));
|
|
90
49
|
}
|
|
91
50
|
get checkCapture() {
|
|
92
51
|
var _a;
|
|
93
|
-
return ((_a = this._checkCapture) !== null && _a !== void 0 ? _a : (this._checkCapture = new Client_js_4.
|
|
52
|
+
return ((_a = this._checkCapture) !== null && _a !== void 0 ? _a : (this._checkCapture = new Client_js_4.CheckCaptureClient(this._options)));
|
|
94
53
|
}
|
|
95
54
|
get cloud() {
|
|
96
55
|
var _a;
|
|
97
|
-
return ((_a = this._cloud) !== null && _a !== void 0 ? _a : (this._cloud = new Client_js_5.
|
|
56
|
+
return ((_a = this._cloud) !== null && _a !== void 0 ? _a : (this._cloud = new Client_js_5.CloudClient(this._options)));
|
|
98
57
|
}
|
|
99
58
|
get customer() {
|
|
100
59
|
var _a;
|
|
101
|
-
return ((_a = this._customer) !== null && _a !== void 0 ? _a : (this._customer = new Client_js_6.
|
|
60
|
+
return ((_a = this._customer) !== null && _a !== void 0 ? _a : (this._customer = new Client_js_6.CustomerClient(this._options)));
|
|
102
61
|
}
|
|
103
62
|
get export() {
|
|
104
63
|
var _a;
|
|
105
|
-
return ((_a = this._export) !== null && _a !== void 0 ? _a : (this._export = new Client_js_7.
|
|
64
|
+
return ((_a = this._export) !== null && _a !== void 0 ? _a : (this._export = new Client_js_7.ExportClient(this._options)));
|
|
106
65
|
}
|
|
107
66
|
get hostedPaymentPages() {
|
|
108
67
|
var _a;
|
|
109
|
-
return ((_a = this._hostedPaymentPages) !== null && _a !== void 0 ? _a : (this._hostedPaymentPages = new Client_js_8.
|
|
68
|
+
return ((_a = this._hostedPaymentPages) !== null && _a !== void 0 ? _a : (this._hostedPaymentPages = new Client_js_8.HostedPaymentPagesClient(this._options)));
|
|
110
69
|
}
|
|
111
70
|
get import() {
|
|
112
71
|
var _a;
|
|
113
|
-
return ((_a = this._import) !== null && _a !== void 0 ? _a : (this._import = new Client_js_9.
|
|
72
|
+
return ((_a = this._import) !== null && _a !== void 0 ? _a : (this._import = new Client_js_9.ImportClient(this._options)));
|
|
114
73
|
}
|
|
115
74
|
get invoice() {
|
|
116
75
|
var _a;
|
|
117
|
-
return ((_a = this._invoice) !== null && _a !== void 0 ? _a : (this._invoice = new Client_js_10.
|
|
76
|
+
return ((_a = this._invoice) !== null && _a !== void 0 ? _a : (this._invoice = new Client_js_10.InvoiceClient(this._options)));
|
|
118
77
|
}
|
|
119
78
|
get lineItem() {
|
|
120
79
|
var _a;
|
|
121
|
-
return ((_a = this._lineItem) !== null && _a !== void 0 ? _a : (this._lineItem = new Client_js_11.
|
|
80
|
+
return ((_a = this._lineItem) !== null && _a !== void 0 ? _a : (this._lineItem = new Client_js_11.LineItemClient(this._options)));
|
|
122
81
|
}
|
|
123
82
|
get moneyIn() {
|
|
124
83
|
var _a;
|
|
125
|
-
return ((_a = this._moneyIn) !== null && _a !== void 0 ? _a : (this._moneyIn = new Client_js_12.
|
|
84
|
+
return ((_a = this._moneyIn) !== null && _a !== void 0 ? _a : (this._moneyIn = new Client_js_12.MoneyInClient(this._options)));
|
|
126
85
|
}
|
|
127
86
|
get moneyOut() {
|
|
128
87
|
var _a;
|
|
129
|
-
return ((_a = this._moneyOut) !== null && _a !== void 0 ? _a : (this._moneyOut = new Client_js_13.
|
|
88
|
+
return ((_a = this._moneyOut) !== null && _a !== void 0 ? _a : (this._moneyOut = new Client_js_13.MoneyOutClient(this._options)));
|
|
130
89
|
}
|
|
131
90
|
get notification() {
|
|
132
91
|
var _a;
|
|
133
|
-
return ((_a = this._notification) !== null && _a !== void 0 ? _a : (this._notification = new Client_js_14.
|
|
92
|
+
return ((_a = this._notification) !== null && _a !== void 0 ? _a : (this._notification = new Client_js_14.NotificationClient(this._options)));
|
|
134
93
|
}
|
|
135
94
|
get notificationlogs() {
|
|
136
95
|
var _a;
|
|
137
|
-
return ((_a = this._notificationlogs) !== null && _a !== void 0 ? _a : (this._notificationlogs = new Client_js_15.
|
|
96
|
+
return ((_a = this._notificationlogs) !== null && _a !== void 0 ? _a : (this._notificationlogs = new Client_js_15.NotificationlogsClient(this._options)));
|
|
138
97
|
}
|
|
139
98
|
get ocr() {
|
|
140
99
|
var _a;
|
|
141
|
-
return ((_a = this._ocr) !== null && _a !== void 0 ? _a : (this._ocr = new Client_js_16.
|
|
100
|
+
return ((_a = this._ocr) !== null && _a !== void 0 ? _a : (this._ocr = new Client_js_16.OcrClient(this._options)));
|
|
142
101
|
}
|
|
143
102
|
get organization() {
|
|
144
103
|
var _a;
|
|
145
|
-
return ((_a = this._organization) !== null && _a !== void 0 ? _a : (this._organization = new Client_js_17.
|
|
104
|
+
return ((_a = this._organization) !== null && _a !== void 0 ? _a : (this._organization = new Client_js_17.OrganizationClient(this._options)));
|
|
146
105
|
}
|
|
147
106
|
get paymentLink() {
|
|
148
107
|
var _a;
|
|
149
|
-
return ((_a = this._paymentLink) !== null && _a !== void 0 ? _a : (this._paymentLink = new Client_js_18.
|
|
108
|
+
return ((_a = this._paymentLink) !== null && _a !== void 0 ? _a : (this._paymentLink = new Client_js_18.PaymentLinkClient(this._options)));
|
|
150
109
|
}
|
|
151
110
|
get paymentMethodDomain() {
|
|
152
111
|
var _a;
|
|
153
|
-
return ((_a = this._paymentMethodDomain) !== null && _a !== void 0 ? _a : (this._paymentMethodDomain = new Client_js_19.
|
|
112
|
+
return ((_a = this._paymentMethodDomain) !== null && _a !== void 0 ? _a : (this._paymentMethodDomain = new Client_js_19.PaymentMethodDomainClient(this._options)));
|
|
154
113
|
}
|
|
155
114
|
get paypoint() {
|
|
156
115
|
var _a;
|
|
157
|
-
return ((_a = this._paypoint) !== null && _a !== void 0 ? _a : (this._paypoint = new Client_js_20.
|
|
116
|
+
return ((_a = this._paypoint) !== null && _a !== void 0 ? _a : (this._paypoint = new Client_js_20.PaypointClient(this._options)));
|
|
158
117
|
}
|
|
159
118
|
get query() {
|
|
160
119
|
var _a;
|
|
161
|
-
return ((_a = this._query) !== null && _a !== void 0 ? _a : (this._query = new Client_js_21.
|
|
120
|
+
return ((_a = this._query) !== null && _a !== void 0 ? _a : (this._query = new Client_js_21.QueryClient(this._options)));
|
|
162
121
|
}
|
|
163
122
|
get statistic() {
|
|
164
123
|
var _a;
|
|
165
|
-
return ((_a = this._statistic) !== null && _a !== void 0 ? _a : (this._statistic = new Client_js_22.
|
|
124
|
+
return ((_a = this._statistic) !== null && _a !== void 0 ? _a : (this._statistic = new Client_js_22.StatisticClient(this._options)));
|
|
166
125
|
}
|
|
167
126
|
get subscription() {
|
|
168
127
|
var _a;
|
|
169
|
-
return ((_a = this._subscription) !== null && _a !== void 0 ? _a : (this._subscription = new Client_js_23.
|
|
128
|
+
return ((_a = this._subscription) !== null && _a !== void 0 ? _a : (this._subscription = new Client_js_23.SubscriptionClient(this._options)));
|
|
170
129
|
}
|
|
171
130
|
get templates() {
|
|
172
131
|
var _a;
|
|
173
|
-
return ((_a = this._templates) !== null && _a !== void 0 ? _a : (this._templates = new Client_js_24.
|
|
132
|
+
return ((_a = this._templates) !== null && _a !== void 0 ? _a : (this._templates = new Client_js_24.TemplatesClient(this._options)));
|
|
174
133
|
}
|
|
175
134
|
get tokenStorage() {
|
|
176
135
|
var _a;
|
|
177
|
-
return ((_a = this._tokenStorage) !== null && _a !== void 0 ? _a : (this._tokenStorage = new Client_js_25.
|
|
136
|
+
return ((_a = this._tokenStorage) !== null && _a !== void 0 ? _a : (this._tokenStorage = new Client_js_25.TokenStorageClient(this._options)));
|
|
178
137
|
}
|
|
179
138
|
get user() {
|
|
180
139
|
var _a;
|
|
181
|
-
return ((_a = this._user) !== null && _a !== void 0 ? _a : (this._user = new Client_js_26.
|
|
140
|
+
return ((_a = this._user) !== null && _a !== void 0 ? _a : (this._user = new Client_js_26.UserClient(this._options)));
|
|
182
141
|
}
|
|
183
142
|
get vendor() {
|
|
184
143
|
var _a;
|
|
185
|
-
return ((_a = this._vendor) !== null && _a !== void 0 ? _a : (this._vendor = new Client_js_27.
|
|
144
|
+
return ((_a = this._vendor) !== null && _a !== void 0 ? _a : (this._vendor = new Client_js_27.VendorClient(this._options)));
|
|
186
145
|
}
|
|
187
146
|
get wallet() {
|
|
188
147
|
var _a;
|
|
189
|
-
return ((_a = this._wallet) !== null && _a !== void 0 ? _a : (this._wallet = new Client_js_28.
|
|
148
|
+
return ((_a = this._wallet) !== null && _a !== void 0 ? _a : (this._wallet = new Client_js_28.WalletClient(this._options)));
|
|
190
149
|
}
|
|
191
150
|
}
|
|
192
151
|
exports.PayabliClient = PayabliClient;
|
|
@@ -44,7 +44,11 @@ class BadRequestError extends errors.PayabliError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.BadRequestError = BadRequestError;
|
|
@@ -44,7 +44,11 @@ class ConflictError extends errors.PayabliError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.ConflictError = ConflictError;
|
|
@@ -44,7 +44,11 @@ class ForbiddenError extends errors.PayabliError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.ForbiddenError = ForbiddenError;
|
|
@@ -44,7 +44,11 @@ class InternalServerError extends errors.PayabliError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.InternalServerError = InternalServerError;
|
|
@@ -44,7 +44,11 @@ class ServiceUnavailableError extends errors.PayabliError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.ServiceUnavailableError = ServiceUnavailableError;
|
|
@@ -44,7 +44,11 @@ class UnauthorizedError extends errors.PayabliError {
|
|
|
44
44
|
body: body,
|
|
45
45
|
rawResponse: rawResponse,
|
|
46
46
|
});
|
|
47
|
-
Object.setPrototypeOf(this,
|
|
47
|
+
Object.setPrototypeOf(this, new.target.prototype);
|
|
48
|
+
if (Error.captureStackTrace) {
|
|
49
|
+
Error.captureStackTrace(this, this.constructor);
|
|
50
|
+
}
|
|
51
|
+
this.name = this.constructor.name;
|
|
48
52
|
}
|
|
49
53
|
}
|
|
50
54
|
exports.UnauthorizedError = UnauthorizedError;
|