@emilgroup/notification-sdk 0.8.1-beta.7 → 0.8.1-beta.71
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.
- package/.openapi-generator/FILES +25 -0
- package/README.md +2 -2
- package/api/email-mailboxes-api.ts +153 -0
- package/api/email-messages-api.ts +197 -40
- package/api/email-subscriptions-api.ts +799 -0
- package/api/email-tracking-api.ts +313 -52
- package/api/email-verifications-api.ts +32 -14
- package/api/health-api.ts +1 -1
- package/api/layouts-api.ts +96 -51
- package/api/msgraph-webhooks-api.ts +278 -0
- package/api/notification-templates-api.ts +96 -51
- package/api/notifications-api.ts +128 -7
- package/api.ts +6 -0
- package/base.ts +239 -43
- package/common.ts +3 -2
- package/configuration.ts +20 -0
- package/dist/api/email-mailboxes-api.d.ts +87 -0
- package/dist/api/email-mailboxes-api.js +225 -0
- package/dist/api/email-messages-api.d.ts +110 -32
- package/dist/api/email-messages-api.js +199 -56
- package/dist/api/email-subscriptions-api.d.ts +432 -0
- package/dist/api/email-subscriptions-api.js +761 -0
- package/dist/api/email-tracking-api.d.ts +174 -44
- package/dist/api/email-tracking-api.js +299 -64
- package/dist/api/email-verifications-api.d.ts +18 -10
- package/dist/api/email-verifications-api.js +46 -24
- package/dist/api/health-api.d.ts +1 -1
- package/dist/api/health-api.js +1 -1
- package/dist/api/layouts-api.d.ts +61 -41
- package/dist/api/layouts-api.js +119 -70
- package/dist/api/msgraph-webhooks-api.d.ts +168 -0
- package/dist/api/msgraph-webhooks-api.js +305 -0
- package/dist/api/notification-templates-api.d.ts +61 -41
- package/dist/api/notification-templates-api.js +119 -70
- package/dist/api/notifications-api.d.ts +66 -5
- package/dist/api/notifications-api.js +123 -12
- package/dist/api.d.ts +3 -0
- package/dist/api.js +3 -0
- package/dist/base.d.ts +26 -0
- package/dist/base.js +243 -60
- package/dist/common.d.ts +1 -1
- package/dist/common.js +1 -0
- package/dist/configuration.d.ts +17 -0
- package/dist/configuration.js +2 -0
- package/dist/models/assign-email-thread-entity-body-dto.d.ts +43 -0
- package/dist/models/assign-email-thread-entity-body-dto.js +22 -0
- package/dist/models/assign-email-thread-entity-response-class.d.ts +25 -0
- package/dist/models/assign-email-thread-entity-response-class.js +15 -0
- package/dist/models/catch-up-email-subscription-response-class.d.ts +24 -0
- package/dist/models/catch-up-email-subscription-response-class.js +15 -0
- package/dist/models/catch-up-email-subscriptions-request-dto.d.ts +24 -0
- package/dist/models/catch-up-email-subscriptions-request-dto.js +15 -0
- package/dist/models/catch-up-email-subscriptions-response-class.d.ts +30 -0
- package/dist/models/catch-up-email-subscriptions-response-class.js +15 -0
- package/dist/models/email-mailbox-class.d.ts +47 -0
- package/dist/models/email-mailbox-class.js +20 -0
- package/dist/models/email-message-class.d.ts +102 -7
- package/dist/models/email-message-class.js +25 -2
- package/dist/models/email-message-summary-class.d.ts +121 -0
- package/dist/models/email-message-summary-class.js +37 -0
- package/dist/models/email-subscription-class.d.ts +110 -0
- package/dist/models/email-subscription-class.js +23 -0
- package/dist/models/email-thread-class.d.ts +37 -5
- package/dist/models/entity-ref-class.d.ts +37 -0
- package/dist/models/entity-ref-class.js +22 -0
- package/dist/models/get-email-subscription-response-class.d.ts +25 -0
- package/dist/models/get-email-subscription-response-class.js +15 -0
- package/dist/models/grpc-send-email-request-dto.d.ts +137 -0
- package/dist/models/grpc-send-email-request-dto.js +22 -0
- package/dist/models/index.d.ts +22 -0
- package/dist/models/index.js +22 -0
- package/dist/models/inline-attachment-dto.d.ts +36 -0
- package/dist/models/inline-attachment-dto.js +15 -0
- package/dist/models/list-email-mailboxes-response-class.d.ts +43 -0
- package/dist/models/list-email-mailboxes-response-class.js +15 -0
- package/dist/models/list-email-subscriptions-response-class.d.ts +43 -0
- package/dist/models/list-email-subscriptions-response-class.js +15 -0
- package/dist/models/reconcile-email-subscriptions-request-dto.d.ts +24 -0
- package/dist/models/reconcile-email-subscriptions-request-dto.js +15 -0
- package/dist/models/reconcile-email-subscriptions-response-class.d.ts +48 -0
- package/dist/models/reconcile-email-subscriptions-response-class.js +15 -0
- package/dist/models/renew-email-subscription-response-class.d.ts +25 -0
- package/dist/models/renew-email-subscription-response-class.js +15 -0
- package/dist/models/resend-email-message-body-dto.d.ts +30 -0
- package/dist/models/resend-email-message-body-dto.js +15 -0
- package/dist/models/resend-email-message-response-class.d.ts +25 -0
- package/dist/models/resend-email-message-response-class.js +15 -0
- package/dist/models/send-email-request-dto.d.ts +131 -0
- package/dist/models/send-email-request-dto.js +22 -0
- package/dist/models/send-email-response-class.d.ts +24 -0
- package/dist/models/send-email-response-class.js +15 -0
- package/dist/models/send-notification-request-dto.d.ts +10 -1
- package/dist/models/send-notification-request-dto.js +2 -1
- package/dist/models/unassign-email-thread-entity-response-class.d.ts +25 -0
- package/dist/models/unassign-email-thread-entity-response-class.js +15 -0
- package/models/assign-email-thread-entity-body-dto.ts +52 -0
- package/models/assign-email-thread-entity-response-class.ts +31 -0
- package/models/catch-up-email-subscription-response-class.ts +30 -0
- package/models/catch-up-email-subscriptions-request-dto.ts +30 -0
- package/models/catch-up-email-subscriptions-response-class.ts +36 -0
- package/models/email-mailbox-class.ts +56 -0
- package/models/email-message-class.ts +108 -8
- package/models/email-message-summary-class.ts +133 -0
- package/models/email-subscription-class.ts +119 -0
- package/models/email-thread-class.ts +37 -5
- package/models/entity-ref-class.ts +46 -0
- package/models/get-email-subscription-response-class.ts +31 -0
- package/models/grpc-send-email-request-dto.ts +144 -0
- package/models/index.ts +22 -0
- package/models/inline-attachment-dto.ts +42 -0
- package/models/list-email-mailboxes-response-class.ts +49 -0
- package/models/list-email-subscriptions-response-class.ts +49 -0
- package/models/reconcile-email-subscriptions-request-dto.ts +30 -0
- package/models/reconcile-email-subscriptions-response-class.ts +54 -0
- package/models/renew-email-subscription-response-class.ts +31 -0
- package/models/resend-email-message-body-dto.ts +36 -0
- package/models/resend-email-message-response-class.ts +31 -0
- package/models/send-email-request-dto.ts +138 -0
- package/models/send-email-response-class.ts +30 -0
- package/models/send-notification-request-dto.ts +9 -2
- package/models/unassign-email-thread-entity-response-class.ts +31 -0
- package/package.json +2 -2
|
@@ -93,7 +93,68 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
93
93
|
var _this = this;
|
|
94
94
|
return {
|
|
95
95
|
/**
|
|
96
|
-
*
|
|
96
|
+
* 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\"
|
|
97
|
+
* @summary Assign an email thread to an entity
|
|
98
|
+
* @param {string} code
|
|
99
|
+
* @param {AssignEmailThreadEntityBodyDto} assignEmailThreadEntityBodyDto
|
|
100
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
101
|
+
* @param {*} [options] Override http request option.
|
|
102
|
+
* @throws {RequiredError}
|
|
103
|
+
*/
|
|
104
|
+
assignEntity: function (code, assignEmailThreadEntityBodyDto, authorization, options) {
|
|
105
|
+
if (options === void 0) { options = {}; }
|
|
106
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
107
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
|
|
108
|
+
var _a;
|
|
109
|
+
return __generator(this, function (_b) {
|
|
110
|
+
switch (_b.label) {
|
|
111
|
+
case 0:
|
|
112
|
+
// verify required parameter 'code' is not null or undefined
|
|
113
|
+
(0, common_1.assertParamExists)('assignEntity', 'code', code);
|
|
114
|
+
// verify required parameter 'assignEmailThreadEntityBodyDto' is not null or undefined
|
|
115
|
+
(0, common_1.assertParamExists)('assignEntity', 'assignEmailThreadEntityBodyDto', assignEmailThreadEntityBodyDto);
|
|
116
|
+
localVarPath = "/notificationservice/v1/email-threads/{code}/entity"
|
|
117
|
+
.replace("{".concat("code", "}"), encodeURIComponent(String(code)));
|
|
118
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
119
|
+
if (configuration) {
|
|
120
|
+
baseOptions = configuration.baseOptions;
|
|
121
|
+
baseAccessToken = configuration.accessToken;
|
|
122
|
+
}
|
|
123
|
+
localVarRequestOptions = __assign(__assign({ method: 'PATCH' }, baseOptions), options);
|
|
124
|
+
localVarHeaderParameter = {};
|
|
125
|
+
localVarQueryParameter = {};
|
|
126
|
+
// authentication bearer required
|
|
127
|
+
// http bearer authentication required
|
|
128
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
129
|
+
// Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
|
|
130
|
+
// no token is stored, so a refused call still refreshes; a session call (account header) sends none.
|
|
131
|
+
];
|
|
132
|
+
case 1:
|
|
133
|
+
// authentication bearer required
|
|
134
|
+
// http bearer authentication required
|
|
135
|
+
_b.sent();
|
|
136
|
+
authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
|
|
137
|
+
authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
|
|
138
|
+
authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
|
|
139
|
+
if (authorizationValue || authorizationKeepEmpty) {
|
|
140
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
141
|
+
}
|
|
142
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
143
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
144
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
145
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
146
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(assignEmailThreadEntityBodyDto, localVarRequestOptions, configuration);
|
|
147
|
+
return [2 /*return*/, {
|
|
148
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
149
|
+
options: localVarRequestOptions,
|
|
150
|
+
}];
|
|
151
|
+
}
|
|
152
|
+
});
|
|
153
|
+
});
|
|
154
|
+
},
|
|
155
|
+
/**
|
|
156
|
+
* Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
|
|
157
|
+
* @summary Close the email thread
|
|
97
158
|
* @param {string} code
|
|
98
159
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
99
160
|
* @param {*} [options] Override http request option.
|
|
@@ -102,9 +163,10 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
102
163
|
closeThread: function (code, authorization, options) {
|
|
103
164
|
if (options === void 0) { options = {}; }
|
|
104
165
|
return __awaiter(_this, void 0, void 0, function () {
|
|
105
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
106
|
-
|
|
107
|
-
|
|
166
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
|
|
167
|
+
var _a;
|
|
168
|
+
return __generator(this, function (_b) {
|
|
169
|
+
switch (_b.label) {
|
|
108
170
|
case 0:
|
|
109
171
|
// verify required parameter 'code' is not null or undefined
|
|
110
172
|
(0, common_1.assertParamExists)('closeThread', 'code', code);
|
|
@@ -120,13 +182,19 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
120
182
|
localVarQueryParameter = {};
|
|
121
183
|
// authentication bearer required
|
|
122
184
|
// http bearer authentication required
|
|
123
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
185
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
186
|
+
// Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
|
|
187
|
+
// no token is stored, so a refused call still refreshes; a session call (account header) sends none.
|
|
188
|
+
];
|
|
124
189
|
case 1:
|
|
125
190
|
// authentication bearer required
|
|
126
191
|
// http bearer authentication required
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
192
|
+
_b.sent();
|
|
193
|
+
authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
|
|
194
|
+
authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
|
|
195
|
+
authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
|
|
196
|
+
if (authorizationValue || authorizationKeepEmpty) {
|
|
197
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
130
198
|
}
|
|
131
199
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
132
200
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -140,7 +208,8 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
140
208
|
});
|
|
141
209
|
},
|
|
142
210
|
/**
|
|
143
|
-
*
|
|
211
|
+
* Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
|
|
212
|
+
* @summary Retrieve the email thread
|
|
144
213
|
* @param {string} code
|
|
145
214
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
146
215
|
* @param {*} [options] Override http request option.
|
|
@@ -149,9 +218,10 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
149
218
|
getThread: function (code, authorization, options) {
|
|
150
219
|
if (options === void 0) { options = {}; }
|
|
151
220
|
return __awaiter(_this, void 0, void 0, function () {
|
|
152
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
153
|
-
|
|
154
|
-
|
|
221
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
|
|
222
|
+
var _a;
|
|
223
|
+
return __generator(this, function (_b) {
|
|
224
|
+
switch (_b.label) {
|
|
155
225
|
case 0:
|
|
156
226
|
// verify required parameter 'code' is not null or undefined
|
|
157
227
|
(0, common_1.assertParamExists)('getThread', 'code', code);
|
|
@@ -167,13 +237,19 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
167
237
|
localVarQueryParameter = {};
|
|
168
238
|
// authentication bearer required
|
|
169
239
|
// http bearer authentication required
|
|
170
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
240
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
241
|
+
// Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
|
|
242
|
+
// no token is stored, so a refused call still refreshes; a session call (account header) sends none.
|
|
243
|
+
];
|
|
171
244
|
case 1:
|
|
172
245
|
// authentication bearer required
|
|
173
246
|
// http bearer authentication required
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
247
|
+
_b.sent();
|
|
248
|
+
authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
|
|
249
|
+
authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
|
|
250
|
+
authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
|
|
251
|
+
if (authorizationValue || authorizationKeepEmpty) {
|
|
252
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
177
253
|
}
|
|
178
254
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
179
255
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -187,13 +263,13 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
187
263
|
});
|
|
188
264
|
},
|
|
189
265
|
/**
|
|
190
|
-
*
|
|
266
|
+
* 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\"
|
|
191
267
|
* @summary List email messages
|
|
192
268
|
* @param {string} code
|
|
193
269
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
194
|
-
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
195
|
-
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
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.<br/> <br/> <i>Allowed values: id, code, threadCode, direction, deliveryStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt</i>
|
|
270
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, resentFromMessageCode, resendReason, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
271
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, resentFromMessageCode, resendReason, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
272
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, threadCode, direction, deliveryStatus, workflowStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt</i>
|
|
197
273
|
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: attachments<i>
|
|
198
274
|
* @param {*} [options] Override http request option.
|
|
199
275
|
* @throws {RequiredError}
|
|
@@ -201,9 +277,10 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
201
277
|
listMessages: function (code, authorization, filter, filters, order, expand, options) {
|
|
202
278
|
if (options === void 0) { options = {}; }
|
|
203
279
|
return __awaiter(_this, void 0, void 0, function () {
|
|
204
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
205
|
-
|
|
206
|
-
|
|
280
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
|
|
281
|
+
var _a;
|
|
282
|
+
return __generator(this, function (_b) {
|
|
283
|
+
switch (_b.label) {
|
|
207
284
|
case 0:
|
|
208
285
|
// verify required parameter 'code' is not null or undefined
|
|
209
286
|
(0, common_1.assertParamExists)('listMessages', 'code', code);
|
|
@@ -223,7 +300,7 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
223
300
|
case 1:
|
|
224
301
|
// authentication bearer required
|
|
225
302
|
// http bearer authentication required
|
|
226
|
-
|
|
303
|
+
_b.sent();
|
|
227
304
|
if (filter !== undefined) {
|
|
228
305
|
localVarQueryParameter['filter'] = filter;
|
|
229
306
|
}
|
|
@@ -236,8 +313,11 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
236
313
|
if (expand !== undefined) {
|
|
237
314
|
localVarQueryParameter['expand'] = expand;
|
|
238
315
|
}
|
|
239
|
-
|
|
240
|
-
|
|
316
|
+
authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
|
|
317
|
+
authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
|
|
318
|
+
authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
|
|
319
|
+
if (authorizationValue || authorizationKeepEmpty) {
|
|
320
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
241
321
|
}
|
|
242
322
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
243
323
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -251,25 +331,26 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
251
331
|
});
|
|
252
332
|
},
|
|
253
333
|
/**
|
|
254
|
-
*
|
|
334
|
+
* 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\"
|
|
255
335
|
* @summary List email threads
|
|
256
336
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
257
337
|
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
258
338
|
* @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=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
259
|
-
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
339
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
260
340
|
* @param {string} [search] To search the list by any field, pass search=xxx to fetch the result.
|
|
261
|
-
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt</i>
|
|
341
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, createdAt, updatedAt</i>
|
|
262
342
|
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: messages<i>
|
|
263
|
-
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
343
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
264
344
|
* @param {*} [options] Override http request option.
|
|
265
345
|
* @throws {RequiredError}
|
|
266
346
|
*/
|
|
267
347
|
listThreads: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
268
348
|
if (options === void 0) { options = {}; }
|
|
269
349
|
return __awaiter(_this, void 0, void 0, function () {
|
|
270
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
271
|
-
|
|
272
|
-
|
|
350
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
|
|
351
|
+
var _a;
|
|
352
|
+
return __generator(this, function (_b) {
|
|
353
|
+
switch (_b.label) {
|
|
273
354
|
case 0:
|
|
274
355
|
localVarPath = "/notificationservice/v1/email-threads";
|
|
275
356
|
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
@@ -286,7 +367,7 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
286
367
|
case 1:
|
|
287
368
|
// authentication bearer required
|
|
288
369
|
// http bearer authentication required
|
|
289
|
-
|
|
370
|
+
_b.sent();
|
|
290
371
|
if (pageSize !== undefined) {
|
|
291
372
|
localVarQueryParameter['pageSize'] = pageSize;
|
|
292
373
|
}
|
|
@@ -308,8 +389,66 @@ var EmailTrackingApiAxiosParamCreator = function (configuration) {
|
|
|
308
389
|
if (filters !== undefined) {
|
|
309
390
|
localVarQueryParameter['filters'] = filters;
|
|
310
391
|
}
|
|
311
|
-
|
|
312
|
-
|
|
392
|
+
authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
|
|
393
|
+
authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
|
|
394
|
+
authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
|
|
395
|
+
if (authorizationValue || authorizationKeepEmpty) {
|
|
396
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
397
|
+
}
|
|
398
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
399
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
400
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
401
|
+
return [2 /*return*/, {
|
|
402
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
403
|
+
options: localVarRequestOptions,
|
|
404
|
+
}];
|
|
405
|
+
}
|
|
406
|
+
});
|
|
407
|
+
});
|
|
408
|
+
},
|
|
409
|
+
/**
|
|
410
|
+
* 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\"
|
|
411
|
+
* @summary Unassign an email thread from its entity
|
|
412
|
+
* @param {string} code
|
|
413
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
414
|
+
* @param {*} [options] Override http request option.
|
|
415
|
+
* @throws {RequiredError}
|
|
416
|
+
*/
|
|
417
|
+
unassignEntity: function (code, authorization, options) {
|
|
418
|
+
if (options === void 0) { options = {}; }
|
|
419
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
420
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationIsAuth, authorizationValue, authorizationKeepEmpty, headersFromBaseOptions;
|
|
421
|
+
var _a;
|
|
422
|
+
return __generator(this, function (_b) {
|
|
423
|
+
switch (_b.label) {
|
|
424
|
+
case 0:
|
|
425
|
+
// verify required parameter 'code' is not null or undefined
|
|
426
|
+
(0, common_1.assertParamExists)('unassignEntity', 'code', code);
|
|
427
|
+
localVarPath = "/notificationservice/v1/email-threads/{code}/entity"
|
|
428
|
+
.replace("{".concat("code", "}"), encodeURIComponent(String(code)));
|
|
429
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
430
|
+
if (configuration) {
|
|
431
|
+
baseOptions = configuration.baseOptions;
|
|
432
|
+
baseAccessToken = configuration.accessToken;
|
|
433
|
+
}
|
|
434
|
+
localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
|
|
435
|
+
localVarHeaderParameter = {};
|
|
436
|
+
localVarQueryParameter = {};
|
|
437
|
+
// authentication bearer required
|
|
438
|
+
// http bearer authentication required
|
|
439
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
440
|
+
// Only Authorization falls back to the configured token. Without a session it is sent as before, empty when
|
|
441
|
+
// no token is stored, so a refused call still refreshes; a session call (account header) sends none.
|
|
442
|
+
];
|
|
443
|
+
case 1:
|
|
444
|
+
// authentication bearer required
|
|
445
|
+
// http bearer authentication required
|
|
446
|
+
_b.sent();
|
|
447
|
+
authorizationIsAuth = 'Authorization'.toLowerCase() === 'authorization';
|
|
448
|
+
authorizationValue = authorizationIsAuth ? (authorization || baseAccessToken) : authorization;
|
|
449
|
+
authorizationKeepEmpty = authorizationIsAuth && authorizationValue === '' && !((_a = baseOptions === null || baseOptions === void 0 ? void 0 : baseOptions.headers) === null || _a === void 0 ? void 0 : _a['X-Emil-Account']);
|
|
450
|
+
if (authorizationValue || authorizationKeepEmpty) {
|
|
451
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
313
452
|
}
|
|
314
453
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
315
454
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -333,7 +472,30 @@ var EmailTrackingApiFp = function (configuration) {
|
|
|
333
472
|
var localVarAxiosParamCreator = (0, exports.EmailTrackingApiAxiosParamCreator)(configuration);
|
|
334
473
|
return {
|
|
335
474
|
/**
|
|
336
|
-
*
|
|
475
|
+
* 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\"
|
|
476
|
+
* @summary Assign an email thread to an entity
|
|
477
|
+
* @param {string} code
|
|
478
|
+
* @param {AssignEmailThreadEntityBodyDto} assignEmailThreadEntityBodyDto
|
|
479
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
480
|
+
* @param {*} [options] Override http request option.
|
|
481
|
+
* @throws {RequiredError}
|
|
482
|
+
*/
|
|
483
|
+
assignEntity: function (code, assignEmailThreadEntityBodyDto, authorization, options) {
|
|
484
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
485
|
+
var localVarAxiosArgs;
|
|
486
|
+
return __generator(this, function (_a) {
|
|
487
|
+
switch (_a.label) {
|
|
488
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.assignEntity(code, assignEmailThreadEntityBodyDto, authorization, options)];
|
|
489
|
+
case 1:
|
|
490
|
+
localVarAxiosArgs = _a.sent();
|
|
491
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
492
|
+
}
|
|
493
|
+
});
|
|
494
|
+
});
|
|
495
|
+
},
|
|
496
|
+
/**
|
|
497
|
+
* Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
|
|
498
|
+
* @summary Close the email thread
|
|
337
499
|
* @param {string} code
|
|
338
500
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
339
501
|
* @param {*} [options] Override http request option.
|
|
@@ -353,7 +515,8 @@ var EmailTrackingApiFp = function (configuration) {
|
|
|
353
515
|
});
|
|
354
516
|
},
|
|
355
517
|
/**
|
|
356
|
-
*
|
|
518
|
+
* Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
|
|
519
|
+
* @summary Retrieve the email thread
|
|
357
520
|
* @param {string} code
|
|
358
521
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
359
522
|
* @param {*} [options] Override http request option.
|
|
@@ -373,13 +536,13 @@ var EmailTrackingApiFp = function (configuration) {
|
|
|
373
536
|
});
|
|
374
537
|
},
|
|
375
538
|
/**
|
|
376
|
-
*
|
|
539
|
+
* 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\"
|
|
377
540
|
* @summary List email messages
|
|
378
541
|
* @param {string} code
|
|
379
542
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
380
|
-
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
381
|
-
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
382
|
-
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, threadCode, direction, deliveryStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt</i>
|
|
543
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, resentFromMessageCode, resendReason, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
544
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, resentFromMessageCode, resendReason, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
545
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, threadCode, direction, deliveryStatus, workflowStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt</i>
|
|
383
546
|
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: attachments<i>
|
|
384
547
|
* @param {*} [options] Override http request option.
|
|
385
548
|
* @throws {RequiredError}
|
|
@@ -398,16 +561,16 @@ var EmailTrackingApiFp = function (configuration) {
|
|
|
398
561
|
});
|
|
399
562
|
},
|
|
400
563
|
/**
|
|
401
|
-
*
|
|
564
|
+
* 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\"
|
|
402
565
|
* @summary List email threads
|
|
403
566
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
404
567
|
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
405
568
|
* @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=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
406
|
-
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
569
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
407
570
|
* @param {string} [search] To search the list by any field, pass search=xxx to fetch the result.
|
|
408
|
-
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt</i>
|
|
571
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, createdAt, updatedAt</i>
|
|
409
572
|
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: messages<i>
|
|
410
|
-
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
573
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
411
574
|
* @param {*} [options] Override http request option.
|
|
412
575
|
* @throws {RequiredError}
|
|
413
576
|
*/
|
|
@@ -424,6 +587,27 @@ var EmailTrackingApiFp = function (configuration) {
|
|
|
424
587
|
});
|
|
425
588
|
});
|
|
426
589
|
},
|
|
590
|
+
/**
|
|
591
|
+
* 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\"
|
|
592
|
+
* @summary Unassign an email thread from its entity
|
|
593
|
+
* @param {string} code
|
|
594
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
595
|
+
* @param {*} [options] Override http request option.
|
|
596
|
+
* @throws {RequiredError}
|
|
597
|
+
*/
|
|
598
|
+
unassignEntity: function (code, authorization, options) {
|
|
599
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
600
|
+
var localVarAxiosArgs;
|
|
601
|
+
return __generator(this, function (_a) {
|
|
602
|
+
switch (_a.label) {
|
|
603
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.unassignEntity(code, authorization, options)];
|
|
604
|
+
case 1:
|
|
605
|
+
localVarAxiosArgs = _a.sent();
|
|
606
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
607
|
+
}
|
|
608
|
+
});
|
|
609
|
+
});
|
|
610
|
+
},
|
|
427
611
|
};
|
|
428
612
|
};
|
|
429
613
|
exports.EmailTrackingApiFp = EmailTrackingApiFp;
|
|
@@ -435,7 +619,20 @@ var EmailTrackingApiFactory = function (configuration, basePath, axios) {
|
|
|
435
619
|
var localVarFp = (0, exports.EmailTrackingApiFp)(configuration);
|
|
436
620
|
return {
|
|
437
621
|
/**
|
|
438
|
-
*
|
|
622
|
+
* 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\"
|
|
623
|
+
* @summary Assign an email thread to an entity
|
|
624
|
+
* @param {string} code
|
|
625
|
+
* @param {AssignEmailThreadEntityBodyDto} assignEmailThreadEntityBodyDto
|
|
626
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
627
|
+
* @param {*} [options] Override http request option.
|
|
628
|
+
* @throws {RequiredError}
|
|
629
|
+
*/
|
|
630
|
+
assignEntity: function (code, assignEmailThreadEntityBodyDto, authorization, options) {
|
|
631
|
+
return localVarFp.assignEntity(code, assignEmailThreadEntityBodyDto, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
632
|
+
},
|
|
633
|
+
/**
|
|
634
|
+
* Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
|
|
635
|
+
* @summary Close the email thread
|
|
439
636
|
* @param {string} code
|
|
440
637
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
441
638
|
* @param {*} [options] Override http request option.
|
|
@@ -445,7 +642,8 @@ var EmailTrackingApiFactory = function (configuration, basePath, axios) {
|
|
|
445
642
|
return localVarFp.closeThread(code, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
446
643
|
},
|
|
447
644
|
/**
|
|
448
|
-
*
|
|
645
|
+
* Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
|
|
646
|
+
* @summary Retrieve the email thread
|
|
449
647
|
* @param {string} code
|
|
450
648
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
451
649
|
* @param {*} [options] Override http request option.
|
|
@@ -455,13 +653,13 @@ var EmailTrackingApiFactory = function (configuration, basePath, axios) {
|
|
|
455
653
|
return localVarFp.getThread(code, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
456
654
|
},
|
|
457
655
|
/**
|
|
458
|
-
*
|
|
656
|
+
* 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\"
|
|
459
657
|
* @summary List email messages
|
|
460
658
|
* @param {string} code
|
|
461
659
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
462
|
-
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
463
|
-
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, direction, deliveryStatus, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
464
|
-
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, threadCode, direction, deliveryStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt</i>
|
|
660
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, resentFromMessageCode, resendReason, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
661
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, threadCode, entityType, entityCode, entityNumber, direction, deliveryStatus, provider, mailbox, workflowStatus, resentFromMessageCode, resendReason, fromAddress, subject, notificationRequestId, sentAt, receivedAt, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
662
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, threadCode, direction, deliveryStatus, workflowStatus, fromAddress, subject, sentAt, receivedAt, createdAt, updatedAt</i>
|
|
465
663
|
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: attachments<i>
|
|
466
664
|
* @param {*} [options] Override http request option.
|
|
467
665
|
* @throws {RequiredError}
|
|
@@ -470,22 +668,33 @@ var EmailTrackingApiFactory = function (configuration, basePath, axios) {
|
|
|
470
668
|
return localVarFp.listMessages(code, authorization, filter, filters, order, expand, options).then(function (request) { return request(axios, basePath); });
|
|
471
669
|
},
|
|
472
670
|
/**
|
|
473
|
-
*
|
|
671
|
+
* 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\"
|
|
474
672
|
* @summary List email threads
|
|
475
673
|
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
476
674
|
* @param {number} [pageSize] A limit on the number of objects to be returned. Limit ranges between 1 and 50. Default: 10.
|
|
477
675
|
* @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=1, your subsequent call can include pageToken=2 in order to fetch the next page of the list.
|
|
478
|
-
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
676
|
+
* @param {string} [filter] Filter the response by one or multiple fields. In general, fetching filtered responses will conserve bandwidth and reduce response time.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
479
677
|
* @param {string} [search] To search the list by any field, pass search=xxx to fetch the result.
|
|
480
|
-
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt</i>
|
|
678
|
+
* @param {string} [order] Order allows you to specify the desired order of entities retrieved from the server by ascending (ASC) or descending (DESC) order.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, createdAt, updatedAt</i>
|
|
481
679
|
* @param {string} [expand] Expand to fetch additional information about the list items. Expanding resources can reduce the number of API calls required to accomplish a task. Use with discretion as some expanded fields can drastically increase payload size.<br/> <br/> <i>Allowed values: messages<i>
|
|
482
|
-
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, subject, status, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
680
|
+
* @param {string} [filters] Filters the response by one or multiple fields. Advanced filter functionality allows you to perform more complex filtering operations.<br/> <br/> <i>Allowed values: id, code, entityType, entityCode, entityNumber, subject, status, mailbox, messageCount, lastMessageAt, latestDirection, latestDeliveryStatus, latestWorkflowStatus, latestFromAddress, latestToAddresses, createdAt, updatedAt, createdBy, updatedBy</i>
|
|
483
681
|
* @param {*} [options] Override http request option.
|
|
484
682
|
* @throws {RequiredError}
|
|
485
683
|
*/
|
|
486
684
|
listThreads: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
487
685
|
return localVarFp.listThreads(authorization, pageSize, pageToken, filter, search, order, expand, filters, options).then(function (request) { return request(axios, basePath); });
|
|
488
686
|
},
|
|
687
|
+
/**
|
|
688
|
+
* 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\"
|
|
689
|
+
* @summary Unassign an email thread from its entity
|
|
690
|
+
* @param {string} code
|
|
691
|
+
* @param {string} [authorization] Bearer Token: provided by the login endpoint under the name accessToken.
|
|
692
|
+
* @param {*} [options] Override http request option.
|
|
693
|
+
* @throws {RequiredError}
|
|
694
|
+
*/
|
|
695
|
+
unassignEntity: function (code, authorization, options) {
|
|
696
|
+
return localVarFp.unassignEntity(code, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
697
|
+
},
|
|
489
698
|
};
|
|
490
699
|
};
|
|
491
700
|
exports.EmailTrackingApiFactory = EmailTrackingApiFactory;
|
|
@@ -501,7 +710,20 @@ var EmailTrackingApi = /** @class */ (function (_super) {
|
|
|
501
710
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
502
711
|
}
|
|
503
712
|
/**
|
|
504
|
-
*
|
|
713
|
+
* 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\"
|
|
714
|
+
* @summary Assign an email thread to an entity
|
|
715
|
+
* @param {EmailTrackingApiAssignEntityRequest} requestParameters Request parameters.
|
|
716
|
+
* @param {*} [options] Override http request option.
|
|
717
|
+
* @throws {RequiredError}
|
|
718
|
+
* @memberof EmailTrackingApi
|
|
719
|
+
*/
|
|
720
|
+
EmailTrackingApi.prototype.assignEntity = function (requestParameters, options) {
|
|
721
|
+
var _this = this;
|
|
722
|
+
return (0, exports.EmailTrackingApiFp)(this.configuration).assignEntity(requestParameters.code, requestParameters.assignEmailThreadEntityBodyDto, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
723
|
+
};
|
|
724
|
+
/**
|
|
725
|
+
* Closes the email thread with the given code and returns the updated thread. **Required Permissions** \"notification-management.email-messages.update\"
|
|
726
|
+
* @summary Close the email thread
|
|
505
727
|
* @param {EmailTrackingApiCloseThreadRequest} requestParameters Request parameters.
|
|
506
728
|
* @param {*} [options] Override http request option.
|
|
507
729
|
* @throws {RequiredError}
|
|
@@ -509,10 +731,11 @@ var EmailTrackingApi = /** @class */ (function (_super) {
|
|
|
509
731
|
*/
|
|
510
732
|
EmailTrackingApi.prototype.closeThread = function (requestParameters, options) {
|
|
511
733
|
var _this = this;
|
|
512
|
-
return (0, exports.EmailTrackingApiFp)(this.configuration).closeThread(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
734
|
+
return (0, exports.EmailTrackingApiFp)(this.configuration).closeThread(requestParameters.code, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
513
735
|
};
|
|
514
736
|
/**
|
|
515
|
-
*
|
|
737
|
+
* Retrieves the details of the email thread with the given code. **Required Permissions** \"notification-management.email-messages.view\"
|
|
738
|
+
* @summary Retrieve the email thread
|
|
516
739
|
* @param {EmailTrackingApiGetThreadRequest} requestParameters Request parameters.
|
|
517
740
|
* @param {*} [options] Override http request option.
|
|
518
741
|
* @throws {RequiredError}
|
|
@@ -520,10 +743,10 @@ var EmailTrackingApi = /** @class */ (function (_super) {
|
|
|
520
743
|
*/
|
|
521
744
|
EmailTrackingApi.prototype.getThread = function (requestParameters, options) {
|
|
522
745
|
var _this = this;
|
|
523
|
-
return (0, exports.EmailTrackingApiFp)(this.configuration).getThread(requestParameters.code, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
746
|
+
return (0, exports.EmailTrackingApiFp)(this.configuration).getThread(requestParameters.code, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
524
747
|
};
|
|
525
748
|
/**
|
|
526
|
-
*
|
|
749
|
+
* 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\"
|
|
527
750
|
* @summary List email messages
|
|
528
751
|
* @param {EmailTrackingApiListMessagesRequest} requestParameters Request parameters.
|
|
529
752
|
* @param {*} [options] Override http request option.
|
|
@@ -532,10 +755,10 @@ var EmailTrackingApi = /** @class */ (function (_super) {
|
|
|
532
755
|
*/
|
|
533
756
|
EmailTrackingApi.prototype.listMessages = function (requestParameters, options) {
|
|
534
757
|
var _this = this;
|
|
535
|
-
return (0, exports.EmailTrackingApiFp)(this.configuration).listMessages(requestParameters.code, requestParameters.authorization, requestParameters.filter, requestParameters.filters, requestParameters.order, requestParameters.expand, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
758
|
+
return (0, exports.EmailTrackingApiFp)(this.configuration).listMessages(requestParameters.code, requestParameters.authorization, requestParameters.filter, requestParameters.filters, requestParameters.order, requestParameters.expand, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
536
759
|
};
|
|
537
760
|
/**
|
|
538
|
-
*
|
|
761
|
+
* 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\"
|
|
539
762
|
* @summary List email threads
|
|
540
763
|
* @param {EmailTrackingApiListThreadsRequest} requestParameters Request parameters.
|
|
541
764
|
* @param {*} [options] Override http request option.
|
|
@@ -545,7 +768,19 @@ var EmailTrackingApi = /** @class */ (function (_super) {
|
|
|
545
768
|
EmailTrackingApi.prototype.listThreads = function (requestParameters, options) {
|
|
546
769
|
var _this = this;
|
|
547
770
|
if (requestParameters === void 0) { requestParameters = {}; }
|
|
548
|
-
return (0, exports.EmailTrackingApiFp)(this.configuration).listThreads(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
771
|
+
return (0, exports.EmailTrackingApiFp)(this.configuration).listThreads(requestParameters.authorization, requestParameters.pageSize, requestParameters.pageToken, requestParameters.filter, requestParameters.search, requestParameters.order, requestParameters.expand, requestParameters.filters, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
772
|
+
};
|
|
773
|
+
/**
|
|
774
|
+
* 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\"
|
|
775
|
+
* @summary Unassign an email thread from its entity
|
|
776
|
+
* @param {EmailTrackingApiUnassignEntityRequest} requestParameters Request parameters.
|
|
777
|
+
* @param {*} [options] Override http request option.
|
|
778
|
+
* @throws {RequiredError}
|
|
779
|
+
* @memberof EmailTrackingApi
|
|
780
|
+
*/
|
|
781
|
+
EmailTrackingApi.prototype.unassignEntity = function (requestParameters, options) {
|
|
782
|
+
var _this = this;
|
|
783
|
+
return (0, exports.EmailTrackingApiFp)(this.configuration).unassignEntity(requestParameters.code, requestParameters.authorization, this.withOwner(options)).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
549
784
|
};
|
|
550
785
|
return EmailTrackingApi;
|
|
551
786
|
}(base_1.BaseAPI));
|