@emilgroup/payment-sdk 1.13.1-beta.72 → 1.13.1-beta.74

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 (29) hide show
  1. package/.openapi-generator/FILES +3 -1
  2. package/README.md +2 -2
  3. package/api/bank-transaction-api.ts +14 -31
  4. package/api/payments-api.ts +129 -4
  5. package/dist/api/bank-transaction-api.d.ts +11 -21
  6. package/dist/api/bank-transaction-api.js +12 -19
  7. package/dist/api/payments-api.d.ts +73 -4
  8. package/dist/api/payments-api.js +109 -4
  9. package/dist/models/bank-transaction-class-without-expand-properties.d.ts +7 -12
  10. package/dist/models/bank-transaction-class.d.ts +7 -12
  11. package/dist/models/bank-transaction-invoice-class.d.ts +54 -0
  12. package/dist/models/create-payment-order-dto.d.ts +48 -0
  13. package/{models/unlink-bank-transaction-request-dto-rest.ts → dist/models/create-payment-order-dto.js} +2 -17
  14. package/dist/models/create-payment-order-request-dto.d.ts +48 -0
  15. package/dist/models/{unlink-bank-transaction-request-dto-rest.d.ts → create-payment-order-request-dto.js} +4 -13
  16. package/dist/models/index.d.ts +3 -1
  17. package/dist/models/index.js +3 -1
  18. package/dist/models/link-bank-transaction-request-dto-rest.d.ts +3 -3
  19. package/dist/models/unlinked-bank-transaction-response-class.d.ts +7 -0
  20. package/models/bank-transaction-class-without-expand-properties.ts +7 -12
  21. package/models/bank-transaction-class.ts +7 -12
  22. package/models/bank-transaction-invoice-class.ts +60 -0
  23. package/models/create-payment-order-dto.ts +54 -0
  24. package/models/create-payment-order-request-dto.ts +54 -0
  25. package/models/index.ts +3 -1
  26. package/models/link-bank-transaction-request-dto-rest.ts +3 -3
  27. package/models/unlinked-bank-transaction-response-class.ts +7 -0
  28. package/package.json +1 -1
  29. /package/dist/models/{unlink-bank-transaction-request-dto-rest.js → bank-transaction-invoice-class.js} +0 -0
