@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.
Files changed (187) hide show
  1. package/README.md +10 -2
  2. package/dist/cjs/BaseClient.d.ts +3 -0
  3. package/dist/cjs/BaseClient.js +17 -2
  4. package/dist/cjs/api/resources/bill/client/Client.js +35 -11
  5. package/dist/cjs/api/resources/boarding/client/Client.d.ts +38 -0
  6. package/dist/cjs/api/resources/boarding/client/Client.js +152 -11
  7. package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointRequest.d.ts +15 -0
  8. package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointRequest.js +3 -0
  9. package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointResponse.d.ts +20 -0
  10. package/dist/cjs/api/resources/boarding/types/CreateApplicationFromPaypointResponse.js +3 -0
  11. package/dist/cjs/api/resources/boarding/types/index.d.ts +2 -0
  12. package/dist/cjs/api/resources/boarding/types/index.js +2 -0
  13. package/dist/cjs/api/resources/chargeBacks/client/Client.js +3 -3
  14. package/dist/cjs/api/resources/checkCapture/client/Client.js +1 -1
  15. package/dist/cjs/api/resources/cloud/client/Client.js +8 -4
  16. package/dist/cjs/api/resources/customer/client/Client.js +10 -6
  17. package/dist/cjs/api/resources/export/client/Client.js +145 -29
  18. package/dist/cjs/api/resources/ghostCard/client/Client.js +2 -2
  19. package/dist/cjs/api/resources/hostedPaymentPages/client/Client.js +3 -3
  20. package/dist/cjs/api/resources/import/client/Client.js +7 -3
  21. package/dist/cjs/api/resources/invoice/client/Client.js +35 -11
  22. package/dist/cjs/api/resources/lineItem/client/Client.js +9 -5
  23. package/dist/cjs/api/resources/management/client/Client.js +1 -1
  24. package/dist/cjs/api/resources/moneyIn/client/Client.js +43 -19
  25. package/dist/cjs/api/resources/moneyOut/client/Client.d.ts +5 -1
  26. package/dist/cjs/api/resources/moneyOut/client/Client.js +25 -13
  27. package/dist/cjs/api/resources/notification/client/Client.js +5 -5
  28. package/dist/cjs/api/resources/notificationlogs/client/Client.js +8 -4
  29. package/dist/cjs/api/resources/ocr/client/Client.js +2 -2
  30. package/dist/cjs/api/resources/organization/client/Client.js +7 -7
  31. package/dist/cjs/api/resources/paymentLink/client/Client.js +31 -11
  32. package/dist/cjs/api/resources/paymentMethodDomain/client/Client.js +11 -7
  33. package/dist/cjs/api/resources/payoutSubscription/client/Client.js +4 -4
  34. package/dist/cjs/api/resources/paypoint/client/Client.js +12 -8
  35. package/dist/cjs/api/resources/query/client/Client.d.ts +58 -0
  36. package/dist/cjs/api/resources/query/client/Client.js +368 -40
  37. package/dist/cjs/api/resources/query/client/requests/ListSubscriptionsOrgRequest.d.ts +1 -0
  38. package/dist/cjs/api/resources/query/client/requests/ListSubscriptionsRequest.d.ts +1 -0
  39. package/dist/cjs/api/resources/query/client/requests/ListTransactionsOrgRequest.d.ts +9 -0
  40. package/dist/cjs/api/resources/query/client/requests/ListTransactionsRequest.d.ts +9 -0
  41. package/dist/cjs/api/resources/query/client/requests/ListVcardsOrgRequest.d.ts +8 -6
  42. package/dist/cjs/api/resources/query/client/requests/ListVcardsRequest.d.ts +8 -6
  43. package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.d.ts +72 -0
  44. package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.js +3 -0
  45. package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsRequest.d.ts +72 -0
  46. package/dist/cjs/api/resources/query/client/requests/ListVcardsTransactionsRequest.js +3 -0
  47. package/dist/cjs/api/resources/query/client/requests/ListVendorsOrgRequest.d.ts +1 -0
  48. package/dist/cjs/api/resources/query/client/requests/ListVendorsRequest.d.ts +1 -0
  49. package/dist/cjs/api/resources/query/client/requests/index.d.ts +2 -0
  50. package/dist/cjs/api/resources/queryTypes/types/QueryTransferDetailResponse.d.ts +2 -0
  51. package/dist/cjs/api/resources/queryTypes/types/QueryTransferSummary.d.ts +2 -0
  52. package/dist/cjs/api/resources/queryTypes/types/VCardTransactionQueryResponse.d.ts +49 -0
  53. package/dist/cjs/api/resources/queryTypes/types/VCardTransactionQueryResponse.js +3 -0
  54. package/dist/cjs/api/resources/queryTypes/types/VCardTransactionRecord.d.ts +86 -0
  55. package/dist/cjs/api/resources/queryTypes/types/VCardTransactionRecord.js +3 -0
  56. package/dist/cjs/api/resources/queryTypes/types/index.d.ts +2 -0
  57. package/dist/cjs/api/resources/queryTypes/types/index.js +2 -0
  58. package/dist/cjs/api/resources/statistic/client/Client.js +20 -4
  59. package/dist/cjs/api/resources/subscription/client/Client.js +8 -4
  60. package/dist/cjs/api/resources/templates/client/Client.js +8 -4
  61. package/dist/cjs/api/resources/tokenStorage/client/Client.js +16 -4
  62. package/dist/cjs/api/resources/user/client/Client.js +16 -12
  63. package/dist/cjs/api/resources/v2MoneyInTypes/types/V2TransactionDetails.d.ts +1 -1
  64. package/dist/cjs/api/resources/vendor/client/Client.js +5 -5
  65. package/dist/cjs/api/resources/wallet/client/Client.js +4 -4
  66. package/dist/cjs/api/types/AutoCapture.d.ts +5 -1
  67. package/dist/cjs/api/types/CustomerQueryRecords.d.ts +10 -8
  68. package/dist/cjs/api/types/CustomerSummaryRecord.d.ts +4 -4
  69. package/dist/cjs/api/types/QueryResponseTransactions.d.ts +74 -0
  70. package/dist/cjs/api/types/SplitCount.d.ts +4 -0
  71. package/dist/cjs/api/types/SplitCount.js +3 -0
  72. package/dist/cjs/api/types/SubscriptionQueryRecords.d.ts +11 -1
  73. package/dist/cjs/api/types/TransactionQueryRecords.d.ts +2 -1
  74. package/dist/cjs/api/types/TransactionQueryRecordsCustomer.d.ts +1 -0
  75. package/dist/cjs/api/types/VCardSummary.d.ts +4 -2
  76. package/dist/cjs/api/types/VendorResponseStoredMethod.d.ts +2 -1
  77. package/dist/cjs/api/types/index.d.ts +1 -0
  78. package/dist/cjs/api/types/index.js +1 -0
  79. package/dist/cjs/core/auth/AuthProvider.d.ts +1 -0
  80. package/dist/cjs/core/auth/AuthProvider.js +7 -0
  81. package/dist/cjs/core/auth/index.d.ts +1 -1
  82. package/dist/cjs/core/auth/index.js +3 -1
  83. package/dist/cjs/core/fetcher/Fetcher.d.ts +6 -0
  84. package/dist/cjs/core/fetcher/Fetcher.js +9 -8
  85. package/dist/cjs/core/fetcher/requestWithRetries.js +4 -1
  86. package/dist/cjs/core/url/QueryStringBuilder.d.ts +47 -0
  87. package/dist/cjs/core/url/QueryStringBuilder.js +83 -0
  88. package/dist/cjs/core/url/index.d.ts +1 -0
  89. package/dist/cjs/core/url/index.js +3 -1
  90. package/dist/cjs/core/url/qs.d.ts +2 -1
  91. package/dist/cjs/core/url/qs.js +24 -12
  92. package/dist/cjs/version.d.ts +1 -1
  93. package/dist/cjs/version.js +1 -1
  94. package/dist/esm/BaseClient.d.mts +3 -0
  95. package/dist/esm/BaseClient.mjs +17 -2
  96. package/dist/esm/api/resources/bill/client/Client.mjs +35 -11
  97. package/dist/esm/api/resources/boarding/client/Client.d.mts +38 -0
  98. package/dist/esm/api/resources/boarding/client/Client.mjs +152 -11
  99. package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointRequest.d.mts +15 -0
  100. package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointRequest.mjs +2 -0
  101. package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointResponse.d.mts +20 -0
  102. package/dist/esm/api/resources/boarding/types/CreateApplicationFromPaypointResponse.mjs +2 -0
  103. package/dist/esm/api/resources/boarding/types/index.d.mts +2 -0
  104. package/dist/esm/api/resources/boarding/types/index.mjs +2 -0
  105. package/dist/esm/api/resources/chargeBacks/client/Client.mjs +3 -3
  106. package/dist/esm/api/resources/checkCapture/client/Client.mjs +1 -1
  107. package/dist/esm/api/resources/cloud/client/Client.mjs +8 -4
  108. package/dist/esm/api/resources/customer/client/Client.mjs +10 -6
  109. package/dist/esm/api/resources/export/client/Client.mjs +145 -29
  110. package/dist/esm/api/resources/ghostCard/client/Client.mjs +2 -2
  111. package/dist/esm/api/resources/hostedPaymentPages/client/Client.mjs +3 -3
  112. package/dist/esm/api/resources/import/client/Client.mjs +7 -3
  113. package/dist/esm/api/resources/invoice/client/Client.mjs +35 -11
  114. package/dist/esm/api/resources/lineItem/client/Client.mjs +9 -5
  115. package/dist/esm/api/resources/management/client/Client.mjs +1 -1
  116. package/dist/esm/api/resources/moneyIn/client/Client.mjs +43 -19
  117. package/dist/esm/api/resources/moneyOut/client/Client.d.mts +5 -1
  118. package/dist/esm/api/resources/moneyOut/client/Client.mjs +25 -13
  119. package/dist/esm/api/resources/notification/client/Client.mjs +5 -5
  120. package/dist/esm/api/resources/notificationlogs/client/Client.mjs +8 -4
  121. package/dist/esm/api/resources/ocr/client/Client.mjs +2 -2
  122. package/dist/esm/api/resources/organization/client/Client.mjs +7 -7
  123. package/dist/esm/api/resources/paymentLink/client/Client.mjs +31 -11
  124. package/dist/esm/api/resources/paymentMethodDomain/client/Client.mjs +11 -7
  125. package/dist/esm/api/resources/payoutSubscription/client/Client.mjs +4 -4
  126. package/dist/esm/api/resources/paypoint/client/Client.mjs +12 -8
  127. package/dist/esm/api/resources/query/client/Client.d.mts +58 -0
  128. package/dist/esm/api/resources/query/client/Client.mjs +368 -40
  129. package/dist/esm/api/resources/query/client/requests/ListSubscriptionsOrgRequest.d.mts +1 -0
  130. package/dist/esm/api/resources/query/client/requests/ListSubscriptionsRequest.d.mts +1 -0
  131. package/dist/esm/api/resources/query/client/requests/ListTransactionsOrgRequest.d.mts +9 -0
  132. package/dist/esm/api/resources/query/client/requests/ListTransactionsRequest.d.mts +9 -0
  133. package/dist/esm/api/resources/query/client/requests/ListVcardsOrgRequest.d.mts +8 -6
  134. package/dist/esm/api/resources/query/client/requests/ListVcardsRequest.d.mts +8 -6
  135. package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.d.mts +72 -0
  136. package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsOrgRequest.mjs +2 -0
  137. package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsRequest.d.mts +72 -0
  138. package/dist/esm/api/resources/query/client/requests/ListVcardsTransactionsRequest.mjs +2 -0
  139. package/dist/esm/api/resources/query/client/requests/ListVendorsOrgRequest.d.mts +1 -0
  140. package/dist/esm/api/resources/query/client/requests/ListVendorsRequest.d.mts +1 -0
  141. package/dist/esm/api/resources/query/client/requests/index.d.mts +2 -0
  142. package/dist/esm/api/resources/queryTypes/types/QueryTransferDetailResponse.d.mts +2 -0
  143. package/dist/esm/api/resources/queryTypes/types/QueryTransferSummary.d.mts +2 -0
  144. package/dist/esm/api/resources/queryTypes/types/VCardTransactionQueryResponse.d.mts +49 -0
  145. package/dist/esm/api/resources/queryTypes/types/VCardTransactionQueryResponse.mjs +2 -0
  146. package/dist/esm/api/resources/queryTypes/types/VCardTransactionRecord.d.mts +86 -0
  147. package/dist/esm/api/resources/queryTypes/types/VCardTransactionRecord.mjs +2 -0
  148. package/dist/esm/api/resources/queryTypes/types/index.d.mts +2 -0
  149. package/dist/esm/api/resources/queryTypes/types/index.mjs +2 -0
  150. package/dist/esm/api/resources/statistic/client/Client.mjs +20 -4
  151. package/dist/esm/api/resources/subscription/client/Client.mjs +8 -4
  152. package/dist/esm/api/resources/templates/client/Client.mjs +8 -4
  153. package/dist/esm/api/resources/tokenStorage/client/Client.mjs +16 -4
  154. package/dist/esm/api/resources/user/client/Client.mjs +16 -12
  155. package/dist/esm/api/resources/v2MoneyInTypes/types/V2TransactionDetails.d.mts +1 -1
  156. package/dist/esm/api/resources/vendor/client/Client.mjs +5 -5
  157. package/dist/esm/api/resources/wallet/client/Client.mjs +4 -4
  158. package/dist/esm/api/types/AutoCapture.d.mts +5 -1
  159. package/dist/esm/api/types/CustomerQueryRecords.d.mts +10 -8
  160. package/dist/esm/api/types/CustomerSummaryRecord.d.mts +4 -4
  161. package/dist/esm/api/types/QueryResponseTransactions.d.mts +74 -0
  162. package/dist/esm/api/types/SplitCount.d.mts +4 -0
  163. package/dist/esm/api/types/SplitCount.mjs +2 -0
  164. package/dist/esm/api/types/SubscriptionQueryRecords.d.mts +11 -1
  165. package/dist/esm/api/types/TransactionQueryRecords.d.mts +2 -1
  166. package/dist/esm/api/types/TransactionQueryRecordsCustomer.d.mts +1 -0
  167. package/dist/esm/api/types/VCardSummary.d.mts +4 -2
  168. package/dist/esm/api/types/VendorResponseStoredMethod.d.mts +2 -1
  169. package/dist/esm/api/types/index.d.mts +1 -0
  170. package/dist/esm/api/types/index.mjs +1 -0
  171. package/dist/esm/core/auth/AuthProvider.d.mts +1 -0
  172. package/dist/esm/core/auth/AuthProvider.mjs +6 -1
  173. package/dist/esm/core/auth/index.d.mts +1 -1
  174. package/dist/esm/core/auth/index.mjs +1 -0
  175. package/dist/esm/core/fetcher/Fetcher.d.mts +6 -0
  176. package/dist/esm/core/fetcher/Fetcher.mjs +9 -8
  177. package/dist/esm/core/fetcher/requestWithRetries.mjs +4 -1
  178. package/dist/esm/core/url/QueryStringBuilder.d.mts +47 -0
  179. package/dist/esm/core/url/QueryStringBuilder.mjs +80 -0
  180. package/dist/esm/core/url/index.d.mts +1 -0
  181. package/dist/esm/core/url/index.mjs +1 -0
  182. package/dist/esm/core/url/qs.d.mts +2 -1
  183. package/dist/esm/core/url/qs.mjs +24 -12
  184. package/dist/esm/version.d.mts +1 -1
  185. package/dist/esm/version.mjs +1 -1
  186. package/package.json +1 -1
  187. 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
- A request is deemed retryable when any of the following HTTP status codes is returned:
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/500) (Internal Server Errors)
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
 
@@ -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. */
@@ -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.143",
47
- "User-Agent": "@payabli/sdk-node/0.0.143",
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -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
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1 +1,3 @@
1
1
  export * from "./AddApplicationRequest.js";
2
+ export * from "./CreateApplicationFromPaypointRequest.js";
3
+ export * from "./CreateApplicationFromPaypointResponse.js";
@@ -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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
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,