@emilgroup/payment-sdk-node 1.8.2 → 1.12.1

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 (91) hide show
  1. package/.openapi-generator/FILES +17 -2
  2. package/README.md +2 -2
  3. package/api/bank-accounts-api.ts +4 -4
  4. package/api/bank-transaction-api.ts +569 -0
  5. package/api/payment-methods-api.ts +4 -4
  6. package/api/payment-reminders-api.ts +12 -10
  7. package/api/payments-api.ts +4 -4
  8. package/api/refunds-api.ts +464 -0
  9. package/api/tenant-bank-account-api.ts +655 -0
  10. package/api.ts +6 -2
  11. package/dist/api/bank-accounts-api.d.ts +4 -4
  12. package/dist/api/bank-accounts-api.js +3 -3
  13. package/dist/api/bank-transaction-api.d.ts +318 -0
  14. package/dist/api/bank-transaction-api.js +543 -0
  15. package/dist/api/payment-methods-api.d.ts +4 -4
  16. package/dist/api/payment-methods-api.js +3 -3
  17. package/dist/api/payment-reminders-api.d.ts +12 -11
  18. package/dist/api/payment-reminders-api.js +7 -7
  19. package/dist/api/payments-api.d.ts +4 -4
  20. package/dist/api/payments-api.js +3 -3
  21. package/dist/api/refunds-api.d.ts +260 -0
  22. package/dist/api/refunds-api.js +445 -0
  23. package/dist/api/tenant-bank-account-api.d.ts +361 -0
  24. package/dist/api/tenant-bank-account-api.js +620 -0
  25. package/dist/api.d.ts +3 -1
  26. package/dist/api.js +3 -1
  27. package/dist/models/bank-transaction-response-class.d.ts +122 -0
  28. package/dist/models/create-payment-reminder-request-dto.d.ts +2 -0
  29. package/dist/models/create-payment-reminder-request-dto.js +3 -1
  30. package/dist/models/create-payment-request-dto.d.ts +3 -3
  31. package/dist/models/create-refund-request-dto.d.ts +24 -0
  32. package/dist/models/create-refund-request-dto.js +15 -0
  33. package/dist/models/create-refund-response-class.d.ts +25 -0
  34. package/dist/models/create-refund-response-class.js +15 -0
  35. package/dist/models/create-tenant-bank-account-request-dto.d.ts +42 -0
  36. package/dist/models/create-tenant-bank-account-request-dto.js +15 -0
  37. package/dist/models/deactivate-payment-reminder-response-class.d.ts +25 -0
  38. package/dist/models/deactivate-payment-reminder-response-class.js +15 -0
  39. package/dist/models/get-bank-transactions-response-class.d.ts +25 -0
  40. package/dist/models/get-bank-transactions-response-class.js +15 -0
  41. package/dist/models/{validate-pspconfig-response-class.d.ts → get-refund-response-class.d.ts} +7 -6
  42. package/dist/models/get-refund-response-class.js +15 -0
  43. package/dist/models/get-tenant-bank-account-response-class.d.ts +25 -0
  44. package/dist/models/get-tenant-bank-account-response-class.js +15 -0
  45. package/dist/models/index.d.ts +14 -1
  46. package/dist/models/index.js +14 -1
  47. package/dist/models/inline-response200.d.ts +6 -6
  48. package/dist/models/inline-response503.d.ts +6 -6
  49. package/dist/models/link-bank-transaction-request-dto.d.ts +30 -0
  50. package/dist/models/link-bank-transaction-request-dto.js +15 -0
  51. package/dist/models/list-bank-transactions-response-class.d.ts +31 -0
  52. package/dist/models/list-bank-transactions-response-class.js +15 -0
  53. package/dist/models/list-refunds-response-class.d.ts +31 -0
  54. package/dist/models/list-refunds-response-class.js +15 -0
  55. package/dist/models/payment-class.d.ts +1 -1
  56. package/dist/models/payment-method-class.d.ts +8 -2
  57. package/dist/models/payment-reminder-class.d.ts +4 -0
  58. package/dist/models/payment-reminder-class.js +6 -2
  59. package/dist/models/refund-class.d.ts +104 -0
  60. package/dist/models/refund-class.js +28 -0
  61. package/dist/models/tenant-bank-account-response-class.d.ts +66 -0
  62. package/dist/models/tenant-bank-account-response-class.js +15 -0
  63. package/dist/models/update-tenant-bank-account-rest-request-dto.d.ts +36 -0
  64. package/dist/models/update-tenant-bank-account-rest-request-dto.js +15 -0
  65. package/models/bank-transaction-response-class.ts +128 -0
  66. package/models/create-payment-reminder-request-dto.ts +3 -1
  67. package/models/create-payment-request-dto.ts +3 -3
  68. package/models/create-refund-request-dto.ts +30 -0
  69. package/models/create-refund-response-class.ts +31 -0
  70. package/models/create-tenant-bank-account-request-dto.ts +48 -0
  71. package/models/deactivate-payment-reminder-response-class.ts +31 -0
  72. package/models/get-bank-transactions-response-class.ts +31 -0
  73. package/models/{validate-pspconfig-response-class.ts → get-refund-response-class.ts} +7 -6
  74. package/models/get-tenant-bank-account-response-class.ts +31 -0
  75. package/models/index.ts +14 -1
  76. package/models/inline-response200.ts +6 -6
  77. package/models/inline-response503.ts +6 -6
  78. package/models/link-bank-transaction-request-dto.ts +36 -0
  79. package/models/list-bank-transactions-response-class.ts +37 -0
  80. package/models/list-refunds-response-class.ts +37 -0
  81. package/models/payment-class.ts +1 -1
  82. package/models/payment-method-class.ts +8 -2
  83. package/models/payment-reminder-class.ts +6 -2
  84. package/models/refund-class.ts +114 -0
  85. package/models/tenant-bank-account-response-class.ts +72 -0
  86. package/models/update-tenant-bank-account-rest-request-dto.ts +42 -0
  87. package/package.json +1 -1
  88. package/api/payment-service-providers-api.ts +0 -165
  89. package/dist/api/payment-service-providers-api.d.ts +0 -93
  90. package/dist/api/payment-service-providers-api.js +0 -224
  91. /package/dist/models/{validate-pspconfig-response-class.js → bank-transaction-response-class.js} +0 -0
