@emilgroup/payment-sdk 1.22.1-beta.48 → 1.22.1-beta.49

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 (73) hide show
  1. package/.openapi-generator/FILES +2 -0
  2. package/README.md +2 -2
  3. package/api/bank-orders-api.ts +8 -8
  4. package/api/exceeding-credits-api.ts +107 -0
  5. package/api/payment-requests-api.ts +12 -12
  6. package/base.ts +36 -15
  7. package/configuration.ts +11 -0
  8. package/dist/api/bank-orders-api.d.ts +8 -8
  9. package/dist/api/bank-orders-api.js +6 -6
  10. package/dist/api/exceeding-credits-api.d.ts +57 -0
  11. package/dist/api/exceeding-credits-api.js +93 -0
  12. package/dist/api/payment-requests-api.d.ts +12 -12
  13. package/dist/api/payment-requests-api.js +9 -9
  14. package/dist/base.d.ts +1 -0
  15. package/dist/base.js +36 -16
  16. package/dist/configuration.d.ts +9 -0
  17. package/dist/configuration.js +1 -0
  18. package/dist/models/bank-order-entity.d.ts +1 -0
  19. package/dist/models/bank-order-entity.js +1 -0
  20. package/dist/models/create-bank-order-request-dto.d.ts +3 -2
  21. package/dist/models/create-bank-order-request-dto.js +1 -0
  22. package/dist/models/create-exceeding-credit-request-dto.d.ts +48 -0
  23. package/dist/models/create-exceeding-credit-request-dto.js +15 -0
  24. package/dist/models/create-exceeding-credit-response-class.d.ts +25 -0
  25. package/dist/models/create-exceeding-credit-response-class.js +15 -0
  26. package/dist/models/create-payment-order-dto.d.ts +1 -1
  27. package/dist/models/create-payment-receipt-request-dto.d.ts +1 -1
  28. package/dist/models/create-payment-request-dto.d.ts +1 -1
  29. package/dist/models/create-payment-request-request-dto.d.ts +12 -0
  30. package/dist/models/credit-allocation-class.d.ts +6 -0
  31. package/dist/models/credit-allocation-entity.d.ts +6 -0
  32. package/dist/models/index.d.ts +2 -0
  33. package/dist/models/index.js +2 -0
  34. package/dist/models/list-billing-addresses-response-class.d.ts +9 -9
  35. package/dist/models/list-exceeding-credits-response-class.d.ts +6 -18
  36. package/dist/models/list-payment-receipts-response-class.d.ts +9 -9
  37. package/dist/models/list-payment-requests-response-class.d.ts +6 -18
  38. package/dist/models/list-payout-methods-response-class.d.ts +9 -9
  39. package/dist/models/list-refunds-response-class.d.ts +6 -18
  40. package/dist/models/payment-class-without-expand-properties.d.ts +2 -2
  41. package/dist/models/payment-class.d.ts +2 -2
  42. package/dist/models/payment-entity.d.ts +1 -1
  43. package/dist/models/payment-receipt-class.d.ts +1 -1
  44. package/dist/models/payment-request-class.d.ts +30 -0
  45. package/dist/models/shared-transaction-class.d.ts +6 -0
  46. package/dist/models/transaction-entity.d.ts +6 -0
  47. package/dist/models/update-bank-order-request-dto.d.ts +2 -2
  48. package/models/bank-order-entity.ts +1 -0
  49. package/models/create-bank-order-request-dto.ts +3 -2
  50. package/models/create-exceeding-credit-request-dto.ts +54 -0
  51. package/models/create-exceeding-credit-response-class.ts +31 -0
  52. package/models/create-payment-order-dto.ts +1 -1
  53. package/models/create-payment-receipt-request-dto.ts +1 -1
  54. package/models/create-payment-request-dto.ts +1 -1
  55. package/models/create-payment-request-request-dto.ts +12 -0
  56. package/models/credit-allocation-class.ts +6 -0
  57. package/models/credit-allocation-entity.ts +6 -0
  58. package/models/index.ts +2 -0
  59. package/models/list-billing-addresses-response-class.ts +9 -9
  60. package/models/list-exceeding-credits-response-class.ts +6 -18
  61. package/models/list-payment-receipts-response-class.ts +9 -9
  62. package/models/list-payment-requests-response-class.ts +6 -18
  63. package/models/list-payout-methods-response-class.ts +9 -9
  64. package/models/list-refunds-response-class.ts +6 -18
  65. package/models/payment-class-without-expand-properties.ts +2 -2
  66. package/models/payment-class.ts +2 -2
  67. package/models/payment-entity.ts +1 -1
  68. package/models/payment-receipt-class.ts +1 -1
  69. package/models/payment-request-class.ts +30 -0
  70. package/models/shared-transaction-class.ts +6 -0
  71. package/models/transaction-entity.ts +6 -0
  72. package/models/update-bank-order-request-dto.ts +2 -2
  73. package/package.json +1 -1
