@emilgroup/payment-sdk 1.22.1-beta.81 → 1.22.1-beta.83

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 (137) hide show
  1. package/.openapi-generator/FILES +0 -6
  2. package/README.md +2 -2
  3. package/api/bank-accounts-api.ts +18 -48
  4. package/api/bank-orders-api.ts +15 -40
  5. package/api/bank-transaction-api.ts +26 -181
  6. package/api/billing-addresses-api.ts +15 -40
  7. package/api/credit-allocation-api.ts +9 -24
  8. package/api/exceeding-credits-api.ts +6 -128
  9. package/api/health-check-api.ts +1 -1
  10. package/api/ibanvalidator-api.ts +3 -8
  11. package/api/payment-methods-api.ts +9 -24
  12. package/api/payment-receipts-api.ts +15 -40
  13. package/api/payment-reminders-api.ts +12 -32
  14. package/api/payment-requests-api.ts +27 -52
  15. package/api/payment-setup-api.ts +6 -16
  16. package/api/payments-api.ts +16 -46
  17. package/api/payout-methods-api.ts +18 -48
  18. package/api/policy-payment-methods-api.ts +9 -24
  19. package/api/refunds-api.ts +9 -24
  20. package/api/tenant-bank-account-api.ts +15 -40
  21. package/api/webhooks-api.ts +2 -2
  22. package/base.ts +43 -239
  23. package/common.ts +2 -3
  24. package/configuration.ts +0 -20
  25. package/dist/api/bank-accounts-api.d.ts +6 -6
  26. package/dist/api/bank-accounts-api.js +46 -82
  27. package/dist/api/bank-orders-api.d.ts +5 -5
  28. package/dist/api/bank-orders-api.js +38 -67
  29. package/dist/api/bank-transaction-api.d.ts +14 -80
  30. package/dist/api/bank-transaction-api.js +52 -194
  31. package/dist/api/billing-addresses-api.d.ts +5 -5
  32. package/dist/api/billing-addresses-api.js +39 -71
  33. package/dist/api/credit-allocation-api.d.ts +3 -3
  34. package/dist/api/credit-allocation-api.js +23 -41
  35. package/dist/api/exceeding-credits-api.d.ts +2 -59
  36. package/dist/api/exceeding-credits-api.js +15 -126
  37. package/dist/api/health-check-api.d.ts +1 -1
  38. package/dist/api/health-check-api.js +1 -1
  39. package/dist/api/ibanvalidator-api.d.ts +1 -1
  40. package/dist/api/ibanvalidator-api.js +8 -15
  41. package/dist/api/payment-methods-api.d.ts +3 -3
  42. package/dist/api/payment-methods-api.js +23 -41
  43. package/dist/api/payment-receipts-api.d.ts +5 -5
  44. package/dist/api/payment-receipts-api.js +38 -67
  45. package/dist/api/payment-reminders-api.d.ts +4 -4
  46. package/dist/api/payment-reminders-api.js +31 -56
  47. package/dist/api/payment-requests-api.d.ts +17 -17
  48. package/dist/api/payment-requests-api.js +47 -76
  49. package/dist/api/payment-setup-api.d.ts +2 -2
  50. package/dist/api/payment-setup-api.js +16 -30
  51. package/dist/api/payments-api.d.ts +4 -4
  52. package/dist/api/payments-api.js +34 -62
  53. package/dist/api/payout-methods-api.d.ts +6 -6
  54. package/dist/api/payout-methods-api.js +46 -82
  55. package/dist/api/policy-payment-methods-api.d.ts +3 -3
  56. package/dist/api/policy-payment-methods-api.js +23 -41
  57. package/dist/api/refunds-api.d.ts +3 -3
  58. package/dist/api/refunds-api.js +22 -37
  59. package/dist/api/tenant-bank-account-api.d.ts +5 -5
  60. package/dist/api/tenant-bank-account-api.js +38 -67
  61. package/dist/api/webhooks-api.d.ts +2 -2
  62. package/dist/api/webhooks-api.js +2 -2
  63. package/dist/base.d.ts +0 -26
  64. package/dist/base.js +60 -243
  65. package/dist/common.d.ts +1 -1
  66. package/dist/common.js +0 -1
  67. package/dist/configuration.d.ts +0 -17
  68. package/dist/configuration.js +0 -2
  69. package/dist/models/bank-transaction-class.d.ts +0 -7
  70. package/dist/models/bank-transaction-entity.d.ts +0 -7
  71. package/dist/models/bank-transaction-invoice-entity.d.ts +0 -24
  72. package/dist/models/create-payment-order-dto.d.ts +1 -1
  73. package/dist/models/create-payment-receipt-request-dto.d.ts +3 -3
  74. package/dist/models/create-payment-request-dto.d.ts +1 -1
  75. package/dist/models/create-payment-request-request-dto.d.ts +0 -6
  76. package/dist/models/credit-allocation-class.d.ts +0 -6
  77. package/dist/models/credit-allocation-entity.d.ts +0 -6
  78. package/dist/models/exceeding-credit-entity.d.ts +0 -6
  79. package/dist/models/index.d.ts +0 -6
  80. package/dist/models/index.js +0 -6
  81. package/dist/models/list-billing-addresses-response-class.d.ts +9 -9
  82. package/dist/models/list-exceeding-credits-response-class.d.ts +18 -6
  83. package/dist/models/list-payment-receipts-response-class.d.ts +9 -9
  84. package/dist/models/list-payment-requests-response-class.d.ts +18 -6
  85. package/dist/models/list-payout-methods-response-class.d.ts +9 -9
  86. package/dist/models/list-refunds-response-class.d.ts +18 -6
  87. package/dist/models/payment-class-without-expand-properties.d.ts +2 -2
  88. package/dist/models/payment-class.d.ts +2 -2
  89. package/dist/models/payment-entity.d.ts +1 -1
  90. package/dist/models/payment-receipt-class.d.ts +1 -13
  91. package/dist/models/payment-request-class.d.ts +6 -13
  92. package/dist/models/payment-request-class.js +0 -1
  93. package/dist/models/shared-transaction-class.d.ts +0 -6
  94. package/dist/models/transaction-entity.d.ts +0 -6
  95. package/models/bank-transaction-class.ts +0 -7
  96. package/models/bank-transaction-entity.ts +0 -7
  97. package/models/bank-transaction-invoice-entity.ts +0 -24
  98. package/models/create-payment-order-dto.ts +1 -1
  99. package/models/create-payment-receipt-request-dto.ts +3 -3
  100. package/models/create-payment-request-dto.ts +1 -1
  101. package/models/create-payment-request-request-dto.ts +0 -6
  102. package/models/credit-allocation-class.ts +0 -6
  103. package/models/credit-allocation-entity.ts +0 -6
  104. package/models/exceeding-credit-entity.ts +0 -6
  105. package/models/index.ts +0 -6
  106. package/models/list-billing-addresses-response-class.ts +9 -9
  107. package/models/list-exceeding-credits-response-class.ts +18 -6
  108. package/models/list-payment-receipts-response-class.ts +9 -9
  109. package/models/list-payment-requests-response-class.ts +18 -6
  110. package/models/list-payout-methods-response-class.ts +9 -9
  111. package/models/list-refunds-response-class.ts +18 -6
  112. package/models/payment-class-without-expand-properties.ts +2 -2
  113. package/models/payment-class.ts +2 -2
  114. package/models/payment-entity.ts +1 -1
  115. package/models/payment-receipt-class.ts +1 -13
  116. package/models/payment-request-class.ts +6 -13
  117. package/models/shared-transaction-class.ts +0 -6
  118. package/models/transaction-entity.ts +0 -6
  119. package/package.json +2 -2
  120. package/dist/models/create-exceeding-credit-request-dto.d.ts +0 -48
  121. package/dist/models/create-exceeding-credit-request-dto.js +0 -15
  122. package/dist/models/create-exceeding-credit-response-class.d.ts +0 -25
  123. package/dist/models/create-exceeding-credit-response-class.js +0 -15
  124. package/dist/models/link-bank-transaction-payment-requests-request-dto-rest.d.ts +0 -30
  125. package/dist/models/link-bank-transaction-payment-requests-request-dto-rest.js +0 -15
  126. package/dist/models/link-bank-transaction-payment-requests-response-class.d.ts +0 -25
  127. package/dist/models/link-bank-transaction-payment-requests-response-class.js +0 -15
  128. package/dist/models/payment-receipt-entity.d.ts +0 -139
  129. package/dist/models/payment-receipt-entity.js +0 -20
  130. package/dist/models/payment-request-entity.d.ts +0 -223
  131. package/dist/models/payment-request-entity.js +0 -39
  132. package/models/create-exceeding-credit-request-dto.ts +0 -54
  133. package/models/create-exceeding-credit-response-class.ts +0 -31
  134. package/models/link-bank-transaction-payment-requests-request-dto-rest.ts +0 -36
  135. package/models/link-bank-transaction-payment-requests-response-class.ts +0 -31
  136. package/models/payment-receipt-entity.ts +0 -148
  137. package/models/payment-request-entity.ts +0 -233
