@payabli/sdk-node 0.0.143 → 0.0.145
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 +10 -2
- package/dist/cjs/BaseClient.d.ts +3 -0
- package/dist/cjs/BaseClient.js +17 -2
- package/dist/cjs/api/resources/bill/client/Client.js +35 -11
- package/dist/cjs/api/resources/boarding/client/Client.d.ts +38 -0
- package/dist/cjs/api/resources/boarding/client/Client.js +152 -11
- package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointRequest.d.ts +15 -0
- package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointRequest.js +3 -0
- package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointResponse.d.ts +20 -0
- package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointResponse.js +3 -0
- package/dist/cjs/api/resources/boarding/types/index.d.ts +2 -0
- package/dist/cjs/api/resources/boarding/types/index.js +2 -0
- package/dist/cjs/api/resources/chargeBacks/client/Client.js +3 -3
- package/dist/cjs/api/resources/checkCapture/client/Client.js +1 -1
- package/dist/cjs/api/resources/cloud/client/Client.js +8 -4
- package/dist/cjs/api/resources/customer/client/Client.js +10 -6
- package/dist/cjs/api/resources/export/client/Client.js +145 -29
- package/dist/cjs/api/resources/ghostCard/client/Client.js +2 -2
- package/dist/cjs/api/resources/hostedPaymentPages/client/Client.js +3 -3
- package/dist/cjs/api/resources/import/client/Client.js +7 -3
- package/dist/cjs/api/resources/invoice/client/Client.js +35 -11
- package/dist/cjs/api/resources/lineItem/client/Client.js +9 -5
- package/dist/cjs/api/resources/management/client/Client.js +1 -1
- package/dist/cjs/api/resources/moneyIn/client/Client.js +43 -19
- package/dist/cjs/api/resources/moneyOut/client/Client.d.ts +5 -1
- package/dist/cjs/api/resources/moneyOut/client/Client.js +25 -13
- package/dist/cjs/api/resources/notification/client/Client.js +5 -5
- package/dist/cjs/api/resources/notificationlogs/client/Client.js +8 -4
- package/dist/cjs/api/resources/ocr/client/Client.js +2 -2
- package/dist/cjs/api/resources/organization/client/Client.js +7 -7
- package/dist/cjs/api/resources/paymentLink/client/Client.js +31 -11
- package/dist/cjs/api/resources/paymentMethodDomain/client/Client.js +11 -7
- package/dist/cjs/api/resources/payoutSubscription/client/Client.js +4 -4
- package/dist/cjs/api/resources/paypoint/client/Client.js +12 -8
- package/dist/cjs/api/resources/query/client/Client.d.ts +58 -0
- package/dist/cjs/api/resources/query/client/Client.js +368 -40
- package/dist/cjs/api/resources/query/client/requests/ListSubscriptionsOrgRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/ListSubscriptionsRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/ListTransactionsOrgRequest.d.ts +9 -0
- package/dist/cjs/api/resources/query/client/requests/ListTransactionsRequest.d.ts +9 -0
- package/dist/cjs/api/resources/query/client/requests/ListVcardsOrgRequest.d.ts +8 -6
- package/dist/cjs/api/resources/query/client/requests/ListVcardsRequest.d.ts +8 -6
- package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.d.ts +72 -0
- package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.js +3 -0
- package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsRequest.d.ts +72 -0
- package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsRequest.js +3 -0
- package/dist/cjs/api/resources/query/client/requests/ListVendorsOrgRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/ListVendorsRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/index.d.ts +2 -0
- package/dist/cjs/api/resources/queryTypes/types/QueryTransferDetailResponse.d.ts +2 -0
- package/dist/cjs/api/resources/queryTypes/types/QueryTransferSummary.d.ts +2 -0
- package/dist/cjs/api/resources/queryTypes/types/VCardTransactionQueryResponse.d.ts +49 -0
- package/dist/cjs/api/resources/queryTypes/types/VCardTransactionQueryResponse.js +3 -0
- package/dist/cjs/api/resources/queryTypes/types/VCardTransactionRecord.d.ts +86 -0
- package/dist/cjs/api/resources/queryTypes/types/VCardTransactionRecord.js +3 -0
- package/dist/cjs/api/resources/queryTypes/types/index.d.ts +2 -0
- package/dist/cjs/api/resources/queryTypes/types/index.js +2 -0
- package/dist/cjs/api/resources/statistic/client/Client.js +20 -4
- package/dist/cjs/api/resources/subscription/client/Client.js +8 -4
- package/dist/cjs/api/resources/templates/client/Client.js +8 -4
- package/dist/cjs/api/resources/tokenStorage/client/Client.js +16 -4
- package/dist/cjs/api/resources/user/client/Client.js +16 -12
- package/dist/cjs/api/resources/v2MoneyInTypes/types/V2TransactionDetails.d.ts +1 -1
- package/dist/cjs/api/resources/vendor/client/Client.js +5 -5
- package/dist/cjs/api/resources/wallet/client/Client.js +4 -4
- package/dist/cjs/api/types/AutoCapture.d.ts +5 -1
- package/dist/cjs/api/types/CustomerQueryRecords.d.ts +10 -8
- package/dist/cjs/api/types/CustomerSummaryRecord.d.ts +4 -4
- package/dist/cjs/api/types/QueryResponseTransactions.d.ts +74 -0
- package/dist/cjs/api/types/SplitCount.d.ts +4 -0
- package/dist/cjs/api/types/SplitCount.js +3 -0
- package/dist/cjs/api/types/SubscriptionQueryRecords.d.ts +11 -1
- package/dist/cjs/api/types/TransactionQueryRecords.d.ts +2 -1
- package/dist/cjs/api/types/TransactionQueryRecordsCustomer.d.ts +1 -0
- package/dist/cjs/api/types/VCardSummary.d.ts +4 -2
- package/dist/cjs/api/types/VendorResponseStoredMethod.d.ts +2 -1
- package/dist/cjs/api/types/index.d.ts +1 -0
- package/dist/cjs/api/types/index.js +1 -0
- package/dist/cjs/core/auth/AuthProvider.d.ts +1 -0
- package/dist/cjs/core/auth/AuthProvider.js +7 -0
- package/dist/cjs/core/auth/index.d.ts +1 -1
- package/dist/cjs/core/auth/index.js +3 -1
- package/dist/cjs/core/fetcher/Fetcher.d.ts +6 -0
- package/dist/cjs/core/fetcher/Fetcher.js +9 -8
- package/dist/cjs/core/fetcher/requestWithRetries.js +4 -1
- package/dist/cjs/core/url/QueryStringBuilder.d.ts +47 -0
- package/dist/cjs/core/url/QueryStringBuilder.js +83 -0
- package/dist/cjs/core/url/index.d.ts +1 -0
- package/dist/cjs/core/url/index.js +3 -1
- package/dist/cjs/core/url/qs.d.ts +2 -1
- package/dist/cjs/core/url/qs.js +24 -12
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +3 -0
- package/dist/esm/BaseClient.mjs +17 -2
- package/dist/esm/api/resources/bill/client/Client.mjs +35 -11
- package/dist/esm/api/resources/boarding/client/Client.d.mts +38 -0
- package/dist/esm/api/resources/boarding/client/Client.mjs +152 -11
- package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointRequest.d.mts +15 -0
- package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointRequest.mjs +2 -0
- package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointResponse.d.mts +20 -0
- package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointResponse.mjs +2 -0
- package/dist/esm/api/resources/boarding/types/index.d.mts +2 -0
- package/dist/esm/api/resources/boarding/types/index.mjs +2 -0
- package/dist/esm/api/resources/chargeBacks/client/Client.mjs +3 -3
- package/dist/esm/api/resources/checkCapture/client/Client.mjs +1 -1
- package/dist/esm/api/resources/cloud/client/Client.mjs +8 -4
- package/dist/esm/api/resources/customer/client/Client.mjs +10 -6
- package/dist/esm/api/resources/export/client/Client.mjs +145 -29
- package/dist/esm/api/resources/ghostCard/client/Client.mjs +2 -2
- package/dist/esm/api/resources/hostedPaymentPages/client/Client.mjs +3 -3
- package/dist/esm/api/resources/import/client/Client.mjs +7 -3
- package/dist/esm/api/resources/invoice/client/Client.mjs +35 -11
- package/dist/esm/api/resources/lineItem/client/Client.mjs +9 -5
- package/dist/esm/api/resources/management/client/Client.mjs +1 -1
- package/dist/esm/api/resources/moneyIn/client/Client.mjs +43 -19
- package/dist/esm/api/resources/moneyOut/client/Client.d.mts +5 -1
- package/dist/esm/api/resources/moneyOut/client/Client.mjs +25 -13
- package/dist/esm/api/resources/notification/client/Client.mjs +5 -5
- package/dist/esm/api/resources/notificationlogs/client/Client.mjs +8 -4
- package/dist/esm/api/resources/ocr/client/Client.mjs +2 -2
- package/dist/esm/api/resources/organization/client/Client.mjs +7 -7
- package/dist/esm/api/resources/paymentLink/client/Client.mjs +31 -11
- package/dist/esm/api/resources/paymentMethodDomain/client/Client.mjs +11 -7
- package/dist/esm/api/resources/payoutSubscription/client/Client.mjs +4 -4
- package/dist/esm/api/resources/paypoint/client/Client.mjs +12 -8
- package/dist/esm/api/resources/query/client/Client.d.mts +58 -0
- package/dist/esm/api/resources/query/client/Client.mjs +368 -40
- package/dist/esm/api/resources/query/client/requests/ListSubscriptionsOrgRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/ListSubscriptionsRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/ListTransactionsOrgRequest.d.mts +9 -0
- package/dist/esm/api/resources/query/client/requests/ListTransactionsRequest.d.mts +9 -0
- package/dist/esm/api/resources/query/client/requests/ListVcardsOrgRequest.d.mts +8 -6
- package/dist/esm/api/resources/query/client/requests/ListVcardsRequest.d.mts +8 -6
- package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.d.mts +72 -0
- package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.mjs +2 -0
- package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsRequest.d.mts +72 -0
- package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsRequest.mjs +2 -0
- package/dist/esm/api/resources/query/client/requests/ListVendorsOrgRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/ListVendorsRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/index.d.mts +2 -0
- package/dist/esm/api/resources/queryTypes/types/QueryTransferDetailResponse.d.mts +2 -0
- package/dist/esm/api/resources/queryTypes/types/QueryTransferSummary.d.mts +2 -0
- package/dist/esm/api/resources/queryTypes/types/VCardTransactionQueryResponse.d.mts +49 -0
- package/dist/esm/api/resources/queryTypes/types/VCardTransactionQueryResponse.mjs +2 -0
- package/dist/esm/api/resources/queryTypes/types/VCardTransactionRecord.d.mts +86 -0
- package/dist/esm/api/resources/queryTypes/types/VCardTransactionRecord.mjs +2 -0
- package/dist/esm/api/resources/queryTypes/types/index.d.mts +2 -0
- package/dist/esm/api/resources/queryTypes/types/index.mjs +2 -0
- package/dist/esm/api/resources/statistic/client/Client.mjs +20 -4
- package/dist/esm/api/resources/subscription/client/Client.mjs +8 -4
- package/dist/esm/api/resources/templates/client/Client.mjs +8 -4
- package/dist/esm/api/resources/tokenStorage/client/Client.mjs +16 -4
- package/dist/esm/api/resources/user/client/Client.mjs +16 -12
- package/dist/esm/api/resources/v2MoneyInTypes/types/V2TransactionDetails.d.mts +1 -1
- package/dist/esm/api/resources/vendor/client/Client.mjs +5 -5
- package/dist/esm/api/resources/wallet/client/Client.mjs +4 -4
- package/dist/esm/api/types/AutoCapture.d.mts +5 -1
- package/dist/esm/api/types/CustomerQueryRecords.d.mts +10 -8
- package/dist/esm/api/types/CustomerSummaryRecord.d.mts +4 -4
- package/dist/esm/api/types/QueryResponseTransactions.d.mts +74 -0
- package/dist/esm/api/types/SplitCount.d.mts +4 -0
- package/dist/esm/api/types/SplitCount.mjs +2 -0
- package/dist/esm/api/types/SubscriptionQueryRecords.d.mts +11 -1
- package/dist/esm/api/types/TransactionQueryRecords.d.mts +2 -1
- package/dist/esm/api/types/TransactionQueryRecordsCustomer.d.mts +1 -0
- package/dist/esm/api/types/VCardSummary.d.mts +4 -2
- package/dist/esm/api/types/VendorResponseStoredMethod.d.mts +2 -1
- package/dist/esm/api/types/index.d.mts +1 -0
- package/dist/esm/api/types/index.mjs +1 -0
- package/dist/esm/core/auth/AuthProvider.d.mts +1 -0
- package/dist/esm/core/auth/AuthProvider.mjs +6 -1
- package/dist/esm/core/auth/index.d.mts +1 -1
- package/dist/esm/core/auth/index.mjs +1 -0
- package/dist/esm/core/fetcher/Fetcher.d.mts +6 -0
- package/dist/esm/core/fetcher/Fetcher.mjs +9 -8
- package/dist/esm/core/fetcher/requestWithRetries.mjs +4 -1
- package/dist/esm/core/url/QueryStringBuilder.d.mts +47 -0
- package/dist/esm/core/url/QueryStringBuilder.mjs +80 -0
- package/dist/esm/core/url/index.d.mts +1 -0
- package/dist/esm/core/url/index.mjs +1 -0
- package/dist/esm/core/url/qs.d.mts +2 -1
- package/dist/esm/core/url/qs.mjs +24 -12
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +287 -1
package/README.md
CHANGED
|
@@ -222,11 +222,19 @@ The SDK is instrumented with automatic retries with exponential backoff. A reque
|
|
|
222
222
|
as the request is deemed retryable and the number of retry attempts has not grown larger than the configured
|
|
223
223
|
retry limit (default: 2).
|
|
224
224
|
|
|
225
|
-
|
|
225
|
+
Which status codes are retried depends on the `retryStatusCodes` generator configuration:
|
|
226
226
|
|
|
227
|
+
**`legacy`** (current default): retries on
|
|
227
228
|
- [408](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/408) (Timeout)
|
|
228
229
|
- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests)
|
|
229
|
-
- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status
|
|
230
|
+
- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status#server_error_responses) (All server errors, including 500)
|
|
231
|
+
|
|
232
|
+
**`recommended`**: retries on
|
|
233
|
+
- [408](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/408) (Timeout)
|
|
234
|
+
- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests)
|
|
235
|
+
- [502](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/502) (Bad Gateway)
|
|
236
|
+
- [503](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503) (Service Unavailable)
|
|
237
|
+
- [504](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/504) (Gateway Timeout)
|
|
230
238
|
|
|
231
239
|
Use the `maxRetries` request option to configure this behavior.
|
|
232
240
|
|
package/dist/cjs/BaseClient.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { HeaderAuthProvider } from "./auth/HeaderAuthProvider.js";
|
|
2
2
|
import * as core from "./core/index.js";
|
|
3
3
|
import type * as environments from "./environments.js";
|
|
4
|
+
export type AuthOption = false | core.AuthProvider["getAuthRequest"] | core.AuthProvider | HeaderAuthProvider.AuthOptions;
|
|
4
5
|
export type BaseClientOptions = {
|
|
5
6
|
environment?: core.Supplier<environments.PayabliEnvironment | string>;
|
|
6
7
|
/** Specify a custom URL to connect the client to. */
|
|
@@ -15,6 +16,8 @@ export type BaseClientOptions = {
|
|
|
15
16
|
fetch?: typeof fetch;
|
|
16
17
|
/** Configure logging for the client. */
|
|
17
18
|
logging?: core.logging.LogConfig | core.logging.Logger;
|
|
19
|
+
/** Override auth. Pass false to disable, a function returning auth headers, an AuthProvider, or auth options. */
|
|
20
|
+
auth?: AuthOption;
|
|
18
21
|
} & HeaderAuthProvider.AuthOptions;
|
|
19
22
|
export interface BaseRequestOptions {
|
|
20
23
|
/** The maximum time to wait for a response in seconds. */
|
package/dist/cjs/BaseClient.js
CHANGED
|
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
|
|
|
43
43
|
const headers = (0, headers_js_1.mergeHeaders)({
|
|
44
44
|
"X-Fern-Language": "JavaScript",
|
|
45
45
|
"X-Fern-SDK-Name": "@payabli/sdk-node",
|
|
46
|
-
"X-Fern-SDK-Version": "0.0.
|
|
47
|
-
"User-Agent": "@payabli/sdk-node/0.0.
|
|
46
|
+
"X-Fern-SDK-Version": "0.0.145",
|
|
47
|
+
"User-Agent": "@payabli/sdk-node/0.0.145",
|
|
48
48
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
49
49
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
50
50
|
}, options === null || options === void 0 ? void 0 : options.headers);
|
|
@@ -53,6 +53,21 @@ function normalizeClientOptions(options) {
|
|
|
53
53
|
function normalizeClientOptionsWithAuth(options) {
|
|
54
54
|
var _a;
|
|
55
55
|
const normalized = normalizeClientOptions(options);
|
|
56
|
+
if (options.auth === false) {
|
|
57
|
+
normalized.authProvider = new core.NoOpAuthProvider();
|
|
58
|
+
return normalized;
|
|
59
|
+
}
|
|
60
|
+
if (options.auth != null) {
|
|
61
|
+
if (typeof options.auth === "function") {
|
|
62
|
+
normalized.authProvider = { getAuthRequest: options.auth };
|
|
63
|
+
return normalized;
|
|
64
|
+
}
|
|
65
|
+
if (core.isAuthProvider(options.auth)) {
|
|
66
|
+
normalized.authProvider = options.auth;
|
|
67
|
+
return normalized;
|
|
68
|
+
}
|
|
69
|
+
Object.assign(normalized, options.auth);
|
|
70
|
+
}
|
|
56
71
|
const normalizedWithNoOpAuthProvider = withNoOpAuthProvider(normalized);
|
|
57
72
|
(_a = normalized.authProvider) !== null && _a !== void 0 ? _a : (normalized.authProvider = new HeaderAuthProvider_js_1.HeaderAuthProvider(normalizedWithNoOpAuthProvider));
|
|
58
73
|
return normalized;
|
|
@@ -121,7 +121,7 @@ class BillClient {
|
|
|
121
121
|
method: "POST",
|
|
122
122
|
headers: _headers,
|
|
123
123
|
contentType: "application/json",
|
|
124
|
-
|
|
124
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
125
125
|
requestType: "json",
|
|
126
126
|
body: _body,
|
|
127
127
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -201,7 +201,11 @@ class BillClient {
|
|
|
201
201
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Bill/attachedFileFromBill/${core.url.encodePathParam(idBill)}/${core.url.encodePathParam(filename)}`),
|
|
202
202
|
method: "DELETE",
|
|
203
203
|
headers: _headers,
|
|
204
|
-
|
|
204
|
+
queryString: core.url
|
|
205
|
+
.queryBuilder()
|
|
206
|
+
.addMany(_queryParams)
|
|
207
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
208
|
+
.build(),
|
|
205
209
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
206
210
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
207
211
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -258,7 +262,7 @@ class BillClient {
|
|
|
258
262
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Bill/${core.url.encodePathParam(idBill)}`),
|
|
259
263
|
method: "DELETE",
|
|
260
264
|
headers: _headers,
|
|
261
|
-
|
|
265
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
262
266
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
263
267
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
264
268
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -320,7 +324,7 @@ class BillClient {
|
|
|
320
324
|
method: "PUT",
|
|
321
325
|
headers: _headers,
|
|
322
326
|
contentType: "application/json",
|
|
323
|
-
|
|
327
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
324
328
|
requestType: "json",
|
|
325
329
|
body: request,
|
|
326
330
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -397,7 +401,11 @@ class BillClient {
|
|
|
397
401
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Bill/attachedFileFromBill/${core.url.encodePathParam(idBill)}/${core.url.encodePathParam(filename)}`),
|
|
398
402
|
method: "GET",
|
|
399
403
|
headers: _headers,
|
|
400
|
-
|
|
404
|
+
queryString: core.url
|
|
405
|
+
.queryBuilder()
|
|
406
|
+
.addMany(_queryParams)
|
|
407
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
408
|
+
.build(),
|
|
401
409
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
402
410
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
403
411
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -454,7 +462,7 @@ class BillClient {
|
|
|
454
462
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Bill/${core.url.encodePathParam(idBill)}`),
|
|
455
463
|
method: "GET",
|
|
456
464
|
headers: _headers,
|
|
457
|
-
|
|
465
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
458
466
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
459
467
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
460
468
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -524,7 +532,11 @@ class BillClient {
|
|
|
524
532
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Query/bills/${core.url.encodePathParam(entry)}`),
|
|
525
533
|
method: "GET",
|
|
526
534
|
headers: _headers,
|
|
527
|
-
|
|
535
|
+
queryString: core.url
|
|
536
|
+
.queryBuilder()
|
|
537
|
+
.addMany(_queryParams)
|
|
538
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
539
|
+
.build(),
|
|
528
540
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
529
541
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
530
542
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -594,7 +606,11 @@ class BillClient {
|
|
|
594
606
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Query/bills/org/${core.url.encodePathParam(orgId)}`),
|
|
595
607
|
method: "GET",
|
|
596
608
|
headers: _headers,
|
|
597
|
-
|
|
609
|
+
queryString: core.url
|
|
610
|
+
.queryBuilder()
|
|
611
|
+
.addMany(_queryParams)
|
|
612
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
613
|
+
.build(),
|
|
598
614
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
599
615
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
600
616
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -653,7 +669,7 @@ class BillClient {
|
|
|
653
669
|
method: "PUT",
|
|
654
670
|
headers: _headers,
|
|
655
671
|
contentType: "application/json",
|
|
656
|
-
|
|
672
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
657
673
|
requestType: "json",
|
|
658
674
|
body: request,
|
|
659
675
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -721,7 +737,11 @@ class BillClient {
|
|
|
721
737
|
method: "POST",
|
|
722
738
|
headers: _headers,
|
|
723
739
|
contentType: "application/json",
|
|
724
|
-
|
|
740
|
+
queryString: core.url
|
|
741
|
+
.queryBuilder()
|
|
742
|
+
.addMany(_queryParams)
|
|
743
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
744
|
+
.build(),
|
|
725
745
|
requestType: "json",
|
|
726
746
|
body: _body,
|
|
727
747
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -786,7 +806,11 @@ class BillClient {
|
|
|
786
806
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Bill/approval/${core.url.encodePathParam(idBill)}/${core.url.encodePathParam(approved)}`),
|
|
787
807
|
method: "GET",
|
|
788
808
|
headers: _headers,
|
|
789
|
-
|
|
809
|
+
queryString: core.url
|
|
810
|
+
.queryBuilder()
|
|
811
|
+
.addMany(_queryParams)
|
|
812
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
813
|
+
.build(),
|
|
790
814
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
791
815
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
792
816
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -711,4 +711,42 @@ export declare class BoardingClient {
|
|
|
711
711
|
*/
|
|
712
712
|
updateApplication(appId: number, request: Payabli.ApplicationData, requestOptions?: BoardingClient.RequestOptions): core.HttpResponsePromise<Payabli.PayabliApiResponse00Responsedatanonobject>;
|
|
713
713
|
private __updateApplication;
|
|
714
|
+
/**
|
|
715
|
+
* Creates a new boarding application linked to an existing paypoint as part of the multi-product boarding flow. Use this endpoint to add new services to a paypoint without creating a duplicate record. The system copies eligible business, contact, banking, and address data from the paypoint to the new application based on 1:1 field matching. The merchant only needs to provide fields that are specific to the new service. See the [Multi-product boarding](/guides/pay-ops-developer-boarding-multi-product) guide for the full flow.
|
|
716
|
+
*
|
|
717
|
+
* @param {Payabli.CreateApplicationFromPaypointRequest} request
|
|
718
|
+
* @param {BoardingClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
719
|
+
*
|
|
720
|
+
* @throws {@link Payabli.BadRequestError}
|
|
721
|
+
* @throws {@link Payabli.UnauthorizedError}
|
|
722
|
+
* @throws {@link Payabli.InternalServerError}
|
|
723
|
+
* @throws {@link Payabli.ServiceUnavailableError}
|
|
724
|
+
*
|
|
725
|
+
* @example
|
|
726
|
+
* await client.boarding.addServiceToPaypointFromApp({
|
|
727
|
+
* paypointId: 123,
|
|
728
|
+
* templateId: 456,
|
|
729
|
+
* recipientEmail: "merchant@example.com",
|
|
730
|
+
* returnBoardingAccessInfoInLine: true,
|
|
731
|
+
* onCreate: ["submitApplication"]
|
|
732
|
+
* })
|
|
733
|
+
*/
|
|
734
|
+
addServiceToPaypointFromApp(request: Payabli.CreateApplicationFromPaypointRequest, requestOptions?: BoardingClient.RequestOptions): core.HttpResponsePromise<Payabli.CreateApplicationFromPaypointResponse>;
|
|
735
|
+
private __addServiceToPaypointFromApp;
|
|
736
|
+
/**
|
|
737
|
+
* Returns all boarding applications associated with a specific paypoint, including those created through the multi-product boarding flow. Use this endpoint to track underwriting progress across multiple service additions or to build reporting views. See the [Multi-product boarding](/guides/pay-ops-developer-boarding-multi-product) guide for the full flow.
|
|
738
|
+
*
|
|
739
|
+
* @param {number} paypointId - ID of the paypoint to retrieve applications for.
|
|
740
|
+
* @param {BoardingClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
741
|
+
*
|
|
742
|
+
* @throws {@link Payabli.BadRequestError}
|
|
743
|
+
* @throws {@link Payabli.UnauthorizedError}
|
|
744
|
+
* @throws {@link Payabli.InternalServerError}
|
|
745
|
+
* @throws {@link Payabli.ServiceUnavailableError}
|
|
746
|
+
*
|
|
747
|
+
* @example
|
|
748
|
+
* await client.boarding.getApplicationsByPaypointId(12345)
|
|
749
|
+
*/
|
|
750
|
+
getApplicationsByPaypointId(paypointId: number, requestOptions?: BoardingClient.RequestOptions): core.HttpResponsePromise<Payabli.QueryBoardingAppsListResponse>;
|
|
751
|
+
private __getApplicationsByPaypointId;
|
|
714
752
|
}
|
|
@@ -591,7 +591,7 @@ class BoardingClient {
|
|
|
591
591
|
method: "POST",
|
|
592
592
|
headers: _headers,
|
|
593
593
|
contentType: "application/json",
|
|
594
|
-
|
|
594
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
595
595
|
requestType: "json",
|
|
596
596
|
body: request,
|
|
597
597
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -653,7 +653,7 @@ class BoardingClient {
|
|
|
653
653
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Boarding/app/${core.url.encodePathParam(appId)}`),
|
|
654
654
|
method: "DELETE",
|
|
655
655
|
headers: _headers,
|
|
656
|
-
|
|
656
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
657
657
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
658
658
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
659
659
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -713,7 +713,7 @@ class BoardingClient {
|
|
|
713
713
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Boarding/read/${core.url.encodePathParam(appId)}`),
|
|
714
714
|
method: "GET",
|
|
715
715
|
headers: _headers,
|
|
716
|
-
|
|
716
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
717
717
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
718
718
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
719
719
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -775,7 +775,7 @@ class BoardingClient {
|
|
|
775
775
|
method: "POST",
|
|
776
776
|
headers: _headers,
|
|
777
777
|
contentType: "application/json",
|
|
778
|
-
|
|
778
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
779
779
|
requestType: "json",
|
|
780
780
|
body: request,
|
|
781
781
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -834,7 +834,7 @@ class BoardingClient {
|
|
|
834
834
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Boarding/linkbyId/${core.url.encodePathParam(boardingLinkId)}`),
|
|
835
835
|
method: "GET",
|
|
836
836
|
headers: _headers,
|
|
837
|
-
|
|
837
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
838
838
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
839
839
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
840
840
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -891,7 +891,7 @@ class BoardingClient {
|
|
|
891
891
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Boarding/linkbyTemplate/${core.url.encodePathParam(templateId)}`),
|
|
892
892
|
method: "GET",
|
|
893
893
|
headers: _headers,
|
|
894
|
-
|
|
894
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
895
895
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
896
896
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
897
897
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -954,7 +954,11 @@ class BoardingClient {
|
|
|
954
954
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Boarding/applink/${core.url.encodePathParam(appId)}/${core.url.encodePathParam(mail2)}`),
|
|
955
955
|
method: "PUT",
|
|
956
956
|
headers: _headers,
|
|
957
|
-
|
|
957
|
+
queryString: core.url
|
|
958
|
+
.queryBuilder()
|
|
959
|
+
.addMany(_queryParams)
|
|
960
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
961
|
+
.build(),
|
|
958
962
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
959
963
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
960
964
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -1011,7 +1015,7 @@ class BoardingClient {
|
|
|
1011
1015
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Boarding/link/${core.url.encodePathParam(boardingLinkReference)}`),
|
|
1012
1016
|
method: "GET",
|
|
1013
1017
|
headers: _headers,
|
|
1014
|
-
|
|
1018
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
1015
1019
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
1016
1020
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
1017
1021
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -1081,7 +1085,11 @@ class BoardingClient {
|
|
|
1081
1085
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Query/boarding/${core.url.encodePathParam(orgId)}`),
|
|
1082
1086
|
method: "GET",
|
|
1083
1087
|
headers: _headers,
|
|
1084
|
-
|
|
1088
|
+
queryString: core.url
|
|
1089
|
+
.queryBuilder()
|
|
1090
|
+
.addMany(_queryParams)
|
|
1091
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
1092
|
+
.build(),
|
|
1085
1093
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
1086
1094
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
1087
1095
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -1153,7 +1161,11 @@ class BoardingClient {
|
|
|
1153
1161
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Query/boardinglinks/${core.url.encodePathParam(orgId)}`),
|
|
1154
1162
|
method: "GET",
|
|
1155
1163
|
headers: _headers,
|
|
1156
|
-
|
|
1164
|
+
queryString: core.url
|
|
1165
|
+
.queryBuilder()
|
|
1166
|
+
.addMany(_queryParams)
|
|
1167
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
1168
|
+
.build(),
|
|
1157
1169
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
1158
1170
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
1159
1171
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -1212,7 +1224,7 @@ class BoardingClient {
|
|
|
1212
1224
|
method: "PUT",
|
|
1213
1225
|
headers: _headers,
|
|
1214
1226
|
contentType: "application/json",
|
|
1215
|
-
|
|
1227
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
1216
1228
|
requestType: "json",
|
|
1217
1229
|
body: request,
|
|
1218
1230
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -1248,5 +1260,134 @@ class BoardingClient {
|
|
|
1248
1260
|
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "PUT", "/Boarding/app/{appId}");
|
|
1249
1261
|
});
|
|
1250
1262
|
}
|
|
1263
|
+
/**
|
|
1264
|
+
* Creates a new boarding application linked to an existing paypoint as part of the multi-product boarding flow. Use this endpoint to add new services to a paypoint without creating a duplicate record. The system copies eligible business, contact, banking, and address data from the paypoint to the new application based on 1:1 field matching. The merchant only needs to provide fields that are specific to the new service. See the [Multi-product boarding](/guides/pay-ops-developer-boarding-multi-product) guide for the full flow.
|
|
1265
|
+
*
|
|
1266
|
+
* @param {Payabli.CreateApplicationFromPaypointRequest} request
|
|
1267
|
+
* @param {BoardingClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
1268
|
+
*
|
|
1269
|
+
* @throws {@link Payabli.BadRequestError}
|
|
1270
|
+
* @throws {@link Payabli.UnauthorizedError}
|
|
1271
|
+
* @throws {@link Payabli.InternalServerError}
|
|
1272
|
+
* @throws {@link Payabli.ServiceUnavailableError}
|
|
1273
|
+
*
|
|
1274
|
+
* @example
|
|
1275
|
+
* await client.boarding.addServiceToPaypointFromApp({
|
|
1276
|
+
* paypointId: 123,
|
|
1277
|
+
* templateId: 456,
|
|
1278
|
+
* recipientEmail: "merchant@example.com",
|
|
1279
|
+
* returnBoardingAccessInfoInLine: true,
|
|
1280
|
+
* onCreate: ["submitApplication"]
|
|
1281
|
+
* })
|
|
1282
|
+
*/
|
|
1283
|
+
addServiceToPaypointFromApp(request, requestOptions) {
|
|
1284
|
+
return core.HttpResponsePromise.fromPromise(this.__addServiceToPaypointFromApp(request, requestOptions));
|
|
1285
|
+
}
|
|
1286
|
+
__addServiceToPaypointFromApp(request, requestOptions) {
|
|
1287
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1288
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1289
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
1290
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1291
|
+
const _response = yield core.fetcher({
|
|
1292
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, "Boarding/applications"),
|
|
1293
|
+
method: "POST",
|
|
1294
|
+
headers: _headers,
|
|
1295
|
+
contentType: "application/json",
|
|
1296
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
1297
|
+
requestType: "json",
|
|
1298
|
+
body: request,
|
|
1299
|
+
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
1300
|
+
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
1301
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1302
|
+
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
1303
|
+
logging: this._options.logging,
|
|
1304
|
+
});
|
|
1305
|
+
if (_response.ok) {
|
|
1306
|
+
return {
|
|
1307
|
+
data: _response.body,
|
|
1308
|
+
rawResponse: _response.rawResponse,
|
|
1309
|
+
};
|
|
1310
|
+
}
|
|
1311
|
+
if (_response.error.reason === "status-code") {
|
|
1312
|
+
switch (_response.error.statusCode) {
|
|
1313
|
+
case 400:
|
|
1314
|
+
throw new Payabli.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1315
|
+
case 401:
|
|
1316
|
+
throw new Payabli.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
1317
|
+
case 500:
|
|
1318
|
+
throw new Payabli.InternalServerError(_response.error.body, _response.rawResponse);
|
|
1319
|
+
case 503:
|
|
1320
|
+
throw new Payabli.ServiceUnavailableError(_response.error.body, _response.rawResponse);
|
|
1321
|
+
default:
|
|
1322
|
+
throw new errors.PayabliError({
|
|
1323
|
+
statusCode: _response.error.statusCode,
|
|
1324
|
+
body: _response.error.body,
|
|
1325
|
+
rawResponse: _response.rawResponse,
|
|
1326
|
+
});
|
|
1327
|
+
}
|
|
1328
|
+
}
|
|
1329
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/Boarding/applications");
|
|
1330
|
+
});
|
|
1331
|
+
}
|
|
1332
|
+
/**
|
|
1333
|
+
* Returns all boarding applications associated with a specific paypoint, including those created through the multi-product boarding flow. Use this endpoint to track underwriting progress across multiple service additions or to build reporting views. See the [Multi-product boarding](/guides/pay-ops-developer-boarding-multi-product) guide for the full flow.
|
|
1334
|
+
*
|
|
1335
|
+
* @param {number} paypointId - ID of the paypoint to retrieve applications for.
|
|
1336
|
+
* @param {BoardingClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
1337
|
+
*
|
|
1338
|
+
* @throws {@link Payabli.BadRequestError}
|
|
1339
|
+
* @throws {@link Payabli.UnauthorizedError}
|
|
1340
|
+
* @throws {@link Payabli.InternalServerError}
|
|
1341
|
+
* @throws {@link Payabli.ServiceUnavailableError}
|
|
1342
|
+
*
|
|
1343
|
+
* @example
|
|
1344
|
+
* await client.boarding.getApplicationsByPaypointId(12345)
|
|
1345
|
+
*/
|
|
1346
|
+
getApplicationsByPaypointId(paypointId, requestOptions) {
|
|
1347
|
+
return core.HttpResponsePromise.fromPromise(this.__getApplicationsByPaypointId(paypointId, requestOptions));
|
|
1348
|
+
}
|
|
1349
|
+
__getApplicationsByPaypointId(paypointId, requestOptions) {
|
|
1350
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1351
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1352
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
1353
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1354
|
+
const _response = yield core.fetcher({
|
|
1355
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `Boarding/applications/${core.url.encodePathParam(paypointId)}`),
|
|
1356
|
+
method: "GET",
|
|
1357
|
+
headers: _headers,
|
|
1358
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
1359
|
+
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
1360
|
+
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
1361
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1362
|
+
fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
|
|
1363
|
+
logging: this._options.logging,
|
|
1364
|
+
});
|
|
1365
|
+
if (_response.ok) {
|
|
1366
|
+
return {
|
|
1367
|
+
data: _response.body,
|
|
1368
|
+
rawResponse: _response.rawResponse,
|
|
1369
|
+
};
|
|
1370
|
+
}
|
|
1371
|
+
if (_response.error.reason === "status-code") {
|
|
1372
|
+
switch (_response.error.statusCode) {
|
|
1373
|
+
case 400:
|
|
1374
|
+
throw new Payabli.BadRequestError(_response.error.body, _response.rawResponse);
|
|
1375
|
+
case 401:
|
|
1376
|
+
throw new Payabli.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
1377
|
+
case 500:
|
|
1378
|
+
throw new Payabli.InternalServerError(_response.error.body, _response.rawResponse);
|
|
1379
|
+
case 503:
|
|
1380
|
+
throw new Payabli.ServiceUnavailableError(_response.error.body, _response.rawResponse);
|
|
1381
|
+
default:
|
|
1382
|
+
throw new errors.PayabliError({
|
|
1383
|
+
statusCode: _response.error.statusCode,
|
|
1384
|
+
body: _response.error.body,
|
|
1385
|
+
rawResponse: _response.rawResponse,
|
|
1386
|
+
});
|
|
1387
|
+
}
|
|
1388
|
+
}
|
|
1389
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/Boarding/applications/{paypointId}");
|
|
1390
|
+
});
|
|
1391
|
+
}
|
|
1251
1392
|
}
|
|
1252
1393
|
exports.BoardingClient = BoardingClient;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Request to create a boarding application linked to an existing paypoint. Used for adding new services to a paypoint without creating a duplicate record.
|
|
3
|
+
*/
|
|
4
|
+
export interface CreateApplicationFromPaypointRequest {
|
|
5
|
+
/** ID of the existing paypoint to link to this application. */
|
|
6
|
+
paypointId: number;
|
|
7
|
+
/** ID of the boarding template to use for the new application. */
|
|
8
|
+
templateId: number;
|
|
9
|
+
/** Email address where the boarding link is sent. Required. If you don't want to email the merchant, send to an internal address and use `returnBoardingAccessInfoInLine` to retrieve the link from the response instead. */
|
|
10
|
+
recipientEmail: string;
|
|
11
|
+
/** When `true`, returns the boarding access information directly in the response. */
|
|
12
|
+
returnBoardingAccessInfoInLine?: boolean | undefined;
|
|
13
|
+
/** Additional actions to trigger when the application is created. Currently only `submitApplication` is supported, which automatically submits the application on creation and skips the draft state. */
|
|
14
|
+
onCreate?: string[] | undefined;
|
|
15
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type * as Payabli from "../../../index.js";
|
|
2
|
+
/**
|
|
3
|
+
* Response returned when creating a boarding application linked to an existing paypoint.
|
|
4
|
+
*/
|
|
5
|
+
export interface CreateApplicationFromPaypointResponse {
|
|
6
|
+
responseCode?: Payabli.Responsecode | undefined;
|
|
7
|
+
pageIdentifier?: Payabli.PageIdentifier | undefined;
|
|
8
|
+
roomId?: Payabli.RoomIdNotInUse | undefined;
|
|
9
|
+
isSuccess?: Payabli.IsSuccess | undefined;
|
|
10
|
+
responseText: Payabli.ResponseText;
|
|
11
|
+
responseData?: CreateApplicationFromPaypointResponse.ResponseData | undefined;
|
|
12
|
+
}
|
|
13
|
+
export declare namespace CreateApplicationFromPaypointResponse {
|
|
14
|
+
interface ResponseData {
|
|
15
|
+
/** Unique identifier for the created application. */
|
|
16
|
+
appId?: number | undefined;
|
|
17
|
+
/** URL where the merchant can complete the boarding process. */
|
|
18
|
+
boardingLink?: string | undefined;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -15,3 +15,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./AddApplicationRequest.js"), exports);
|
|
18
|
+
__exportStar(require("./CreateApplicationFromPaypointRequest.js"), exports);
|
|
19
|
+
__exportStar(require("./CreateApplicationFromPaypointResponse.js"), exports);
|
|
@@ -97,7 +97,7 @@ class ChargeBacksClient {
|
|
|
97
97
|
method: "POST",
|
|
98
98
|
headers: _headers,
|
|
99
99
|
contentType: "application/json",
|
|
100
|
-
|
|
100
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
101
101
|
requestType: "json",
|
|
102
102
|
body: _body,
|
|
103
103
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
@@ -156,7 +156,7 @@ class ChargeBacksClient {
|
|
|
156
156
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `ChargeBacks/read/${core.url.encodePathParam(Id)}`),
|
|
157
157
|
method: "GET",
|
|
158
158
|
headers: _headers,
|
|
159
|
-
|
|
159
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
160
160
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
161
161
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
162
162
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
@@ -214,7 +214,7 @@ class ChargeBacksClient {
|
|
|
214
214
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `ChargeBacks/getChargebackAttachments/${core.url.encodePathParam(Id)}/${core.url.encodePathParam(fileName)}`),
|
|
215
215
|
method: "GET",
|
|
216
216
|
headers: _headers,
|
|
217
|
-
|
|
217
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
218
218
|
responseType: "text",
|
|
219
219
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|
|
220
220
|
maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
|
|
@@ -89,7 +89,7 @@ class CheckCaptureClient {
|
|
|
89
89
|
method: "POST",
|
|
90
90
|
headers: _headers,
|
|
91
91
|
contentType: "application/json",
|
|
92
|
-
|
|
92
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
93
93
|
requestType: "json",
|
|
94
94
|
body: request,
|
|
95
95
|
timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
|