@develit-services/notification 1.0.0 → 2.0.0
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/dist/export/worker.cjs
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
3
|
const backendSdk = require('@develit-io/backend-sdk');
|
|
6
4
|
const webhook_connector = require('../shared/notification.BLPB8Ib2.cjs');
|
|
7
5
|
require('@develit-io/backend-sdk/signature');
|
|
@@ -259,17 +257,7 @@ let NotificationServiceBase = class extends backendSdk.develitWorker(
|
|
|
259
257
|
);
|
|
260
258
|
}
|
|
261
259
|
async sendEmailSync(input) {
|
|
262
|
-
return this.
|
|
263
|
-
{ data: input, schema: webhook_connector.sendEmailInputSchema },
|
|
264
|
-
{ successMessage: "Email sent.", sensitiveKeys: ["attachments"] },
|
|
265
|
-
async (params) => {
|
|
266
|
-
const { email, metadata } = params;
|
|
267
|
-
return this._sendEmail({
|
|
268
|
-
email,
|
|
269
|
-
metadata
|
|
270
|
-
});
|
|
271
|
-
}
|
|
272
|
-
);
|
|
260
|
+
return this._sendEmail(input);
|
|
273
261
|
}
|
|
274
262
|
async sendSms(input) {
|
|
275
263
|
return this.handleAction(
|
|
@@ -580,7 +568,4 @@ function defineNotificationService() {
|
|
|
580
568
|
};
|
|
581
569
|
}
|
|
582
570
|
|
|
583
|
-
const NotificationService = defineNotificationService();
|
|
584
|
-
|
|
585
|
-
exports.default = NotificationService;
|
|
586
571
|
exports.defineNotificationService = defineNotificationService;
|
package/dist/export/worker.d.cts
CHANGED
|
@@ -41,10 +41,6 @@ declare class NotificationServiceBase extends NotificationServiceBase_base {
|
|
|
41
41
|
*/
|
|
42
42
|
clearReceivedEmails(input: ClearReceivedEmailsInput): Promise<IRPCResponse<ClearReceivedEmailsOutput>>;
|
|
43
43
|
}
|
|
44
|
-
declare function defineNotificationService():
|
|
44
|
+
declare function defineNotificationService(): typeof NotificationServiceBase;
|
|
45
45
|
|
|
46
|
-
declare const _default: new (ctx: ExecutionContext, env: NotificationEnv) => WorkerEntrypoint<NotificationEnv>;
|
|
47
|
-
|
|
48
|
-
// @ts-ignore
|
|
49
|
-
export = _default;
|
|
50
46
|
export { defineNotificationService };
|
package/dist/export/worker.d.mts
CHANGED
|
@@ -41,8 +41,6 @@ declare class NotificationServiceBase extends NotificationServiceBase_base {
|
|
|
41
41
|
*/
|
|
42
42
|
clearReceivedEmails(input: ClearReceivedEmailsInput): Promise<IRPCResponse<ClearReceivedEmailsOutput>>;
|
|
43
43
|
}
|
|
44
|
-
declare function defineNotificationService():
|
|
44
|
+
declare function defineNotificationService(): typeof NotificationServiceBase;
|
|
45
45
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
export { _default as default, defineNotificationService };
|
|
46
|
+
export { defineNotificationService };
|
package/dist/export/worker.d.ts
CHANGED
|
@@ -41,10 +41,6 @@ declare class NotificationServiceBase extends NotificationServiceBase_base {
|
|
|
41
41
|
*/
|
|
42
42
|
clearReceivedEmails(input: ClearReceivedEmailsInput): Promise<IRPCResponse<ClearReceivedEmailsOutput>>;
|
|
43
43
|
}
|
|
44
|
-
declare function defineNotificationService():
|
|
44
|
+
declare function defineNotificationService(): typeof NotificationServiceBase;
|
|
45
45
|
|
|
46
|
-
declare const _default: new (ctx: ExecutionContext, env: NotificationEnv) => WorkerEntrypoint<NotificationEnv>;
|
|
47
|
-
|
|
48
|
-
// @ts-ignore
|
|
49
|
-
export = _default;
|
|
50
46
|
export { defineNotificationService };
|
package/dist/export/worker.mjs
CHANGED
|
@@ -255,17 +255,7 @@ let NotificationServiceBase = class extends develitWorker(
|
|
|
255
255
|
);
|
|
256
256
|
}
|
|
257
257
|
async sendEmailSync(input) {
|
|
258
|
-
return this.
|
|
259
|
-
{ data: input, schema: sendEmailInputSchema },
|
|
260
|
-
{ successMessage: "Email sent.", sensitiveKeys: ["attachments"] },
|
|
261
|
-
async (params) => {
|
|
262
|
-
const { email, metadata } = params;
|
|
263
|
-
return this._sendEmail({
|
|
264
|
-
email,
|
|
265
|
-
metadata
|
|
266
|
-
});
|
|
267
|
-
}
|
|
268
|
-
);
|
|
258
|
+
return this._sendEmail(input);
|
|
269
259
|
}
|
|
270
260
|
async sendSms(input) {
|
|
271
261
|
return this.handleAction(
|
|
@@ -576,6 +566,4 @@ function defineNotificationService() {
|
|
|
576
566
|
};
|
|
577
567
|
}
|
|
578
568
|
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
export { NotificationService as default, defineNotificationService };
|
|
569
|
+
export { defineNotificationService };
|