@emilgroup/settlement-sdk 0.3.1-beta.6

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 (61) hide show
  1. package/.openapi-generator/FILES +25 -0
  2. package/.openapi-generator/VERSION +1 -0
  3. package/.openapi-generator-ignore +23 -0
  4. package/README.md +51 -0
  5. package/api/health-api.ts +120 -0
  6. package/api/settlements-api.ts +676 -0
  7. package/api.ts +29 -0
  8. package/base.ts +282 -0
  9. package/common.ts +198 -0
  10. package/configuration.ts +110 -0
  11. package/dist/api/health-api.d.ts +66 -0
  12. package/dist/api/health-api.js +196 -0
  13. package/dist/api/settlements-api.d.ts +383 -0
  14. package/dist/api/settlements-api.js +637 -0
  15. package/dist/api.d.ts +13 -0
  16. package/dist/api.js +31 -0
  17. package/dist/base.d.ts +77 -0
  18. package/dist/base.js +324 -0
  19. package/dist/common.d.ts +91 -0
  20. package/dist/common.js +276 -0
  21. package/dist/configuration.d.ts +89 -0
  22. package/dist/configuration.js +52 -0
  23. package/dist/index.d.ts +15 -0
  24. package/dist/index.js +36 -0
  25. package/dist/models/add-settlement-entry-response-class.d.ts +25 -0
  26. package/dist/models/add-settlement-entry-response-class.js +15 -0
  27. package/dist/models/create-settlement-request-dto.d.ts +42 -0
  28. package/dist/models/create-settlement-request-dto.js +20 -0
  29. package/dist/models/create-settlement-response-class.d.ts +25 -0
  30. package/dist/models/create-settlement-response-class.js +15 -0
  31. package/dist/models/get-settlement-response-class.d.ts +25 -0
  32. package/dist/models/get-settlement-response-class.js +15 -0
  33. package/dist/models/index.d.ts +10 -0
  34. package/dist/models/index.js +26 -0
  35. package/dist/models/inline-response200.d.ts +54 -0
  36. package/dist/models/inline-response200.js +15 -0
  37. package/dist/models/inline-response503.d.ts +54 -0
  38. package/dist/models/inline-response503.js +15 -0
  39. package/dist/models/list-settlements-response-class.d.ts +43 -0
  40. package/dist/models/list-settlements-response-class.js +15 -0
  41. package/dist/models/settlement-class.d.ts +134 -0
  42. package/dist/models/settlement-class.js +38 -0
  43. package/dist/models/settlement-entry-class.d.ts +119 -0
  44. package/dist/models/settlement-entry-class.js +20 -0
  45. package/dist/models/settlement-entry-input-dto.d.ts +103 -0
  46. package/dist/models/settlement-entry-input-dto.js +43 -0
  47. package/git_push.sh +57 -0
  48. package/index.ts +19 -0
  49. package/models/add-settlement-entry-response-class.ts +31 -0
  50. package/models/create-settlement-request-dto.ts +51 -0
  51. package/models/create-settlement-response-class.ts +31 -0
  52. package/models/get-settlement-response-class.ts +31 -0
  53. package/models/index.ts +10 -0
  54. package/models/inline-response200.ts +48 -0
  55. package/models/inline-response503.ts +48 -0
  56. package/models/list-settlements-response-class.ts +49 -0
  57. package/models/settlement-class.ts +145 -0
  58. package/models/settlement-entry-class.ts +128 -0
  59. package/models/settlement-entry-input-dto.ts +115 -0
  60. package/package.json +27 -0
  61. package/tsconfig.json +23 -0
