@emilgroup/insurance-sdk 1.107.1-beta.100 → 1.107.1-beta.102

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.
@@ -161,6 +161,8 @@ models/grouped-product-factor-value-class.ts
161
161
  models/grouped-product-factors-response-class.ts
162
162
  models/grpc-mandate-dto.ts
163
163
  models/index.ts
164
+ models/inline-response200.ts
165
+ models/inline-response503.ts
164
166
  models/insured-object-class.ts
165
167
  models/insured-object-type-class.ts
166
168
  models/invoice-item-class.ts
@@ -233,8 +235,6 @@ models/product-factor-value-for-version-class.ts
233
235
  models/product-field-class.ts
234
236
  models/product-field-type-class.ts
235
237
  models/product-version-class.ts
236
- models/regulation-subtype-class.ts
237
- models/regulation-subtypes-class.ts
238
238
  models/rest-calculate-product-tariff-quote-request-dto.ts
239
239
  models/rest-calculate-product-tariff-quote-response-class.ts
240
240
  models/rest-clone-lead-account-request-dto.ts
package/README.md CHANGED
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
17
17
  Navigate to the folder of your consuming project and run one of the following commands:
18
18
 
19
19
  ```
20
- npm install @emilgroup/insurance-sdk@1.107.1-beta.100 --save
20
+ npm install @emilgroup/insurance-sdk@1.107.1-beta.102 --save
21
21
  ```
22
22
  or
23
23
  ```
24
- yarn add @emilgroup/insurance-sdk@1.107.1-beta.100
24
+ yarn add @emilgroup/insurance-sdk@1.107.1-beta.102
25
25
  ```
26
26
 
27
27
  And then you can import `PoliciesApi`.
@@ -20,6 +20,10 @@ import { Configuration } from '../configuration';
20
20
  import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
21
21
  // @ts-ignore
22
22
  import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from '../base';
23
+ // @ts-ignore
24
+ import { InlineResponse200 } from '../models';
25
+ // @ts-ignore
26
+ import { InlineResponse503 } from '../models';
23
27
  /**
24
28
  * HealthCheckApi - axios parameter creator
25
29
  * @export
@@ -27,7 +31,7 @@ import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } fr
27
31
  export const HealthCheckApiAxiosParamCreator = function (configuration?: Configuration) {
28
32
  return {
29
33
  /**
30
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
34
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
31
35
  * @summary Health Check
32
36
  * @param {*} [options] Override http request option.
33
37
  * @throws {RequiredError}
@@ -69,12 +73,12 @@ export const HealthCheckApiFp = function(configuration?: Configuration) {
69
73
  const localVarAxiosParamCreator = HealthCheckApiAxiosParamCreator(configuration)
70
74
  return {
71
75
  /**
72
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
76
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
73
77
  * @summary Health Check
74
78
  * @param {*} [options] Override http request option.
75
79
  * @throws {RequiredError}
76
80
  */