@@ -12,6 +12,8 @@
12
12
  import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
13
13
  import { Configuration } from '../configuration';
14
14
  import { RequestArgs, BaseAPI } from '../base';
15
+ import { CreateExceedingCreditRequestDto } from '../models';
16
+ import { CreateExceedingCreditResponseClass } from '../models';
15
17
  import { GetExceedingCreditResponseClass } from '../models';
16
18
  import { ListExceedingCreditsResponseClass } from '../models';
17
19
  /**
@@ -19,6 +21,15 @@ import { ListExceedingCreditsResponseClass } from '../models';
19
21
  * @export
20
22
  */
21
23
  export declare const ExceedingCreditsApiAxiosParamCreator: (configuration?: Configuration) => {
24
+ /**
25
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
26
+ * @summary Create the exceeding credit
27
+ * @param {CreateExceedingCreditRequestDto} createExceedingCreditRequestDto
28
+ * @param {string} [authorization] Bearer Token
29
+ * @param {*} [options] Override http request option.
30
+ * @throws {RequiredError}
31
+ */
32
+ createExceedingCredit: (createExceedingCreditRequestDto: CreateExceedingCreditRequestDto, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
22
33
  /**
23
34
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
24
35
  * @summary Retrieve the exceeding credit
@@ -49,6 +60,15 @@ export declare const ExceedingCreditsApiAxiosParamCreator: (configuration?: Conf
49
60
  * @export
50
61
  */
51
62
  export declare const ExceedingCreditsApiFp: (configuration?: Configuration) => {
63
+ /**
64
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
65
+ * @summary Create the exceeding credit
66
+ * @param {CreateExceedingCreditRequestDto} createExceedingCreditRequestDto
67
+ * @param {string} [authorization] Bearer Token
68
+ * @param {*} [options] Override http request option.
69
+ * @throws {RequiredError}
70
+ */
71
+ createExceedingCredit(createExceedingCreditRequestDto: CreateExceedingCreditRequestDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreateExceedingCreditResponseClass>>;
52
72
  /**
53
73
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
54
74
  * @summary Retrieve the exceeding credit
@@ -79,6 +99,15 @@ export declare const ExceedingCreditsApiFp: (configuration?: Configuration) => {
79
99
  * @export
80
100
  */
81
101
  export declare const ExceedingCreditsApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
102
+ /**
103
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
104
+ * @summary Create the exceeding credit
105
+ * @param {CreateExceedingCreditRequestDto} createExceedingCreditRequestDto
106
+ * @param {string} [authorization] Bearer Token
107
+ * @param {*} [options] Override http request option.
108
+ * @throws {RequiredError}
109
+ */
110
+ createExceedingCredit(createExceedingCreditRequestDto: CreateExceedingCreditRequestDto, authorization?: string, options?: any): AxiosPromise<CreateExceedingCreditResponseClass>;
82
111
  /**
83
112
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
84
113
  * @summary Retrieve the exceeding credit
@@ -104,6 +133,25 @@ export declare const ExceedingCreditsApiFactory: (configuration?: Configuration,
104
133
  */
105
134
  listExceedingCredits(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListExceedingCreditsResponseClass>;
106
135
  };
136
+ /**
137
+ * Request parameters for createExceedingCredit operation in ExceedingCreditsApi.
138
+ * @export
139
+ * @interface ExceedingCreditsApiCreateExceedingCreditRequest
140
+ */
141
+ export interface ExceedingCreditsApiCreateExceedingCreditRequest {
142
+ /**
143
+ *
144
+ * @type {CreateExceedingCreditRequestDto}
145
+ * @memberof ExceedingCreditsApiCreateExceedingCredit
146
+ */
147
+ readonly createExceedingCreditRequestDto: CreateExceedingCreditRequestDto;
148
+ /**
149
+ * Bearer Token
150
+ * @type {string}
151
+ * @memberof ExceedingCreditsApiCreateExceedingCredit
152
+ */
153
+ readonly authorization?: string;
154
+ }
107
155
  /**
108
156
  * Request parameters for getExceedingCredit operation in ExceedingCreditsApi.
109
157
  * @export
@@ -185,6 +233,15 @@ export interface ExceedingCreditsApiListExceedingCreditsRequest {
185
233
  * @extends {BaseAPI}
186
234
  */
187
235
  export declare class ExceedingCreditsApi extends BaseAPI {
236
+ /**
237
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
238
+ * @summary Create the exceeding credit
239
+ * @param {ExceedingCreditsApiCreateExceedingCreditRequest} requestParameters Request parameters.
240
+ * @param {*} [options] Override http request option.
241
+ * @throws {RequiredError}
242
+ * @memberof ExceedingCreditsApi
243
+ */
244
+ createExceedingCredit(requestParameters: ExceedingCreditsApiCreateExceedingCreditRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateExceedingCreditResponseClass, any, {}>>;
188
245
  /**
189
246
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
190
247
  * @summary Retrieve the exceeding credit
@@ -92,6 +92,55 @@ var base_1 = require("../base");
92
92
  var ExceedingCreditsApiAxiosParamCreator = function (configuration) {
93
93
  var _this = this;
94
94
  return {
95
+ /**
96
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
97
+ * @summary Create the exceeding credit
98
+ * @param {CreateExceedingCreditRequestDto} createExceedingCreditRequestDto
99
+ * @param {string} [authorization] Bearer Token
100
+ * @param {*} [options] Override http request option.
101
+ * @throws {RequiredError}
102
+ */
103
+ createExceedingCredit: function (createExceedingCreditRequestDto, 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 'createExceedingCreditRequestDto' is not null or undefined
111
+ (0, common_1.assertParamExists)('createExceedingCredit', 'createExceedingCreditRequestDto', createExceedingCreditRequestDto);
112
+ localVarPath = "/paymentservice/v1/exceeding-credits";
113
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
114
+ if (configuration) {
115
+ baseOptions = configuration.baseOptions;
116
+ baseAccessToken = configuration.accessToken;
117
+ }
118
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
119
+ localVarHeaderParameter = {};
120
+ localVarQueryParameter = {};
121
+ // authentication bearer required
122
+ // http bearer authentication required
123
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
124
+ case 1:
125
+ // authentication bearer required
126
+ // http bearer authentication required
127
+ _a.sent();
128
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
129
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
130
+ }
131
+ localVarHeaderParameter['Content-Type'] = 'application/json';
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
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createExceedingCreditRequestDto, localVarRequestOptions, configuration);
136
+ return [2 /*return*/, {
137
+ url: (0, common_1.toPathString)(localVarUrlObj),
138
+ options: localVarRequestOptions,
139
+ }];
140
+ }
141
+ });
142
+ });
143
+ },
95
144
  /**
96
145
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
97
146
  * @summary Retrieve the exceeding credit
@@ -222,6 +271,27 @@ exports.ExceedingCreditsApiAxiosParamCreator = ExceedingCreditsApiAxiosParamCrea
222
271
  var ExceedingCreditsApiFp = function (configuration) {
223
272
  var localVarAxiosParamCreator = (0, exports.ExceedingCreditsApiAxiosParamCreator)(configuration);
224
273
  return {
274
+ /**
275
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
276
+ * @summary Create the exceeding credit
277
+ * @param {CreateExceedingCreditRequestDto} createExceedingCreditRequestDto
278
+ * @param {string} [authorization] Bearer Token
279
+ * @param {*} [options] Override http request option.
280
+ * @throws {RequiredError}
281
+ */
282
+ createExceedingCredit: function (createExceedingCreditRequestDto, authorization, options) {
283
+ return __awaiter(this, void 0, void 0, function () {
284
+ var localVarAxiosArgs;
285
+ return __generator(this, function (_a) {
286
+ switch (_a.label) {
287
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.createExceedingCredit(createExceedingCreditRequestDto, authorization, options)];
288
+ case 1:
289
+ localVarAxiosArgs = _a.sent();
290
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
291
+ }
292
+ });
293
+ });
294
+ },
225
295
  /**
226
296
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
227
297
  * @summary Retrieve the exceeding credit
@@ -280,6 +350,17 @@ exports.ExceedingCreditsApiFp = ExceedingCreditsApiFp;
280
350
  var ExceedingCreditsApiFactory = function (configuration, basePath, axios) {
281
351
  var localVarFp = (0, exports.ExceedingCreditsApiFp)(configuration);
282
352
  return {
353
+ /**
354
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
355
+ * @summary Create the exceeding credit
356
+ * @param {CreateExceedingCreditRequestDto} createExceedingCreditRequestDto
357
+ * @param {string} [authorization] Bearer Token
358
+ * @param {*} [options] Override http request option.
359
+ * @throws {RequiredError}
360
+ */
361
+ createExceedingCredit: function (createExceedingCreditRequestDto, authorization, options) {
362
+ return localVarFp.createExceedingCredit(createExceedingCreditRequestDto, authorization, options).then(function (request) { return request(axios, basePath); });
363
+ },
283
364
  /**
284
365
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
285
366
  * @summary Retrieve the exceeding credit
@@ -322,6 +403,18 @@ var ExceedingCreditsApi = /** @class */ (function (_super) {
322
403
  function ExceedingCreditsApi() {
323
404
  return _super !== null && _super.apply(this, arguments) || this;
324
405
  }
406
+ /**
407
+ * Create an exceeding credit for a bank transaction that exceeds the invoiced amount. **Required Permissions** \"payment-management.payments.create\"
408
+ * @summary Create the exceeding credit
409
+ * @param {ExceedingCreditsApiCreateExceedingCreditRequest} requestParameters Request parameters.
410
+ * @param {*} [options] Override http request option.
411
+ * @throws {RequiredError}
412
+ * @memberof ExceedingCreditsApi
413
+ */
414
+ ExceedingCreditsApi.prototype.createExceedingCredit = function (requestParameters, options) {
415
+ var _this = this;
416
+ return (0, exports.ExceedingCreditsApiFp)(this.configuration).createExceedingCredit(requestParameters.createExceedingCreditRequestDto, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
417
+ };
325
418
  /**
326
419
  * Retrieves the details of the exceeding credit that was previously created. Supply the unique exceeding credit code that was returned when you created it and Emil Api will return the corresponding exceeding credit information. **Required Permissions** \"payment-management.payments.view\"
327
420
  * @summary Retrieve the exceeding credit
@@ -57,11 +57,11 @@ export declare const PaymentRequestsApiAxiosParamCreator: (configuration?: Confi
57
57
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
58
58
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
59
59
  * @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.
60
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
61
- * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber&lt;/i&gt;
60
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
61
+ * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber, settlementCode, bankOrderNumber&lt;/i&gt;
62
62
  * @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, paymentRequestNumber, financialEntityNumber, domainEntityNumber, createdAt, status&lt;/i&gt;
63
63
  * @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: paymentReceipts&lt;i&gt;
64
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
64
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
65
65
  * @param {*} [options] Override http request option.
66
66
  * @throws {RequiredError}
67
67
  */
@@ -116,11 +116,11 @@ export declare const PaymentRequestsApiFp: (configuration?: Configuration) => {
116
116
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
117
117
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
118
118
  * @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.
119
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
120
- * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber&lt;/i&gt;
119
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
120
+ * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber, settlementCode, bankOrderNumber&lt;/i&gt;
121
121
  * @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, paymentRequestNumber, financialEntityNumber, domainEntityNumber, createdAt, status&lt;/i&gt;
122
122
  * @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: paymentReceipts&lt;i&gt;
123
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
123
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
124
124
  * @param {*} [options] Override http request option.
125
125
  * @throws {RequiredError}
126
126
  */
@@ -175,11 +175,11 @@ export declare const PaymentRequestsApiFactory: (configuration?: Configuration,
175
175
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
176
176
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
177
177
  * @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.
178
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
179
- * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber&lt;/i&gt;
178
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
179
+ * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber, settlementCode, bankOrderNumber&lt;/i&gt;
180
180
  * @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, paymentRequestNumber, financialEntityNumber, domainEntityNumber, createdAt, status&lt;/i&gt;
181
181
  * @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: paymentReceipts&lt;i&gt;
182
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
182
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
183
183
  * @param {*} [options] Override http request option.
184
184
  * @throws {RequiredError}
185
185
  */
@@ -283,13 +283,13 @@ export interface PaymentRequestsApiListPaymentRequestsRequest {
283
283
  */
284
284
  readonly pageToken?: string;
285
285
  /**
286
- * 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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
286
+ * 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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
287
287
  * @type {string}
288
288
  * @memberof PaymentRequestsApiListPaymentRequests
289
289
  */
290
290
  readonly filter?: string;
291
291
  /**
292
- * 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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber&lt;/i&gt;
292
+ * 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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber, settlementCode, bankOrderNumber&lt;/i&gt;
293
293
  * @type {string}
294
294
  * @memberof PaymentRequestsApiListPaymentRequests
295
295
  */
@@ -307,7 +307,7 @@ export interface PaymentRequestsApiListPaymentRequestsRequest {
307
307
  */
308
308
  readonly expand?: string;
309
309
  /**
310
- * 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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
310
+ * 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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
311
311
  * @type {string}
312
312
  * @memberof PaymentRequestsApiListPaymentRequests
313
313
  */
@@ -249,11 +249,11 @@ var PaymentRequestsApiAxiosParamCreator = function (configuration) {
249
249
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
250
250
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
251
251
  * @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.
252
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
253
- * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber&lt;/i&gt;
252
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
253
+ * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber, settlementCode, bankOrderNumber&lt;/i&gt;
254
254
  * @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, paymentRequestNumber, financialEntityNumber, domainEntityNumber, createdAt, status&lt;/i&gt;
255
255
  * @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: paymentReceipts&lt;i&gt;
256
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
256
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
257
257
  * @param {*} [options] Override http request option.
258
258
  * @throws {RequiredError}
259
259
  */
@@ -448,11 +448,11 @@ var PaymentRequestsApiFp = function (configuration) {
448
448
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
449
449
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
450
450
  * @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.
451
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
452
- * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber&lt;/i&gt;
451
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
452
+ * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber, settlementCode, bankOrderNumber&lt;/i&gt;
453
453
  * @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, paymentRequestNumber, financialEntityNumber, domainEntityNumber, createdAt, status&lt;/i&gt;
454
454
  * @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: paymentReceipts&lt;i&gt;
455
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
455
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
456
456
  * @param {*} [options] Override http request option.
457
457
  * @throws {RequiredError}
458
458
  */
@@ -541,11 +541,11 @@ var PaymentRequestsApiFactory = function (configuration, basePath, axios) {
541
541
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
542
542
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
543
543
  * @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.
544
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
545
- * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber&lt;/i&gt;
544
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
545
+ * @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: code, paymentRequestNumber, financialEntityCode, financialEntityNumber, domainEntityCode, domainEntityNumber, settlementCode, bankOrderNumber&lt;/i&gt;
546
546
  * @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, paymentRequestNumber, financialEntityNumber, domainEntityNumber, createdAt, status&lt;/i&gt;
547
547
  * @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: paymentReceipts&lt;i&gt;
548
- * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt&lt;/i&gt;
548
+ * @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, paymentRequestNumber, status, direction, financialEntityType, domainEntityType, paymentMethodPsp, paymentMethodType, createdAt, settlementCode, partnerCode, bankOrderCode, bankOrderNumber, creditAllocationType&lt;/i&gt;
549
549
  * @param {*} [options] Override http request option.
550
550
  * @throws {RequiredError}
551
551
  */
package/dist/base.d.ts CHANGED
@@ -63,6 +63,7 @@ export declare class BaseAPI {
63
63
  protected configuration: Configuration | undefined;
64
64
  private tokenData?;
65
65
  constructor(configuration?: Configuration, basePath?: string, axios?: AxiosInstance);
66
+ private useCookieAuth;
66
67
  selectEnvironment(env: Environment): void;
67
68
  selectBasePath(path: string): void;
68
69
  getPermissions(): Array<string>;
package/dist/base.js CHANGED
@@ -128,10 +128,15 @@ var BaseAPI = /** @class */ (function () {
128
128
  var accessToken = this.tokenData.accessToken;
129
129
  this.configuration = configuration;
130
130
  this.basePath = configuration.basePath || this.basePath;
131
- // Use config token if provided, otherwise use tokenData token
132
- var configToken = this.configuration.accessToken;
133
- var storedToken = accessToken ? "Bearer ".concat(accessToken) : '';
134
- this.configuration.accessToken = configToken || storedToken;
131
+ if (configuration.cookieAuth) {
132
+ this.useCookieAuth();
133
+ }
134
+ else {
135
+ // Use config token if provided, otherwise use tokenData token
136
+ var configToken = this.configuration.accessToken;
137
+ var storedToken = accessToken ? "Bearer ".concat(accessToken) : '';
138
+ this.configuration.accessToken = configToken || storedToken;
139
+ }
135
140
  }
136
141
  else {
137
142
  var _a = this.tokenData, accessToken = _a.accessToken, username = _a.username;
@@ -143,6 +148,11 @@ var BaseAPI = /** @class */ (function () {
143
148
  }
144
149
  this.attachInterceptor(axios);
145
150
  }
151
+ // Cookie mode: the browser sends the HttpOnly access cookie, so no token is read from storage.
152
+ BaseAPI.prototype.useCookieAuth = function () {
153
+ this.configuration.username = this.configuration.username || this.tokenData.username;
154
+ this.configuration.baseOptions = __assign(__assign({}, this.configuration.baseOptions), { withCredentials: true });
155
+ };
146
156
  BaseAPI.prototype.selectEnvironment = function (env) {
147
157
  this.selectBasePath(env);
148
158
  };
@@ -177,10 +187,12 @@ var BaseAPI = /** @class */ (function () {
177
187
  response = _b.sent();
178
188
  _a = response.data, accessToken = _a.accessToken, permissions = _a.permissions;
179
189
  this.configuration.username = username;
180
- this.configuration.accessToken = "Bearer ".concat(accessToken);
181
190
  this.tokenData.username = username;
182
- this.tokenData.accessToken = accessToken;
183
191
  this.tokenData.permissions = permissions;
192
+ if (!this.configuration.cookieAuth) {
193
+ this.configuration.accessToken = "Bearer ".concat(accessToken);
194
+ this.tokenData.accessToken = accessToken;
195
+ }
184
196
  if (!targetWorkspace) return [3 /*break*/, 3];
185
197
  return [4 /*yield*/, this.switchWorkspace(targetWorkspace)];
186
198
  case 2:
@@ -206,10 +218,7 @@ var BaseAPI = /** @class */ (function () {
206
218
  options = {
207
219
  method: 'POST',
208
220
  url: "".concat(this.configuration.basePath, "/authservice/v1/workspaces/switch"),
209
- headers: {
210
- 'Content-Type': 'application/json',
211
- 'Authorization': "Bearer ".concat(this.configuration.accessToken),
212
- },
221
+ headers: __assign({ 'Content-Type': 'application/json' }, (this.configuration.cookieAuth ? {} : { 'Authorization': "Bearer ".concat(this.configuration.accessToken) })),
213
222
  data: {
214
223
  username: this.configuration.username,
215
224
  targetWorkspace: targetWorkspace,
@@ -220,9 +229,11 @@ var BaseAPI = /** @class */ (function () {
220
229
  case 1:
221
230
  response = _b.sent();
222
231
  _a = response.data, accessToken = _a.accessToken, permissions = _a.permissions;
223
- this.configuration.accessToken = "Bearer ".concat(accessToken);
224
- this.tokenData.accessToken = accessToken;
225
232
  this.tokenData.permissions = permissions;
233
+ if (!this.configuration.cookieAuth) {
234
+ this.configuration.accessToken = "Bearer ".concat(accessToken);
235
+ this.tokenData.accessToken = accessToken;
236
+ }
226
237
  this.storeTokenData(__assign({}, this.tokenData));
227
238
  return [2 /*return*/];
228
239
  }
@@ -265,7 +276,13 @@ var BaseAPI = /** @class */ (function () {
265
276
  });
266
277
  };
267
278
  BaseAPI.prototype.storeTokenData = function (tokenData) {
279
+ var _a;
268
280
  if (typeof window !== 'undefined') {
281
+ if (tokenData && ((_a = this.configuration) === null || _a === void 0 ? void 0 : _a.cookieAuth)) {
282
+ // Cookie mode saves who is logged in, never the token; a token saved by apps not yet migrated stays.
283
+ var username = tokenData.username, permissions = tokenData.permissions;
284
+ tokenData = __assign(__assign({}, ((0, common_1.defaultStorage)().get(TOKEN_DATA) || {})), { username: username, permissions: permissions });
285
+ }
269
286
  (0, common_1.defaultStorage)().set(TOKEN_DATA, tokenData);
270
287
  }
271
288
  };
@@ -300,12 +317,15 @@ var BaseAPI = /** @class */ (function () {
300
317
  return [4 /*yield*/, this.refreshTokenInternal()];
301
318
  case 2:
302
319
  _a = _c.sent(), tokenString = _a.accessToken, permissions = _a.permissions;
303
- accessToken = "Bearer ".concat(tokenString);
304
320
  this.tokenData.permissions = permissions;
305
321
  delete originalConfig.headers['Authorization'];
306
- originalConfig.headers['Authorization'] = accessToken;
307
- this.configuration.accessToken = accessToken;
308
- this.tokenData.accessToken = tokenString;
322
+ // In cookie mode the refresh reply renewed the access cookie, so retry without a header.
323
+ if (!this.configuration.cookieAuth) {
324
+ accessToken = "Bearer ".concat(tokenString);
325
+ originalConfig.headers['Authorization'] = accessToken;
326
+ this.configuration.accessToken = accessToken;
327
+ this.tokenData.accessToken = tokenString;
328
+ }
309
329
  this.storeTokenData(this.tokenData);
310
330
  return [2 /*return*/, axios(originalConfig)];
311
331
  case 3:
@@ -17,6 +17,7 @@ export interface ConfigurationParameters {
17
17
  basePath?: string;
18
18
  baseOptions?: any;
19
19
  formDataCtor?: new () => any;
20
+ cookieAuth?: boolean;
20
21
  }
21
22
  export declare class Configuration {
22
23
  /**
@@ -68,6 +69,14 @@ export declare class Configuration {
68
69
  * @type {new () => FormData}
69
70
  */
70
71
  formDataCtor?: new () => any;
72
+ /**
73
+ * Authenticate with the HttpOnly access cookie instead of a stored token: every call sends credentials.
74
+ * The browser holds one cookie, so use it with one logged-in account; log out through the auth service.
75
+ *
76
+ * @type {boolean}
77
+ * @memberof Configuration
78
+ */
79
+ cookieAuth?: boolean;
71
80
  constructor(param?: ConfigurationParameters);
72
81
  /**
73
82
  * Check if the given MIME is a JSON MIME.
@@ -24,6 +24,7 @@ var Configuration = /** @class */ (function () {
24
24
  this.basePath = param.basePath;
25
25
  this.baseOptions = param.baseOptions;
26
26
  this.formDataCtor = param.formDataCtor;
27
+ this.cookieAuth = param.cookieAuth;
27
28
  }
28
29
  /**
29
30
  * Check if the given MIME is a JSON MIME.
@@ -143,6 +143,7 @@ export declare const BankOrderEntityTypeEnum: {
143
143
  readonly DirectDebit: "direct_debit";
144
144
  readonly PremiumPayment: "premium_payment";
145
145
  readonly ClaimPayment: "claim_payment";
146
+ readonly RefundPayment: "refund_payment";
146
147
  readonly CommissionPayment: "commission_payment";
147
148
  };
148
149
  export type BankOrderEntityTypeEnum = typeof BankOrderEntityTypeEnum[keyof typeof BankOrderEntityTypeEnum];
@@ -18,6 +18,7 @@ exports.BankOrderEntityTypeEnum = {
18
18
  DirectDebit: 'direct_debit',
19
19
  PremiumPayment: 'premium_payment',
20
20
  ClaimPayment: 'claim_payment',
21
+ RefundPayment: 'refund_payment',
21
22
  CommissionPayment: 'commission_payment'
22
23
  };
23
24
  exports.BankOrderEntityStatusEnum = {
@@ -52,16 +52,17 @@ export interface CreateBankOrderRequestDto {
52
52
  */
53
53
  'executionDate': string;
54
54
  /**
55
- * Latest due date.
55
+ * Latest due date. Required for \'direct_debit\' and \'commission_payment\'; ignored for \'claim_payment\' and \'refund_payment\', where the execution date is stored in its place.
56
56
  * @type {string}
57
57
  * @memberof CreateBankOrderRequestDto
58
58
  */
59
- 'dueDate': string;
59
+ 'dueDate'?: string;
60
60
  }
61
61
  export declare const CreateBankOrderRequestDtoTypeEnum: {
62
62
  readonly DirectDebit: "direct_debit";
63
63
  readonly PremiumPayment: "premium_payment";
64
64
  readonly ClaimPayment: "claim_payment";
65
+ readonly RefundPayment: "refund_payment";
65
66
  readonly CommissionPayment: "commission_payment";
66
67
  };
67
68
  export type CreateBankOrderRequestDtoTypeEnum = typeof CreateBankOrderRequestDtoTypeEnum[keyof typeof CreateBankOrderRequestDtoTypeEnum];
@@ -18,6 +18,7 @@ exports.CreateBankOrderRequestDtoTypeEnum = {
18
18
  DirectDebit: 'direct_debit',
19
19
  PremiumPayment: 'premium_payment',
20
20
  ClaimPayment: 'claim_payment',
21
+ RefundPayment: 'refund_payment',
21
22
  CommissionPayment: 'commission_payment'
22
23
  };
23
24
  exports.CreateBankOrderRequestDtoStatusEnum = {
@@ -0,0 +1,48 @@
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 CreateExceedingCreditRequestDto
16
+ */
17
+ export interface CreateExceedingCreditRequestDto {
18
+ /**
19
+ * The amount of the credit
20
+ * @type {number}
21
+ * @memberof CreateExceedingCreditRequestDto
22
+ */
23
+ 'amount': number;
24
+ /**
25
+ * The description of the credit
26
+ * @type {string}
27
+ * @memberof CreateExceedingCreditRequestDto
28
+ */
29
+ 'description'?: string;
30
+ /**
31
+ * The policy code of the credit
32
+ * @type {string}
33
+ * @memberof CreateExceedingCreditRequestDto
34
+ */
35
+ 'policyCode': string;
36
+ /**
37
+ * The transaction code of the credit
38
+ * @type {string}
39
+ * @memberof CreateExceedingCreditRequestDto
40
+ */
41
+ 'bankTransactionCode': string;
42
+ /**
43
+ * The invoice code of the credit
44
+ * @type {string}
45
+ * @memberof CreateExceedingCreditRequestDto
46
+ */
47
+ 'invoiceCode': string;
48
+ }