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

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 (114) hide show
  1. package/.openapi-generator/FILES +23 -0
  2. package/README.md +2 -2
  3. package/api/email-mailboxes-api.ts +150 -0
  4. package/api/email-messages-api.ts +56 -36
  5. package/api/email-subscriptions-api.ts +781 -0
  6. package/api/email-tracking-api.ts +291 -48
  7. package/api/email-verifications-api.ts +24 -12
  8. package/api/layouts-api.ts +76 -46
  9. package/api/msgraph-webhooks-api.ts +278 -0
  10. package/api/notification-templates-api.ts +76 -46
  11. package/api/notifications-api.ts +121 -6
  12. package/api.ts +6 -0
  13. package/base.ts +174 -41
  14. package/common.ts +3 -2
  15. package/configuration.ts +20 -0
  16. package/dist/api/email-mailboxes-api.d.ts +87 -0
  17. package/dist/api/email-mailboxes-api.js +221 -0
  18. package/dist/api/email-messages-api.d.ts +44 -32
  19. package/dist/api/email-messages-api.js +62 -40
  20. package/dist/api/email-subscriptions-api.d.ts +432 -0
  21. package/dist/api/email-subscriptions-api.js +738 -0
  22. package/dist/api/email-tracking-api.d.ts +174 -44
  23. package/dist/api/email-tracking-api.js +261 -48
  24. package/dist/api/email-verifications-api.d.ts +18 -10
  25. package/dist/api/email-verifications-api.js +30 -16
  26. package/dist/api/health-api.d.ts +1 -1
  27. package/dist/api/layouts-api.d.ts +61 -41
  28. package/dist/api/layouts-api.js +81 -50
  29. package/dist/api/msgraph-webhooks-api.d.ts +168 -0
  30. package/dist/api/msgraph-webhooks-api.js +305 -0
  31. package/dist/api/notification-templates-api.d.ts +61 -41
  32. package/dist/api/notification-templates-api.js +81 -50
  33. package/dist/api/notifications-api.d.ts +66 -5
  34. package/dist/api/notifications-api.js +111 -8
  35. package/dist/api.d.ts +3 -0
  36. package/dist/api.js +3 -0
  37. package/dist/base.d.ts +24 -0
  38. package/dist/base.js +178 -59
  39. package/dist/common.d.ts +1 -1
  40. package/dist/common.js +1 -0
  41. package/dist/configuration.d.ts +17 -0
  42. package/dist/configuration.js +2 -0
  43. package/dist/models/assign-email-thread-entity-body-dto.d.ts +43 -0
  44. package/dist/models/assign-email-thread-entity-body-dto.js +22 -0
  45. package/dist/models/assign-email-thread-entity-response-class.d.ts +25 -0
  46. package/dist/models/assign-email-thread-entity-response-class.js +15 -0
  47. package/dist/models/catch-up-email-subscription-response-class.d.ts +24 -0
  48. package/dist/models/catch-up-email-subscription-response-class.js +15 -0
  49. package/dist/models/catch-up-email-subscriptions-request-dto.d.ts +24 -0
  50. package/dist/models/catch-up-email-subscriptions-request-dto.js +15 -0
  51. package/dist/models/catch-up-email-subscriptions-response-class.d.ts +30 -0
  52. package/dist/models/catch-up-email-subscriptions-response-class.js +15 -0
  53. package/dist/models/email-mailbox-class.d.ts +47 -0
  54. package/dist/models/email-mailbox-class.js +20 -0
  55. package/dist/models/email-message-class.d.ts +73 -7
  56. package/dist/models/email-message-class.js +22 -3
  57. package/dist/models/email-message-summary-class.d.ts +98 -0
  58. package/dist/models/email-message-summary-class.js +33 -0
  59. package/dist/models/email-subscription-class.d.ts +110 -0
  60. package/dist/models/email-subscription-class.js +23 -0
  61. package/dist/models/email-thread-class.d.ts +37 -5
  62. package/dist/models/entity-ref-class.d.ts +37 -0
  63. package/dist/models/entity-ref-class.js +22 -0
  64. package/dist/models/get-email-subscription-response-class.d.ts +25 -0
  65. package/dist/models/get-email-subscription-response-class.js +15 -0
  66. package/dist/models/grpc-send-email-request-dto.d.ts +137 -0
  67. package/dist/models/grpc-send-email-request-dto.js +22 -0
  68. package/dist/models/index.d.ts +20 -0
  69. package/dist/models/index.js +20 -0
  70. package/dist/models/inline-attachment-dto.d.ts +36 -0
  71. package/dist/models/inline-attachment-dto.js +15 -0
  72. package/dist/models/list-email-mailboxes-response-class.d.ts +43 -0
  73. package/dist/models/list-email-mailboxes-response-class.js +15 -0
  74. package/dist/models/list-email-subscriptions-response-class.d.ts +43 -0
  75. package/dist/models/list-email-subscriptions-response-class.js +15 -0
  76. package/dist/models/reconcile-email-subscriptions-request-dto.d.ts +24 -0
  77. package/dist/models/reconcile-email-subscriptions-request-dto.js +15 -0
  78. package/dist/models/reconcile-email-subscriptions-response-class.d.ts +48 -0
  79. package/dist/models/reconcile-email-subscriptions-response-class.js +15 -0
  80. package/dist/models/renew-email-subscription-response-class.d.ts +25 -0
  81. package/dist/models/renew-email-subscription-response-class.js +15 -0
  82. package/dist/models/send-email-request-dto.d.ts +131 -0
  83. package/dist/models/send-email-request-dto.js +22 -0
  84. package/dist/models/send-email-response-class.d.ts +24 -0
  85. package/dist/models/send-email-response-class.js +15 -0
  86. package/dist/models/send-notification-request-dto.d.ts +10 -1
  87. package/dist/models/send-notification-request-dto.js +2 -1
  88. package/dist/models/unassign-email-thread-entity-response-class.d.ts +25 -0
  89. package/dist/models/unassign-email-thread-entity-response-class.js +15 -0
  90. package/models/assign-email-thread-entity-body-dto.ts +52 -0
  91. package/models/assign-email-thread-entity-response-class.ts +31 -0
  92. package/models/catch-up-email-subscription-response-class.ts +30 -0
  93. package/models/catch-up-email-subscriptions-request-dto.ts +30 -0
  94. package/models/catch-up-email-subscriptions-response-class.ts +36 -0
  95. package/models/email-mailbox-class.ts +56 -0
  96. package/models/email-message-class.ts +78 -8
  97. package/models/email-message-summary-class.ts +109 -0
  98. package/models/email-subscription-class.ts +119 -0
  99. package/models/email-thread-class.ts +37 -5
  100. package/models/entity-ref-class.ts +46 -0
  101. package/models/get-email-subscription-response-class.ts +31 -0
  102. package/models/grpc-send-email-request-dto.ts +144 -0
  103. package/models/index.ts +20 -0
  104. package/models/inline-attachment-dto.ts +42 -0
  105. package/models/list-email-mailboxes-response-class.ts +49 -0
  106. package/models/list-email-subscriptions-response-class.ts +49 -0
  107. package/models/reconcile-email-subscriptions-request-dto.ts +30 -0
  108. package/models/reconcile-email-subscriptions-response-class.ts +54 -0
  109. package/models/renew-email-subscription-response-class.ts +31 -0
  110. package/models/send-email-request-dto.ts +138 -0
  111. package/models/send-email-response-class.ts +30 -0
  112. package/models/send-notification-request-dto.ts +9 -2
  113. package/models/unassign-email-thread-entity-response-class.ts +31 -0
  114. package/package.json +2 -2