@@ -0,0 +1,620 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Emil Payment Service
6
+ * This service directly communicates with the various Payment Service Providers (PSPs) in order to charge or refund customers. This service will automatically connect to the PSP linked in your admin configuration; meaning if you configured Stripe, it will automatically create a payment on Stripe when you create it in Emil.
7
+ *
8
+ * The version of the OpenAPI document: 1.0
9
+ * Contact: kontakt@emil.de
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ var __extends = (this && this.__extends) || (function () {
16
+ var extendStatics = function (d, b) {
17
+ extendStatics = Object.setPrototypeOf ||
18
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
19
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
20
+ return extendStatics(d, b);
21
+ };
22
+ return function (d, b) {
23
+ if (typeof b !== "function" && b !== null)
24
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
25
+ extendStatics(d, b);
26
+ function __() { this.constructor = d; }
27
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
28
+ };
29
+ })();
30
+ var __assign = (this && this.__assign) || function () {
31
+ __assign = Object.assign || function(t) {
32
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
33
+ s = arguments[i];
34
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
35
+ t[p] = s[p];
36
+ }
37
+ return t;
38
+ };
39
+ return __assign.apply(this, arguments);
40
+ };
41
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
42
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
43
+ return new (P || (P = Promise))(function (resolve, reject) {
44
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
45
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
46
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
47
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
48
+ });
49
+ };
50
+ var __generator = (this && this.__generator) || function (thisArg, body) {
51
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
52
+ return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
53
+ function verb(n) { return function (v) { return step([n, v]); }; }
54
+ function step(op) {
55
+ if (f) throw new TypeError("Generator is already executing.");
56
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
57
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
58
+ if (y = 0, t) op = [op[0] & 2, t.value];
59
+ switch (op[0]) {
60
+ case 0: case 1: t = op; break;
61
+ case 4: _.label++; return { value: op[1], done: false };
62
+ case 5: _.label++; y = op[1]; op = [0]; continue;
63
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
64
+ default:
65
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
66
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
67
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
68
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
69
+ if (t[2]) _.ops.pop();
70
+ _.trys.pop(); continue;
71
+ }
72
+ op = body.call(thisArg, _);
73
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
74
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
75
+ }
76
+ };
77
+ var __importDefault = (this && this.__importDefault) || function (mod) {
78
+ return (mod && mod.__esModule) ? mod : { "default": mod };
79
+ };
80
+ Object.defineProperty(exports, "__esModule", { value: true });
81
+ exports.TenantBankAccountApi = exports.TenantBankAccountApiFactory = exports.TenantBankAccountApiFp = exports.TenantBankAccountApiAxiosParamCreator = void 0;
82
+ var axios_1 = __importDefault(require("axios"));
83
+ // Some imports not used depending on template conditions
84
+ // @ts-ignore
85
+ var common_1 = require("../common");
86
+ // @ts-ignore
87
+ var base_1 = require("../base");
88
+ // URLSearchParams not necessarily used
89
+ // @ts-ignore
90
+ var url_1 = require("url");
91
+ var FormData = require('form-data');
92
+ /**
93
+ * TenantBankAccountApi - axios parameter creator
94
+ * @export
95
+ */
96
+ var TenantBankAccountApiAxiosParamCreator = function (configuration) {
97
+ var _this = this;
98
+ return {
99
+ /**
100
+ *
101
+ * @param {CreateTenantBankAccountRequestDto} createTenantBankAccountRequestDto
102
+ * @param {string} [authorization] Bearer Token
103
+ * @param {*} [options] Override http request option.
104
+ * @throws {RequiredError}
105
+ */
106
+ createTenantBankAccount: function (createTenantBankAccountRequestDto, authorization, options) {
107
+ if (options === void 0) { options = {}; }
108
+ return __awaiter(_this, void 0, void 0, function () {
109
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
110
+ return __generator(this, function (_a) {
111
+ switch (_a.label) {
112
+ case 0:
113
+ // verify required parameter 'createTenantBankAccountRequestDto' is not null or undefined
114
+ (0, common_1.assertParamExists)('createTenantBankAccount', 'createTenantBankAccountRequestDto', createTenantBankAccountRequestDto);
115
+ localVarPath = "/paymentservice/v1/tenant/bank-accounts";
116
+ localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
117
+ if (configuration) {
118
+ baseOptions = configuration.baseOptions;
119
+ baseAccessToken = configuration.accessToken;
120
+ }
121
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
122
+ localVarHeaderParameter = {};
123
+ localVarQueryParameter = {};
124
+ // authentication bearer required
125
+ // http bearer authentication required
126
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
127
+ case 1:
128
+ // authentication bearer required
129
+ // http bearer authentication required
130
+ _a.sent();
131
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
132
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
133
+ }
134
+ localVarHeaderParameter['Content-Type'] = 'application/json';
135
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
136
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
137
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
138
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createTenantBankAccountRequestDto, localVarRequestOptions, configuration);
139
+ return [2 /*return*/, {
140
+ url: (0, common_1.toPathString)(localVarUrlObj),
141
+ options: localVarRequestOptions,
142
+ }];
143
+ }
144
+ });
145
+ });
146
+ },
147
+ /**
148
+ *
149
+ * @param {string} code Unique identifier for the object.
150
+ * @param {string} [authorization] Bearer Token
151
+ * @param {*} [options] Override http request option.
152
+ * @throws {RequiredError}
153
+ */
154
+ deleteTenantBankAccount: function (code, authorization, options) {
155
+ if (options === void 0) { options = {}; }
156
+ return __awaiter(_this, void 0, void 0, function () {
157
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
158
+ return __generator(this, function (_a) {
159
+ switch (_a.label) {
160
+ case 0:
161
+ // verify required parameter 'code' is not null or undefined
162
+ (0, common_1.assertParamExists)('deleteTenantBankAccount', 'code', code);
163
+ localVarPath = "/paymentservice/v1/tenant/bank-accounts/{code}"
164
+ .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
165
+ localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
166
+ if (configuration) {
167
+ baseOptions = configuration.baseOptions;
168
+ baseAccessToken = configuration.accessToken;
169
+ }
170
+ localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
171
+ localVarHeaderParameter = {};
172
+ localVarQueryParameter = {};
173
+ // authentication bearer required
174
+ // http bearer authentication required
175
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
176
+ case 1:
177
+ // authentication bearer required
178
+ // http bearer authentication required
179
+ _a.sent();
180
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
181
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
182
+ }
183
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
184
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
185
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
186
+ return [2 /*return*/, {
187
+ url: (0, common_1.toPathString)(localVarUrlObj),
188
+ options: localVarRequestOptions,
189
+ }];
190
+ }
191
+ });
192
+ });
193
+ },
194
+ /**
195
+ *
196
+ * @param {string} code Unique identifier for the object.
197
+ * @param {string} [authorization] Bearer Token
198
+ * @param {string} [expand] Expand the response with additional entities
199
+ * @param {*} [options] Override http request option.
200
+ * @throws {RequiredError}
201
+ */
202
+ getTenantBankAccount: function (code, authorization, expand, options) {
203
+ if (options === void 0) { options = {}; }
204
+ return __awaiter(_this, void 0, void 0, function () {
205
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
206
+ return __generator(this, function (_a) {
207
+ switch (_a.label) {
208
+ case 0:
209
+ // verify required parameter 'code' is not null or undefined
210
+ (0, common_1.assertParamExists)('getTenantBankAccount', 'code', code);
211
+ localVarPath = "/paymentservice/v1/tenant/bank-accounts/{code}"
212
+ .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
213
+ localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
214
+ if (configuration) {
215
+ baseOptions = configuration.baseOptions;
216
+ baseAccessToken = configuration.accessToken;
217
+ }
218
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
219
+ localVarHeaderParameter = {};
220
+ localVarQueryParameter = {};
221
+ // authentication bearer required
222
+ // http bearer authentication required
223
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
224
+ case 1:
225
+ // authentication bearer required
226
+ // http bearer authentication required
227
+ _a.sent();
228
+ if (expand !== undefined) {
229
+ localVarQueryParameter['expand'] = expand;
230
+ }
231
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
232
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
233
+ }
234
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
235
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
236
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
237
+ return [2 /*return*/, {
238
+ url: (0, common_1.toPathString)(localVarUrlObj),
239
+ options: localVarRequestOptions,
240
+ }];
241
+ }
242
+ });
243
+ });
244
+ },
245
+ /**
246
+ *
247
+ * @param {string} [authorization] Bearer Token
248
+ * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
249
+ * @param {any} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
250
+ * @param {any} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
251
+ * @param {any} [search] Search the list by any field. For instance, if you want to search by code add code&#x3D;xxx in order to fetch the result.
252
+ * @param {any} [order] The order parameter determines how the results should be sorted according to a specified field. It functions similarly to an SQL ORDER BY. Sorting can be performed in either ascending (ASC) or descending (DESC) order. Default: ASC.
253
+ * @param {string} [expand] Expand the response with additional entities
254
+ * @param {*} [options] Override http request option.
255
+ * @throws {RequiredError}
256
+ */
257
+ listTenantBankAccounts: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
258
+ if (options === void 0) { options = {}; }
259
+ return __awaiter(_this, void 0, void 0, function () {
260
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
261
+ return __generator(this, function (_a) {
262
+ switch (_a.label) {
263
+ case 0:
264
+ localVarPath = "/paymentservice/v1/tenant/bank-accounts";
265
+ localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
266
+ if (configuration) {
267
+ baseOptions = configuration.baseOptions;
268
+ baseAccessToken = configuration.accessToken;
269
+ }
270
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
271
+ localVarHeaderParameter = {};
272
+ localVarQueryParameter = {};
273
+ // authentication bearer required
274
+ // http bearer authentication required
275
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
276
+ case 1:
277
+ // authentication bearer required
278
+ // http bearer authentication required
279
+ _a.sent();
280
+ if (pageSize !== undefined) {
281
+ localVarQueryParameter['pageSize'] = pageSize;
282
+ }
283
+ if (pageToken !== undefined) {
284
+ localVarQueryParameter['pageToken'] = pageToken;
285
+ }
286
+ if (filter !== undefined) {
287
+ localVarQueryParameter['filter'] = filter;
288
+ }
289
+ if (search !== undefined) {
290
+ localVarQueryParameter['search'] = search;
291
+ }
292
+ if (order !== undefined) {
293
+ localVarQueryParameter['order'] = order;
294
+ }
295
+ if (expand !== undefined) {
296
+ localVarQueryParameter['expand'] = expand;
297
+ }
298
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
299
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
300
+ }
301
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
302
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
303
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
304
+ return [2 /*return*/, {
305
+ url: (0, common_1.toPathString)(localVarUrlObj),
306
+ options: localVarRequestOptions,
307
+ }];
308
+ }
309
+ });
310
+ });
311
+ },
312
+ /**
313
+ *
314
+ * @param {string} code Unique identifier for the object.
315
+ * @param {UpdateTenantBankAccountRestRequestDto} updateTenantBankAccountRestRequestDto
316
+ * @param {string} [authorization] Bearer Token
317
+ * @param {*} [options] Override http request option.
318
+ * @throws {RequiredError}
319
+ */
320
+ updateTenantBankAccount: function (code, updateTenantBankAccountRestRequestDto, authorization, options) {
321
+ if (options === void 0) { options = {}; }
322
+ return __awaiter(_this, void 0, void 0, function () {
323
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
324
+ return __generator(this, function (_a) {
325
+ switch (_a.label) {
326
+ case 0:
327
+ // verify required parameter 'code' is not null or undefined
328
+ (0, common_1.assertParamExists)('updateTenantBankAccount', 'code', code);
329
+ // verify required parameter 'updateTenantBankAccountRestRequestDto' is not null or undefined
330
+ (0, common_1.assertParamExists)('updateTenantBankAccount', 'updateTenantBankAccountRestRequestDto', updateTenantBankAccountRestRequestDto);
331
+ localVarPath = "/paymentservice/v1/tenant/bank-accounts/{code}"
332
+ .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
333
+ localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
334
+ if (configuration) {
335
+ baseOptions = configuration.baseOptions;
336
+ baseAccessToken = configuration.accessToken;
337
+ }
338
+ localVarRequestOptions = __assign(__assign({ method: 'PUT' }, baseOptions), options);
339
+ localVarHeaderParameter = {};
340
+ localVarQueryParameter = {};
341
+ // authentication bearer required
342
+ // http bearer authentication required
343
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
344
+ case 1:
345
+ // authentication bearer required
346
+ // http bearer authentication required
347
+ _a.sent();
348
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
349
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
350
+ }
351
+ localVarHeaderParameter['Content-Type'] = 'application/json';
352
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
353
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
354
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
355
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(updateTenantBankAccountRestRequestDto, localVarRequestOptions, configuration);
356
+ return [2 /*return*/, {
357
+ url: (0, common_1.toPathString)(localVarUrlObj),
358
+ options: localVarRequestOptions,
359
+ }];
360
+ }
361
+ });
362
+ });
363
+ },
364
+ };
365
+ };
366
+ exports.TenantBankAccountApiAxiosParamCreator = TenantBankAccountApiAxiosParamCreator;
367
+ /**
368
+ * TenantBankAccountApi - functional programming interface
369
+ * @export
370
+ */
371
+ var TenantBankAccountApiFp = function (configuration) {
372
+ var localVarAxiosParamCreator = (0, exports.TenantBankAccountApiAxiosParamCreator)(configuration);
373
+ return {
374
+ /**
375
+ *
376
+ * @param {CreateTenantBankAccountRequestDto} createTenantBankAccountRequestDto
377
+ * @param {string} [authorization] Bearer Token
378
+ * @param {*} [options] Override http request option.
379
+ * @throws {RequiredError}
380
+ */
381
+ createTenantBankAccount: function (createTenantBankAccountRequestDto, authorization, options) {
382
+ return __awaiter(this, void 0, void 0, function () {
383
+ var localVarAxiosArgs;
384
+ return __generator(this, function (_a) {
385
+ switch (_a.label) {
386
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.createTenantBankAccount(createTenantBankAccountRequestDto, authorization, options)];
387
+ case 1:
388
+ localVarAxiosArgs = _a.sent();
389
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
390
+ }
391
+ });
392
+ });
393
+ },
394
+ /**
395
+ *
396
+ * @param {string} code Unique identifier for the object.
397
+ * @param {string} [authorization] Bearer Token
398
+ * @param {*} [options] Override http request option.
399
+ * @throws {RequiredError}
400
+ */
401
+ deleteTenantBankAccount: function (code, authorization, options) {
402
+ return __awaiter(this, void 0, void 0, function () {
403
+ var localVarAxiosArgs;
404
+ return __generator(this, function (_a) {
405
+ switch (_a.label) {
406
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteTenantBankAccount(code, authorization, options)];
407
+ case 1:
408
+ localVarAxiosArgs = _a.sent();
409
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
410
+ }
411
+ });
412
+ });
413
+ },
414
+ /**
415
+ *
416
+ * @param {string} code Unique identifier for the object.
417
+ * @param {string} [authorization] Bearer Token
418
+ * @param {string} [expand] Expand the response with additional entities
419
+ * @param {*} [options] Override http request option.
420
+ * @throws {RequiredError}
421
+ */
422
+ getTenantBankAccount: function (code, authorization, expand, options) {
423
+ return __awaiter(this, void 0, void 0, function () {
424
+ var localVarAxiosArgs;
425
+ return __generator(this, function (_a) {
426
+ switch (_a.label) {
427
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.getTenantBankAccount(code, authorization, expand, options)];
428
+ case 1:
429
+ localVarAxiosArgs = _a.sent();
430
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
431
+ }
432
+ });
433
+ });
434
+ },
435
+ /**
436
+ *
437
+ * @param {string} [authorization] Bearer Token
438
+ * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
439
+ * @param {any} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
440
+ * @param {any} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
441
+ * @param {any} [search] Search the list by any field. For instance, if you want to search by code add code&#x3D;xxx in order to fetch the result.
442
+ * @param {any} [order] The order parameter determines how the results should be sorted according to a specified field. It functions similarly to an SQL ORDER BY. Sorting can be performed in either ascending (ASC) or descending (DESC) order. Default: ASC.
443
+ * @param {string} [expand] Expand the response with additional entities
444
+ * @param {*} [options] Override http request option.
445
+ * @throws {RequiredError}
446
+ */
447
+ listTenantBankAccounts: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
448
+ return __awaiter(this, void 0, void 0, function () {
449
+ var localVarAxiosArgs;
450
+ return __generator(this, function (_a) {
451
+ switch (_a.label) {
452
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.listTenantBankAccounts(authorization, pageSize, pageToken, filter, search, order, expand, options)];
453
+ case 1:
454
+ localVarAxiosArgs = _a.sent();
455
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
456
+ }
457
+ });
458
+ });
459
+ },
460
+ /**
461
+ *
462
+ * @param {string} code Unique identifier for the object.
463
+ * @param {UpdateTenantBankAccountRestRequestDto} updateTenantBankAccountRestRequestDto
464
+ * @param {string} [authorization] Bearer Token
465
+ * @param {*} [options] Override http request option.
466
+ * @throws {RequiredError}
467
+ */
468
+ updateTenantBankAccount: function (code, updateTenantBankAccountRestRequestDto, authorization, options) {
469
+ return __awaiter(this, void 0, void 0, function () {
470
+ var localVarAxiosArgs;
471
+ return __generator(this, function (_a) {
472
+ switch (_a.label) {
473
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.updateTenantBankAccount(code, updateTenantBankAccountRestRequestDto, authorization, options)];
474
+ case 1:
475
+ localVarAxiosArgs = _a.sent();
476
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
477
+ }
478
+ });
479
+ });
480
+ },
481
+ };
482
+ };
483
+ exports.TenantBankAccountApiFp = TenantBankAccountApiFp;
484
+ /**
485
+ * TenantBankAccountApi - factory interface
486
+ * @export
487
+ */
488
+ var TenantBankAccountApiFactory = function (configuration, basePath, axios) {
489
+ var localVarFp = (0, exports.TenantBankAccountApiFp)(configuration);
490
+ return {
491
+ /**
492
+ *
493
+ * @param {CreateTenantBankAccountRequestDto} createTenantBankAccountRequestDto
494
+ * @param {string} [authorization] Bearer Token
495
+ * @param {*} [options] Override http request option.
496
+ * @throws {RequiredError}
497
+ */
498
+ createTenantBankAccount: function (createTenantBankAccountRequestDto, authorization, options) {
499
+ return localVarFp.createTenantBankAccount(createTenantBankAccountRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
500
+ },
501
+ /**
502
+ *
503
+ * @param {string} code Unique identifier for the object.
504
+ * @param {string} [authorization] Bearer Token
505
+ * @param {*} [options] Override http request option.
506
+ * @throws {RequiredError}
507
+ */
508
+ deleteTenantBankAccount: function (code, authorization, options) {
509
+ return localVarFp.deleteTenantBankAccount(code, authorization, options).then(function (request) { return request(axios, basePath); });
510
+ },
511
+ /**
512
+ *
513
+ * @param {string} code Unique identifier for the object.
514
+ * @param {string} [authorization] Bearer Token
515
+ * @param {string} [expand] Expand the response with additional entities
516
+ * @param {*} [options] Override http request option.
517
+ * @throws {RequiredError}
518
+ */
519
+ getTenantBankAccount: function (code, authorization, expand, options) {
520
+ return localVarFp.getTenantBankAccount(code, authorization, expand, options).then(function (request) { return request(axios, basePath); });
521
+ },
522
+ /**
523
+ *
524
+ * @param {string} [authorization] Bearer Token
525
+ * @param {any} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
526
+ * @param {any} [pageToken] A cursor for use in pagination. pageToken is an ID that defines your place in the list. For instance, if you make a list request and receive 100 objects and pageToken&#x3D;1, your subsequent call can include pageToken&#x3D;2 in order to fetch the next page of the list.
527
+ * @param {any} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.
528
+ * @param {any} [search] Search the list by any field. For instance, if you want to search by code add code&#x3D;xxx in order to fetch the result.
529
+ * @param {any} [order] The order parameter determines how the results should be sorted according to a specified field. It functions similarly to an SQL ORDER BY. Sorting can be performed in either ascending (ASC) or descending (DESC) order. Default: ASC.
530
+ * @param {string} [expand] Expand the response with additional entities
531
+ * @param {*} [options] Override http request option.
532
+ * @throws {RequiredError}
533
+ */
534
+ listTenantBankAccounts: function (authorization, pageSize, pageToken, filter, search, order, expand, options) {
535
+ return localVarFp.listTenantBankAccounts(authorization, pageSize, pageToken, filter, search, order, expand, options).then(function (request) { return request(axios, basePath); });
536
+ },
537
+ /**
538
+ *
539
+ * @param {string} code Unique identifier for the object.
540
+ * @param {UpdateTenantBankAccountRestRequestDto} updateTenantBankAccountRestRequestDto
541
+ * @param {string} [authorization] Bearer Token
542
+ * @param {*} [options] Override http request option.
543
+ * @throws {RequiredError}
544
+ */
545
+ updateTenantBankAccount: function (code, updateTenantBankAccountRestRequestDto, authorization, options) {
546
+ return localVarFp.updateTenantBankAccount(code, updateTenantBankAccountRestRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
547
+ },
548
+ };
549
+ };
550
+ exports.TenantBankAccountApiFactory = TenantBankAccountApiFactory;
551
+ /**
552
+ * TenantBankAccountApi - object-oriented interface
553
+ * @export
554
+ * @class TenantBankAccountApi
555
+ * @extends {BaseAPI}
556
+ */
557
+ var TenantBankAccountApi = /** @class */ (function (_super) {
558
+ __extends(TenantBankAccountApi, _super);
559
+ function TenantBankAccountApi() {
560
+ return _super !== null && _super.apply(this, arguments) || this;
561
+ }
562
+ /**
563
+ *
564
+ * @param {TenantBankAccountApiCreateTenantBankAccountRequest} requestParameters Request parameters.
565
+ * @param {*} [options] Override http request option.
566
+ * @throws {RequiredError}
567
+ * @memberof TenantBankAccountApi
568
+ */
569
+ TenantBankAccountApi.prototype.createTenantBankAccount = function (requestParameters, options) {
570
+ var _this = this;
571
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).createTenantBankAccount(requestParameters.createTenantBankAccountRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
572
+ };
573
+ /**
574
+ *
575
+ * @param {TenantBankAccountApiDeleteTenantBankAccountRequest} requestParameters Request parameters.
576
+ * @param {*} [options] Override http request option.
577
+ * @throws {RequiredError}
578
+ * @memberof TenantBankAccountApi
579
+ */
580
+ TenantBankAccountApi.prototype.deleteTenantBankAccount = function (requestParameters, options) {
581
+ var _this = this;
582
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).deleteTenantBankAccount(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
583
+ };
584
+ /**
585
+ *
586
+ * @param {TenantBankAccountApiGetTenantBankAccountRequest} requestParameters Request parameters.
587
+ * @param {*} [options] Override http request option.
588
+ * @throws {RequiredError}
589
+ * @memberof TenantBankAccountApi
590
+ */
591
+ TenantBankAccountApi.prototype.getTenantBankAccount = function (requestParameters, options) {
592
+ var _this = this;
593
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).getTenantBankAccount(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
594
+ };
595
+ /**
596
+ *
597
+ * @param {TenantBankAccountApiListTenantBankAccountsRequest} requestParameters Request parameters.
598
+ * @param {*} [options] Override http request option.
599
+ * @throws {RequiredError}
600
+ * @memberof TenantBankAccountApi
601
+ */
602
+ TenantBankAccountApi.prototype.listTenantBankAccounts = function (requestParameters, options) {
603
+ var _this = this;
604
+ if (requestParameters === void 0) { requestParameters = {}; }
605
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).listTenantBankAccounts(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
606
+ };
607
+ /**
608
+ *
609
+ * @param {TenantBankAccountApiUpdateTenantBankAccountRequest} requestParameters Request parameters.
610
+ * @param {*} [options] Override http request option.
611
+ * @throws {RequiredError}
612
+ * @memberof TenantBankAccountApi
613
+ */
614
+ TenantBankAccountApi.prototype.updateTenantBankAccount = function (requestParameters, options) {
615
+ var _this = this;
616
+ return (0, exports.TenantBankAccountApiFp)(this.configuration).updateTenantBankAccount(requestParameters.code, requestParameters.updateTenantBankAccountRestRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
617
+ };
618
+ return TenantBankAccountApi;
619
+ }(base_1.BaseAPI));
620
+ exports.TenantBankAccountApi = TenantBankAccountApi;
package/dist/api.d.ts CHANGED
@@ -10,10 +10,12 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  export * from './api/bank-accounts-api';
13
+ export * from './api/bank-transaction-api';
13
14
  export * from './api/default-api';
14
15
  export * from './api/payment-methods-api';
15
16
  export * from './api/payment-reminders-api';
16
- export * from './api/payment-service-providers-api';
17
17
  export * from './api/payment-setup-api';
18
18
  export * from './api/payments-api';
19
+ export * from './api/refunds-api';
20
+ export * from './api/tenant-bank-account-api';
19
21
  export * from './api/webhooks-api';
package/dist/api.js CHANGED
@@ -28,10 +28,12 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
28
28
  };
29
29
  Object.defineProperty(exports, "__esModule", { value: true });
30
30
  __exportStar(require("./api/bank-accounts-api"), exports);
31
+ __exportStar(require("./api/bank-transaction-api"), exports);
31
32
  __exportStar(require("./api/default-api"), exports);
32
33
  __exportStar(require("./api/payment-methods-api"), exports);
33
34
  __exportStar(require("./api/payment-reminders-api"), exports);
34
- __exportStar(require("./api/payment-service-providers-api"), exports);
35
35
  __exportStar(require("./api/payment-setup-api"), exports);
36
36
  __exportStar(require("./api/payments-api"), exports);
37
+ __exportStar(require("./api/refunds-api"), exports);
38
+ __exportStar(require("./api/tenant-bank-account-api"), exports);
37
39
  __exportStar(require("./api/webhooks-api"), exports);