@emilgroup/notification-sdk 0.8.1-beta.60 → 0.8.1-beta.61

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 (37) hide show
  1. package/README.md +2 -2
  2. package/api/email-mailboxes-api.ts +2 -4
  3. package/api/email-messages-api.ts +8 -16
  4. package/api/email-subscriptions-api.ts +12 -24
  5. package/api/email-tracking-api.ts +12 -24
  6. package/api/email-verifications-api.ts +4 -8
  7. package/api/layouts-api.ts +10 -20
  8. package/api/notification-templates-api.ts +10 -20
  9. package/api/notifications-api.ts +4 -8
  10. package/base.ts +41 -174
  11. package/common.ts +2 -3
  12. package/configuration.ts +0 -20
  13. package/dist/api/email-mailboxes-api.d.ts +1 -1
  14. package/dist/api/email-mailboxes-api.js +4 -7
  15. package/dist/api/email-messages-api.d.ts +4 -4
  16. package/dist/api/email-messages-api.js +15 -25
  17. package/dist/api/email-subscriptions-api.d.ts +6 -6
  18. package/dist/api/email-subscriptions-api.js +23 -39
  19. package/dist/api/email-tracking-api.d.ts +6 -6
  20. package/dist/api/email-tracking-api.js +22 -36
  21. package/dist/api/email-verifications-api.d.ts +2 -2
  22. package/dist/api/email-verifications-api.js +8 -14
  23. package/dist/api/health-api.d.ts +1 -1
  24. package/dist/api/layouts-api.d.ts +5 -5
  25. package/dist/api/layouts-api.js +18 -29
  26. package/dist/api/msgraph-webhooks-api.d.ts +2 -2
  27. package/dist/api/notification-templates-api.d.ts +5 -5
  28. package/dist/api/notification-templates-api.js +18 -29
  29. package/dist/api/notifications-api.d.ts +2 -2
  30. package/dist/api/notifications-api.js +8 -14
  31. package/dist/base.d.ts +0 -24
  32. package/dist/base.js +59 -178
  33. package/dist/common.d.ts +1 -1
  34. package/dist/common.js +0 -1
  35. package/dist/configuration.d.ts +0 -17
  36. package/dist/configuration.js +0 -2
  37. package/package.json +2 -2
