@emilgroup/payment-sdk 1.14.1-beta.57 → 1.14.1-beta.59

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 (31) hide show
  1. package/.openapi-generator/FILES +6 -0
  2. package/README.md +2 -2
  3. package/api/payout-methods-api.ts +672 -0
  4. package/api.ts +2 -0
  5. package/dist/api/payout-methods-api.d.ts +382 -0
  6. package/dist/api/payout-methods-api.js +635 -0
  7. package/dist/api.d.ts +1 -0
  8. package/dist/api.js +1 -0
  9. package/dist/models/create-billing-address-request-dto.d.ts +1 -7
  10. package/dist/models/create-payout-method-request-dto.d.ts +60 -0
  11. package/dist/models/create-payout-method-request-dto.js +15 -0
  12. package/dist/models/create-payout-method-response-class.d.ts +25 -0
  13. package/dist/models/create-payout-method-response-class.js +15 -0
  14. package/dist/models/get-payout-method-response-class.d.ts +25 -0
  15. package/dist/models/get-payout-method-response-class.js +15 -0
  16. package/dist/models/index.d.ts +5 -0
  17. package/dist/models/index.js +5 -0
  18. package/dist/models/list-payout-methods-response-class.d.ts +43 -0
  19. package/dist/models/list-payout-methods-response-class.js +15 -0
  20. package/dist/models/payout-method-class.d.ts +115 -0
  21. package/dist/models/payout-method-class.js +15 -0
  22. package/dist/models/update-billing-address-request-dto.d.ts +1 -7
  23. package/models/create-billing-address-request-dto.ts +1 -7
  24. package/models/create-payout-method-request-dto.ts +66 -0
  25. package/models/create-payout-method-response-class.ts +31 -0
  26. package/models/get-payout-method-response-class.ts +31 -0
  27. package/models/index.ts +5 -0
  28. package/models/list-payout-methods-response-class.ts +49 -0
  29. package/models/payout-method-class.ts +121 -0
  30. package/models/update-billing-address-request-dto.ts +1 -7
  31. package/package.json +1 -1