@@ -104,10 +104,9 @@ var PolicyPaymentMethodsApiAxiosParamCreator = function (configuration) {
104
104
  activatePolicyPaymentMethod: function (code, activatePolicyPaymentMethodRequestDto, authorization, options) {
105
105
  if (options === void 0) { options = {}; }
106
106
  return __awaiter(_this, void 0, void 0, function () {
107
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
108
- var _a;
109
- return __generator(this, function (_b) {
110
- switch (_b.label) {
107
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
108
+ return __generator(this, function (_a) {
109
+ switch (_a.label) {
111
110
  case 0:
112
111
  // verify required parameter 'code' is not null or undefined
113
112
  (0, common_1.assertParamExists)('activatePolicyPaymentMethod', 'code', code);
@@ -125,19 +124,13 @@ var PolicyPaymentMethodsApiAxiosParamCreator = function (configuration) {
125
124
  localVarQueryParameter = {};
126
125
  // authentication bearer required
127
126
  // http bearer authentication required
128
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
129
- // Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
130
- // no token is stored, so a refused call still refreshes; a session call (account header) sends none.
131
- ];
127
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
132
128
  case 1:
133
129
  // authentication bearer required
134
130
  // http bearer authentication required
135
- _b.sent();
136
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
137
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
138
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
139
- if (authorizationValue || authorizationKeepEmpty) {
140
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
131
+ _a.sent();
132
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
133
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
141
134
  }
142
135
  localVarHeaderParameter['Content-Type'] = 'application/json';
143
136
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -163,10 +156,9 @@ var PolicyPaymentMethodsApiAxiosParamCreator = function (configuration) {
163
156
  createPolicyPaymentMethod: function (createPolicyPaymentMethodRequestDto, authorization, options) {
164
157
  if (options === void 0) { options = {}; }
165
158
  return __awaiter(_this, void 0, void 0, function () {
166
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
167
- var _a;
168
- return __generator(this, function (_b) {
169
- switch (_b.label) {
159
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
160
+ return __generator(this, function (_a) {
161
+ switch (_a.label) {
170
162
  case 0:
171
163
  // verify required parameter 'createPolicyPaymentMethodRequestDto' is not null or undefined
172
164
  (0, common_1.assertParamExists)('createPolicyPaymentMethod', 'createPolicyPaymentMethodRequestDto', createPolicyPaymentMethodRequestDto);
@@ -181,19 +173,13 @@ var PolicyPaymentMethodsApiAxiosParamCreator = function (configuration) {
181
173
  localVarQueryParameter = {};
182
174
  // authentication bearer required
183
175
  // http bearer authentication required
184
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
185
- // Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
186
- // no token is stored, so a refused call still refreshes; a session call (account header) sends none.
187
- ];
176
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
188
177
  case 1:
189
178
  // authentication bearer required
190
179
  // http bearer authentication required
191
- _b.sent();
192
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
193
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
194
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
195
- if (authorizationValue || authorizationKeepEmpty) {
196
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
180
+ _a.sent();
181
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
182
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
197
183
  }
198
184
  localVarHeaderParameter['Content-Type'] = 'application/json';
199
185
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -225,10 +211,9 @@ var PolicyPaymentMethodsApiAxiosParamCreator = function (configuration) {
225
211
  listPolicyPaymentMethods: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
226
212
  if (options === void 0) { options = {}; }
227
213
  return __awaiter(_this, void 0, void 0, function () {
228
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
229
- var _a;
230
- return __generator(this, function (_b) {
231
- switch (_b.label) {
214
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
215
+ return __generator(this, function (_a) {
216
+ switch (_a.label) {
232
217
  case 0:
233
218
  localVarPath = "/paymentservice/v1/policy-payment-methods";
234
219
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -245,7 +230,7 @@ var PolicyPaymentMethodsApiAxiosParamCreator = function (configuration) {
245
230
  case 1:
246
231
  // authentication bearer required
247
232
  // http bearer authentication required
248
- _b.sent();
233
+ _a.sent();
249
234
  if (pageSize !== undefined) {
250
235
  localVarQueryParameter['pageSize'] = pageSize;
251
236
  }
@@ -267,11 +252,8 @@ var PolicyPaymentMethodsApiAxiosParamCreator = function (configuration) {
267
252
  if (filters !== undefined) {
268
253
  localVarQueryParameter['filters'] = filters;
269
254
  }
270
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
271
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
272
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
273
- if (authorizationValue || authorizationKeepEmpty) {
274
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
255
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
256
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
275
257
  }
276
258
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
277
259
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -438,7 +420,7 @@ var PolicyPaymentMethodsApi = /** @class */ (function (_super) {
438
420
  */
439
421
  PolicyPaymentMethodsApi.prototype.activatePolicyPaymentMethod = function (requestParameters, options) {
440
422
  var _this = this;
441
- return (0, exports.PolicyPaymentMethodsApiFp)(this.configuration).activatePolicyPaymentMethod(requestParameters.code, requestParameters.activatePolicyPaymentMethodRequestDto, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
423
+ return (0, exports.PolicyPaymentMethodsApiFp)(this.configuration).activatePolicyPaymentMethod(requestParameters.code, requestParameters.activatePolicyPaymentMethodRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
442
424
  };
443
425
  /**
444
426
  * Attaches a payment method to a policy by creating a policy payment method and setting it as active. Any previous payment method attachment will be deactivated. **Required Permissions** \"payment-management.payments.create\"
@@ -450,7 +432,7 @@ var PolicyPaymentMethodsApi = /** @class */ (function (_super) {
450
432
  */
451
433
  PolicyPaymentMethodsApi.prototype.createPolicyPaymentMethod = function (requestParameters, options) {
452
434
  var _this = this;
453
- return (0, exports.PolicyPaymentMethodsApiFp)(this.configuration).createPolicyPaymentMethod(requestParameters.createPolicyPaymentMethodRequestDto, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
435
+ return (0, exports.PolicyPaymentMethodsApiFp)(this.configuration).createPolicyPaymentMethod(requestParameters.createPolicyPaymentMethodRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
454
436
  };
455
437
  /**
456
438
  * List policy payment methods **Required Permissions** \"payment-management.payments.view\"
@@ -463,7 +445,7 @@ var PolicyPaymentMethodsApi = /** @class */ (function (_super) {
463
445
  PolicyPaymentMethodsApi.prototype.listPolicyPaymentMethods = function (requestParameters, options) {
464
446
  var _this = this;
465
447
  if (requestParameters === void 0) { requestParameters = {}; }
466
- return (0, exports.PolicyPaymentMethodsApiFp)(this.configuration).listPolicyPaymentMethods(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
448
+ return (0, exports.PolicyPaymentMethodsApiFp)(this.configuration).listPolicyPaymentMethods(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
467
449
  };
468
450
  return PolicyPaymentMethodsApi;
469
451
  }(base_1.BaseAPI));
@@ -250,7 +250,7 @@ export declare class RefundsApi extends BaseAPI {
250
250
  * @throws {RequiredError}
251
251
  * @memberof RefundsApi
252
252
  */
253
- createRefund(requestParameters: RefundsApiCreateRefundRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateRefundResponseClass, any, {}, any>>;
253
+ createRefund(requestParameters: RefundsApiCreateRefundRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateRefundResponseClass, any, {}>>;
254
254
  /**
255
255
  * Retrieves the details of the refund that was previously created. Supply the unique refund code that was returned when you created it and Emil Api will return the corresponding refund information. **Required Permissions** \"payment-management.payments.view\"
256
256
  * @summary Retrieve the refund
@@ -259,7 +259,7 @@ export declare class RefundsApi extends BaseAPI {
259
259
  * @throws {RequiredError}
260
260
  * @memberof RefundsApi
261
261
  */
262
- getRefund(requestParameters: RefundsApiGetRefundRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetRefundResponseClass, any, {}, any>>;
262
+ getRefund(requestParameters: RefundsApiGetRefundRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetRefundResponseClass, any, {}>>;
263
263
  /**
264
264
  * Returns a list of refunds you have previously created. The refunds are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"payment-management.payments.view\"
265
265
  * @summary List refunds
@@ -268,5 +268,5 @@ export declare class RefundsApi extends BaseAPI {
268
268
  * @throws {RequiredError}
269
269
  * @memberof RefundsApi
270
270
  */
271
- listRefunds(requestParameters?: RefundsApiListRefundsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListRefundsResponseClass, any, {}, any>>;
271
+ listRefunds(requestParameters?: RefundsApiListRefundsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListRefundsResponseClass, any, {}>>;
272
272
  }
@@ -103,10 +103,9 @@ var RefundsApiAxiosParamCreator = function (configuration) {
103
103
  createRefund: function (createRefundRequestDto, authorization, options) {
104
104
  if (options === void 0) { options = {}; }
105
105
  return __awaiter(_this, void 0, void 0, function () {
106
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
107
- var _a;
108
- return __generator(this, function (_b) {
109
- switch (_b.label) {
106
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
+ return __generator(this, function (_a) {
108
+ switch (_a.label) {
110
109
  case 0:
111
110
  // verify required parameter 'createRefundRequestDto' is not null or undefined
112
111
  (0, common_1.assertParamExists)('createRefund', 'createRefundRequestDto', createRefundRequestDto);
@@ -121,19 +120,13 @@ var RefundsApiAxiosParamCreator = function (configuration) {
121
120
  localVarQueryParameter = {};
122
121
  // authentication bearer required
123
122
  // http bearer authentication required
124
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
125
- // Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
126
- // no token is stored, so a refused call still refreshes; a session call (account header) sends none.
127
- ];
123
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
128
124
  case 1:
129
125
  // authentication bearer required
130
126
  // http bearer authentication required
131
- _b.sent();
132
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
133
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
134
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
135
- if (authorizationValue || authorizationKeepEmpty) {
136
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
127
+ _a.sent();
128
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
129
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
137
130
  }
138
131
  localVarHeaderParameter['Content-Type'] = 'application/json';
139
132
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -160,10 +153,9 @@ var RefundsApiAxiosParamCreator = function (configuration) {
160
153
  getRefund: function (code, authorization, expand, options) {
161
154
  if (options === void 0) { options = {}; }
162
155
  return __awaiter(_this, void 0, void 0, function () {
163
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
164
- var _a;
165
- return __generator(this, function (_b) {
166
- switch (_b.label) {
156
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
157
+ return __generator(this, function (_a) {
158
+ switch (_a.label) {
167
159
  case 0:
168
160
  // verify required parameter 'code' is not null or undefined
169
161
  (0, common_1.assertParamExists)('getRefund', 'code', code);
@@ -183,15 +175,12 @@ var RefundsApiAxiosParamCreator = function (configuration) {
183
175
  case 1:
184
176
  // authentication bearer required
185
177
  // http bearer authentication required
186
- _b.sent();
178
+ _a.sent();
187
179
  if (expand !== undefined) {
188
180
  localVarQueryParameter['expand'] = expand;
189
181
  }
190
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
191
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
192
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
193
- if (authorizationValue || authorizationKeepEmpty) {
194
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
182
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
183
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
195
184
  }
196
185
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
197
186
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -221,10 +210,9 @@ var RefundsApiAxiosParamCreator = function (configuration) {
221
210
  listRefunds: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
222
211
  if (options === void 0) { options = {}; }
223
212
  return __awaiter(_this, void 0, void 0, function () {
224
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
225
- var _a;
226
- return __generator(this, function (_b) {
227
- switch (_b.label) {
213
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
214
+ return __generator(this, function (_a) {
215
+ switch (_a.label) {
228
216
  case 0:
229
217
  localVarPath = "/paymentservice/v1/refunds";
230
218
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -241,7 +229,7 @@ var RefundsApiAxiosParamCreator = function (configuration) {
241
229
  case 1:
242
230
  // authentication bearer required
243
231
  // http bearer authentication required
244
- _b.sent();
232
+ _a.sent();
245
233
  if (pageSize !== undefined) {
246
234
  localVarQueryParameter['pageSize'] = pageSize;
247
235
  }
@@ -263,11 +251,8 @@ var RefundsApiAxiosParamCreator = function (configuration) {
263
251
  if (filters !== undefined) {
264
252
  localVarQueryParameter['filters'] = filters;
265
253
  }
266
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
267
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
268
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
269
- if (authorizationValue || authorizationKeepEmpty) {
270
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
254
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
255
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
271
256
  }
272
257
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
273
258
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -434,7 +419,7 @@ var RefundsApi = /** @class */ (function (_super) {
434
419
  */
435
420
  RefundsApi.prototype.createRefund = function (requestParameters, options) {
436
421
  var _this = this;
437
- return (0, exports.RefundsApiFp)(this.configuration).createRefund(requestParameters.createRefundRequestDto, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
422
+ return (0, exports.RefundsApiFp)(this.configuration).createRefund(requestParameters.createRefundRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
438
423
  };
439
424
  /**
440
425
  * Retrieves the details of the refund that was previously created. Supply the unique refund code that was returned when you created it and Emil Api will return the corresponding refund information. **Required Permissions** \"payment-management.payments.view\"
@@ -446,7 +431,7 @@ var RefundsApi = /** @class */ (function (_super) {
446
431
  */
447
432
  RefundsApi.prototype.getRefund = function (requestParameters, options) {
448
433
  var _this = this;
449
- return (0, exports.RefundsApiFp)(this.configuration).getRefund(requestParameters.code, requestParameters.authorization, requestParameters.expand, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
434
+ return (0, exports.RefundsApiFp)(this.configuration).getRefund(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
450
435
  };
451
436
  /**
452
437
  * Returns a list of refunds you have previously created. The refunds are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation. **Required Permissions** \"payment-management.payments.view\"
@@ -459,7 +444,7 @@ var RefundsApi = /** @class */ (function (_super) {
459
444
  RefundsApi.prototype.listRefunds = function (requestParameters, options) {
460
445
  var _this = this;
461
446
  if (requestParameters === void 0) { requestParameters = {}; }
462
- return (0, exports.RefundsApiFp)(this.configuration).listRefunds(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
447
+ return (0, exports.RefundsApiFp)(this.configuration).listRefunds(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
463
448
  };
464
449
  return RefundsApi;
465
450
  }(base_1.BaseAPI));
@@ -353,7 +353,7 @@ export declare class TenantBankAccountApi extends BaseAPI {
353
353
  * @throws {RequiredError}
354
354
  * @memberof TenantBankAccountApi
355
355
  */
356
- createTenantBankAccount(requestParameters: TenantBankAccountApiCreateTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateTenantBankAccountResponseClass, any, {}, any>>;
356
+ createTenantBankAccount(requestParameters: TenantBankAccountApiCreateTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateTenantBankAccountResponseClass, any, {}>>;
357
357
  /**
358
358
  * Deletes a tenant bank account by code
359
359
  * @summary Delete the tenant bank account
@@ -362,7 +362,7 @@ export declare class TenantBankAccountApi extends BaseAPI {
362
362
  * @throws {RequiredError}
363
363
  * @memberof TenantBankAccountApi
364
364
  */
365
- deleteTenantBankAccount(requestParameters: TenantBankAccountApiDeleteTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<object, any, {}, any>>;
365
+ deleteTenantBankAccount(requestParameters: TenantBankAccountApiDeleteTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<object, any, {}>>;
366
366
  /**
367
367
  * Retrieves the details of the tenant bank account that was previously created. Supply the unique tenant bank account code that was returned when you created it and Emil Api will return the corresponding tenant bank account information.
368
368
  * @summary Retrieve the tenant bank account
@@ -371,7 +371,7 @@ export declare class TenantBankAccountApi extends BaseAPI {
371
371
  * @throws {RequiredError}
372
372
  * @memberof TenantBankAccountApi
373
373
  */
374
- getTenantBankAccount(requestParameters: TenantBankAccountApiGetTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetTenantBankAccountResponseClass, any, {}, any>>;
374
+ getTenantBankAccount(requestParameters: TenantBankAccountApiGetTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetTenantBankAccountResponseClass, any, {}>>;
375
375
  /**
376
376
  * Returns a list of tenant bank accounts you have previously created. The tenant bank accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
377
377
  * @summary List tenant bank accounts
@@ -380,7 +380,7 @@ export declare class TenantBankAccountApi extends BaseAPI {
380
380
  * @throws {RequiredError}
381
381
  * @memberof TenantBankAccountApi
382
382
  */
383
- listTenantBankAccounts(requestParameters?: TenantBankAccountApiListTenantBankAccountsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListTenantBankAccountResponseClass, any, {}, any>>;
383
+ listTenantBankAccounts(requestParameters?: TenantBankAccountApiListTenantBankAccountsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListTenantBankAccountResponseClass, any, {}>>;
384
384
  /**
385
385
  * Update a tenant bank account by code
386
386
  * @summary Update the tenant bank account
@@ -389,5 +389,5 @@ export declare class TenantBankAccountApi extends BaseAPI {
389
389
  * @throws {RequiredError}
390
390
  * @memberof TenantBankAccountApi
391
391
  */
392
- updateTenantBankAccount(requestParameters: TenantBankAccountApiUpdateTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UpdateTenantBankAccountResponseClass, any, {}, any>>;
392
+ updateTenantBankAccount(requestParameters: TenantBankAccountApiUpdateTenantBankAccountRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UpdateTenantBankAccountResponseClass, any, {}>>;
393
393
  }
@@ -103,10 +103,9 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
103
103
  createTenantBankAccount: function (createTenantBankAccountRequestDto, authorization, options) {
104
104
  if (options === void 0) { options = {}; }
105
105
  return __awaiter(_this, void 0, void 0, function () {
106
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
107
- var _a;
108
- return __generator(this, function (_b) {
109
- switch (_b.label) {
106
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
+ return __generator(this, function (_a) {
108
+ switch (_a.label) {
110
109
  case 0:
111
110
  // verify required parameter 'createTenantBankAccountRequestDto' is not null or undefined
112
111
  (0, common_1.assertParamExists)('createTenantBankAccount', 'createTenantBankAccountRequestDto', createTenantBankAccountRequestDto);
@@ -121,19 +120,13 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
121
120
  localVarQueryParameter = {};
122
121
  // authentication bearer required
123
122
  // http bearer authentication required
124
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
125
- // Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
126
- // no token is stored, so a refused call still refreshes; a session call (account header) sends none.
127
- ];
123
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
128
124
  case 1:
129
125
  // authentication bearer required
130
126
  // http bearer authentication required
131
- _b.sent();
132
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
133
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
134
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
135
- if (authorizationValue || authorizationKeepEmpty) {
136
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
127
+ _a.sent();
128
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
129
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
137
130
  }
138
131
  localVarHeaderParameter['Content-Type'] = 'application/json';
139
132
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -159,10 +152,9 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
159
152
  deleteTenantBankAccount: function (code, authorization, options) {
160
153
  if (options === void 0) { options = {}; }
161
154
  return __awaiter(_this, void 0, void 0, function () {
162
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
163
- var _a;
164
- return __generator(this, function (_b) {
165
- switch (_b.label) {
155
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
156
+ return __generator(this, function (_a) {
157
+ switch (_a.label) {
166
158
  case 0:
167
159
  // verify required parameter 'code' is not null or undefined
168
160
  (0, common_1.assertParamExists)('deleteTenantBankAccount', 'code', code);
@@ -178,19 +170,13 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
178
170
  localVarQueryParameter = {};
179
171
  // authentication bearer required
180
172
  // http bearer authentication required
181
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
182
- // Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
183
- // no token is stored, so a refused call still refreshes; a session call (account header) sends none.
184
- ];
173
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
185
174
  case 1:
186
175
  // authentication bearer required
187
176
  // http bearer authentication required
188
- _b.sent();
189
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
190
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
191
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
192
- if (authorizationValue || authorizationKeepEmpty) {
193
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
177
+ _a.sent();
178
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
179
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
194
180
  }
195
181
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
196
182
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -215,10 +201,9 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
215
201
  getTenantBankAccount: function (code, authorization, expand, options) {
216
202
  if (options === void 0) { options = {}; }
217
203
  return __awaiter(_this, void 0, void 0, function () {
218
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
219
- var _a;
220
- return __generator(this, function (_b) {
221
- switch (_b.label) {
204
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
205
+ return __generator(this, function (_a) {
206
+ switch (_a.label) {
222
207
  case 0:
223
208
  // verify required parameter 'code' is not null or undefined
224
209
  (0, common_1.assertParamExists)('getTenantBankAccount', 'code', code);
@@ -238,15 +223,12 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
238
223
  case 1:
239
224
  // authentication bearer required
240
225
  // http bearer authentication required
241
- _b.sent();
226
+ _a.sent();
242
227
  if (expand !== undefined) {
243
228
  localVarQueryParameter['expand'] = expand;
244
229
  }
245
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
246
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
247
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
248
- if (authorizationValue || authorizationKeepEmpty) {
249
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
230
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
231
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
250
232
  }
251
233
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
252
234
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -276,10 +258,9 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
276
258
  listTenantBankAccounts: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
277
259
  if (options === void 0) { options = {}; }
278
260
  return __awaiter(_this, void 0, void 0, function () {
279
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
280
- var _a;
281
- return __generator(this, function (_b) {
282
- switch (_b.label) {
261
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
262
+ return __generator(this, function (_a) {
263
+ switch (_a.label) {
283
264
  case 0:
284
265
  localVarPath = "/paymentservice/v1/tenant/bank-accounts";
285
266
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -296,7 +277,7 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
296
277
  case 1:
297
278
  // authentication bearer required
298
279
  // http bearer authentication required
299
- _b.sent();
280
+ _a.sent();
300
281
  if (pageSize !== undefined) {
301
282
  localVarQueryParameter['pageSize'] = pageSize;
302
283
  }
@@ -318,11 +299,8 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
318
299
  if (filters !== undefined) {
319
300
  localVarQueryParameter['filters'] = filters;
320
301
  }
321
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
322
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
323
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
324
- if (authorizationValue || authorizationKeepEmpty) {
325
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
302
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
303
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
326
304
  }
327
305
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
328
306
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -347,10 +325,9 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
347
325
  updateTenantBankAccount: function (code, updateTenantBankAccountRestRequestDto, authorization, options) {
348
326
  if (options === void 0) { options = {}; }
349
327
  return __awaiter(_this, void 0, void 0, function () {
350
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
351
- var _a;
352
- return __generator(this, function (_b) {
353
- switch (_b.label) {
328
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
329
+ return __generator(this, function (_a) {
330
+ switch (_a.label) {
354
331
  case 0:
355
332
  // verify required parameter 'code' is not null or undefined
356
333
  (0, common_1.assertParamExists)('updateTenantBankAccount', 'code', code);
@@ -368,19 +345,13 @@ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
368
345
  localVarQueryParameter = {};
369
346
  // authentication bearer required
370
347
  // http bearer authentication required
371
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
372
- // Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
373
- // no token is stored, so a refused call still refreshes; a session call (account header) sends none.
374
- ];
348
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
375
349
  case 1:
376
350
  // authentication bearer required
377
351
  // http bearer authentication required
378
- _b.sent();
379
- authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
380
- authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
381
- authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
382
- if (authorizationValue || authorizationKeepEmpty) {
383
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
352
+ _a.sent();
353
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
354
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
384
355
  }
385
356
  localVarHeaderParameter['Content-Type'] = 'application/json';
386
357
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -615,7 +586,7 @@ var TenantBankAccountApi = /** @class */ (function (_super) {
615
586
  */
616
587
  TenantBankAccountApi.prototype.createTenantBankAccount = function (requestParameters, options) {
617
588
  var _this = this;
618
- return (0, exports.TenantBankAccountApiFp)(this.configuration).createTenantBankAccount(requestParameters.createTenantBankAccountRequestDto, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
589
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).createTenantBankAccount(requestParameters.createTenantBankAccountRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
619
590
  };
620
591
  /**
621
592
  * Deletes a tenant bank account by code
@@ -627,7 +598,7 @@ var TenantBankAccountApi = /** @class */ (function (_super) {
627
598
  */
628
599
  TenantBankAccountApi.prototype.deleteTenantBankAccount = function (requestParameters, options) {
629
600
  var _this = this;
630
- return (0, exports.TenantBankAccountApiFp)(this.configuration).deleteTenantBankAccount(requestParameters.code, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
601
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).deleteTenantBankAccount(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
631
602
  };
632
603
  /**
633
604
  * Retrieves the details of the tenant bank account that was previously created. Supply the unique tenant bank account code that was returned when you created it and Emil Api will return the corresponding tenant bank account information.
@@ -639,7 +610,7 @@ var TenantBankAccountApi = /** @class */ (function (_super) {
639
610
  */
640
611
  TenantBankAccountApi.prototype.getTenantBankAccount = function (requestParameters, options) {
641
612
  var _this = this;
642
- return (0, exports.TenantBankAccountApiFp)(this.configuration).getTenantBankAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
613
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).getTenantBankAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
643
614
  };
644
615
  /**
645
616
  * Returns a list of tenant bank accounts you have previously created. The tenant bank accounts are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
@@ -652,7 +623,7 @@ var TenantBankAccountApi = /** @class */ (function (_super) {
652
623
  TenantBankAccountApi.prototype.listTenantBankAccounts = function (requestParameters, options) {
653
624
  var _this = this;
654
625
  if (requestParameters === void 0) { requestParameters = {}; }
655
- return (0, exports.TenantBankAccountApiFp)(this.configuration).listTenantBankAccounts(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
626
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).listTenantBankAccounts(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
656
627
  };
657
628
  /**
658
629
  * Update a tenant bank account by code
@@ -664,7 +635,7 @@ var TenantBankAccountApi = /** @class */ (function (_super) {
664
635
  */
665
636
  TenantBankAccountApi.prototype.updateTenantBankAccount = function (requestParameters, options) {
666
637
  var _this = this;
667
- return (0, exports.TenantBankAccountApiFp)(this.configuration).updateTenantBankAccount(requestParameters.code, requestParameters.updateTenantBankAccountRestRequestDto, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
638
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).updateTenantBankAccount(requestParameters.code, requestParameters.updateTenantBankAccountRestRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
668
639
  };
669
640
  return TenantBankAccountApi;
670
641
  }(base_1.BaseAPI));
@@ -164,7 +164,7 @@ export declare class WebhooksApi extends BaseAPI {
164
164
  * @throws {RequiredError}
165
165
  * @memberof WebhooksApi
166
166
  */
167
- postWebhook(requestParameters: WebhooksApiPostWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}, any>>;
167
+ postWebhook(requestParameters: WebhooksApiPostWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
168
168
  /**
169
169
  * This will processes the webhook from external payment service provider. **Required Permissions** none
170
170
  * @summary Handle the webhook from PSP
@@ -173,5 +173,5 @@ export declare class WebhooksApi extends BaseAPI {
173
173
  * @throws {RequiredError}
174
174
  * @memberof WebhooksApi
175
175
  */
176
- postWebhookWithProductSlug(requestParameters: WebhooksApiPostWebhookWithProductSlugRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}, any>>;
176
+ postWebhookWithProductSlug(requestParameters: WebhooksApiPostWebhookWithProductSlugRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
177
177
  }