@@ -103,7 +103,7 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
103
103
  createLayout: function (createLayoutRequestDto, authorization, options) {
104
104
  if (options === void 0) { options = {}; }
105
105
  return __awaiter(_this, void 0, void 0, function () {
106
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
106
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
107
  return __generator(this, function (_a) {
108
108
  switch (_a.label) {
109
109
  case 0:
@@ -120,16 +120,13 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
120
120
  localVarQueryParameter = {};
121
121
  // authentication bearer required
122
122
  // http bearer authentication required
123
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
124
- // Only Authorization falls back to the configured token; an empty value is never sent.
125
- ];
123
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
126
124
  case 1:
127
125
  // authentication bearer required
128
126
  // http bearer authentication required
129
127
  _a.sent();
130
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
131
- if (authorizationValue) {
132
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
128
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
129
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
133
130
  }
134
131
  localVarHeaderParameter['Content-Type'] = 'application/json';
135
132
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -155,7 +152,7 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
155
152
  deleteLayout: function (id, authorization, options) {
156
153
  if (options === void 0) { options = {}; }
157
154
  return __awaiter(_this, void 0, void 0, function () {
158
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
155
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
159
156
  return __generator(this, function (_a) {
160
157
  switch (_a.label) {
161
158
  case 0:
@@ -173,16 +170,13 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
173
170
  localVarQueryParameter = {};
174
171
  // authentication bearer required
175
172
  // http bearer authentication required
176
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
177
- // Only Authorization falls back to the configured token; an empty value is never sent.
178
- ];
173
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
179
174
  case 1:
180
175
  // authentication bearer required
181
176
  // http bearer authentication required
182
177
  _a.sent();
183
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
184
- if (authorizationValue) {
185
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
178
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
179
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
186
180
  }
187
181
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
188
182
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -207,7 +201,7 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
207
201
  getLayout: function (id, id2, authorization, options) {
208
202
  if (options === void 0) { options = {}; }
209
203
  return __awaiter(_this, void 0, void 0, function () {
210
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
204
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
211
205
  return __generator(this, function (_a) {
212
206
  switch (_a.label) {
213
207
  case 0:
@@ -235,9 +229,8 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
235
229
  if (id2 !== undefined) {
236
230
  localVarQueryParameter['id'] = id2;
237
231
  }
238
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
239
- if (authorizationValue) {
240
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
232
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
233
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
241
234
  }
242
235
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
243
236
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -267,7 +260,7 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
267
260
  listLayouts: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
268
261
  if (options === void 0) { options = {}; }
269
262
  return __awaiter(_this, void 0, void 0, function () {
270
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
263
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
271
264
  return __generator(this, function (_a) {
272
265
  switch (_a.label) {
273
266
  case 0:
@@ -308,9 +301,8 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
308
301
  if (filters !== undefined) {
309
302
  localVarQueryParameter['filters'] = filters;
310
303
  }
311
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
312
- if (authorizationValue) {
313
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
304
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
305
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
314
306
  }
315
307
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
316
308
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -335,7 +327,7 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
335
327
  updateLayout: function (id, updateLayoutRequestDto, authorization, options) {
336
328
  if (options === void 0) { options = {}; }
337
329
  return __awaiter(_this, void 0, void 0, function () {
338
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
330
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
339
331
  return __generator(this, function (_a) {
340
332
  switch (_a.label) {
341
333
  case 0:
@@ -355,16 +347,13 @@ var LayoutsApiAxiosParamCreator = function (configuration) {
355
347
  localVarQueryParameter = {};
356
348
  // authentication bearer required
357
349
  // http bearer authentication required
358
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
359
- // Only Authorization falls back to the configured token; an empty value is never sent.
360
- ];
350
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
361
351
  case 1:
362
352
  // authentication bearer required
363
353
  // http bearer authentication required
364
354
  _a.sent();
365
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
366
- if (authorizationValue) {
367
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
355
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
356
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
368
357
  }
369
358
  localVarHeaderParameter['Content-Type'] = 'application/json';
370
359
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -155,7 +155,7 @@ export declare class MSGraphWebhooksApi extends BaseAPI {
155
155
  * @throws {RequiredError}
156
156
  * @memberof MSGraphWebhooksApi
157
157
  */
158
- receiveLifecycle(requestParameters: MSGraphWebhooksApiReceiveLifecycleRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}, any>>;
158
+ receiveLifecycle(requestParameters: MSGraphWebhooksApiReceiveLifecycleRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
159
159
  /**
160
160
  * Public route called by Microsoft Graph. Echoes `validationToken` as text/plain, otherwise enqueues the notifications and answers 202. See docs/webhooks/msgraph.md. **Required Permissions** none
161
161
  * @summary Receive Microsoft Graph change notifications
@@ -164,5 +164,5 @@ export declare class MSGraphWebhooksApi extends BaseAPI {
164
164
  * @throws {RequiredError}
165
165
  * @memberof MSGraphWebhooksApi
166
166
  */
167
- receiveNotifications(requestParameters: MSGraphWebhooksApiReceiveNotificationsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}, any>>;
167
+ receiveNotifications(requestParameters: MSGraphWebhooksApiReceiveNotificationsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
168
168
  }
@@ -362,7 +362,7 @@ export declare class NotificationTemplatesApi extends BaseAPI {
362
362
  * @throws {RequiredError}
363
363
  * @memberof NotificationTemplatesApi
364
364
  */
365
- createNotificationTemplate(requestParameters: NotificationTemplatesApiCreateNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateNotificationTemplateResponseClass, any, {}, any>>;
365
+ createNotificationTemplate(requestParameters: NotificationTemplatesApiCreateNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateNotificationTemplateResponseClass, any, {}>>;
366
366
  /**
367
367
  * Permanently deletes the notification template with the given id. **Required Permissions** \"notification-management.email-templates.delete\"
368
368
  * @summary Delete the notification template
@@ -371,7 +371,7 @@ export declare class NotificationTemplatesApi extends BaseAPI {
371
371
  * @throws {RequiredError}
372
372
  * @memberof NotificationTemplatesApi
373
373
  */
374
- deleteNotificationTemplate(requestParameters: NotificationTemplatesApiDeleteNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<object, any, {}, any>>;
374
+ deleteNotificationTemplate(requestParameters: NotificationTemplatesApiDeleteNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<object, any, {}>>;
375
375
  /**
376
376
  * Retrieves the details of the notification template with the given id. **Required Permissions** \"notification-management.email-templates.view\"
377
377
  * @summary Retrieve the notification template
@@ -380,7 +380,7 @@ export declare class NotificationTemplatesApi extends BaseAPI {
380
380
  * @throws {RequiredError}
381
381
  * @memberof NotificationTemplatesApi
382
382
  */
383
- getNotificationTemplate(requestParameters: NotificationTemplatesApiGetNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetNotificationTemplateResponseClass, any, {}, any>>;
383
+ getNotificationTemplate(requestParameters: NotificationTemplatesApiGetNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetNotificationTemplateResponseClass, any, {}>>;
384
384
  /**
385
385
  * Returns a list of notification templates. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-templates.view\"
386
386
  * @summary List notification templates
@@ -389,7 +389,7 @@ export declare class NotificationTemplatesApi extends BaseAPI {
389
389
  * @throws {RequiredError}
390
390
  * @memberof NotificationTemplatesApi
391
391
  */
392
- listNotificationTemplates(requestParameters?: NotificationTemplatesApiListNotificationTemplatesRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListNotificationTemplatesResponseClass, any, {}, any>>;
392
+ listNotificationTemplates(requestParameters?: NotificationTemplatesApiListNotificationTemplatesRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListNotificationTemplatesResponseClass, any, {}>>;
393
393
  /**
394
394
  * Updates the specified notification template by setting the values of the parameters passed. Any parameters not provided will be left unchanged. **Required Permissions** \"notification-management.email-templates.update\"
395
395
  * @summary Update the notification template
@@ -398,5 +398,5 @@ export declare class NotificationTemplatesApi extends BaseAPI {
398
398
  * @throws {RequiredError}
399
399
  * @memberof NotificationTemplatesApi
400
400
  */
401
- updateNotificationTemplate(requestParameters: NotificationTemplatesApiUpdateNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UpdateNotificationTemplateResponseClass, any, {}, any>>;
401
+ updateNotificationTemplate(requestParameters: NotificationTemplatesApiUpdateNotificationTemplateRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UpdateNotificationTemplateResponseClass, any, {}>>;
402
402
  }
@@ -103,7 +103,7 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
103
103
  createNotificationTemplate: function (createNotificationTemplateRequestDto, authorization, options) {
104
104
  if (options === void 0) { options = {}; }
105
105
  return __awaiter(_this, void 0, void 0, function () {
106
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
106
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
107
  return __generator(this, function (_a) {
108
108
  switch (_a.label) {
109
109
  case 0:
@@ -120,16 +120,13 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
120
120
  localVarQueryParameter = {};
121
121
  // authentication bearer required
122
122
  // http bearer authentication required
123
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
124
- // Only Authorization falls back to the configured token; an empty value is never sent.
125
- ];
123
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
126
124
  case 1:
127
125
  // authentication bearer required
128
126
  // http bearer authentication required
129
127
  _a.sent();
130
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
131
- if (authorizationValue) {
132
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
128
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
129
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
133
130
  }
134
131
  localVarHeaderParameter['Content-Type'] = 'application/json';
135
132
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -155,7 +152,7 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
155
152
  deleteNotificationTemplate: function (id, authorization, options) {
156
153
  if (options === void 0) { options = {}; }
157
154
  return __awaiter(_this, void 0, void 0, function () {
158
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
155
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
159
156
  return __generator(this, function (_a) {
160
157
  switch (_a.label) {
161
158
  case 0:
@@ -173,16 +170,13 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
173
170
  localVarQueryParameter = {};
174
171
  // authentication bearer required
175
172
  // http bearer authentication required
176
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
177
- // Only Authorization falls back to the configured token; an empty value is never sent.
178
- ];
173
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
179
174
  case 1:
180
175
  // authentication bearer required
181
176
  // http bearer authentication required
182
177
  _a.sent();
183
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
184
- if (authorizationValue) {
185
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
178
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
179
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
186
180
  }
187
181
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
188
182
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -208,7 +202,7 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
208
202
  getNotificationTemplate: function (id, id2, authorization, expand, options) {
209
203
  if (options === void 0) { options = {}; }
210
204
  return __awaiter(_this, void 0, void 0, function () {
211
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
205
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
212
206
  return __generator(this, function (_a) {
213
207
  switch (_a.label) {
214
208
  case 0:
@@ -239,9 +233,8 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
239
233
  if (expand !== undefined) {
240
234
  localVarQueryParameter['expand'] = expand;
241
235
  }
242
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
243
- if (authorizationValue) {
244
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
236
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
237
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
245
238
  }
246
239
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
247
240
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -271,7 +264,7 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
271
264
  listNotificationTemplates: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
272
265
  if (options === void 0) { options = {}; }
273
266
  return __awaiter(_this, void 0, void 0, function () {
274
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
267
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
275
268
  return __generator(this, function (_a) {
276
269
  switch (_a.label) {
277
270
  case 0:
@@ -312,9 +305,8 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
312
305
  if (filters !== undefined) {
313
306
  localVarQueryParameter['filters'] = filters;
314
307
  }
315
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
316
- if (authorizationValue) {
317
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
308
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
309
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
318
310
  }
319
311
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
320
312
  headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -339,7 +331,7 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
339
331
  updateNotificationTemplate: function (id, updateNotificationTemplateRequestDto, authorization, options) {
340
332
  if (options === void 0) { options = {}; }
341
333
  return __awaiter(_this, void 0, void 0, function () {
342
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
334
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
343
335
  return __generator(this, function (_a) {
344
336
  switch (_a.label) {
345
337
  case 0:
@@ -359,16 +351,13 @@ var NotificationTemplatesApiAxiosParamCreator = function (configuration) {
359
351
  localVarQueryParameter = {};
360
352
  // authentication bearer required
361
353
  // http bearer authentication required
362
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
363
- // Only Authorization falls back to the configured token; an empty value is never sent.
364
- ];
354
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
365
355
  case 1:
366
356
  // authentication bearer required
367
357
  // http bearer authentication required
368
358
  _a.sent();
369
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
370
- if (authorizationValue) {
371
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
359
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
360
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
372
361
  }
373
362
  localVarHeaderParameter['Content-Type'] = 'application/json';
374
363
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -141,7 +141,7 @@ export declare class NotificationsApi extends BaseAPI {
141
141
  * @throws {RequiredError}
142
142
  * @memberof NotificationsApi
143
143
  */
144
- sendEmail(requestParameters: NotificationsApiSendEmailRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<SendEmailResponseClass, any, {}, any>>;
144
+ sendEmail(requestParameters: NotificationsApiSendEmailRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<SendEmailResponseClass, any, {}>>;
145
145
  /**
146
146
  * Sends an email using the notification template identified by `templateSlug`. Provide `entityType` and `entityCode` to track replies in an email thread. **Required Permissions** none
147
147
  * @summary Send a notification
@@ -150,5 +150,5 @@ export declare class NotificationsApi extends BaseAPI {
150
150
  * @throws {RequiredError}
151
151
  * @memberof NotificationsApi
152
152
  */
153
- sendNotification(requestParameters: NotificationsApiSendNotificationRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<SendNotificationResponseClass, any, {}, any>>;
153
+ sendNotification(requestParameters: NotificationsApiSendNotificationRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<SendNotificationResponseClass, any, {}>>;
154
154
  }
@@ -103,7 +103,7 @@ var NotificationsApiAxiosParamCreator = function (configuration) {
103
103
  sendEmail: function (sendEmailRequestDto, authorization, options) {
104
104
  if (options === void 0) { options = {}; }
105
105
  return __awaiter(_this, void 0, void 0, function () {
106
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
106
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
107
  return __generator(this, function (_a) {
108
108
  switch (_a.label) {
109
109
  case 0:
@@ -120,16 +120,13 @@ var NotificationsApiAxiosParamCreator = function (configuration) {
120
120
  localVarQueryParameter = {};
121
121
  // authentication bearer required
122
122
  // http bearer authentication required
123
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
124
- // Only Authorization falls back to the configured token; an empty value is never sent.
125
- ];
123
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
126
124
  case 1:
127
125
  // authentication bearer required
128
126
  // http bearer authentication required
129
127
  _a.sent();
130
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
131
- if (authorizationValue) {
132
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
128
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
129
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
133
130
  }
134
131
  localVarHeaderParameter['Content-Type'] = 'application/json';
135
132
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
@@ -155,7 +152,7 @@ var NotificationsApiAxiosParamCreator = function (configuration) {
155
152
  sendNotification: function (sendNotificationRequestDto, authorization, options) {
156
153
  if (options === void 0) { options = {}; }
157
154
  return __awaiter(_this, void 0, void 0, function () {
158
- var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
155
+ var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
159
156
  return __generator(this, function (_a) {
160
157
  switch (_a.label) {
161
158
  case 0:
@@ -172,16 +169,13 @@ var NotificationsApiAxiosParamCreator = function (configuration) {
172
169
  localVarQueryParameter = {};
173
170
  // authentication bearer required
174
171
  // http bearer authentication required
175
- return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
176
- // Only Authorization falls back to the configured token; an empty value is never sent.
177
- ];
172
+ return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)];
178
173
  case 1:
179
174
  // authentication bearer required
180
175
  // http bearer authentication required
181
176
  _a.sent();
182
- authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
183
- if (authorizationValue) {
184
- localVarHeaderParameter['Authorization'] = String(authorizationValue);
177
+ if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
178
+ localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
185
179
  }
186
180
  localVarHeaderParameter['Content-Type'] = 'application/json';
187
181
  (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
package/dist/base.d.ts CHANGED
@@ -22,19 +22,9 @@ export declare const COLLECTION_FORMATS: {
22
22
  tsv: string;
23
23
  pipes: string;
24
24
  };
25
- export interface SessionClass {
26
- sub: string;
27
- username?: string;
28
- email?: string;
29
- tenantSlug?: string;
30
- permissions?: string;
31
- expiresAt?: number;
32
- }
33
25
  export interface LoginClass {
34
26
  accessToken: string;
35
27
  permissions: string;
36
- authMode?: string;
37
- session?: SessionClass;
38
28
  }
39
29
  export interface SwitchWorkspaceRequest {
40
30
  username: string;
@@ -43,8 +33,6 @@ export interface SwitchWorkspaceRequest {
43
33
  export interface SwitchWorkspaceResponseClass {
44
34
  accessToken: string;
45
35
  permissions: string;
46
- authMode?: string;
47
- session?: SessionClass;
48
36
  }
49
37
  export declare enum Environment {
50
38
  Production = "https://apiv2.emil.de",
@@ -75,18 +63,6 @@ export declare class BaseAPI {
75
63
  protected configuration: Configuration | undefined;
76
64
  private tokenData?;
77
65
  constructor(configuration?: Configuration, basePath?: string, axios?: AxiosInstance);
78
- private sessionAccount;
79
- private authBasePath;
80
- private usesSession;
81
- private useSessionAuth;
82
- private useHeaderAuth;
83
- private applyTokenReply;
84
- private sessionHeaders;
85
- private withCurrentAuth;
86
- private canRetryWithToken;
87
- private canResend;
88
- private switchToToken;
89
- private retryWithToken;
90
66
  selectEnvironment(env: Environment): void;
91
67
  selectBasePath(path: string): void;
92
68
  getPermissions(): Array<string>;