@@ -0,0 +1,635 @@
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.PayoutMethodsApi = exports.PayoutMethodsApiFactory = exports.PayoutMethodsApiFp = exports.PayoutMethodsApiAxiosParamCreator = 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
+ /**
89
+ * PayoutMethodsApi - axios parameter creator
90
+ * @export
91
+ */
92
+ var PayoutMethodsApiAxiosParamCreator = function (configuration) {
93
+ var _this = this;
94
+ return {
95
+ /**
96
+ * Activates a payout method **Required Permissions** \"payment-management.payments.create\"
97
+ * @summary Create the Payout Method Activation
98
+ * @param {string} code
99
+ * @param {string} [authorization] Bearer Token
100
+ * @param {*} [options] Override http request option.
101
+ * @throws {RequiredError}
102
+ */
103
+ activatePayoutMethod: function (code, authorization, options) {
104
+ if (options === void 0) { options = {}; }
105
+ return __awaiter(_this, void 0, void 0, function () {
106
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
+ return __generator(this, function (_a) {
108
+ switch (_a.label) {
109
+ case 0:
110
+ // verify required parameter 'code' is not null or undefined
111
+ (0, common_1.assertParamExists)('activatePayoutMethod', 'code', code);
112
+ localVarPath = "/paymentservice/v1/payout-methods/{code}/activate"
113
+ .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
114
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
115
+ if (configuration) {
116
+ baseOptions = configuration.baseOptions;
117
+ baseAccessToken = configuration.accessToken;
118
+ }
119
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
120
+ localVarHeaderParameter = {};
121
+ localVarQueryParameter = {};
122
+ // authentication bearer required
123
+ // http bearer authentication required
124
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
125
+ case 1:
126
+ // authentication bearer required
127
+ // http bearer authentication required
128
+ _a.sent();
129
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
130
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
131
+ }
132
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
133
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
134
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
135
+ return [2 /*return*/, {
136
+ url: (0, common_1.toPathString)(localVarUrlObj),
137
+ options: localVarRequestOptions,
138
+ }];
139
+ }
140
+ });
141
+ });
142
+ },
143
+ /**
144
+ * Creates a new payout method **Required Permissions** \"payment-management.payments.create\"
145
+ * @summary Create the Payout Method
146
+ * @param {CreatePayoutMethodRequestDto} createPayoutMethodRequestDto
147
+ * @param {string} [authorization] Bearer Token
148
+ * @param {*} [options] Override http request option.
149
+ * @throws {RequiredError}
150
+ */
151
+ createPayoutMethod: function (createPayoutMethodRequestDto, authorization, options) {
152
+ if (options === void 0) { options = {}; }
153
+ return __awaiter(_this, void 0, void 0, function () {
154
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
155
+ return __generator(this, function (_a) {
156
+ switch (_a.label) {
157
+ case 0:
158
+ // verify required parameter 'createPayoutMethodRequestDto' is not null or undefined
159
+ (0, common_1.assertParamExists)('createPayoutMethod', 'createPayoutMethodRequestDto', createPayoutMethodRequestDto);
160
+ localVarPath = "/paymentservice/v1/payout-methods";
161
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
162
+ if (configuration) {
163
+ baseOptions = configuration.baseOptions;
164
+ baseAccessToken = configuration.accessToken;
165
+ }
166
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
167
+ localVarHeaderParameter = {};
168
+ localVarQueryParameter = {};
169
+ // authentication bearer required
170
+ // http bearer authentication required
171
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
172
+ case 1:
173
+ // authentication bearer required
174
+ // http bearer authentication required
175
+ _a.sent();
176
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
177
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
178
+ }
179
+ localVarHeaderParameter['Content-Type'] = 'application/json';
180
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
181
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
182
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
183
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createPayoutMethodRequestDto, localVarRequestOptions, configuration);
184
+ return [2 /*return*/, {
185
+ url: (0, common_1.toPathString)(localVarUrlObj),
186
+ options: localVarRequestOptions,
187
+ }];
188
+ }
189
+ });
190
+ });
191
+ },
192
+ /**
193
+ * Deletes a payout method by its code **Required Permissions** \"payment-management.payments.delete\"
194
+ * @summary Delete the Payout Method
195
+ * @param {string} code Unique identifier for the object.
196
+ * @param {string} [authorization] Bearer Token
197
+ * @param {*} [options] Override http request option.
198
+ * @throws {RequiredError}
199
+ */
200
+ deletePayoutMethod: function (code, authorization, options) {
201
+ if (options === void 0) { options = {}; }
202
+ return __awaiter(_this, void 0, void 0, function () {
203
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
204
+ return __generator(this, function (_a) {
205
+ switch (_a.label) {
206
+ case 0:
207
+ // verify required parameter 'code' is not null or undefined
208
+ (0, common_1.assertParamExists)('deletePayoutMethod', 'code', code);
209
+ localVarPath = "/paymentservice/v1/payout-methods/{code}"
210
+ .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
211
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
212
+ if (configuration) {
213
+ baseOptions = configuration.baseOptions;
214
+ baseAccessToken = configuration.accessToken;
215
+ }
216
+ localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
217
+ localVarHeaderParameter = {};
218
+ localVarQueryParameter = {};
219
+ // authentication bearer required
220
+ // http bearer authentication required
221
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
222
+ case 1:
223
+ // authentication bearer required
224
+ // http bearer authentication required
225
+ _a.sent();
226
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
227
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
228
+ }
229
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
230
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
231
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
232
+ return [2 /*return*/, {
233
+ url: (0, common_1.toPathString)(localVarUrlObj),
234
+ options: localVarRequestOptions,
235
+ }];
236
+ }
237
+ });
238
+ });
239
+ },
240
+ /**
241
+ * Retrieves the details of the Payout Method that was previously created. Supply the unique Payout Method code that was returned when you created it and Emil Api will return the corresponding Payout Method information. **Required Permissions** \"payment-management.payments.view\"
242
+ * @summary Retrieve the Payout Method
243
+ * @param {string} code
244
+ * @param {string} [authorization] Bearer Token
245
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: billingAddress&lt;i&gt;
246
+ * @param {*} [options] Override http request option.
247
+ * @throws {RequiredError}
248
+ */
249
+ getPayoutMethod: function (code, authorization, expand, options) {
250
+ if (options === void 0) { options = {}; }
251
+ return __awaiter(_this, void 0, void 0, function () {
252
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
253
+ return __generator(this, function (_a) {
254
+ switch (_a.label) {
255
+ case 0:
256
+ // verify required parameter 'code' is not null or undefined
257
+ (0, common_1.assertParamExists)('getPayoutMethod', 'code', code);
258
+ localVarPath = "/paymentservice/v1/payout-methods/{code}"
259
+ .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
260
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
261
+ if (configuration) {
262
+ baseOptions = configuration.baseOptions;
263
+ baseAccessToken = configuration.accessToken;
264
+ }
265
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
266
+ localVarHeaderParameter = {};
267
+ localVarQueryParameter = {};
268
+ // authentication bearer required
269
+ // http bearer authentication required
270
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
271
+ case 1:
272
+ // authentication bearer required
273
+ // http bearer authentication required
274
+ _a.sent();
275
+ if (expand !== undefined) {
276
+ localVarQueryParameter['expand'] = expand;
277
+ }
278
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
279
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
280
+ }
281
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
282
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
283
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
284
+ return [2 /*return*/, {
285
+ url: (0, common_1.toPathString)(localVarUrlObj),
286
+ options: localVarRequestOptions,
287
+ }];
288
+ }
289
+ });
290
+ });
291
+ },
292
+ /**
293
+ * Returns a list of Payout Methods you have previously created. The Payout Methods 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\"
294
+ * @summary List Payout Methods
295
+ * @param {string} [authorization] Bearer Token
296
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
297
+ * @param {string} [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.
298
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, firstName, lastName, iban, bankName, accountCode, partnerCode, isActive, billingAddressId, createdAt, updatedAt&lt;/i&gt;
299
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: firstName, lastName, iban, bankName, accountCode, partnerCode&lt;/i&gt;
300
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, isActive, createdAt, updatedAt&lt;/i&gt;
301
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: billingAddress&lt;i&gt;
302
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, firstName, lastName, iban, bankName, accountCode, partnerCode, isActive, billingAddressId, createdAt, updatedAt&lt;/i&gt;
303
+ * @param {*} [options] Override http request option.
304
+ * @throws {RequiredError}
305
+ */
306
+ listPayoutMethods: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
307
+ if (options === void 0) { options = {}; }
308
+ return __awaiter(_this, void 0, void 0, function () {
309
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
310
+ return __generator(this, function (_a) {
311
+ switch (_a.label) {
312
+ case 0:
313
+ localVarPath = "/paymentservice/v1/payout-methods";
314
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
315
+ if (configuration) {
316
+ baseOptions = configuration.baseOptions;
317
+ baseAccessToken = configuration.accessToken;
318
+ }
319
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
320
+ localVarHeaderParameter = {};
321
+ localVarQueryParameter = {};
322
+ // authentication bearer required
323
+ // http bearer authentication required
324
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
325
+ case 1:
326
+ // authentication bearer required
327
+ // http bearer authentication required
328
+ _a.sent();
329
+ if (pageSize !== undefined) {
330
+ localVarQueryParameter['pageSize'] = pageSize;
331
+ }
332
+ if (pageToken !== undefined) {
333
+ localVarQueryParameter['pageToken'] = pageToken;
334
+ }
335
+ if (filter !== undefined) {
336
+ localVarQueryParameter['filter'] = filter;
337
+ }
338
+ if (search !== undefined) {
339
+ localVarQueryParameter['search'] = search;
340
+ }
341
+ if (order !== undefined) {
342
+ localVarQueryParameter['order'] = order;
343
+ }
344
+ if (expand !== undefined) {
345
+ localVarQueryParameter['expand'] = expand;
346
+ }
347
+ if (filters !== undefined) {
348
+ localVarQueryParameter['filters'] = filters;
349
+ }
350
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
351
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
352
+ }
353
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
354
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
355
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
356
+ return [2 /*return*/, {
357
+ url: (0, common_1.toPathString)(localVarUrlObj),
358
+ options: localVarRequestOptions,
359
+ }];
360
+ }
361
+ });
362
+ });
363
+ },
364
+ };
365
+ };
366
+ exports.PayoutMethodsApiAxiosParamCreator = PayoutMethodsApiAxiosParamCreator;
367
+ /**
368
+ * PayoutMethodsApi - functional programming interface
369
+ * @export
370
+ */
371
+ var PayoutMethodsApiFp = function (configuration) {
372
+ var localVarAxiosParamCreator = (0, exports.PayoutMethodsApiAxiosParamCreator)(configuration);
373
+ return {
374
+ /**
375
+ * Activates a payout method **Required Permissions** \"payment-management.payments.create\"
376
+ * @summary Create the Payout Method Activation
377
+ * @param {string} code
378
+ * @param {string} [authorization] Bearer Token
379
+ * @param {*} [options] Override http request option.
380
+ * @throws {RequiredError}
381
+ */
382
+ activatePayoutMethod: function (code, authorization, options) {
383
+ return __awaiter(this, void 0, void 0, function () {
384
+ var localVarAxiosArgs;
385
+ return __generator(this, function (_a) {
386
+ switch (_a.label) {
387
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.activatePayoutMethod(code, authorization, options)];
388
+ case 1:
389
+ localVarAxiosArgs = _a.sent();
390
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
391
+ }
392
+ });
393
+ });
394
+ },
395
+ /**
396
+ * Creates a new payout method **Required Permissions** \"payment-management.payments.create\"
397
+ * @summary Create the Payout Method
398
+ * @param {CreatePayoutMethodRequestDto} createPayoutMethodRequestDto
399
+ * @param {string} [authorization] Bearer Token
400
+ * @param {*} [options] Override http request option.
401
+ * @throws {RequiredError}
402
+ */
403
+ createPayoutMethod: function (createPayoutMethodRequestDto, authorization, options) {
404
+ return __awaiter(this, void 0, void 0, function () {
405
+ var localVarAxiosArgs;
406
+ return __generator(this, function (_a) {
407
+ switch (_a.label) {
408
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.createPayoutMethod(createPayoutMethodRequestDto, authorization, options)];
409
+ case 1:
410
+ localVarAxiosArgs = _a.sent();
411
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
412
+ }
413
+ });
414
+ });
415
+ },
416
+ /**
417
+ * Deletes a payout method by its code **Required Permissions** \"payment-management.payments.delete\"
418
+ * @summary Delete the Payout Method
419
+ * @param {string} code Unique identifier for the object.
420
+ * @param {string} [authorization] Bearer Token
421
+ * @param {*} [options] Override http request option.
422
+ * @throws {RequiredError}
423
+ */
424
+ deletePayoutMethod: function (code, authorization, options) {
425
+ return __awaiter(this, void 0, void 0, function () {
426
+ var localVarAxiosArgs;
427
+ return __generator(this, function (_a) {
428
+ switch (_a.label) {
429
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.deletePayoutMethod(code, authorization, options)];
430
+ case 1:
431
+ localVarAxiosArgs = _a.sent();
432
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
433
+ }
434
+ });
435
+ });
436
+ },
437
+ /**
438
+ * Retrieves the details of the Payout Method that was previously created. Supply the unique Payout Method code that was returned when you created it and Emil Api will return the corresponding Payout Method information. **Required Permissions** \"payment-management.payments.view\"
439
+ * @summary Retrieve the Payout Method
440
+ * @param {string} code
441
+ * @param {string} [authorization] Bearer Token
442
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: billingAddress&lt;i&gt;
443
+ * @param {*} [options] Override http request option.
444
+ * @throws {RequiredError}
445
+ */
446
+ getPayoutMethod: function (code, authorization, expand, options) {
447
+ return __awaiter(this, void 0, void 0, function () {
448
+ var localVarAxiosArgs;
449
+ return __generator(this, function (_a) {
450
+ switch (_a.label) {
451
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.getPayoutMethod(code, authorization, expand, options)];
452
+ case 1:
453
+ localVarAxiosArgs = _a.sent();
454
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
455
+ }
456
+ });
457
+ });
458
+ },
459
+ /**
460
+ * Returns a list of Payout Methods you have previously created. The Payout Methods 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\"
461
+ * @summary List Payout Methods
462
+ * @param {string} [authorization] Bearer Token
463
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
464
+ * @param {string} [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.
465
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, firstName, lastName, iban, bankName, accountCode, partnerCode, isActive, billingAddressId, createdAt, updatedAt&lt;/i&gt;
466
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: firstName, lastName, iban, bankName, accountCode, partnerCode&lt;/i&gt;
467
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, isActive, createdAt, updatedAt&lt;/i&gt;
468
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: billingAddress&lt;i&gt;
469
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, firstName, lastName, iban, bankName, accountCode, partnerCode, isActive, billingAddressId, createdAt, updatedAt&lt;/i&gt;
470
+ * @param {*} [options] Override http request option.
471
+ * @throws {RequiredError}
472
+ */
473
+ listPayoutMethods: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
474
+ return __awaiter(this, void 0, void 0, function () {
475
+ var localVarAxiosArgs;
476
+ return __generator(this, function (_a) {
477
+ switch (_a.label) {
478
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.listPayoutMethods(authorization, pageSize, pageToken, filter, search, order, expand, filters, options)];
479
+ case 1:
480
+ localVarAxiosArgs = _a.sent();
481
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
482
+ }
483
+ });
484
+ });
485
+ },
486
+ };
487
+ };
488
+ exports.PayoutMethodsApiFp = PayoutMethodsApiFp;
489
+ /**
490
+ * PayoutMethodsApi - factory interface
491
+ * @export
492
+ */
493
+ var PayoutMethodsApiFactory = function (configuration, basePath, axios) {
494
+ var localVarFp = (0, exports.PayoutMethodsApiFp)(configuration);
495
+ return {
496
+ /**
497
+ * Activates a payout method **Required Permissions** \"payment-management.payments.create\"
498
+ * @summary Create the Payout Method Activation
499
+ * @param {string} code
500
+ * @param {string} [authorization] Bearer Token
501
+ * @param {*} [options] Override http request option.
502
+ * @throws {RequiredError}
503
+ */
504
+ activatePayoutMethod: function (code, authorization, options) {
505
+ return localVarFp.activatePayoutMethod(code, authorization, options).then(function (request) { return request(axios, basePath); });
506
+ },
507
+ /**
508
+ * Creates a new payout method **Required Permissions** \"payment-management.payments.create\"
509
+ * @summary Create the Payout Method
510
+ * @param {CreatePayoutMethodRequestDto} createPayoutMethodRequestDto
511
+ * @param {string} [authorization] Bearer Token
512
+ * @param {*} [options] Override http request option.
513
+ * @throws {RequiredError}
514
+ */
515
+ createPayoutMethod: function (createPayoutMethodRequestDto, authorization, options) {
516
+ return localVarFp.createPayoutMethod(createPayoutMethodRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
517
+ },
518
+ /**
519
+ * Deletes a payout method by its code **Required Permissions** \"payment-management.payments.delete\"
520
+ * @summary Delete the Payout Method
521
+ * @param {string} code Unique identifier for the object.
522
+ * @param {string} [authorization] Bearer Token
523
+ * @param {*} [options] Override http request option.
524
+ * @throws {RequiredError}
525
+ */
526
+ deletePayoutMethod: function (code, authorization, options) {
527
+ return localVarFp.deletePayoutMethod(code, authorization, options).then(function (request) { return request(axios, basePath); });
528
+ },
529
+ /**
530
+ * Retrieves the details of the Payout Method that was previously created. Supply the unique Payout Method code that was returned when you created it and Emil Api will return the corresponding Payout Method information. **Required Permissions** \"payment-management.payments.view\"
531
+ * @summary Retrieve the Payout Method
532
+ * @param {string} code
533
+ * @param {string} [authorization] Bearer Token
534
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: billingAddress&lt;i&gt;
535
+ * @param {*} [options] Override http request option.
536
+ * @throws {RequiredError}
537
+ */
538
+ getPayoutMethod: function (code, authorization, expand, options) {
539
+ return localVarFp.getPayoutMethod(code, authorization, expand, options).then(function (request) { return request(axios, basePath); });
540
+ },
541
+ /**
542
+ * Returns a list of Payout Methods you have previously created. The Payout Methods 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\"
543
+ * @summary List Payout Methods
544
+ * @param {string} [authorization] Bearer Token
545
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
546
+ * @param {string} [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.
547
+ * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, firstName, lastName, iban, bankName, accountCode, partnerCode, isActive, billingAddressId, createdAt, updatedAt&lt;/i&gt;
548
+ * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Searchable fields: firstName, lastName, iban, bankName, accountCode, partnerCode&lt;/i&gt;
549
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, isActive, createdAt, updatedAt&lt;/i&gt;
550
+ * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: billingAddress&lt;i&gt;
551
+ * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, firstName, lastName, iban, bankName, accountCode, partnerCode, isActive, billingAddressId, createdAt, updatedAt&lt;/i&gt;
552
+ * @param {*} [options] Override http request option.
553
+ * @throws {RequiredError}
554
+ */
555
+ listPayoutMethods: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
556
+ return localVarFp.listPayoutMethods(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
557
+ },
558
+ };
559
+ };
560
+ exports.PayoutMethodsApiFactory = PayoutMethodsApiFactory;
561
+ /**
562
+ * PayoutMethodsApi - object-oriented interface
563
+ * @export
564
+ * @class PayoutMethodsApi
565
+ * @extends {BaseAPI}
566
+ */
567
+ var PayoutMethodsApi = /** @class */ (function (_super) {
568
+ __extends(PayoutMethodsApi, _super);
569
+ function PayoutMethodsApi() {
570
+ return _super !== null && _super.apply(this, arguments) || this;
571
+ }
572
+ /**
573
+ * Activates a payout method **Required Permissions** \"payment-management.payments.create\"
574
+ * @summary Create the Payout Method Activation
575
+ * @param {PayoutMethodsApiActivatePayoutMethodRequest} requestParameters Request parameters.
576
+ * @param {*} [options] Override http request option.
577
+ * @throws {RequiredError}
578
+ * @memberof PayoutMethodsApi
579
+ */
580
+ PayoutMethodsApi.prototype.activatePayoutMethod = function (requestParameters, options) {
581
+ var _this = this;
582
+ return (0, exports.PayoutMethodsApiFp)(this.configuration).activatePayoutMethod(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
583
+ };
584
+ /**
585
+ * Creates a new payout method **Required Permissions** \"payment-management.payments.create\"
586
+ * @summary Create the Payout Method
587
+ * @param {PayoutMethodsApiCreatePayoutMethodRequest} requestParameters Request parameters.
588
+ * @param {*} [options] Override http request option.
589
+ * @throws {RequiredError}
590
+ * @memberof PayoutMethodsApi
591
+ */
592
+ PayoutMethodsApi.prototype.createPayoutMethod = function (requestParameters, options) {
593
+ var _this = this;
594
+ return (0, exports.PayoutMethodsApiFp)(this.configuration).createPayoutMethod(requestParameters.createPayoutMethodRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
595
+ };
596
+ /**
597
+ * Deletes a payout method by its code **Required Permissions** \"payment-management.payments.delete\"
598
+ * @summary Delete the Payout Method
599
+ * @param {PayoutMethodsApiDeletePayoutMethodRequest} requestParameters Request parameters.
600
+ * @param {*} [options] Override http request option.
601
+ * @throws {RequiredError}
602
+ * @memberof PayoutMethodsApi
603
+ */
604
+ PayoutMethodsApi.prototype.deletePayoutMethod = function (requestParameters, options) {
605
+ var _this = this;
606
+ return (0, exports.PayoutMethodsApiFp)(this.configuration).deletePayoutMethod(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
607
+ };
608
+ /**
609
+ * Retrieves the details of the Payout Method that was previously created. Supply the unique Payout Method code that was returned when you created it and Emil Api will return the corresponding Payout Method information. **Required Permissions** \"payment-management.payments.view\"
610
+ * @summary Retrieve the Payout Method
611
+ * @param {PayoutMethodsApiGetPayoutMethodRequest} requestParameters Request parameters.
612
+ * @param {*} [options] Override http request option.
613
+ * @throws {RequiredError}
614
+ * @memberof PayoutMethodsApi
615
+ */
616
+ PayoutMethodsApi.prototype.getPayoutMethod = function (requestParameters, options) {
617
+ var _this = this;
618
+ return (0, exports.PayoutMethodsApiFp)(this.configuration).getPayoutMethod(requestParameters.code, requestParameters.authorization, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
619
+ };
620
+ /**
621
+ * Returns a list of Payout Methods you have previously created. The Payout Methods 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\"
622
+ * @summary List Payout Methods
623
+ * @param {PayoutMethodsApiListPayoutMethodsRequest} requestParameters Request parameters.
624
+ * @param {*} [options] Override http request option.
625
+ * @throws {RequiredError}
626
+ * @memberof PayoutMethodsApi
627
+ */
628
+ PayoutMethodsApi.prototype.listPayoutMethods = function (requestParameters, options) {
629
+ var _this = this;
630
+ if (requestParameters === void 0) { requestParameters = {}; }
631
+ return (0, exports.PayoutMethodsApiFp)(this.configuration).listPayoutMethods(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); });
632
+ };
633
+ return PayoutMethodsApi;
634
+ }(base_1.BaseAPI));
635
+ exports.PayoutMethodsApi = PayoutMethodsApi;
package/dist/api.d.ts CHANGED
@@ -20,6 +20,7 @@ export * from './api/payment-methods-api';
20
20
  export * from './api/payment-reminders-api';
21
21
  export * from './api/payment-setup-api';
22
22
  export * from './api/payments-api';
23
+ export * from './api/payout-methods-api';
23
24
  export * from './api/policy-payment-methods-api';
24
25
  export * from './api/refunds-api';
25
26
  export * from './api/tenant-bank-account-api';