@@ -145,7 +145,7 @@ var BankTransactionApiAxiosParamCreator = function (configuration) {
145
145
  * @summary Retrieve the bank transaction
146
146
  * @param {string} code
147
147
  * @param {string} [authorization] Bearer Token
148
- * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder<i>
148
+ * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder, bankTransactionInvoices<i>
149
149
  * @param {*} [options] Override http request option.
150
150
  * @throws {RequiredError}
151
151
  */
@@ -306,7 +306,7 @@ var BankTransactionApiAxiosParamCreator = function (configuration) {
306
306
  * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, bankAccountId, bankAccountNumber, messageReference, amount, currency, transactionReference, transactionDate, entryDate, isLinked</i>
307
307
  * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: id, createdAt, amount</i>
308
308
  * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt, transactionDate, entryDate</i>
309
- * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder<i>
309
+ * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder, bankTransactionInvoices<i>
310
310
  * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, bankAccountId, bankAccountNumber, messageReference, amount, currency, transactionReference, transactionDate, entryDate, isLinked</i>
311
311
  * @param {*} [options] Override http request option.
312
312
  * @throws {RequiredError}
@@ -373,12 +373,11 @@ var BankTransactionApiAxiosParamCreator = function (configuration) {
373
373
  * Unlinks an already linked bank transaction **Required Permissions** \"payment-management.bank-accounts.update\"
374
374
  * @summary Unlink bank transaction
375
375
  * @param {string} code Code of the bank transaction to unlink
376
- * @param {UnlinkBankTransactionRequestDtoRest} unlinkBankTransactionRequestDtoRest
377
376
  * @param {string} [authorization] Bearer Token
378
377
  * @param {*} [options] Override http request option.
379
378
  * @throws {RequiredError}
380
379
  */
381
- unlinkBankTransaction: function (code, unlinkBankTransactionRequestDtoRest, authorization, options) {
380
+ unlinkBankTransaction: function (code, authorization, options) {
382
381
  if (options === void 0) { options = {}; }
383
382
  return __awaiter(_this, void 0, void 0, function () {
384
383
  var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
@@ -387,8 +386,6 @@ var BankTransactionApiAxiosParamCreator = function (configuration) {
387
386
  case 0:
388
387
  // verify required parameter 'code' is not null or undefined
389
388
  (0, common_1.assertParamExists)('unlinkBankTransaction', 'code', code);
390
- // verify required parameter 'unlinkBankTransactionRequestDtoRest' is not null or undefined
391
- (0, common_1.assertParamExists)('unlinkBankTransaction', 'unlinkBankTransactionRequestDtoRest', unlinkBankTransactionRequestDtoRest);
392
389
  localVarPath = "/paymentservice/v1/tenant/bank-transactions/{code}/unlink"
393
390
  .replace("{".concat("code", "}"), encodeURIComponent(String(code)));
394
391
  localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
@@ -409,11 +406,9 @@ var BankTransactionApiAxiosParamCreator = function (configuration) {
409
406
  if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
410
407
  localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
411
408
  }
412
- localVarHeaderParameter['Content-Type'] = 'application/json';
413
409
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
414
410
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
415
411
  localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
416
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(unlinkBankTransactionRequestDtoRest, localVarRequestOptions, configuration);
417
412
  return [2 /*return*/, {
418
413
  url: (0, common_1.toPathString)(localVarUrlObj),
419
414
  options: localVarRequestOptions,
@@ -458,7 +453,7 @@ var BankTransactionApiFp = function (configuration) {
458
453
  * @summary Retrieve the bank transaction
459
454
  * @param {string} code
460
455
  * @param {string} [authorization] Bearer Token
461
- * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder<i>
456
+ * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder, bankTransactionInvoices<i>
462
457
  * @param {*} [options] Override http request option.
463
458
  * @throws {RequiredError}
464
459
  */
@@ -527,7 +522,7 @@ var BankTransactionApiFp = function (configuration) {
527
522
  * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, bankAccountId, bankAccountNumber, messageReference, amount, currency, transactionReference, transactionDate, entryDate, isLinked</i>
528
523
  * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: id, createdAt, amount</i>
529
524
  * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt, transactionDate, entryDate</i>
530
- * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder<i>
525
+ * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder, bankTransactionInvoices<i>
531
526
  * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, bankAccountId, bankAccountNumber, messageReference, amount, currency, transactionReference, transactionDate, entryDate, isLinked</i>
532
527
  * @param {*} [options] Override http request option.
533
528
  * @throws {RequiredError}
@@ -549,17 +544,16 @@ var BankTransactionApiFp = function (configuration) {
549
544
  * Unlinks an already linked bank transaction **Required Permissions** \"payment-management.bank-accounts.update\"
550
545
  * @summary Unlink bank transaction
551
546
  * @param {string} code Code of the bank transaction to unlink
552
- * @param {UnlinkBankTransactionRequestDtoRest} unlinkBankTransactionRequestDtoRest
553
547
  * @param {string} [authorization] Bearer Token
554
548
  * @param {*} [options] Override http request option.
555
549
  * @throws {RequiredError}
556
550
  */
557
- unlinkBankTransaction: function (code, unlinkBankTransactionRequestDtoRest, authorization, options) {
551
+ unlinkBankTransaction: function (code, authorization, options) {
558
552
  return __awaiter(this, void 0, void 0, function () {
559
553
  var localVarAxiosArgs;
560
554
  return __generator(this, function (_a) {
561
555
  switch (_a.label) {
562
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.unlinkBankTransaction(code, unlinkBankTransactionRequestDtoRest, authorization, options)];
556
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.unlinkBankTransaction(code, authorization, options)];
563
557
  case 1:
564
558
  localVarAxiosArgs = _a.sent();
565
559
  return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
@@ -593,7 +587,7 @@ var BankTransactionApiFactory = function (configuration, basePath, axios) {
593
587
  * @summary Retrieve the bank transaction
594
588
  * @param {string} code
595
589
  * @param {string} [authorization] Bearer Token
596
- * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder<i>
590
+ * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder, bankTransactionInvoices<i>
597
591
  * @param {*} [options] Override http request option.
598
592
  * @throws {RequiredError}
599
593
  */
@@ -632,7 +626,7 @@ var BankTransactionApiFactory = function (configuration, basePath, axios) {
632
626
  * @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, bankAccountId, bankAccountNumber, messageReference, amount, currency, transactionReference, transactionDate, entryDate, isLinked</i>
633
627
  * @param {string} [search] Search the response for matches in any searchable field. Use filter instead where possible for improved performance.<br/> <br/> <i>Searchable fields: id, createdAt, amount</i>
634
628
  * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, createdAt, transactionDate, entryDate</i>
635
- * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder<i>
629
+ * @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.<br/> <br/> <i>Allowed values: bankAccount, transaction, invoiceMatchSuggestions, suggestionGenerationProgress, linkedBankOrder, bankTransactionInvoices<i>
636
630
  * @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, bankAccountId, bankAccountNumber, messageReference, amount, currency, transactionReference, transactionDate, entryDate, isLinked</i>
637
631
  * @param {*} [options] Override http request option.
638
632
  * @throws {RequiredError}
@@ -644,13 +638,12 @@ var BankTransactionApiFactory = function (configuration, basePath, axios) {
644
638
  * Unlinks an already linked bank transaction **Required Permissions** \"payment-management.bank-accounts.update\"
645
639
  * @summary Unlink bank transaction
646
640
  * @param {string} code Code of the bank transaction to unlink
647
- * @param {UnlinkBankTransactionRequestDtoRest} unlinkBankTransactionRequestDtoRest
648
641
  * @param {string} [authorization] Bearer Token
649
642
  * @param {*} [options] Override http request option.
650
643
  * @throws {RequiredError}
651
644
  */
652
- unlinkBankTransaction: function (code, unlinkBankTransactionRequestDtoRest, authorization, options) {
653
- return localVarFp.unlinkBankTransaction(code, unlinkBankTransactionRequestDtoRest, authorization, options).then(function (request) { return request(axios, basePath); });
645
+ unlinkBankTransaction: function (code, authorization, options) {
646
+ return localVarFp.unlinkBankTransaction(code, authorization, options).then(function (request) { return request(axios, basePath); });
654
647
  },
655
648
  };
656
649
  };
@@ -737,7 +730,7 @@ var BankTransactionApi = /** @class */ (function (_super) {
737
730
  */
738
731
  BankTransactionApi.prototype.unlinkBankTransaction = function (requestParameters, options) {
739
732
  var _this = this;
740
- return (0, exports.BankTransactionApiFp)(this.configuration).unlinkBankTransaction(requestParameters.code, requestParameters.unlinkBankTransactionRequestDtoRest, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
733
+ return (0, exports.BankTransactionApiFp)(this.configuration).unlinkBankTransaction(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
741
734
  };
742
735
  return BankTransactionApi;
743
736
  }(base_1.BaseAPI));
@@ -12,6 +12,7 @@
12
12
  import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
13
13
  import { Configuration } from '../configuration';
14
14
  import { RequestArgs, BaseAPI } from '../base';
15
+ import { CreatePaymentOrderDto } from '../models';
15
16
  import { CreatePaymentRequestDto } from '../models';
16
17
  import { CreatePaymentResponseClass } from '../models';
17
18
  import { GetPaymentResponseClass } from '../models';
@@ -22,15 +23,26 @@ import { ListPaymentsResponseClass } from '../models';
22
23
  */
23
24
  export declare const PaymentsApiAxiosParamCreator: (configuration?: Configuration) => {
24
25
  /**
25
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
26
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
26
27
  * @summary Create the payment
27
28
  * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
28
29
  * @param {CreatePaymentRequestDto} createPaymentRequestDto
29
30
  * @param {string} [authorization] Bearer Token
30
31
  * @param {*} [options] Override http request option.
32
+ * @deprecated
31
33
  * @throws {RequiredError}
32
34
  */
33
35
  createPayment: (idempotencyKey: string, createPaymentRequestDto: CreatePaymentRequestDto, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
36
+ /**
37
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
38
+ * @summary Create the payment
39
+ * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
40
+ * @param {CreatePaymentOrderDto} createPaymentOrderDto
41
+ * @param {string} [authorization] Bearer Token
42
+ * @param {*} [options] Override http request option.
43
+ * @throws {RequiredError}
44
+ */
45
+ createPaymentOrder: (idempotencyKey: string, createPaymentOrderDto: CreatePaymentOrderDto, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
34
46
  /**
35
47
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
36
48
  * @summary Retrieve the payment
@@ -63,15 +75,26 @@ export declare const PaymentsApiAxiosParamCreator: (configuration?: Configuratio
63
75
  */
64
76
  export declare const PaymentsApiFp: (configuration?: Configuration) => {
65
77
  /**
66
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
78
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
67
79
  * @summary Create the payment
68
80
  * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
69
81
  * @param {CreatePaymentRequestDto} createPaymentRequestDto
70
82
  * @param {string} [authorization] Bearer Token
71
83
  * @param {*} [options] Override http request option.
84
+ * @deprecated
72
85
  * @throws {RequiredError}
73
86
  */
74
87
  createPayment(idempotencyKey: string, createPaymentRequestDto: CreatePaymentRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreatePaymentResponseClass>>;
88
+ /**
89
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
90
+ * @summary Create the payment
91
+ * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
92
+ * @param {CreatePaymentOrderDto} createPaymentOrderDto
93
+ * @param {string} [authorization] Bearer Token
94
+ * @param {*} [options] Override http request option.
95
+ * @throws {RequiredError}
96
+ */
97
+ createPaymentOrder(idempotencyKey: string, createPaymentOrderDto: CreatePaymentOrderDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreatePaymentResponseClass>>;
75
98
  /**
76
99
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
77
100
  * @summary Retrieve the payment
@@ -104,15 +127,26 @@ export declare const PaymentsApiFp: (configuration?: Configuration) => {
104
127
  */
105
128
  export declare const PaymentsApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
106
129
  /**
107
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
130
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
108
131
  * @summary Create the payment
109
132
  * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
110
133
  * @param {CreatePaymentRequestDto} createPaymentRequestDto
111
134
  * @param {string} [authorization] Bearer Token
112
135
  * @param {*} [options] Override http request option.
136
+ * @deprecated
113
137
  * @throws {RequiredError}
114
138
  */
115
139
  createPayment(idempotencyKey: string, createPaymentRequestDto: CreatePaymentRequestDto, authorization?: string, options?: any): AxiosPromise<CreatePaymentResponseClass>;
140
+ /**
141
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
142
+ * @summary Create the payment
143
+ * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
144
+ * @param {CreatePaymentOrderDto} createPaymentOrderDto
145
+ * @param {string} [authorization] Bearer Token
146
+ * @param {*} [options] Override http request option.
147
+ * @throws {RequiredError}
148
+ */
149
+ createPaymentOrder(idempotencyKey: string, createPaymentOrderDto: CreatePaymentOrderDto, authorization?: string, options?: any): AxiosPromise<CreatePaymentResponseClass>;
116
150
  /**
117
151
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
118
152
  * @summary Retrieve the payment
@@ -164,6 +198,31 @@ export interface PaymentsApiCreatePaymentRequest {
164
198
  */
165
199
  readonly authorization?: string;
166
200
  }
201
+ /**
202
+ * Request parameters for createPaymentOrder operation in PaymentsApi.
203
+ * @export
204
+ * @interface PaymentsApiCreatePaymentOrderRequest
205
+ */
206
+ export interface PaymentsApiCreatePaymentOrderRequest {
207
+ /**
208
+ * Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
209
+ * @type {string}
210
+ * @memberof PaymentsApiCreatePaymentOrder
211
+ */
212
+ readonly idempotencyKey: string;
213
+ /**
214
+ *
215
+ * @type {CreatePaymentOrderDto}
216
+ * @memberof PaymentsApiCreatePaymentOrder
217
+ */
218
+ readonly createPaymentOrderDto: CreatePaymentOrderDto;
219
+ /**
220
+ * Bearer Token
221
+ * @type {string}
222
+ * @memberof PaymentsApiCreatePaymentOrder
223
+ */
224
+ readonly authorization?: string;
225
+ }
167
226
  /**
168
227
  * Request parameters for getPayment operation in PaymentsApi.
169
228
  * @export
@@ -252,14 +311,24 @@ export interface PaymentsApiListPaymentsRequest {
252
311
  */
253
312
  export declare class PaymentsApi extends BaseAPI {
254
313
  /**
255
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
314
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
256
315
  * @summary Create the payment
257
316
  * @param {PaymentsApiCreatePaymentRequest} requestParameters Request parameters.
258
317
  * @param {*} [options] Override http request option.
318
+ * @deprecated
259
319
  * @throws {RequiredError}
260
320
  * @memberof PaymentsApi
261
321
  */
262
322
  createPayment(requestParameters: PaymentsApiCreatePaymentRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreatePaymentResponseClass, any>>;
323
+ /**
324
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
325
+ * @summary Create the payment
326
+ * @param {PaymentsApiCreatePaymentOrderRequest} requestParameters Request parameters.
327
+ * @param {*} [options] Override http request option.
328
+ * @throws {RequiredError}
329
+ * @memberof PaymentsApi
330
+ */
331
+ createPaymentOrder(requestParameters: PaymentsApiCreatePaymentOrderRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreatePaymentResponseClass, any>>;
263
332
  /**
264
333
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
265
334
  * @summary Retrieve the payment
@@ -93,12 +93,13 @@ var PaymentsApiAxiosParamCreator = function (configuration) {
93
93
  var _this = this;
94
94
  return {
95
95
  /**
96
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
96
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
97
97
  * @summary Create the payment
98
98
  * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
99
99
  * @param {CreatePaymentRequestDto} createPaymentRequestDto
100
100
  * @param {string} [authorization] Bearer Token
101
101
  * @param {*} [options] Override http request option.
102
+ * @deprecated
102
103
  * @throws {RequiredError}
103
104
  */
104
105
  createPayment: function (idempotencyKey, createPaymentRequestDto, authorization, options) {
@@ -147,6 +148,61 @@ var PaymentsApiAxiosParamCreator = function (configuration) {
147
148
  });
148
149
  });
149
150
  },
151
+ /**
152
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
153
+ * @summary Create the payment
154
+ * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
155
+ * @param {CreatePaymentOrderDto} createPaymentOrderDto
156
+ * @param {string} [authorization] Bearer Token
157
+ * @param {*} [options] Override http request option.
158
+ * @throws {RequiredError}
159
+ */
160
+ createPaymentOrder: function (idempotencyKey, createPaymentOrderDto, authorization, options) {
161
+ if (options === void 0) { options = {}; }
162
+ return __awaiter(_this, void 0, void 0, function () {
163
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
164
+ return __generator(this, function (_a) {
165
+ switch (_a.label) {
166
+ case 0:
167
+ // verify required parameter 'idempotencyKey' is not null or undefined
168
+ (0, common_1.assertParamExists)('createPaymentOrder', 'idempotencyKey', idempotencyKey);
169
+ // verify required parameter 'createPaymentOrderDto' is not null or undefined
170
+ (0, common_1.assertParamExists)('createPaymentOrder', 'createPaymentOrderDto', createPaymentOrderDto);
171
+ localVarPath = "/paymentservice/v1/payments/order";
172
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
173
+ if (configuration) {
174
+ baseOptions = configuration.baseOptions;
175
+ baseAccessToken = configuration.accessToken;
176
+ }
177
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
178
+ localVarHeaderParameter = {};
179
+ localVarQueryParameter = {};
180
+ // authentication bearer required
181
+ // http bearer authentication required
182
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
183
+ case 1:
184
+ // authentication bearer required
185
+ // http bearer authentication required
186
+ _a.sent();
187
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
188
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
189
+ }
190
+ if (idempotencyKey !== undefined && idempotencyKey !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
191
+ localVarHeaderParameter['Idempotency-Key'] = String(idempotencyKey ? idempotencyKey : baseAccessToken);
192
+ }
193
+ localVarHeaderParameter['Content-Type'] = 'application/json';
194
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
195
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
196
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
197
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createPaymentOrderDto, localVarRequestOptions, configuration);
198
+ return [2 /*return*/, {
199
+ url: (0, common_1.toPathString)(localVarUrlObj),
200
+ options: localVarRequestOptions,
201
+ }];
202
+ }
203
+ });
204
+ });
205
+ },
150
206
  /**
151
207
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
152
208
  * @summary Retrieve the payment
@@ -282,12 +338,13 @@ var PaymentsApiFp = function (configuration) {
282
338
  var localVarAxiosParamCreator = (0, exports.PaymentsApiAxiosParamCreator)(configuration);
283
339
  return {
284
340
  /**
285
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
341
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
286
342
  * @summary Create the payment
287
343
  * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
288
344
  * @param {CreatePaymentRequestDto} createPaymentRequestDto
289
345
  * @param {string} [authorization] Bearer Token
290
346
  * @param {*} [options] Override http request option.
347
+ * @deprecated
291
348
  * @throws {RequiredError}
292
349
  */
293
350
  createPayment: function (idempotencyKey, createPaymentRequestDto, authorization, options) {
@@ -303,6 +360,28 @@ var PaymentsApiFp = function (configuration) {
303
360
  });
304
361
  });
305
362
  },
363
+ /**
364
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
365
+ * @summary Create the payment
366
+ * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
367
+ * @param {CreatePaymentOrderDto} createPaymentOrderDto
368
+ * @param {string} [authorization] Bearer Token
369
+ * @param {*} [options] Override http request option.
370
+ * @throws {RequiredError}
371
+ */
372
+ createPaymentOrder: function (idempotencyKey, createPaymentOrderDto, authorization, options) {
373
+ return __awaiter(this, void 0, void 0, function () {
374
+ var localVarAxiosArgs;
375
+ return __generator(this, function (_a) {
376
+ switch (_a.label) {
377
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.createPaymentOrder(idempotencyKey, createPaymentOrderDto, authorization, options)];
378
+ case 1:
379
+ localVarAxiosArgs = _a.sent();
380
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
381
+ }
382
+ });
383
+ });
384
+ },
306
385
  /**
307
386
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
308
387
  * @summary Retrieve the payment
@@ -363,17 +442,30 @@ var PaymentsApiFactory = function (configuration, basePath, axios) {
363
442
  var localVarFp = (0, exports.PaymentsApiFp)(configuration);
364
443
  return {
365
444
  /**
366
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
445
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
367
446
  * @summary Create the payment
368
447
  * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
369
448
  * @param {CreatePaymentRequestDto} createPaymentRequestDto
370
449
  * @param {string} [authorization] Bearer Token
371
450
  * @param {*} [options] Override http request option.
451
+ * @deprecated
372
452
  * @throws {RequiredError}
373
453
  */
374
454
  createPayment: function (idempotencyKey, createPaymentRequestDto, authorization, options) {
375
455
  return localVarFp.createPayment(idempotencyKey, createPaymentRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
376
456
  },
457
+ /**
458
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
459
+ * @summary Create the payment
460
+ * @param {string} idempotencyKey Idempotency Key used to make the request idempotent. The key should be unique. Usually, a generated v4 UUID is enough.
461
+ * @param {CreatePaymentOrderDto} createPaymentOrderDto
462
+ * @param {string} [authorization] Bearer Token
463
+ * @param {*} [options] Override http request option.
464
+ * @throws {RequiredError}
465
+ */
466
+ createPaymentOrder: function (idempotencyKey, createPaymentOrderDto, authorization, options) {
467
+ return localVarFp.createPaymentOrder(idempotencyKey, createPaymentOrderDto, authorization, options).then(function (request) { return request(axios, basePath); });
468
+ },
377
469
  /**
378
470
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
379
471
  * @summary Retrieve the payment
@@ -418,10 +510,11 @@ var PaymentsApi = /** @class */ (function (_super) {
418
510
  return _super !== null && _super.apply(this, arguments) || this;
419
511
  }
420
512
  /**
421
- * This will create a payment for a specified account. This function is idempotent. **Required Permissions** \"payment-management.payments.create\"
513
+ * This will create a payment for a specified account. This function is idempotent. This endpoint is deprecated. Please use the create Payment Order endpoint instead. **Required Permissions** \"payment-management.payments.create\"
422
514
  * @summary Create the payment
423
515
  * @param {PaymentsApiCreatePaymentRequest} requestParameters Request parameters.
424
516
  * @param {*} [options] Override http request option.
517
+ * @deprecated
425
518
  * @throws {RequiredError}
426
519
  * @memberof PaymentsApi
427
520
  */
@@ -429,6 +522,18 @@ var PaymentsApi = /** @class */ (function (_super) {
429
522
  var _this = this;
430
523
  return (0, exports.PaymentsApiFp)(this.configuration).createPayment(requestParameters.idempotencyKey, requestParameters.createPaymentRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
431
524
  };
525
+ /**
526
+ * This will create a payment order for a specified invoice. **Required Permissions** \"payment-management.payments.create\"
527
+ * @summary Create the payment
528
+ * @param {PaymentsApiCreatePaymentOrderRequest} requestParameters Request parameters.
529
+ * @param {*} [options] Override http request option.
530
+ * @throws {RequiredError}
531
+ * @memberof PaymentsApi
532
+ */
533
+ PaymentsApi.prototype.createPaymentOrder = function (requestParameters, options) {
534
+ var _this = this;
535
+ return (0, exports.PaymentsApiFp)(this.configuration).createPaymentOrder(requestParameters.idempotencyKey, requestParameters.createPaymentOrderDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
536
+ };
432
537
  /**
433
538
  * Retrieves the details of the payment that was previously created. Supply the unique payment code that was returned when you created it and Emil Api will return the corresponding payment information. **Required Permissions** \"payment-management.payments.view\"
434
539
  * @summary Retrieve the payment
@@ -10,6 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import { BankOrderClass } from './bank-order-class';
13
+ import { BankTransactionInvoiceClass } from './bank-transaction-invoice-class';
13
14
  /**
14
15
  *
15
16
  * @export
@@ -94,24 +95,18 @@ export interface BankTransactionClassWithoutExpandProperties {
94
95
  * @memberof BankTransactionClassWithoutExpandProperties
95
96
  */
96
97
  'linkedTransactionId'?: number;
97
- /**
98
- * The code of the invoice that this bank transaction is linked to
99
- * @type {string}
100
- * @memberof BankTransactionClassWithoutExpandProperties
101
- */
102
- 'linkedInvoiceCode'?: string;
103
- /**
104
- * The identifying invoice number that this bank transaction is linked to
105
- * @type {string}
106
- * @memberof BankTransactionClassWithoutExpandProperties
107
- */
108
- 'linkedInvoiceNumber'?: string;
109
98
  /**
110
99
  * Boolean flag to indicate if the bank transaction is linked to an invoice - defaults to false
111
100
  * @type {boolean}
112
101
  * @memberof BankTransactionClassWithoutExpandProperties
113
102
  */
114
103
  'isLinked': boolean;
104
+ /**
105
+ * The bank transaction invoices that this bank transaction is linked to
106
+ * @type {Array<BankTransactionInvoiceClass>}
107
+ * @memberof BankTransactionClassWithoutExpandProperties
108
+ */
109
+ 'bankTransactionInvoices'?: Array<BankTransactionInvoiceClass>;
115
110
  /**
116
111
  * The linked bank order object
117
112
  * @type {BankOrderClass}
@@ -10,6 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import { BankOrderClass } from './bank-order-class';
13
+ import { BankTransactionInvoiceClass } from './bank-transaction-invoice-class';
13
14
  import { InvoiceMatchSuggestionClass } from './invoice-match-suggestion-class';
14
15
  import { SharedTransactionClass } from './shared-transaction-class';
15
16
  import { SuggestionGenerationProgressClass } from './suggestion-generation-progress-class';
@@ -98,24 +99,18 @@ export interface BankTransactionClass {
98
99
  * @memberof BankTransactionClass
99
100
  */
100
101
  'linkedTransactionId'?: number;
101
- /**
102
- * The code of the invoice that this bank transaction is linked to
103
- * @type {string}
104
- * @memberof BankTransactionClass
105
- */
106
- 'linkedInvoiceCode'?: string;
107
- /**
108
- * The identifying invoice number that this bank transaction is linked to
109
- * @type {string}
110
- * @memberof BankTransactionClass
111
- */
112
- 'linkedInvoiceNumber'?: string;
113
102
  /**
114
103
  * Boolean flag to indicate if the bank transaction is linked to an invoice - defaults to false
115
104
  * @type {boolean}
116
105
  * @memberof BankTransactionClass
117
106
  */
118
107
  'isLinked': boolean;
108
+ /**
109
+ * The bank transaction invoices that this bank transaction is linked to
110
+ * @type {Array<BankTransactionInvoiceClass>}
111
+ * @memberof BankTransactionClass
112
+ */
113
+ 'bankTransactionInvoices'?: Array<BankTransactionInvoiceClass>;
119
114
  /**
120
115
  * The bank account object that this transaction is belongs to
121
116
  * @type {TenantBankAccountClassWithoutExpandProperties}
@@ -0,0 +1,54 @@
1
+ /**
2
+ * Emil Payment Service
3
+ * 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.
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
+ /**
13
+ *
14
+ * @export
15
+ * @interface BankTransactionInvoiceClass
16
+ */
17
+ export interface BankTransactionInvoiceClass {
18
+ /**
19
+ * Internal unique identifier for the object. You should not have to use this, use code instead.
20
+ * @type {number}
21
+ * @memberof BankTransactionInvoiceClass
22
+ */
23
+ 'id': number;
24
+ /**
25
+ * Unique identifier for the object.
26
+ * @type {string}
27
+ * @memberof BankTransactionInvoiceClass
28
+ */
29
+ 'code': string;
30
+ /**
31
+ * Bank transaction id
32
+ * @type {number}
33
+ * @memberof BankTransactionInvoiceClass
34
+ */
35
+ 'bankTransactionId': number;
36
+ /**
37
+ * Invoice code of the bank transaction invoice
38
+ * @type {string}
39
+ * @memberof BankTransactionInvoiceClass
40
+ */
41
+ 'invoiceCode': string;
42
+ /**
43
+ * Invoice number of the bank transaction invoice
44
+ * @type {string}
45
+ * @memberof BankTransactionInvoiceClass
46
+ */
47
+ 'invoiceNumber': string;
48
+ /**
49
+ * Time at which the object was created.
50
+ * @type {string}
51
+ * @memberof BankTransactionInvoiceClass
52
+ */
53
+ 'createdAt': string;
54
+ }