77
- async check(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
81
+ async check(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse200>> {
78
82
  const localVarAxiosArgs = await localVarAxiosParamCreator.check(options);
79
83
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
80
84
  },
@@ -89,12 +93,12 @@ export const HealthCheckApiFactory = function (configuration?: Configuration, ba
89
93
  const localVarFp = HealthCheckApiFp(configuration)
90
94
  return {
91
95
  /**
92
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
96
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
93
97
  * @summary Health Check
94
98
  * @param {*} [options] Override http request option.
95
99
  * @throws {RequiredError}
96
100
  */
97
- check(options?: any): AxiosPromise<void> {
101
+ check(options?: any): AxiosPromise<InlineResponse200> {
98
102
  return localVarFp.check(options).then((request) => request(axios, basePath));
99
103
  },
100
104
  };
@@ -108,7 +112,7 @@ export const HealthCheckApiFactory = function (configuration?: Configuration, ba
108
112
  */
109
113
  export class HealthCheckApi extends BaseAPI {
110
114
  /**
111
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
115
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
112
116
  * @summary Health Check
113
117
  * @param {*} [options] Override http request option.
114
118
  * @throws {RequiredError}
package/base.ts CHANGED
@@ -102,14 +102,10 @@ export class BaseAPI {
102
102
  this.configuration = configuration;
103
103
  this.basePath = configuration.basePath || this.basePath;
104
104
 
105
- if (configuration.cookieAuth) {
106
- this.useCookieAuth();
107
- } else {
108
- // Use config token if provided, otherwise use tokenData token
109
- const configToken = this.configuration.accessToken;
110
- const storedToken = accessToken ? `Bearer ${accessToken}` : '';
111
- this.configuration.accessToken = configToken || storedToken;
112
- }
105
+ // Use config token if provided, otherwise use tokenData token
106
+ const configToken = this.configuration.accessToken;
107
+ const storedToken = accessToken ? `Bearer ${accessToken}` : '';
108
+ this.configuration.accessToken = configToken || storedToken;
113
109
  } else {
114
110
  const { accessToken, username } = this.tokenData;
115
111
 
@@ -123,12 +119,6 @@ export class BaseAPI {
123
119
  this.attachInterceptor(axios);
124
120
  }
125
121
 
126
- // Cookie mode: the browser sends the HttpOnly access cookie, so no token is read from storage.
127
- private useCookieAuth() {
128
- this.configuration.username = this.configuration.username || this.tokenData.username;
129
- this.configuration.baseOptions = { ...this.configuration.baseOptions, withCredentials: true };
130
- }
131
-
132
122
  selectEnvironment(env: Environment) {
133
123
  this.selectBasePath(env);
134
124
  }
@@ -162,12 +152,10 @@ export class BaseAPI {
162
152
  const { data: { accessToken, permissions } } = response;
163
153
 
164
154
  this.configuration.username = username;
155
+ this.configuration.accessToken = `Bearer ${accessToken}`;
165
156
  this.tokenData.username = username;
157
+ this.tokenData.accessToken = accessToken;
166
158
  this.tokenData.permissions = permissions;
167
- if (!this.configuration.cookieAuth) {
168
- this.configuration.accessToken = `Bearer ${accessToken}`;
169
- this.tokenData.accessToken = accessToken;
170
- }
171
159
 
172
160
  // Switch workspace if provided
173
161
  if (targetWorkspace) {
@@ -190,7 +178,7 @@ export class BaseAPI {
190
178
  url: `${this.configuration.basePath}/authservice/v1/workspaces/switch`,
191
179
  headers: {
192
180
  'Content-Type': 'application/json',
193
- ...(this.configuration.cookieAuth ? {} : { 'Authorization': `Bearer ${this.configuration.accessToken}` }),
181
+ 'Authorization': `Bearer ${this.configuration.accessToken}`,
194
182
  },
195
183
  data: {
196
184
  username: this.configuration.username,
@@ -202,12 +190,10 @@ export class BaseAPI {
202
190
  const response = await globalAxios.request<SwitchWorkspaceResponseClass>(options);
203
191
 
204
192
  const { data: { accessToken, permissions } } = response;
205
-
193
+
194
+ this.configuration.accessToken = `Bearer ${accessToken}`;
195
+ this.tokenData.accessToken = accessToken;
206
196
  this.tokenData.permissions = permissions;
207
- if (!this.configuration.cookieAuth) {
208
- this.configuration.accessToken = `Bearer ${accessToken}`;
209
- this.tokenData.accessToken = accessToken;
210
- }
211
197
 
212
198
  this.storeTokenData({
213
199
  ...this.tokenData
@@ -247,11 +233,6 @@ export class BaseAPI {
247
233
 
248
234
  private storeTokenData(tokenData?: TokenData) {
249
235
  if (typeof window !== 'undefined') {
250
- if (tokenData && this.configuration?.cookieAuth) {
251
- // Cookie mode saves who is logged in, never the token; a token saved by apps not yet migrated stays.
252
- const { username, permissions } = tokenData;
253
- tokenData = { ...(defaultStorage().get<TokenData>(TOKEN_DATA) || {}), username, permissions };
254
- }
255
236
  defaultStorage().set<TokenData>(TOKEN_DATA, tokenData);
256
237
  }
257
238
  }
@@ -282,17 +263,15 @@ export class BaseAPI {
282
263
  originalConfig._retry = true;
283
264
  try {
284
265
  const { accessToken: tokenString, permissions } = await this.refreshTokenInternal();
266
+ const accessToken = `Bearer ${tokenString}`;
285
267
  this.tokenData.permissions = permissions;
286
268
 
287
269
  delete originalConfig.headers['Authorization']
288
270
 
289
- // In cookie mode the refresh reply renewed the access cookie, so retry without a header.
290
- if (!this.configuration.cookieAuth) {
291
- const accessToken = `Bearer ${tokenString}`;
292
- originalConfig.headers['Authorization'] = accessToken;
293
- this.configuration.accessToken = accessToken;
294
- this.tokenData.accessToken = tokenString;
295
- }
271
+ originalConfig.headers['Authorization'] = accessToken;
272
+
273
+ this.configuration.accessToken = accessToken;
274
+ this.tokenData.accessToken = tokenString;
296
275
 
297
276
  this.storeTokenData(this.tokenData);
298
277
 
package/configuration.ts CHANGED
@@ -21,7 +21,6 @@ export interface ConfigurationParameters {
21
21
  basePath?: string;
22
22
  baseOptions?: any;
23
23
  formDataCtor?: new () => any;
24
- cookieAuth?: boolean;
25
24
  }
26
25
 
27
26
  export class Configuration {
@@ -75,15 +74,6 @@ export class Configuration {
75
74
  */
76
75
  formDataCtor?: new () => any;
77
76
 
78
- /**
79
- * Authenticate with the HttpOnly access cookie instead of a stored token: every call sends credentials.
80
- * The browser holds one cookie, so use it with one logged-in account; log out through the auth service.
81
- *
82
- * @type {boolean}
83
- * @memberof Configuration
84
- */
85
- cookieAuth?: boolean;
86
-
87
77
  constructor(param: ConfigurationParameters = {}) {
88
78
  this.apiKey = param.apiKey;
89
79
  this.username = param.username;
@@ -92,7 +82,6 @@ export class Configuration {
92
82
  this.basePath = param.basePath;
93
83
  this.baseOptions = param.baseOptions;
94
84
  this.formDataCtor = param.formDataCtor;
95
- this.cookieAuth = param.cookieAuth;
96
85
  }
97
86
 
98
87
  /**
@@ -12,13 +12,14 @@
12
12
  import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
13
13
  import { Configuration } from '../configuration';
14
14
  import { RequestArgs, BaseAPI } from '../base';
15
+ import { InlineResponse200 } from '../models';
15
16
  /**
16
17
  * HealthCheckApi - axios parameter creator
17
18
  * @export
18
19
  */
19
20
  export declare const HealthCheckApiAxiosParamCreator: (configuration?: Configuration) => {
20
21
  /**
21
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
22
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
22
23
  * @summary Health Check
23
24
  * @param {*} [options] Override http request option.
24
25
  * @throws {RequiredError}
@@ -31,12 +32,12 @@ export declare const HealthCheckApiAxiosParamCreator: (configuration?: Configura
31
32
  */
32
33
  export declare const HealthCheckApiFp: (configuration?: Configuration) => {
33
34
  /**
34
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
35
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
35
36
  * @summary Health Check
36
37
  * @param {*} [options] Override http request option.
37
38
  * @throws {RequiredError}
38
39
  */
39
- check(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
40
+ check(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse200>>;
40
41
  };
41
42
  /**
42
43
  * HealthCheckApi - factory interface
@@ -44,12 +45,12 @@ export declare const HealthCheckApiFp: (configuration?: Configuration) => {
44
45
  */
45
46
  export declare const HealthCheckApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
46
47
  /**
47
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
48
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
48
49
  * @summary Health Check
49
50
  * @param {*} [options] Override http request option.
50
51
  * @throws {RequiredError}
51
52
  */
52
- check(options?: any): AxiosPromise<void>;
53
+ check(options?: any): AxiosPromise<InlineResponse200>;
53
54
  };
54
55
  /**
55
56
  * HealthCheckApi - object-oriented interface
@@ -59,11 +60,11 @@ export declare const HealthCheckApiFactory: (configuration?: Configuration, base
59
60
  */
60
61
  export declare class HealthCheckApi extends BaseAPI {
61
62
  /**
62
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
63
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
63
64
  * @summary Health Check
64
65
  * @param {*} [options] Override http request option.
65
66
  * @throws {RequiredError}
66
67
  * @memberof HealthCheckApi
67
68
  */
68
- check(options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
69
+ check(options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<InlineResponse200, any, {}>>;
69
70
  }
@@ -93,7 +93,7 @@ var HealthCheckApiAxiosParamCreator = function (configuration) {
93
93
  var _this = this;
94
94
  return {
95
95
  /**
96
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
96
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
97
97
  * @summary Health Check
98
98
  * @param {*} [options] Override http request option.
99
99
  * @throws {RequiredError}
@@ -133,7 +133,7 @@ var HealthCheckApiFp = function (configuration) {
133
133
  var localVarAxiosParamCreator = (0, exports.HealthCheckApiAxiosParamCreator)(configuration);
134
134
  return {
135
135
  /**
136
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
136
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
137
137
  * @summary Health Check
138
138
  * @param {*} [options] Override http request option.
139
139
  * @throws {RequiredError}
@@ -162,7 +162,7 @@ var HealthCheckApiFactory = function (configuration, basePath, axios) {
162
162
  var localVarFp = (0, exports.HealthCheckApiFp)(configuration);
163
163
  return {
164
164
  /**
165
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
165
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
166
166
  * @summary Health Check
167
167
  * @param {*} [options] Override http request option.
168
168
  * @throws {RequiredError}
@@ -185,7 +185,7 @@ var HealthCheckApi = /** @class */ (function (_super) {
185
185
  return _super !== null && _super.apply(this, arguments) || this;
186
186
  }
187
187
  /**
188
- * Returns the health status of the insuranceservice service. This endpoint is used to monitor the operational status of the insuranceservice service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
188
+ * Returns the health status of the insurance service. This endpoint is used to monitor the operational status of the insurance service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
189
189
  * @summary Health Check
190
190
  * @param {*} [options] Override http request option.
191
191
  * @throws {RequiredError}
package/dist/base.d.ts CHANGED
@@ -63,7 +63,6 @@ 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;
67
66
  selectEnvironment(env: Environment): void;
68
67
  selectBasePath(path: string): void;
69
68
  getPermissions(): Array<string>;
package/dist/base.js CHANGED
@@ -128,15 +128,10 @@ 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
- 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
- }
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;
140
135
  }
141
136
  else {
142
137
  var _a = this.tokenData, accessToken = _a.accessToken, username = _a.username;
@@ -148,11 +143,6 @@ var BaseAPI = /** @class */ (function () {
148
143
  }
149
144
  this.attachInterceptor(axios);
150
145
  }
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
- };
156
146
  BaseAPI.prototype.selectEnvironment = function (env) {
157
147
  this.selectBasePath(env);
158
148
  };
@@ -187,12 +177,10 @@ var BaseAPI = /** @class */ (function () {
187
177
  response = _b.sent();
188
178
  _a = response.data, accessToken = _a.accessToken, permissions = _a.permissions;
189
179
  this.configuration.username = username;
180
+ this.configuration.accessToken = "Bearer ".concat(accessToken);
190
181
  this.tokenData.username = username;
182
+ this.tokenData.accessToken = accessToken;
191
183
  this.tokenData.permissions = permissions;
192
- if (!this.configuration.cookieAuth) {
193
- this.configuration.accessToken = "Bearer ".concat(accessToken);
194
- this.tokenData.accessToken = accessToken;
195
- }
196
184
  if (!targetWorkspace) return [3 /*break*/, 3];
197
185
  return [4 /*yield*/, this.switchWorkspace(targetWorkspace)];
198
186
  case 2:
@@ -218,7 +206,10 @@ var BaseAPI = /** @class */ (function () {
218
206
  options = {
219
207
  method: 'POST',
220
208
  url: "".concat(this.configuration.basePath, "/authservice/v1/workspaces/switch"),
221
- headers: __assign({ 'Content-Type': 'application/json' }, (this.configuration.cookieAuth ? {} : { 'Authorization': "Bearer ".concat(this.configuration.accessToken) })),
209
+ headers: {
210
+ 'Content-Type': 'application/json',
211
+ 'Authorization': "Bearer ".concat(this.configuration.accessToken),
212
+ },
222
213
  data: {
223
214
  username: this.configuration.username,
224
215
  targetWorkspace: targetWorkspace,
@@ -229,11 +220,9 @@ var BaseAPI = /** @class */ (function () {
229
220
  case 1:
230
221
  response = _b.sent();
231
222
  _a = response.data, accessToken = _a.accessToken, permissions = _a.permissions;
223
+ this.configuration.accessToken = "Bearer ".concat(accessToken);
224
+ this.tokenData.accessToken = accessToken;
232
225
  this.tokenData.permissions = permissions;
233
- if (!this.configuration.cookieAuth) {
234
- this.configuration.accessToken = "Bearer ".concat(accessToken);
235
- this.tokenData.accessToken = accessToken;
236
- }
237
226
  this.storeTokenData(__assign({}, this.tokenData));
238
227
  return [2 /*return*/];
239
228
  }
@@ -276,13 +265,7 @@ var BaseAPI = /** @class */ (function () {
276
265
  });
277
266
  };
278
267
  BaseAPI.prototype.storeTokenData = function (tokenData) {
279
- var _a;
280
268
  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
- }
286
269
  (0, common_1.defaultStorage)().set(TOKEN_DATA, tokenData);
287
270
  }
288
271
  };
@@ -317,15 +300,12 @@ var BaseAPI = /** @class */ (function () {
317
300
  return [4 /*yield*/, this.refreshTokenInternal()];
318
301
  case 2:
319
302
  _a = _c.sent(), tokenString = _a.accessToken, permissions = _a.permissions;
303
+ accessToken = "Bearer ".concat(tokenString);
320
304
  this.tokenData.permissions = permissions;
321
305
  delete originalConfig.headers['Authorization'];
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
- }
306
+ originalConfig.headers['Authorization'] = accessToken;
307
+ this.configuration.accessToken = accessToken;
308
+ this.tokenData.accessToken = tokenString;
329
309
  this.storeTokenData(this.tokenData);
330
310
  return [2 /*return*/, axios(originalConfig)];
331
311
  case 3:
@@ -17,7 +17,6 @@ export interface ConfigurationParameters {
17
17
  basePath?: string;
18
18
  baseOptions?: any;
19
19
  formDataCtor?: new () => any;
20
- cookieAuth?: boolean;
21
20
  }
22
21
  export declare class Configuration {
23
22
  /**
@@ -69,14 +68,6 @@ export declare class Configuration {
69
68
  * @type {new () => FormData}
70
69
  */
71
70
  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;
80
71
  constructor(param?: ConfigurationParameters);
81
72
  /**
82
73
  * Check if the given MIME is a JSON MIME.
@@ -24,7 +24,6 @@ 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;
28
27
  }
29
28
  /**
30
29
  * Check if the given MIME is a JSON MIME.
@@ -11,7 +11,6 @@
11
11
  */
12
12
  import { ClaimPositionFieldsClass } from './claim-position-fields-class';
13
13
  import { GeneralSettingClass } from './general-setting-class';
14
- import { RegulationSubtypesClass } from './regulation-subtypes-class';
15
14
  /**
16
15
  *
17
16
  * @export
@@ -30,10 +29,4 @@ export interface ClaimConfigClass {
30
29
  * @memberof ClaimConfigClass
31
30
  */
32
31
  'claimPositionFields': ClaimPositionFieldsClass;
33
- /**
34
- * Client-defined subtypes per regulation item type, selectable on claim regulations
35
- * @type {RegulationSubtypesClass}
36
- * @memberof ClaimConfigClass
37
- */
38
- 'regulationSubtypes'?: RegulationSubtypesClass;
39
32
  }
@@ -124,6 +124,8 @@ export * from './grouped-product-factor-class';
124
124
  export * from './grouped-product-factor-value-class';
125
125
  export * from './grouped-product-factors-response-class';
126
126
  export * from './grpc-mandate-dto';
127
+ export * from './inline-response200';
128
+ export * from './inline-response503';
127
129
  export * from './insured-object-class';
128
130
  export * from './insured-object-type-class';
129
131
  export * from './invoice-item-class';
@@ -196,8 +198,6 @@ export * from './product-factor-value-for-version-class';
196
198
  export * from './product-field-class';
197
199
  export * from './product-field-type-class';
198
200
  export * from './product-version-class';
199
- export * from './regulation-subtype-class';
200
- export * from './regulation-subtypes-class';
201
201
  export * from './rest-calculate-product-tariff-quote-request-dto';
202
202
  export * from './rest-calculate-product-tariff-quote-response-class';
203
203
  export * from './rest-clone-lead-account-request-dto';
@@ -140,6 +140,8 @@ __exportStar(require("./grouped-product-factor-class"), exports);
140
140
  __exportStar(require("./grouped-product-factor-value-class"), exports);
141
141
  __exportStar(require("./grouped-product-factors-response-class"), exports);
142
142
  __exportStar(require("./grpc-mandate-dto"), exports);
143
+ __exportStar(require("./inline-response200"), exports);
144
+ __exportStar(require("./inline-response503"), exports);
143
145
  __exportStar(require("./insured-object-class"), exports);
144
146
  __exportStar(require("./insured-object-type-class"), exports);
145
147
  __exportStar(require("./invoice-item-class"), exports);
@@ -212,8 +214,6 @@ __exportStar(require("./product-factor-value-for-version-class"), exports);
212
214
  __exportStar(require("./product-field-class"), exports);
213
215
  __exportStar(require("./product-field-type-class"), exports);
214
216
  __exportStar(require("./product-version-class"), exports);
215
- __exportStar(require("./regulation-subtype-class"), exports);
216
- __exportStar(require("./regulation-subtypes-class"), exports);
217
217
  __exportStar(require("./rest-calculate-product-tariff-quote-request-dto"), exports);
218
218
  __exportStar(require("./rest-calculate-product-tariff-quote-response-class"), exports);
219
219
  __exportStar(require("./rest-clone-lead-account-request-dto"), exports);
@@ -0,0 +1,54 @@
1
+ /**
2
+ * EMIL InsuranceService
3
+ * The EMIL InsuranceService API description
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ * Contact: kontakt@emil.de
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface InlineResponse200
16
+ */
17
+ export interface InlineResponse200 {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof InlineResponse200
22
+ */
23
+ 'status'?: string;
24
+ /**
25
+ *
26
+ * @type {{ [key: string]: { [key: string]: object; }; }}
27
+ * @memberof InlineResponse200
28
+ */
29
+ 'info'?: {
30
+ [key: string]: {
31
+ [key: string]: object;
32
+ };
33
+ } | null;
34
+ /**
35
+ *
36
+ * @type {{ [key: string]: { [key: string]: object; }; }}
37
+ * @memberof InlineResponse200
38
+ */
39
+ 'error'?: {
40
+ [key: string]: {
41
+ [key: string]: object;
42
+ };
43
+ } | null;
44
+ /**
45
+ *
46
+ * @type {{ [key: string]: { [key: string]: object; }; }}
47
+ * @memberof InlineResponse200
48
+ */
49
+ 'details'?: {
50
+ [key: string]: {
51
+ [key: string]: object;
52
+ };
53
+ };
54
+ }
@@ -0,0 +1,54 @@
1
+ /**
2
+ * EMIL InsuranceService
3
+ * The EMIL InsuranceService API description
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ * Contact: kontakt@emil.de
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface InlineResponse503
16
+ */
17
+ export interface InlineResponse503 {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof InlineResponse503
22
+ */
23
+ 'status'?: string;
24
+ /**
25
+ *
26
+ * @type {{ [key: string]: { [key: string]: object; }; }}
27
+ * @memberof InlineResponse503
28
+ */
29
+ 'info'?: {
30
+ [key: string]: {
31
+ [key: string]: object;
32
+ };
33
+ } | null;
34
+ /**
35
+ *
36
+ * @type {{ [key: string]: { [key: string]: object; }; }}
37
+ * @memberof InlineResponse503
38
+ */
39
+ 'error'?: {
40
+ [key: string]: {
41
+ [key: string]: object;
42
+ };
43
+ } | null;
44
+ /**
45
+ *
46
+ * @type {{ [key: string]: { [key: string]: object; }; }}
47
+ * @memberof InlineResponse503
48
+ */
49
+ 'details'?: {
50
+ [key: string]: {
51
+ [key: string]: object;
52
+ };
53
+ };
54
+ }
@@ -15,7 +15,6 @@
15
15
 
16
16
  import { ClaimPositionFieldsClass } from './claim-position-fields-class';
17
17
  import { GeneralSettingClass } from './general-setting-class';
18
- import { RegulationSubtypesClass } from './regulation-subtypes-class';
19
18
 
20
19
  /**
21
20
  *
@@ -35,11 +34,5 @@ export interface ClaimConfigClass {
35
34
  * @memberof ClaimConfigClass
36
35
  */
37
36
  'claimPositionFields': ClaimPositionFieldsClass;
38
- /**
39
- * Client-defined subtypes per regulation item type, selectable on claim regulations
40
- * @type {RegulationSubtypesClass}
41
- * @memberof ClaimConfigClass
42
- */
43
- 'regulationSubtypes'?: RegulationSubtypesClass;
44
37
  }
45
38
 
package/models/index.ts CHANGED
@@ -124,6 +124,8 @@ export * from './grouped-product-factor-class';
124
124
  export * from './grouped-product-factor-value-class';
125
125
  export * from './grouped-product-factors-response-class';
126
126
  export * from './grpc-mandate-dto';
127
+ export * from './inline-response200';
128
+ export * from './inline-response503';
127
129
  export * from './insured-object-class';
128
130
  export * from './insured-object-type-class';
129
131
  export * from './invoice-item-class';
@@ -196,8 +198,6 @@ export * from './product-factor-value-for-version-class';
196
198
  export * from './product-field-class';
197
199
  export * from './product-field-type-class';
198
200
  export * from './product-version-class';
199
- export * from './regulation-subtype-class';
200
- export * from './regulation-subtypes-class';
201
201
  export * from './rest-calculate-product-tariff-quote-request-dto';
202
202
  export * from './rest-calculate-product-tariff-quote-response-class';
203
203
  export * from './rest-clone-lead-account-request-dto';
@@ -0,0 +1,48 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * EMIL InsuranceService
5
+ * The EMIL InsuranceService API description
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ * Contact: kontakt@emil.de
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+
16
+
17
+ /**
18
+ *
19
+ * @export
20
+ * @interface InlineResponse200
21
+ */
22
+ export interface InlineResponse200 {
23
+ /**
24
+ *
25
+ * @type {string}
26
+ * @memberof InlineResponse200
27
+ */
28
+ 'status'?: string;
29
+ /**
30
+ *
31
+ * @type {{ [key: string]: { [key: string]: object; }; }}
32
+ * @memberof InlineResponse200
33
+ */
34
+ 'info'?: { [key: string]: { [key: string]: object; }; } | null;
35
+ /**
36
+ *
37
+ * @type {{ [key: string]: { [key: string]: object; }; }}
38
+ * @memberof InlineResponse200
39
+ */
40
+ 'error'?: { [key: string]: { [key: string]: object; }; } | null;
41
+ /**
42
+ *
43
+ * @type {{ [key: string]: { [key: string]: object; }; }}
44
+ * @memberof InlineResponse200
45
+ */
46
+ 'details'?: { [key: string]: { [key: string]: object; }; };
47
+ }
48
+
@@ -0,0 +1,48 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * EMIL InsuranceService
5
+ * The EMIL InsuranceService API description
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ * Contact: kontakt@emil.de
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+
16
+
17
+ /**
18
+ *
19
+ * @export
20
+ * @interface InlineResponse503
21
+ */
22
+ export interface InlineResponse503 {
23
+ /**
24
+ *
25
+ * @type {string}
26
+ * @memberof InlineResponse503
27
+ */
28
+ 'status'?: string;
29
+ /**
30
+ *
31
+ * @type {{ [key: string]: { [key: string]: object; }; }}
32
+ * @memberof InlineResponse503
33
+ */
34
+ 'info'?: { [key: string]: { [key: string]: object; }; } | null;
35
+ /**
36
+ *
37
+ * @type {{ [key: string]: { [key: string]: object; }; }}
38
+ * @memberof InlineResponse503
39
+ */
40
+ 'error'?: { [key: string]: { [key: string]: object; }; } | null;
41
+ /**
42
+ *
43
+ * @type {{ [key: string]: { [key: string]: object; }; }}
44
+ * @memberof InlineResponse503
45
+ */
46
+ 'details'?: { [key: string]: { [key: string]: object; }; };
47
+ }
48
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@emilgroup/insurance-sdk",
3
- "version": "1.107.1-beta.100",
3
+ "version": "1.107.1-beta.102",
4
4
  "description": "OpenAPI client for @emilgroup/insurance-sdk",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "keywords": [
@@ -1,30 +0,0 @@
1
- /**
2
- * EMIL InsuranceService
3
- * The EMIL InsuranceService API description
4
- *
5
- * The version of the OpenAPI document: 1.0
6
- * Contact: kontakt@emil.de
7
- *
8
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
- * https://openapi-generator.tech
10
- * Do not edit the class manually.
11
- */
12
- /**
13
- *
14
- * @export
15
- * @interface RegulationSubtypeClass
16
- */
17
- export interface RegulationSubtypeClass {
18
- /**
19
- * Unique identifier key of the regulation subtype. Stored on the regulation item.
20
- * @type {string}
21
- * @memberof RegulationSubtypeClass
22
- */
23
- 'key': string;
24
- /**
25
- * Display name shown to users
26
- * @type {string}
27
- * @memberof RegulationSubtypeClass
28
- */
29
- 'label': string;
30
- }
@@ -1,37 +0,0 @@
1
- /**
2
- * EMIL InsuranceService
3
- * The EMIL InsuranceService API description
4
- *
5
- * The version of the OpenAPI document: 1.0
6
- * Contact: kontakt@emil.de
7
- *
8
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
- * https://openapi-generator.tech
10
- * Do not edit the class manually.
11
- */
12
- import { RegulationSubtypeClass } from './regulation-subtype-class';
13
- /**
14
- *
15
- * @export
16
- * @interface RegulationSubtypesClass
17
- */
18
- export interface RegulationSubtypesClass {
19
- /**
20
- * Subtypes available for payout regulations. Always contains the default subtypes \"indemnity\" and \"internalProcess\".
21
- * @type {Array<RegulationSubtypeClass>}
22
- * @memberof RegulationSubtypesClass
23
- */
24
- 'payout': Array<RegulationSubtypeClass>;
25
- /**
26
- * Subtypes available for regress regulations
27
- * @type {Array<RegulationSubtypeClass>}
28
- * @memberof RegulationSubtypesClass
29
- */
30
- 'regress': Array<RegulationSubtypeClass>;
31
- /**
32
- * Subtypes available for reserve regulations
33
- * @type {Array<RegulationSubtypeClass>}
34
- * @memberof RegulationSubtypesClass
35
- */
36
- 'reserve': Array<RegulationSubtypeClass>;
37
- }
@@ -1,36 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * EMIL InsuranceService
5
- * The EMIL InsuranceService API description
6
- *
7
- * The version of the OpenAPI document: 1.0
8
- * Contact: kontakt@emil.de
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
-
16
-
17
- /**
18
- *
19
- * @export
20
- * @interface RegulationSubtypeClass
21
- */
22
- export interface RegulationSubtypeClass {
23
- /**
24
- * Unique identifier key of the regulation subtype. Stored on the regulation item.
25
- * @type {string}
26
- * @memberof RegulationSubtypeClass
27
- */
28
- 'key': string;
29
- /**
30
- * Display name shown to users
31
- * @type {string}
32
- * @memberof RegulationSubtypeClass
33
- */
34
- 'label': string;
35
- }
36
-
@@ -1,43 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * EMIL InsuranceService
5
- * The EMIL InsuranceService API description
6
- *
7
- * The version of the OpenAPI document: 1.0
8
- * Contact: kontakt@emil.de
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
-
16
- import { RegulationSubtypeClass } from './regulation-subtype-class';
17
-
18
- /**
19
- *
20
- * @export
21
- * @interface RegulationSubtypesClass
22
- */
23
- export interface RegulationSubtypesClass {
24
- /**
25
- * Subtypes available for payout regulations. Always contains the default subtypes \"indemnity\" and \"internalProcess\".
26
- * @type {Array<RegulationSubtypeClass>}
27
- * @memberof RegulationSubtypesClass
28
- */
29
- 'payout': Array<RegulationSubtypeClass>;
30
- /**
31
- * Subtypes available for regress regulations
32
- * @type {Array<RegulationSubtypeClass>}
33
- * @memberof RegulationSubtypesClass
34
- */
35
- 'regress': Array<RegulationSubtypeClass>;
36
- /**
37
- * Subtypes available for reserve regulations
38
- * @type {Array<RegulationSubtypeClass>}
39
- * @memberof RegulationSubtypesClass
40
- */
41
- 'reserve': Array<RegulationSubtypeClass>;
42
- }
43
-