@memberjunction/communication-engine 3.4.0 → 4.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/BaseProvider.js +13 -17
- package/dist/BaseProvider.js.map +1 -1
- package/dist/Engine.js +12 -16
- package/dist/Engine.js.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -18
- package/dist/index.js.map +1 -1
- package/package.json +10 -9
package/dist/BaseProvider.js
CHANGED
|
@@ -1,16 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
const communication_types_1 = require("@memberjunction/communication-types");
|
|
5
|
-
const core_1 = require("@memberjunction/core");
|
|
6
|
-
const templates_1 = require("@memberjunction/templates");
|
|
1
|
+
import { ProcessedMessage } from "@memberjunction/communication-types";
|
|
2
|
+
import { LogError } from "@memberjunction/core";
|
|
3
|
+
import { TemplateEngineServer } from '@memberjunction/templates';
|
|
7
4
|
/**
|
|
8
5
|
* Server side implementation that calls the templating engine to process the message
|
|
9
6
|
*/
|
|
10
|
-
class ProcessedMessageServer extends
|
|
7
|
+
export class ProcessedMessageServer extends ProcessedMessage {
|
|
11
8
|
async Process(forceTemplateRefresh, contextUser) {
|
|
12
9
|
if (this.BodyTemplate || this.SubjectTemplate || this.HTMLBodyTemplate)
|
|
13
|
-
await
|
|
10
|
+
await TemplateEngineServer.Instance.Config(forceTemplateRefresh, contextUser); // make sure the template engine is configured if we are using either template
|
|
14
11
|
if (this.BodyTemplate) {
|
|
15
12
|
// process the body template
|
|
16
13
|
const regularContent = this.BodyTemplate.GetHighestPriorityContent('Text');
|
|
@@ -19,12 +16,12 @@ class ProcessedMessageServer extends communication_types_1.ProcessedMessage {
|
|
|
19
16
|
Success: false,
|
|
20
17
|
Message: 'BodyTemplate does not have a Text option and this is required for processing the body of the message.'
|
|
21
18
|
};
|
|
22
|
-
const result = await
|
|
19
|
+
const result = await TemplateEngineServer.Instance.RenderTemplate(this.BodyTemplate, regularContent, this.ContextData);
|
|
23
20
|
if (result && result.Success) {
|
|
24
21
|
this.ProcessedBody = result.Output;
|
|
25
22
|
}
|
|
26
23
|
else {
|
|
27
|
-
|
|
24
|
+
LogError(`Failed to render template for body: ${result.Message}`);
|
|
28
25
|
return {
|
|
29
26
|
Success: false,
|
|
30
27
|
Message: result.Message
|
|
@@ -33,12 +30,12 @@ class ProcessedMessageServer extends communication_types_1.ProcessedMessage {
|
|
|
33
30
|
if (!this.HTMLBodyTemplate && !this.HTMLBody) { // if we have an HTMLBodyTemplate, we will process it separately below
|
|
34
31
|
const htmlContent = this.BodyTemplate.GetHighestPriorityContent('HTML');
|
|
35
32
|
if (htmlContent) {
|
|
36
|
-
const result = await
|
|
33
|
+
const result = await TemplateEngineServer.Instance.RenderTemplate(this.BodyTemplate, htmlContent, this.ContextData);
|
|
37
34
|
if (result && result.Success) {
|
|
38
35
|
this.ProcessedHTMLBody = result.Output;
|
|
39
36
|
}
|
|
40
37
|
else {
|
|
41
|
-
|
|
38
|
+
LogError(`Failed to render template for html body: ${result.Message}`);
|
|
42
39
|
return {
|
|
43
40
|
Success: false,
|
|
44
41
|
Message: result.Message
|
|
@@ -58,12 +55,12 @@ class ProcessedMessageServer extends communication_types_1.ProcessedMessage {
|
|
|
58
55
|
// process the subject template
|
|
59
56
|
const htmlContent = this.HTMLBodyTemplate.GetHighestPriorityContent('HTML');
|
|
60
57
|
if (htmlContent) {
|
|
61
|
-
const result = await
|
|
58
|
+
const result = await TemplateEngineServer.Instance.RenderTemplate(this.HTMLBodyTemplate, htmlContent, this.ContextData);
|
|
62
59
|
if (result && result.Success) {
|
|
63
60
|
this.ProcessedHTMLBody = result.Output;
|
|
64
61
|
}
|
|
65
62
|
else {
|
|
66
|
-
|
|
63
|
+
LogError(`Failed to render template for html body 2: ${result.Message}`);
|
|
67
64
|
return {
|
|
68
65
|
Success: false,
|
|
69
66
|
Message: result.Message
|
|
@@ -84,12 +81,12 @@ class ProcessedMessageServer extends communication_types_1.ProcessedMessage {
|
|
|
84
81
|
// process the subject template
|
|
85
82
|
const subjectContent = this.SubjectTemplate.GetHighestPriorityContent('HTML');
|
|
86
83
|
if (subjectContent) {
|
|
87
|
-
const result = await
|
|
84
|
+
const result = await TemplateEngineServer.Instance.RenderTemplate(this.SubjectTemplate, subjectContent, this.ContextData);
|
|
88
85
|
if (result && result.Success) {
|
|
89
86
|
this.ProcessedSubject = result.Output;
|
|
90
87
|
}
|
|
91
88
|
else {
|
|
92
|
-
|
|
89
|
+
LogError(`Failed to render template for subject: ${result.Message}`);
|
|
93
90
|
return {
|
|
94
91
|
Success: false,
|
|
95
92
|
Message: result.Message
|
|
@@ -111,5 +108,4 @@ class ProcessedMessageServer extends communication_types_1.ProcessedMessage {
|
|
|
111
108
|
};
|
|
112
109
|
}
|
|
113
110
|
}
|
|
114
|
-
exports.ProcessedMessageServer = ProcessedMessageServer;
|
|
115
111
|
//# sourceMappingURL=BaseProvider.js.map
|
package/dist/BaseProvider.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseProvider.js","sourceRoot":"","sources":["../src/BaseProvider.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BaseProvider.js","sourceRoot":"","sources":["../src/BaseProvider.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AACvE,OAAO,EAAE,QAAQ,EAAY,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AAEjE;;GAEG;AACH,MAAM,OAAO,sBAAuB,SAAQ,gBAAgB;IACjD,KAAK,CAAC,OAAO,CAAC,oBAA8B,EAAE,WAAsB;QACvE,IAAI,IAAI,CAAC,YAAY,IAAI,IAAI,CAAC,eAAe,IAAI,IAAI,CAAC,gBAAgB;YAClE,MAAM,oBAAoB,CAAC,QAAQ,CAAC,MAAM,CAAC,oBAAoB,EAAE,WAAW,CA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AAI,CAAC,eAAe,CAAC,yBAAyB,CAAC,MAAM,CAAC,CAAC;YAC9E,IAAI,cAAc,EAAE,CAAC;gBACjB,MAAM,MAAM,GAAG,MAAM,oBAAoB,CAAC,QAAQ,CAAC,cAAc,CAAC,IAAI,CAAC,eAAe,EAAE,cAAc,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;gBAC1H,IAAI,MAAM,IAAI,MAAM,CAAC,OAAO,EAAE,CAAC;oBAC3B,IAAI,CAAC,gBAAgB,GAAG,MAAM,CAAC,MAAM,CAAC;gBAC1C,CAAC;qBACI,CAAC;oBACF,QAAQ,CAAC,0CAA0C,MAAM,CAAC,OAAO,EAAE,CAAC,CAAC;oBACrE,OAAO;wBACH,OAAO,EAAE,KAAK;wBACd,OAAO,EAAE,MAAM,CAAC,OAAO;qBAC1B,CAAA;gBACL,CAAC;YACL,CAAC;iBACI,CAAC;gBACF,OAAO;oBACH,OAAO,EAAE,KAAK;oBACd,OAAO,EAAE,0IAA0I;iBACtJ,CAAA;YACL,CAAC;QACL,CAAC;aACI,CAAC;YACF,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,OAAO,IAAI,EAAE,CAAC;QAC/C,CAAC;QAED,OAAO;YACH,OAAO,EAAE,IAAI;SAChB,CAAA;IACL,CAAC;CACJ"}
|
package/dist/Engine.js
CHANGED
|
@@ -1,15 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
const core_1 = require("@memberjunction/core");
|
|
6
|
-
const global_1 = require("@memberjunction/global");
|
|
7
|
-
const BaseProvider_1 = require("./BaseProvider");
|
|
1
|
+
import { BaseCommunicationProvider, CommunicationEngineBase, Message } from "@memberjunction/communication-types";
|
|
2
|
+
import { LogError, LogStatus } from "@memberjunction/core";
|
|
3
|
+
import { MJGlobal } from "@memberjunction/global";
|
|
4
|
+
import { ProcessedMessageServer } from "./BaseProvider.js";
|
|
8
5
|
/**
|
|
9
6
|
* Base class for communications. This class can be sub-classed if desired if you would like to modify the logic across ALL actions. To do so, sub-class this class and use the
|
|
10
7
|
* @RegisterClass decorator from the @memberjunction/global package to register your sub-class with the ClassFactory. This will cause your sub-class to be used instead of this base class when the Metadata object insantiates the ActionEngine.
|
|
11
8
|
*/
|
|
12
|
-
class CommunicationEngine extends
|
|
9
|
+
export class CommunicationEngine extends CommunicationEngineBase {
|
|
13
10
|
static get Instance() {
|
|
14
11
|
return super.getInstance();
|
|
15
12
|
}
|
|
@@ -22,7 +19,7 @@ class CommunicationEngine extends communication_types_1.CommunicationEngineBase
|
|
|
22
19
|
if (!this.Loaded) {
|
|
23
20
|
throw new Error(`Metadata not loaded. Call Config() before accessing metadata.`);
|
|
24
21
|
}
|
|
25
|
-
const instance =
|
|
22
|
+
const instance = MJGlobal.Instance.ClassFactory.CreateInstance(BaseCommunicationProvider, providerName);
|
|
26
23
|
if (instance) {
|
|
27
24
|
// make sure the class we got back is NOT an instance of the base class, that is the default behavior of CreateInstance if we
|
|
28
25
|
// dont have a registration for the class we are looking for
|
|
@@ -56,7 +53,7 @@ class CommunicationEngine extends communication_types_1.CommunicationEngineBase
|
|
|
56
53
|
throw new Error(`Failed to start communication run.`);
|
|
57
54
|
const results = [];
|
|
58
55
|
for (const r of recipients) {
|
|
59
|
-
const messageCopy = new
|
|
56
|
+
const messageCopy = new Message(message);
|
|
60
57
|
messageCopy.To = r.To;
|
|
61
58
|
messageCopy.ContextData = r.ContextData;
|
|
62
59
|
const result = await this.SendSingleMessage(providerName, providerMessageTypeName, messageCopy, run, previewOnly, credentials);
|
|
@@ -99,7 +96,7 @@ class CommunicationEngine extends communication_types_1.CommunicationEngineBase
|
|
|
99
96
|
message.MessageType = providerMessageType;
|
|
100
97
|
}
|
|
101
98
|
// now, process the message
|
|
102
|
-
const processedMessage = new
|
|
99
|
+
const processedMessage = new ProcessedMessageServer(message);
|
|
103
100
|
const processResult = await processedMessage.Process(false, this.ContextUser);
|
|
104
101
|
if (processResult.Success) {
|
|
105
102
|
if (previewOnly) {
|
|
@@ -163,7 +160,7 @@ class CommunicationEngine extends communication_types_1.CommunicationEngineBase
|
|
|
163
160
|
};
|
|
164
161
|
}
|
|
165
162
|
// Process message (render templates)
|
|
166
|
-
const processedMessage = new
|
|
163
|
+
const processedMessage = new ProcessedMessageServer(message);
|
|
167
164
|
const processResult = await processedMessage.Process(false, contextUser || this.ContextUser);
|
|
168
165
|
if (!processResult.Success) {
|
|
169
166
|
return {
|
|
@@ -177,16 +174,16 @@ class CommunicationEngine extends communication_types_1.CommunicationEngineBase
|
|
|
177
174
|
ContextData: message.ContextData
|
|
178
175
|
}, credentials);
|
|
179
176
|
if (result.Success) {
|
|
180
|
-
|
|
177
|
+
LogStatus(`Draft created successfully via ${providerName}. Draft ID: ${result.DraftID}`);
|
|
181
178
|
}
|
|
182
179
|
else {
|
|
183
|
-
|
|
180
|
+
LogError(`Failed to create draft via ${providerName}`, undefined, result.ErrorMessage);
|
|
184
181
|
}
|
|
185
182
|
return result;
|
|
186
183
|
}
|
|
187
184
|
catch (error) {
|
|
188
185
|
const errorMessage = error instanceof Error ? error.message : 'Error creating draft';
|
|
189
|
-
|
|
186
|
+
LogError('Error creating draft', undefined, error);
|
|
190
187
|
return {
|
|
191
188
|
Success: false,
|
|
192
189
|
ErrorMessage: errorMessage
|
|
@@ -194,5 +191,4 @@ class CommunicationEngine extends communication_types_1.CommunicationEngineBase
|
|
|
194
191
|
}
|
|
195
192
|
}
|
|
196
193
|
}
|
|
197
|
-
exports.CommunicationEngine = CommunicationEngine;
|
|
198
194
|
//# sourceMappingURL=Engine.js.map
|
package/dist/Engine.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Engine.js","sourceRoot":"","sources":["../src/Engine.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Engine.js","sourceRoot":"","sources":["../src/Engine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,uBAAuB,EAAqB,OAAO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sB,CAAC,OAAO,CAAC,CAAC;YAC7D,MAAM,aAAa,GAAG,MAAM,gBAAgB,CAAC,OAAO,CAAC,KAAK,EAAE,WAAW,IAAI,IAAI,CAAC,WAAW,CAAC,CAAC;YAE7F,IAAI,CAAC,aAAa,CAAC,OAAO,EAAE,CAAC;gBACzB,OAAO;oBACH,OAAO,EAAE,KAAK;oBACd,YAAY,EAAE,8BAA8B,aAAa,CAAC,OAAO,EAAE;iBACtE,CAAC;YACN,CAAC;YAED,4BAA4B;YAC5B,MAAM,MAAM,GAAG,MAAM,QAAQ,CAAC,WAAW,CAAC;gBACtC,OAAO,EAAE,gBAAgB;gBACzB,WAAW,EAAE,OAAO,CAAC,WAAW;aACnC,EAAE,WAAW,CAAC,CAAC;YAEhB,IAAI,MAAM,CAAC,OAAO,EAAE,CAAC;gBACjB,SAAS,CAAC,kCAAkC,YAAY,eAAe,MAAM,CAAC,OAAO,EAAE,CAAC,CAAC;YAC7F,CAAC;iBAAM,CAAC;gBACJ,QAAQ,CAAC,8BAA8B,YAAY,EAAE,EAAE,SAAS,EAAE,MAAM,CAAC,YAAY,CAAC,CAAC;YAC3F,CAAC;YAED,OAAO,MAAM,CAAC;QAClB,CAAC;QAAC,OAAO,KAAc,EAAE,CAAC;YACtB,MAAM,YAAY,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,sBAAsB,CAAC;YACrF,QAAQ,CAAC,sBAAsB,EAAE,SAAS,EAAE,KAAK,CAAC,CAAC;YACnD,OAAO;gBACH,OAAO,EAAE,KAAK;gBACd,YAAY,EAAE,YAAY;aAC7B,CAAC;QACN,CAAC;IACL,CAAC;CACL"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './Engine';
|
|
2
|
-
export * from './BaseProvider';
|
|
1
|
+
export * from './Engine.js';
|
|
2
|
+
export * from './BaseProvider.js';
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.js
CHANGED
|
@@ -1,20 +1,4 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
1
|
// PUBLIC API SURFACE AREA
|
|
18
|
-
|
|
19
|
-
|
|
2
|
+
export * from './Engine.js';
|
|
3
|
+
export * from './BaseProvider.js';
|
|
20
4
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,0BAA0B;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,gBAAgB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@memberjunction/communication-engine",
|
|
3
|
-
"
|
|
3
|
+
"type": "module",
|
|
4
|
+
"version": "4.0.0",
|
|
4
5
|
"description": "MemberJunction: Core Communication Framework Library",
|
|
5
6
|
"main": "dist/index.js",
|
|
6
7
|
"types": "dist/index.d.ts",
|
|
@@ -9,22 +10,22 @@
|
|
|
9
10
|
],
|
|
10
11
|
"scripts": {
|
|
11
12
|
"start": "ts-node-dev src/index.ts",
|
|
12
|
-
"build": "tsc",
|
|
13
|
+
"build": "tsc && tsc-alias -f",
|
|
13
14
|
"test": "echo \"Error: no test specified\" && exit 1"
|
|
14
15
|
},
|
|
15
16
|
"author": "MemberJunction.com",
|
|
16
17
|
"license": "ISC",
|
|
17
18
|
"devDependencies": {
|
|
18
19
|
"ts-node-dev": "^2.0.0",
|
|
19
|
-
"typescript": "^5.
|
|
20
|
+
"typescript": "^5.9.3"
|
|
20
21
|
},
|
|
21
22
|
"dependencies": {
|
|
22
|
-
"@memberjunction/global": "
|
|
23
|
-
"@memberjunction/core": "
|
|
24
|
-
"@memberjunction/templates": "
|
|
25
|
-
"@memberjunction/core-entities": "
|
|
26
|
-
"@memberjunction/communication-types": "
|
|
27
|
-
"rxjs": "^7.8.
|
|
23
|
+
"@memberjunction/global": "4.0.0",
|
|
24
|
+
"@memberjunction/core": "4.0.0",
|
|
25
|
+
"@memberjunction/templates": "4.0.0",
|
|
26
|
+
"@memberjunction/core-entities": "4.0.0",
|
|
27
|
+
"@memberjunction/communication-types": "4.0.0",
|
|
28
|
+
"rxjs": "^7.8.2"
|
|
28
29
|
},
|
|
29
30
|
"repository": {
|
|
30
31
|
"type": "git",
|