@@ -21,11 +21,17 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj
21
21
  // @ts-ignore
22
22
  import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from '../base';
23
23
  // @ts-ignore
24
+ import { AssignEmailThreadEntityBodyDto } from '../models';
25
+ // @ts-ignore
26
+ import { AssignEmailThreadEntityResponseClass } from '../models';
27
+ // @ts-ignore
24
28
  import { GetEmailThreadResponseClass } from '../models';
25
29
  // @ts-ignore
26
30
  import { ListEmailMessagesResponseClass } from '../models';
27
31
  // @ts-ignore
28
32
  import { ListEmailThreadsResponseClass } from '../models';
33
+ // @ts-ignore
34
+ import { UnassignEmailThreadEntityResponseClass } from '../models';
29
35
  /**
30
36
  * EmailTrackingApi - axios parameter creator
31
37
  * @export
@@ -33,7 +39,61 @@ import { ListEmailThreadsResponseClass } from '../models';
33
39
  export const EmailTrackingApiAxiosParamCreator = function (configuration?: Configuration) {
34
40
  return {
35
41
  /**
36
- * undefined **Required Permissions** \"notification-management.email-messages.update\"
42
+ * Links the email thread, and every message in it, to the given entity, identified by code or by number (the code wins when both are set). Replaces the current link. The entity must exist. Messages that arrive in the thread later are linked to the same entity. **Required Permissions** \"notification-management.email-messages.update\"
43
+ * @summary Assign an email thread to an entity
44
+ * @param {string} code
45
+ * @param {AssignEmailThreadEntityBodyDto} assignEmailThreadEntityBodyDto
46
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
47
+ * @param {*} [options] Override http request option.
48
+ * @throws {RequiredError}
49
+ */
50
+ assignEntity: async (code: string, assignEmailThreadEntityBodyDto: AssignEmailThreadEntityBodyDto, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
51
+ // verify required parameter 'code' is not null or undefined
52
+ assertParamExists('assignEntity', 'code', code)
53
+ // verify required parameter 'assignEmailThreadEntityBodyDto' is not null or undefined
54
+ assertParamExists('assignEntity', 'assignEmailThreadEntityBodyDto', assignEmailThreadEntityBodyDto)
55
+ const localVarPath = `/notificationservice/v1/email-threads/{code}/entity`
56
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
57
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
58
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
59
+ let baseOptions;
60
+ let baseAccessToken;
61
+ if (configuration) {
62
+ baseOptions = configuration.baseOptions;
63
+ baseAccessToken = configuration.accessToken;
64
+ }
65
+
66
+ const localVarRequestOptions = { method: 'PATCH', ...baseOptions, ...options};
67
+ const localVarHeaderParameter = {} as any;
68
+ const localVarQueryParameter = {} as any;
69
+
70
+ // authentication bearer required
71
+ // http bearer authentication required
72
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
73
+
74
+ // Only Authorization falls back to the configured token; an empty value is never sent.
75
+ const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
76
+ if (authorizationValue) {
77
+ localVarHeaderParameter['Authorization'] = String(authorizationValue);
78
+ }
79
+
80
+
81
+
82
+ localVarHeaderParameter['Content-Type'] = 'application/json';
83
+
84
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
85
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
86
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
87
+ localVarRequestOptions.data = serializeDataIfNeeded(assignEmailThreadEntityBodyDto, localVarRequestOptions, configuration)
88
+
89
+ return {
90
+ url: toPathString(localVarUrlObj),
91
+ options: localVarRequestOptions,
92
+ };
93
+ },
94
+ /**
95
+ * Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
96
+ * @summary Close the email thread
37
97
  * @param {string} code
38
98
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
39
99
  * @param {*} [options] Override http request option.
@@ -61,8 +121,10 @@ export const EmailTrackingApiAxiosParamCreator = function (configuration?: Confi
61
121
  // http bearer authentication required
62
122
  await setBearerAuthToObject(localVarHeaderParameter, configuration)
63
123
 
64
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
65
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
124
+ // Only Authorization falls back to the configured token; an empty value is never sent.
125
+ const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
126
+ if (authorizationValue) {
127
+ localVarHeaderParameter['Authorization'] = String(authorizationValue);
66
128
  }
67
129
 
68
130
 
@@ -77,7 +139,8 @@ export const EmailTrackingApiAxiosParamCreator = function (configuration?: Confi
77
139
  };
78
140
  },
79
141
  /**
80
- * undefined **Required Permissions** \"notification-management.email-messages.view\"
142
+ * Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
143
+ * @summary Retrieve the email thread
81
144
  * @param {string} code
82
145
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
83
146
  * @param {*} [options] Override http request option.
@@ -105,8 +168,10 @@ export const EmailTrackingApiAxiosParamCreator = function (configuration?: Confi
105
168
  // http bearer authentication required
106
169
  await setBearerAuthToObject(localVarHeaderParameter, configuration)
107
170
 
108
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
109
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
171
+ // Only Authorization falls back to the configured token; an empty value is never sent.
172
+ const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
173
+ if (authorizationValue) {
174
+ localVarHeaderParameter['Authorization'] = String(authorizationValue);
110
175
  }
111
176
 
112
177
 
@@ -121,13 +186,13 @@ export const EmailTrackingApiAxiosParamCreator = function (configuration?: Confi
121
186
  };
122
187
  },
123
188
  /**
124
- * Lists all email messages for a thread **Required Permissions** \"notification-management.email-messages.view\"
189
+ * Returns the email messages of the email thread with the given code. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
125
190
  * @summary List email messages
126
191
  * @param {string} code
127
192
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
128
- * @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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
129
- * @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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
130
- * @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, code, threadCode, direction, deliveryStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
193
+ * @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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
194
+ * @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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
195
+ * @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, code, threadCode, direction, deliveryStatus, workflowStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
131
196
  * @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: attachments&lt;i&gt;
132
197
  * @param {*} [options] Override http request option.
133
198
  * @throws {RequiredError}
@@ -170,8 +235,10 @@ export const EmailTrackingApiAxiosParamCreator = function (configuration?: Confi
170
235
  localVarQueryParameter['expand'] = expand;
171
236
  }
172
237
 
173
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
174
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
238
+ // Only Authorization falls back to the configured token; an empty value is never sent.
239
+ const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
240
+ if (authorizationValue) {
241
+ localVarHeaderParameter['Authorization'] = String(authorizationValue);
175
242
  }
176
243
 
177
244
 
@@ -186,16 +253,16 @@ export const EmailTrackingApiAxiosParamCreator = function (configuration?: Confi
186
253
  };
187
254
  },
188
255
  /**
189
- * Lists all email threads with optional filters **Required Permissions** \"notification-management.email-messages.view\"
256
+ * Returns a list of email threads, newest first. A thread groups an email with its replies; each item carries the newest message of the thread in latestMessage and the number of messages in messageCount. Threads without a message yet are not listed. Filter on the newest message with latestDirection (inbox tabs), latestDeliveryStatus or latestWorkflowStatus (use latestWorkflowStatus==$null for threads whose newest message has no workflow). Add expand=messages to get every message of each thread, without bodies. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
190
257
  * @summary List email threads
191
258
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
192
259
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
193
260
  * @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.
194
- * @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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
261
+ * @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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
195
262
  * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
196
- * @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, code, entityType, entityCode, subject, status, createdAt, updatedAt&lt;/i&gt;
263
+ * @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, code, entityType, entityCode, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, createdAt, updatedAt&lt;/i&gt;
197
264
  * @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: messages&lt;i&gt;
198
- * @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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
265
+ * @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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
199
266
  * @param {*} [options] Override http request option.
200
267
  * @throws {RequiredError}
201
268
  */