@@ -0,0 +1,637 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * EMIL SettlementService
6
+ * The EMIL SettlementService API description
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.SettlementsApi = exports.SettlementsApiFactory = exports.SettlementsApiFp = exports.SettlementsApiAxiosParamCreator = 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
+ * SettlementsApi - axios parameter creator
90
+ * @export
91
+ */
92
+ var SettlementsApiAxiosParamCreator = function (configuration) {
93
+ var _this = this;
94
+ return {
95
+ /**
96
+ * This will add settlement entry. **Required Permissions** none
97
+ * @summary Create the settlement entry
98
+ * @param {string} settlementCode
99
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
100
+ * @param {*} [options] Override http request option.
101
+ * @throws {RequiredError}
102
+ */
103
+ addSettlementEntry: function (settlementCode, 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 'settlementCode' is not null or undefined
111
+ (0, common_1.assertParamExists)('addSettlementEntry', 'settlementCode', settlementCode);
112
+ localVarPath = "/settlementservice/v1/settlements/{settlementCode}/entries"
113
+ .replace("{".concat("settlementCode", "}"), encodeURIComponent(String(settlementCode)));
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
+ * This will create settlement. **Required Permissions** none
145
+ * @summary Create the settlement
146
+ * @param {CreateSettlementRequestDto} createSettlementRequestDto
147
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
148
+ * @param {*} [options] Override http request option.
149
+ * @throws {RequiredError}
150
+ */
151
+ createSettlement: function (createSettlementRequestDto, 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 'createSettlementRequestDto' is not null or undefined
159
+ (0, common_1.assertParamExists)('createSettlement', 'createSettlementRequestDto', createSettlementRequestDto);
160
+ localVarPath = "/settlementservice/v1/settlements";
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)(createSettlementRequestDto, localVarRequestOptions, configuration);
184
+ return [2 /*return*/, {
185
+ url: (0, common_1.toPathString)(localVarUrlObj),
186
+ options: localVarRequestOptions,
187
+ }];
188
+ }
189
+ });
190
+ });
191
+ },
192
+ /**
193
+ * This will delete settlement. **Required Permissions** none
194
+ * @summary Delete the settlement
195
+ * @param {string} code Unique identifier for the object.
196
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
197
+ * @param {*} [options] Override http request option.
198
+ * @throws {RequiredError}
199
+ */
200
+ deleteSettlement: 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)('deleteSettlement', 'code', code);
209
+ localVarPath = "/settlementservice/v1/settlements/{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
+ * This will get settlement. **Required Permissions** none
242
+ * @summary Retrieve the settlement
243
+ * @param {string} code
244
+ * @param {string} expand
245
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
246
+ * @param {*} [options] Override http request option.
247
+ * @throws {RequiredError}
248
+ */
249
+ getSettlement: function (code, expand, authorization, 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)('getSettlement', 'code', code);
258
+ // verify required parameter 'expand' is not null or undefined
259
+ (0, common_1.assertParamExists)('getSettlement', 'expand', expand);
260
+ localVarPath = "/settlementservice/v1/settlements/{code}"
261
+ .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
262
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
263
+ if (configuration) {
264
+ baseOptions = configuration.baseOptions;
265
+ baseAccessToken = configuration.accessToken;
266
+ }
267
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
268
+ localVarHeaderParameter = {};
269
+ localVarQueryParameter = {};
270
+ // authentication bearer required
271
+ // http bearer authentication required
272
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
273
+ case 1:
274
+ // authentication bearer required
275
+ // http bearer authentication required
276
+ _a.sent();
277
+ if (expand !== undefined) {
278
+ localVarQueryParameter['expand'] = expand;
279
+ }
280
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
281
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
282
+ }
283
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
284
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
285
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
286
+ return [2 /*return*/, {
287
+ url: (0, common_1.toPathString)(localVarUrlObj),
288
+ options: localVarRequestOptions,
289
+ }];
290
+ }
291
+ });
292
+ });
293
+ },
294
+ /**
295
+ * Retrieves a list of settlements. **Required Permissions** none
296
+ * @summary List settlements
297
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
298
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
299
+ * @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.
300
+ * @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, createdAt&lt;/i&gt;
301
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
302
+ * @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: createdAt&lt;/i&gt;
303
+ * @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;
304
+ * @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, createdAt&lt;/i&gt;
305
+ * @param {*} [options] Override http request option.
306
+ * @throws {RequiredError}
307
+ */
308
+ listSettlements: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
309
+ if (options === void 0) { options = {}; }
310
+ return __awaiter(_this, void 0, void 0, function () {
311
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
312
+ return __generator(this, function (_a) {
313
+ switch (_a.label) {
314
+ case 0:
315
+ localVarPath = "/settlementservice/v1/settlements";
316
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
317
+ if (configuration) {
318
+ baseOptions = configuration.baseOptions;
319
+ baseAccessToken = configuration.accessToken;
320
+ }
321
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
322
+ localVarHeaderParameter = {};
323
+ localVarQueryParameter = {};
324
+ // authentication bearer required
325
+ // http bearer authentication required
326
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
327
+ case 1:
328
+ // authentication bearer required
329
+ // http bearer authentication required
330
+ _a.sent();
331
+ if (pageSize !== undefined) {
332
+ localVarQueryParameter['pageSize'] = pageSize;
333
+ }
334
+ if (pageToken !== undefined) {
335
+ localVarQueryParameter['pageToken'] = pageToken;
336
+ }
337
+ if (filter !== undefined) {
338
+ localVarQueryParameter['filter'] = filter;
339
+ }
340
+ if (search !== undefined) {
341
+ localVarQueryParameter['search'] = search;
342
+ }
343
+ if (order !== undefined) {
344
+ localVarQueryParameter['order'] = order;
345
+ }
346
+ if (expand !== undefined) {
347
+ localVarQueryParameter['expand'] = expand;
348
+ }
349
+ if (filters !== undefined) {
350
+ localVarQueryParameter['filters'] = filters;
351
+ }
352
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
353
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
354
+ }
355
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
356
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
357
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
358
+ return [2 /*return*/, {
359
+ url: (0, common_1.toPathString)(localVarUrlObj),
360
+ options: localVarRequestOptions,
361
+ }];
362
+ }
363
+ });
364
+ });
365
+ },
366
+ };
367
+ };
368
+ exports.SettlementsApiAxiosParamCreator = SettlementsApiAxiosParamCreator;
369
+ /**
370
+ * SettlementsApi - functional programming interface
371
+ * @export
372
+ */
373
+ var SettlementsApiFp = function (configuration) {
374
+ var localVarAxiosParamCreator = (0, exports.SettlementsApiAxiosParamCreator)(configuration);
375
+ return {
376
+ /**
377
+ * This will add settlement entry. **Required Permissions** none
378
+ * @summary Create the settlement entry
379
+ * @param {string} settlementCode
380
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
381
+ * @param {*} [options] Override http request option.
382
+ * @throws {RequiredError}
383
+ */
384
+ addSettlementEntry: function (settlementCode, authorization, options) {
385
+ return __awaiter(this, void 0, void 0, function () {
386
+ var localVarAxiosArgs;
387
+ return __generator(this, function (_a) {
388
+ switch (_a.label) {
389
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.addSettlementEntry(settlementCode, authorization, options)];
390
+ case 1:
391
+ localVarAxiosArgs = _a.sent();
392
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
393
+ }
394
+ });
395
+ });
396
+ },
397
+ /**
398
+ * This will create settlement. **Required Permissions** none
399
+ * @summary Create the settlement
400
+ * @param {CreateSettlementRequestDto} createSettlementRequestDto
401
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
402
+ * @param {*} [options] Override http request option.
403
+ * @throws {RequiredError}
404
+ */
405
+ createSettlement: function (createSettlementRequestDto, authorization, options) {
406
+ return __awaiter(this, void 0, void 0, function () {
407
+ var localVarAxiosArgs;
408
+ return __generator(this, function (_a) {
409
+ switch (_a.label) {
410
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.createSettlement(createSettlementRequestDto, authorization, options)];
411
+ case 1:
412
+ localVarAxiosArgs = _a.sent();
413
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
414
+ }
415
+ });
416
+ });
417
+ },
418
+ /**
419
+ * This will delete settlement. **Required Permissions** none
420
+ * @summary Delete the settlement
421
+ * @param {string} code Unique identifier for the object.
422
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
423
+ * @param {*} [options] Override http request option.
424
+ * @throws {RequiredError}
425
+ */
426
+ deleteSettlement: function (code, authorization, options) {
427
+ return __awaiter(this, void 0, void 0, function () {
428
+ var localVarAxiosArgs;
429
+ return __generator(this, function (_a) {
430
+ switch (_a.label) {
431
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteSettlement(code, authorization, options)];
432
+ case 1:
433
+ localVarAxiosArgs = _a.sent();
434
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
435
+ }
436
+ });
437
+ });
438
+ },
439
+ /**
440
+ * This will get settlement. **Required Permissions** none
441
+ * @summary Retrieve the settlement
442
+ * @param {string} code
443
+ * @param {string} expand
444
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
445
+ * @param {*} [options] Override http request option.
446
+ * @throws {RequiredError}
447
+ */
448
+ getSettlement: function (code, expand, authorization, options) {
449
+ return __awaiter(this, void 0, void 0, function () {
450
+ var localVarAxiosArgs;
451
+ return __generator(this, function (_a) {
452
+ switch (_a.label) {
453
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.getSettlement(code, expand, authorization, options)];
454
+ case 1:
455
+ localVarAxiosArgs = _a.sent();
456
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
457
+ }
458
+ });
459
+ });
460
+ },
461
+ /**
462
+ * Retrieves a list of settlements. **Required Permissions** none
463
+ * @summary List settlements
464
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
465
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
466
+ * @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.
467
+ * @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, createdAt&lt;/i&gt;
468
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
469
+ * @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: createdAt&lt;/i&gt;
470
+ * @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;
471
+ * @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, createdAt&lt;/i&gt;
472
+ * @param {*} [options] Override http request option.
473
+ * @throws {RequiredError}
474
+ */
475
+ listSettlements: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
476
+ return __awaiter(this, void 0, void 0, function () {
477
+ var localVarAxiosArgs;
478
+ return __generator(this, function (_a) {
479
+ switch (_a.label) {
480
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.listSettlements(authorization, pageSize, pageToken, filter, search, order, expand, filters, options)];
481
+ case 1:
482
+ localVarAxiosArgs = _a.sent();
483
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
484
+ }
485
+ });
486
+ });
487
+ },
488
+ };
489
+ };
490
+ exports.SettlementsApiFp = SettlementsApiFp;
491
+ /**
492
+ * SettlementsApi - factory interface
493
+ * @export
494
+ */
495
+ var SettlementsApiFactory = function (configuration, basePath, axios) {
496
+ var localVarFp = (0, exports.SettlementsApiFp)(configuration);
497
+ return {
498
+ /**
499
+ * This will add settlement entry. **Required Permissions** none
500
+ * @summary Create the settlement entry
501
+ * @param {string} settlementCode
502
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
503
+ * @param {*} [options] Override http request option.
504
+ * @throws {RequiredError}
505
+ */
506
+ addSettlementEntry: function (settlementCode, authorization, options) {
507
+ return localVarFp.addSettlementEntry(settlementCode, authorization, options).then(function (request) { return request(axios, basePath); });
508
+ },
509
+ /**
510
+ * This will create settlement. **Required Permissions** none
511
+ * @summary Create the settlement
512
+ * @param {CreateSettlementRequestDto} createSettlementRequestDto
513
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
514
+ * @param {*} [options] Override http request option.
515
+ * @throws {RequiredError}
516
+ */
517
+ createSettlement: function (createSettlementRequestDto, authorization, options) {
518
+ return localVarFp.createSettlement(createSettlementRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
519
+ },
520
+ /**
521
+ * This will delete settlement. **Required Permissions** none
522
+ * @summary Delete the settlement
523
+ * @param {string} code Unique identifier for the object.
524
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
525
+ * @param {*} [options] Override http request option.
526
+ * @throws {RequiredError}
527
+ */
528
+ deleteSettlement: function (code, authorization, options) {
529
+ return localVarFp.deleteSettlement(code, authorization, options).then(function (request) { return request(axios, basePath); });
530
+ },
531
+ /**
532
+ * This will get settlement. **Required Permissions** none
533
+ * @summary Retrieve the settlement
534
+ * @param {string} code
535
+ * @param {string} expand
536
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
537
+ * @param {*} [options] Override http request option.
538
+ * @throws {RequiredError}
539
+ */
540
+ getSettlement: function (code, expand, authorization, options) {
541
+ return localVarFp.getSettlement(code, expand, authorization, options).then(function (request) { return request(axios, basePath); });
542
+ },
543
+ /**
544
+ * Retrieves a list of settlements. **Required Permissions** none
545
+ * @summary List settlements
546
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
547
+ * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
548
+ * @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.
549
+ * @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, createdAt&lt;/i&gt;
550
+ * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
551
+ * @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: createdAt&lt;/i&gt;
552
+ * @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;
553
+ * @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, createdAt&lt;/i&gt;
554
+ * @param {*} [options] Override http request option.
555
+ * @throws {RequiredError}
556
+ */
557
+ listSettlements: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
558
+ return localVarFp.listSettlements(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
559
+ },
560
+ };
561
+ };
562
+ exports.SettlementsApiFactory = SettlementsApiFactory;
563
+ /**
564
+ * SettlementsApi - object-oriented interface
565
+ * @export
566
+ * @class SettlementsApi
567
+ * @extends {BaseAPI}
568
+ */
569
+ var SettlementsApi = /** @class */ (function (_super) {
570
+ __extends(SettlementsApi, _super);
571
+ function SettlementsApi() {
572
+ return _super !== null && _super.apply(this, arguments) || this;
573
+ }
574
+ /**
575
+ * This will add settlement entry. **Required Permissions** none
576
+ * @summary Create the settlement entry
577
+ * @param {SettlementsApiAddSettlementEntryRequest} requestParameters Request parameters.
578
+ * @param {*} [options] Override http request option.
579
+ * @throws {RequiredError}
580
+ * @memberof SettlementsApi
581
+ */
582
+ SettlementsApi.prototype.addSettlementEntry = function (requestParameters, options) {
583
+ var _this = this;
584
+ return (0, exports.SettlementsApiFp)(this.configuration).addSettlementEntry(requestParameters.settlementCode, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
585
+ };
586
+ /**
587
+ * This will create settlement. **Required Permissions** none
588
+ * @summary Create the settlement
589
+ * @param {SettlementsApiCreateSettlementRequest} requestParameters Request parameters.
590
+ * @param {*} [options] Override http request option.
591
+ * @throws {RequiredError}
592
+ * @memberof SettlementsApi
593
+ */
594
+ SettlementsApi.prototype.createSettlement = function (requestParameters, options) {
595
+ var _this = this;
596
+ return (0, exports.SettlementsApiFp)(this.configuration).createSettlement(requestParameters.createSettlementRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
597
+ };
598
+ /**
599
+ * This will delete settlement. **Required Permissions** none
600
+ * @summary Delete the settlement
601
+ * @param {SettlementsApiDeleteSettlementRequest} requestParameters Request parameters.
602
+ * @param {*} [options] Override http request option.
603
+ * @throws {RequiredError}
604
+ * @memberof SettlementsApi
605
+ */
606
+ SettlementsApi.prototype.deleteSettlement = function (requestParameters, options) {
607
+ var _this = this;
608
+ return (0, exports.SettlementsApiFp)(this.configuration).deleteSettlement(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
609
+ };
610
+ /**
611
+ * This will get settlement. **Required Permissions** none
612
+ * @summary Retrieve the settlement
613
+ * @param {SettlementsApiGetSettlementRequest} requestParameters Request parameters.
614
+ * @param {*} [options] Override http request option.
615
+ * @throws {RequiredError}
616
+ * @memberof SettlementsApi
617
+ */
618
+ SettlementsApi.prototype.getSettlement = function (requestParameters, options) {
619
+ var _this = this;
620
+ return (0, exports.SettlementsApiFp)(this.configuration).getSettlement(requestParameters.code, requestParameters.expand, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
621
+ };
622
+ /**
623
+ * Retrieves a list of settlements. **Required Permissions** none
624
+ * @summary List settlements
625
+ * @param {SettlementsApiListSettlementsRequest} requestParameters Request parameters.
626
+ * @param {*} [options] Override http request option.
627
+ * @throws {RequiredError}
628
+ * @memberof SettlementsApi
629
+ */
630
+ SettlementsApi.prototype.listSettlements = function (requestParameters, options) {
631
+ var _this = this;
632
+ if (requestParameters === void 0) { requestParameters = {}; }
633
+ return (0, exports.SettlementsApiFp)(this.configuration).listSettlements(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); });
634
+ };
635
+ return SettlementsApi;
636
+ }(base_1.BaseAPI));
637
+ exports.SettlementsApi = SettlementsApi;
package/dist/api.d.ts ADDED
@@ -0,0 +1,13 @@
1
+ /**
2
+ * EMIL SettlementService
3
+ * The EMIL SettlementService API description
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ * Contact: kontakt@emil.de
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ export * from './api/health-api';
13
+ export * from './api/settlements-api';