@@ -246,8 +313,57 @@ export const EmailTrackingApiAxiosParamCreator = function (configuration?: Confi
246
313
  localVarQueryParameter['filters'] = filters;
247
314
  }
248
315
 
249
- if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
250
- localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
316
+ // Only Authorization falls back to the configured token; an empty value is never sent.
317
+ const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
318
+ if (authorizationValue) {
319
+ localVarHeaderParameter['Authorization'] = String(authorizationValue);
320
+ }
321
+
322
+
323
+
324
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
325
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
326
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
327
+
328
+ return {
329
+ url: toPathString(localVarUrlObj),
330
+ options: localVarRequestOptions,
331
+ };
332
+ },
333
+ /**
334
+ * Removes the entity link from the email thread and every message in it, and marks the messages as unassigned. **Required Permissions** \"notification-management.email-messages.update\"
335
+ * @summary Unassign an email thread from its entity
336
+ * @param {string} code
337
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
338
+ * @param {*} [options] Override http request option.
339
+ * @throws {RequiredError}
340
+ */
341
+ unassignEntity: async (code: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
342
+ // verify required parameter 'code' is not null or undefined
343
+ assertParamExists('unassignEntity', 'code', code)
344
+ const localVarPath = `/notificationservice/v1/email-threads/{code}/entity`
345
+ .replace(`{${"code"}}`, encodeURIComponent(String(code)));
346
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
347
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
348
+ let baseOptions;
349
+ let baseAccessToken;
350
+ if (configuration) {
351
+ baseOptions = configuration.baseOptions;
352
+ baseAccessToken = configuration.accessToken;
353
+ }
354
+
355
+ const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
356
+ const localVarHeaderParameter = {} as any;
357
+ const localVarQueryParameter = {} as any;
358
+
359
+ // authentication bearer required
360
+ // http bearer authentication required
361
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
362
+
363
+ // Only Authorization falls back to the configured token; an empty value is never sent.
364
+ const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
365
+ if (authorizationValue) {
366
+ localVarHeaderParameter['Authorization'] = String(authorizationValue);
251
367
  }
252
368
 
253
369
 
@@ -272,7 +388,21 @@ export const EmailTrackingApiFp = function(configuration?: Configuration) {
272
388
  const localVarAxiosParamCreator = EmailTrackingApiAxiosParamCreator(configuration)
273
389
  return {
274
390
  /**
275
- * undefined **Required Permissions** \"notification-management.email-messages.update\"
391
+ * Links the email thread, and every message in it, to the given entity, identified by code or by number (the code wins when both are set). Replaces the current link. The entity must exist. Messages that arrive in the thread later are linked to the same entity. **Required Permissions** \"notification-management.email-messages.update\"
392
+ * @summary Assign an email thread to an entity
393
+ * @param {string} code
394
+ * @param {AssignEmailThreadEntityBodyDto} assignEmailThreadEntityBodyDto
395
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
396
+ * @param {*} [options] Override http request option.
397
+ * @throws {RequiredError}
398
+ */
399
+ async assignEntity(code: string, assignEmailThreadEntityBodyDto: AssignEmailThreadEntityBodyDto, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AssignEmailThreadEntityResponseClass>> {
400
+ const localVarAxiosArgs = await localVarAxiosParamCreator.assignEntity(code, assignEmailThreadEntityBodyDto, authorization, options);
401
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
402
+ },
403
+ /**
404
+ * Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
405
+ * @summary Close the email thread
276
406
  * @param {string} code
277
407
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
278
408
  * @param {*} [options] Override http request option.
@@ -283,7 +413,8 @@ export const EmailTrackingApiFp = function(configuration?: Configuration) {
283
413
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
284
414
  },
285
415
  /**
286
- * undefined **Required Permissions** \"notification-management.email-messages.view\"
416
+ * Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
417
+ * @summary Retrieve the email thread
287
418
  * @param {string} code
288
419
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
289
420
  * @param {*} [options] Override http request option.
@@ -294,13 +425,13 @@ export const EmailTrackingApiFp = function(configuration?: Configuration) {
294
425
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
295
426
  },
296
427
  /**
297
- * Lists all email messages for a thread **Required Permissions** \"notification-management.email-messages.view\"
428
+ * Returns the email messages of the email thread with the given code. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
298
429
  * @summary List email messages
299
430
  * @param {string} code
300
431
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
301
- * @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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
302
- * @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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
303
- * @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, code, threadCode, direction, deliveryStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
432
+ * @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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
433
+ * @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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
434
+ * @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, code, threadCode, direction, deliveryStatus, workflowStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
304
435
  * @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: attachments&lt;i&gt;
305
436
  * @param {*} [options] Override http request option.
306
437
  * @throws {RequiredError}
@@ -310,16 +441,16 @@ export const EmailTrackingApiFp = function(configuration?: Configuration) {
310
441
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
311
442
  },
312
443
  /**
313
- * Lists all email threads with optional filters **Required Permissions** \"notification-management.email-messages.view\"
444
+ * Returns a list of email threads, newest first. A thread groups an email with its replies; each item carries the newest message of the thread in latestMessage and the number of messages in messageCount. Threads without a message yet are not listed. Filter on the newest message with latestDirection (inbox tabs), latestDeliveryStatus or latestWorkflowStatus (use latestWorkflowStatus==$null for threads whose newest message has no workflow). Add expand=messages to get every message of each thread, without bodies. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
314
445
  * @summary List email threads
315
446
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
316
447
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
317
448
  * @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.
318
- * @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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
449
+ * @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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
319
450
  * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
320
- * @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, code, entityType, entityCode, subject, status, createdAt, updatedAt&lt;/i&gt;
451
+ * @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, code, entityType, entityCode, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, createdAt, updatedAt&lt;/i&gt;
321
452
  * @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: messages&lt;i&gt;
322
- * @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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
453
+ * @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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
323
454
  * @param {*} [options] Override http request option.
324
455
  * @throws {RequiredError}
325
456
  */
@@ -327,6 +458,18 @@ export const EmailTrackingApiFp = function(configuration?: Configuration) {
327
458
  const localVarAxiosArgs = await localVarAxiosParamCreator.listThreads(authorization, pageSize, pageToken, filter, search, order, expand, filters, options);
328
459
  return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
329
460
  },
461
+ /**
462
+ * Removes the entity link from the email thread and every message in it, and marks the messages as unassigned. **Required Permissions** \"notification-management.email-messages.update\"
463
+ * @summary Unassign an email thread from its entity
464
+ * @param {string} code
465
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
466
+ * @param {*} [options] Override http request option.
467
+ * @throws {RequiredError}
468
+ */
469
+ async unassignEntity(code: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UnassignEmailThreadEntityResponseClass>> {
470
+ const localVarAxiosArgs = await localVarAxiosParamCreator.unassignEntity(code, authorization, options);
471
+ return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
472
+ },
330
473
  }
331
474
  };
332
475
 
@@ -338,7 +481,20 @@ export const EmailTrackingApiFactory = function (configuration?: Configuration,
338
481
  const localVarFp = EmailTrackingApiFp(configuration)
339
482
  return {
340
483
  /**
341
- * undefined **Required Permissions** \"notification-management.email-messages.update\"
484
+ * Links the email thread, and every message in it, to the given entity, identified by code or by number (the code wins when both are set). Replaces the current link. The entity must exist. Messages that arrive in the thread later are linked to the same entity. **Required Permissions** \"notification-management.email-messages.update\"
485
+ * @summary Assign an email thread to an entity
486
+ * @param {string} code
487
+ * @param {AssignEmailThreadEntityBodyDto} assignEmailThreadEntityBodyDto
488
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
489
+ * @param {*} [options] Override http request option.
490
+ * @throws {RequiredError}
491
+ */
492
+ assignEntity(code: string, assignEmailThreadEntityBodyDto: AssignEmailThreadEntityBodyDto, authorization?: string, options?: any): AxiosPromise<AssignEmailThreadEntityResponseClass> {
493
+ return localVarFp.assignEntity(code, assignEmailThreadEntityBodyDto, authorization, options).then((request) => request(axios, basePath));
494
+ },
495
+ /**
496
+ * Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
497
+ * @summary Close the email thread
342
498
  * @param {string} code
343
499
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
344
500
  * @param {*} [options] Override http request option.
@@ -348,7 +504,8 @@ export const EmailTrackingApiFactory = function (configuration?: Configuration,
348
504
  return localVarFp.closeThread(code, authorization, options).then((request) => request(axios, basePath));
349
505
  },
350
506
  /**
351
- * undefined **Required Permissions** \"notification-management.email-messages.view\"
507
+ * Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
508
+ * @summary Retrieve the email thread
352
509
  * @param {string} code
353
510
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
354
511
  * @param {*} [options] Override http request option.
@@ -358,13 +515,13 @@ export const EmailTrackingApiFactory = function (configuration?: Configuration,
358
515
  return localVarFp.getThread(code, authorization, options).then((request) => request(axios, basePath));
359
516
  },
360
517
  /**
361
- * Lists all email messages for a thread **Required Permissions** \"notification-management.email-messages.view\"
518
+ * Returns the email messages of the email thread with the given code. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
362
519
  * @summary List email messages
363
520
  * @param {string} code
364
521
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
365
- * @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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
366
- * @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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
367
- * @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, code, threadCode, direction, deliveryStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
522
+ * @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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
523
+ * @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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
524
+ * @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: id, code, threadCode, direction, deliveryStatus, workflowStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
368
525
  * @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.&lt;br/&gt; &lt;br/&gt; &lt;i&gt;Allowed values: attachments&lt;i&gt;
369
526
  * @param {*} [options] Override http request option.
370
527
  * @throws {RequiredError}
@@ -373,25 +530,64 @@ export const EmailTrackingApiFactory = function (configuration?: Configuration,
373
530
  return localVarFp.listMessages(code, authorization, filter, filters, order, expand, options).then((request) => request(axios, basePath));
374
531
  },
375
532
  /**
376
- * Lists all email threads with optional filters **Required Permissions** \"notification-management.email-messages.view\"
533
+ * Returns a list of email threads, newest first. A thread groups an email with its replies; each item carries the newest message of the thread in latestMessage and the number of messages in messageCount. Threads without a message yet are not listed. Filter on the newest message with latestDirection (inbox tabs), latestDeliveryStatus or latestWorkflowStatus (use latestWorkflowStatus==$null for threads whose newest message has no workflow). Add expand=messages to get every message of each thread, without bodies. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
377
534
  * @summary List email threads
378
535
  * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
379
536
  * @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
380
537
  * @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.
381
- * @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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
538
+ * @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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
382
539
  * @param {string} [search] To search the list by any field, pass search&#x3D;xxx to fetch the result.
383
- * @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, code, entityType, entityCode, subject, status, createdAt, updatedAt&lt;/i&gt;
540
+ * @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, code, entityType, entityCode, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, createdAt, updatedAt&lt;/i&gt;
384
541
  * @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: messages&lt;i&gt;
385
- * @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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
542
+ * @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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
386
543
  * @param {*} [options] Override http request option.
387
544
  * @throws {RequiredError}
388
545
  */
389
546
  listThreads(authorization?: string, pageSize?: number, pageToken?: string, filter?: string, search?: string, order?: string, expand?: string, filters?: string, options?: any): AxiosPromise<ListEmailThreadsResponseClass> {
390
547
  return localVarFp.listThreads(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then((request) => request(axios, basePath));
391
548
  },
549
+ /**
550
+ * Removes the entity link from the email thread and every message in it, and marks the messages as unassigned. **Required Permissions** \"notification-management.email-messages.update\"
551
+ * @summary Unassign an email thread from its entity
552
+ * @param {string} code
553
+ * @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
554
+ * @param {*} [options] Override http request option.
555
+ * @throws {RequiredError}
556
+ */
557
+ unassignEntity(code: string, authorization?: string, options?: any): AxiosPromise<UnassignEmailThreadEntityResponseClass> {
558
+ return localVarFp.unassignEntity(code, authorization, options).then((request) => request(axios, basePath));
559
+ },
392
560
  };
393
561
  };
394
562
 
563
+ /**
564
+ * Request parameters for assignEntity operation in EmailTrackingApi.
565
+ * @export
566
+ * @interface EmailTrackingApiAssignEntityRequest
567
+ */
568
+ export interface EmailTrackingApiAssignEntityRequest {
569
+ /**
570
+ *
571
+ * @type {string}
572
+ * @memberof EmailTrackingApiAssignEntity
573
+ */
574
+ readonly code: string
575
+
576
+ /**
577
+ *
578
+ * @type {AssignEmailThreadEntityBodyDto}
579
+ * @memberof EmailTrackingApiAssignEntity
580
+ */
581
+ readonly assignEmailThreadEntityBodyDto: AssignEmailThreadEntityBodyDto
582
+
583
+ /**
584
+ * Bearer Token: provided by the login endpoint under the name accessToken.
585
+ * @type {string}
586
+ * @memberof EmailTrackingApiAssignEntity
587
+ */
588
+ readonly authorization?: string
589
+ }
590
+
395
591
  /**
396
592
  * Request parameters for closeThread operation in EmailTrackingApi.
397
593
  * @export
@@ -455,21 +651,21 @@ export interface EmailTrackingApiListMessagesRequest {
455
651
  readonly authorization?: string
456
652
 
457
653
  /**
458
- * 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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
654
+ * 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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
459
655
  * @type {string}
460
656
  * @memberof EmailTrackingApiListMessages
461
657
  */
462
658
  readonly filter?: string
463
659
 
464
660
  /**
465
- * 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, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
661
+ * 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, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
466
662
  * @type {string}
467
663
  * @memberof EmailTrackingApiListMessages
468
664
  */
469
665
  readonly filters?: string
470
666
 
471
667
  /**
472
- * 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, code, threadCode, direction, deliveryStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
668
+ * 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, code, threadCode, direction, deliveryStatus, workflowStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt&lt;/i&gt;
473
669
  * @type {string}
474
670
  * @memberof EmailTrackingApiListMessages
475
671
  */
@@ -511,7 +707,7 @@ export interface EmailTrackingApiListThreadsRequest {
511
707
  readonly pageToken?: string
512
708
 
513
709
  /**
514
- * 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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
710
+ * 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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
515
711
  * @type {string}
516
712
  * @memberof EmailTrackingApiListThreads
517
713
  */
@@ -525,7 +721,7 @@ export interface EmailTrackingApiListThreadsRequest {
525
721
  readonly search?: string
526
722
 
527
723
  /**
528
- * 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, code, entityType, entityCode, subject, status, createdAt, updatedAt&lt;/i&gt;
724
+ * 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, code, entityType, entityCode, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, createdAt, updatedAt&lt;/i&gt;
529
725
  * @type {string}
530
726
  * @memberof EmailTrackingApiListThreads
531
727
  */
@@ -539,13 +735,34 @@ export interface EmailTrackingApiListThreadsRequest {
539
735
  readonly expand?: string
540
736
 
541
737
  /**
542
- * 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, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
738
+ * 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, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy&lt;/i&gt;
543
739
  * @type {string}
544
740
  * @memberof EmailTrackingApiListThreads
545
741
  */
546
742
  readonly filters?: string
547
743
  }
548
744
 
745
+ /**
746
+ * Request parameters for unassignEntity operation in EmailTrackingApi.
747
+ * @export
748
+ * @interface EmailTrackingApiUnassignEntityRequest
749
+ */
750
+ export interface EmailTrackingApiUnassignEntityRequest {
751
+ /**
752
+ *
753
+ * @type {string}
754
+ * @memberof EmailTrackingApiUnassignEntity
755
+ */
756
+ readonly code: string
757
+
758
+ /**
759
+ * Bearer Token: provided by the login endpoint under the name accessToken.
760
+ * @type {string}
761
+ * @memberof EmailTrackingApiUnassignEntity
762
+ */
763
+ readonly authorization?: string
764
+ }
765
+
549
766
  /**
550
767
  * EmailTrackingApi - object-oriented interface
551
768
  * @export
@@ -554,7 +771,20 @@ export interface EmailTrackingApiListThreadsRequest {
554
771
  */
555
772
  export class EmailTrackingApi extends BaseAPI {
556
773
  /**
557
- * undefined **Required Permissions** \"notification-management.email-messages.update\"
774
+ * Links the email thread, and every message in it, to the given entity, identified by code or by number (the code wins when both are set). Replaces the current link. The entity must exist. Messages that arrive in the thread later are linked to the same entity. **Required Permissions** \"notification-management.email-messages.update\"
775
+ * @summary Assign an email thread to an entity
776
+ * @param {EmailTrackingApiAssignEntityRequest} requestParameters Request parameters.
777
+ * @param {*} [options] Override http request option.
778
+ * @throws {RequiredError}
779
+ * @memberof EmailTrackingApi
780
+ */
781
+ public assignEntity(requestParameters: EmailTrackingApiAssignEntityRequest, options?: AxiosRequestConfig) {
782
+ return EmailTrackingApiFp(this.configuration).assignEntity(requestParameters.code, requestParameters.assignEmailThreadEntityBodyDto, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
783
+ }
784
+
785
+ /**
786
+ * Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
787
+ * @summary Close the email thread
558
788
  * @param {EmailTrackingApiCloseThreadRequest} requestParameters Request parameters.
559
789
  * @param {*} [options] Override http request option.
560
790
  * @throws {RequiredError}
@@ -565,7 +795,8 @@ export class EmailTrackingApi extends BaseAPI {
565
795
  }
566
796
 
567
797
  /**
568
- * undefined **Required Permissions** \"notification-management.email-messages.view\"
798
+ * Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
799
+ * @summary Retrieve the email thread
569
800
  * @param {EmailTrackingApiGetThreadRequest} requestParameters Request parameters.
570
801
  * @param {*} [options] Override http request option.
571
802
  * @throws {RequiredError}
@@ -576,7 +807,7 @@ export class EmailTrackingApi extends BaseAPI {
576
807
  }
577
808
 
578
809
  /**
579
- * Lists all email messages for a thread **Required Permissions** \"notification-management.email-messages.view\"
810
+ * Returns the email messages of the email thread with the given code. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
580
811
  * @summary List email messages
581
812
  * @param {EmailTrackingApiListMessagesRequest} requestParameters Request parameters.
582
813
  * @param {*} [options] Override http request option.
@@ -588,7 +819,7 @@ export class EmailTrackingApi extends BaseAPI {
588
819
  }
589
820
 
590
821
  /**
591
- * Lists all email threads with optional filters **Required Permissions** \"notification-management.email-messages.view\"
822
+ * Returns a list of email threads, newest first. A thread groups an email with its replies; each item carries the newest message of the thread in latestMessage and the number of messages in messageCount. Threads without a message yet are not listed. Filter on the newest message with latestDirection (inbox tabs), latestDeliveryStatus or latestWorkflowStatus (use latestWorkflowStatus==$null for threads whose newest message has no workflow). Add expand=messages to get every message of each thread, without bodies. For more information about pagination, read the Pagination documentation. **Required Permissions** \"notification-management.email-messages.view\"
592
823
  * @summary List email threads
593
824
  * @param {EmailTrackingApiListThreadsRequest} requestParameters Request parameters.
594
825
  * @param {*} [options] Override http request option.
@@ -598,4 +829,16 @@ export class EmailTrackingApi extends BaseAPI {
598
829
  public listThreads(requestParameters: EmailTrackingApiListThreadsRequest = {}, options?: AxiosRequestConfig) {
599
830
  return EmailTrackingApiFp(this.configuration).listThreads(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then((request) => request(this.axios, this.basePath));
600
831
  }
832
+
833
+ /**
834
+ * Removes the entity link from the email thread and every message in it, and marks the messages as unassigned. **Required Permissions** \"notification-management.email-messages.update\"
835
+ * @summary Unassign an email thread from its entity
836
+ * @param {EmailTrackingApiUnassignEntityRequest} requestParameters Request parameters.
837
+ * @param {*} [options] Override http request option.
838
+ * @throws {RequiredError}
839
+ * @memberof EmailTrackingApi
840
+ */
841
+ public unassignEntity(requestParameters: EmailTrackingApiUnassignEntityRequest, options?: AxiosRequestConfig) {
842
+ return EmailTrackingApiFp(this.configuration).unassignEntity(requestParameters.code, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
843
+ }
601
844
  }