@twin.org/messaging-connector-entity-storage 0.0.1-next.7 → 0.0.1-next.8
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/cjs/index.cjs +27 -34
- package/dist/esm/index.mjs +27 -34
- package/dist/types/entityStorageMessagingEmailConnector.d.ts +2 -6
- package/dist/types/entityStorageMessagingPushNotificationConnector.d.ts +2 -8
- package/dist/types/entityStorageMessagingSmsConnector.d.ts +2 -6
- package/dist/types/index.d.ts +3 -0
- package/dist/types/models/IEntityStorageMessagingEmailConnectorConstructorOptions.d.ts +14 -0
- package/dist/types/models/IEntityStorageMessagingPushNotificationConnectorConstructorOptions.d.ts +19 -0
- package/dist/types/models/IEntityStorageMessagingSmsConnectorConstructorOptions.d.ts +14 -0
- package/docs/changelog.md +1 -1
- package/docs/reference/classes/EntityStorageMessagingEmailConnector.md +15 -13
- package/docs/reference/classes/EntityStorageMessagingPushNotificationConnector.md +18 -18
- package/docs/reference/classes/EntityStorageMessagingSmsConnector.md +9 -11
- package/docs/reference/functions/initSchema.md +10 -4
- package/docs/reference/index.md +6 -0
- package/docs/reference/interfaces/IEntityStorageMessagingEmailConnectorConstructorOptions.md +25 -0
- package/docs/reference/interfaces/IEntityStorageMessagingPushNotificationConnectorConstructorOptions.md +39 -0
- package/docs/reference/interfaces/IEntityStorageMessagingSmsConnectorConstructorOptions.md +25 -0
- package/package.json +2 -2
package/dist/cjs/index.cjs
CHANGED
|
@@ -45,35 +45,35 @@ exports.EmailEntry = class EmailEntry {
|
|
|
45
45
|
__decorate([
|
|
46
46
|
entity.property({ type: "string", isPrimary: true }),
|
|
47
47
|
__metadata("design:type", String)
|
|
48
|
-
], exports.EmailEntry.prototype, "id",
|
|
48
|
+
], exports.EmailEntry.prototype, "id", undefined);
|
|
49
49
|
__decorate([
|
|
50
50
|
entity.property({ type: "string" }),
|
|
51
51
|
__metadata("design:type", String)
|
|
52
|
-
], exports.EmailEntry.prototype, "sender",
|
|
52
|
+
], exports.EmailEntry.prototype, "sender", undefined);
|
|
53
53
|
__decorate([
|
|
54
54
|
entity.property({ type: "array", itemType: "string" }),
|
|
55
55
|
__metadata("design:type", Array)
|
|
56
|
-
], exports.EmailEntry.prototype, "recipients",
|
|
56
|
+
], exports.EmailEntry.prototype, "recipients", undefined);
|
|
57
57
|
__decorate([
|
|
58
58
|
entity.property({ type: "integer" }),
|
|
59
59
|
__metadata("design:type", Number)
|
|
60
|
-
], exports.EmailEntry.prototype, "ts",
|
|
60
|
+
], exports.EmailEntry.prototype, "ts", undefined);
|
|
61
61
|
__decorate([
|
|
62
62
|
entity.property({ type: "string" }),
|
|
63
63
|
__metadata("design:type", String)
|
|
64
|
-
], exports.EmailEntry.prototype, "message",
|
|
64
|
+
], exports.EmailEntry.prototype, "message", undefined);
|
|
65
65
|
__decorate([
|
|
66
66
|
entity.property({ type: "string" }),
|
|
67
67
|
__metadata("design:type", String)
|
|
68
|
-
], exports.EmailEntry.prototype, "subject",
|
|
68
|
+
], exports.EmailEntry.prototype, "subject", undefined);
|
|
69
69
|
__decorate([
|
|
70
70
|
entity.property({ type: "string" }),
|
|
71
71
|
__metadata("design:type", String)
|
|
72
|
-
], exports.EmailEntry.prototype, "status",
|
|
72
|
+
], exports.EmailEntry.prototype, "status", undefined);
|
|
73
73
|
__decorate([
|
|
74
74
|
entity.property({ type: "object" }),
|
|
75
75
|
__metadata("design:type", Object)
|
|
76
|
-
], exports.EmailEntry.prototype, "error",
|
|
76
|
+
], exports.EmailEntry.prototype, "error", undefined);
|
|
77
77
|
exports.EmailEntry = __decorate([
|
|
78
78
|
entity.entity()
|
|
79
79
|
], exports.EmailEntry);
|
|
@@ -110,27 +110,27 @@ exports.PushNotificationDeviceEntry = class PushNotificationDeviceEntry {
|
|
|
110
110
|
__decorate([
|
|
111
111
|
entity.property({ type: "string", isPrimary: true }),
|
|
112
112
|
__metadata("design:type", String)
|
|
113
|
-
], exports.PushNotificationDeviceEntry.prototype, "id",
|
|
113
|
+
], exports.PushNotificationDeviceEntry.prototype, "id", undefined);
|
|
114
114
|
__decorate([
|
|
115
115
|
entity.property({ type: "string" }),
|
|
116
116
|
__metadata("design:type", String)
|
|
117
|
-
], exports.PushNotificationDeviceEntry.prototype, "applicationId",
|
|
117
|
+
], exports.PushNotificationDeviceEntry.prototype, "applicationId", undefined);
|
|
118
118
|
__decorate([
|
|
119
119
|
entity.property({ type: "string" }),
|
|
120
120
|
__metadata("design:type", String)
|
|
121
|
-
], exports.PushNotificationDeviceEntry.prototype, "deviceToken",
|
|
121
|
+
], exports.PushNotificationDeviceEntry.prototype, "deviceToken", undefined);
|
|
122
122
|
__decorate([
|
|
123
123
|
entity.property({ type: "integer" }),
|
|
124
124
|
__metadata("design:type", Number)
|
|
125
|
-
], exports.PushNotificationDeviceEntry.prototype, "ts",
|
|
125
|
+
], exports.PushNotificationDeviceEntry.prototype, "ts", undefined);
|
|
126
126
|
__decorate([
|
|
127
127
|
entity.property({ type: "string" }),
|
|
128
128
|
__metadata("design:type", String)
|
|
129
|
-
], exports.PushNotificationDeviceEntry.prototype, "status",
|
|
129
|
+
], exports.PushNotificationDeviceEntry.prototype, "status", undefined);
|
|
130
130
|
__decorate([
|
|
131
131
|
entity.property({ type: "object" }),
|
|
132
132
|
__metadata("design:type", Object)
|
|
133
|
-
], exports.PushNotificationDeviceEntry.prototype, "error",
|
|
133
|
+
], exports.PushNotificationDeviceEntry.prototype, "error", undefined);
|
|
134
134
|
exports.PushNotificationDeviceEntry = __decorate([
|
|
135
135
|
entity.entity()
|
|
136
136
|
], exports.PushNotificationDeviceEntry);
|
|
@@ -171,31 +171,31 @@ exports.PushNotificationMessageEntry = class PushNotificationMessageEntry {
|
|
|
171
171
|
__decorate([
|
|
172
172
|
entity.property({ type: "string", isPrimary: true }),
|
|
173
173
|
__metadata("design:type", String)
|
|
174
|
-
], exports.PushNotificationMessageEntry.prototype, "id",
|
|
174
|
+
], exports.PushNotificationMessageEntry.prototype, "id", undefined);
|
|
175
175
|
__decorate([
|
|
176
176
|
entity.property({ type: "string" }),
|
|
177
177
|
__metadata("design:type", String)
|
|
178
|
-
], exports.PushNotificationMessageEntry.prototype, "deviceAddress",
|
|
178
|
+
], exports.PushNotificationMessageEntry.prototype, "deviceAddress", undefined);
|
|
179
179
|
__decorate([
|
|
180
180
|
entity.property({ type: "string" }),
|
|
181
181
|
__metadata("design:type", String)
|
|
182
|
-
], exports.PushNotificationMessageEntry.prototype, "title",
|
|
182
|
+
], exports.PushNotificationMessageEntry.prototype, "title", undefined);
|
|
183
183
|
__decorate([
|
|
184
184
|
entity.property({ type: "string" }),
|
|
185
185
|
__metadata("design:type", String)
|
|
186
|
-
], exports.PushNotificationMessageEntry.prototype, "message",
|
|
186
|
+
], exports.PushNotificationMessageEntry.prototype, "message", undefined);
|
|
187
187
|
__decorate([
|
|
188
188
|
entity.property({ type: "integer" }),
|
|
189
189
|
__metadata("design:type", Number)
|
|
190
|
-
], exports.PushNotificationMessageEntry.prototype, "ts",
|
|
190
|
+
], exports.PushNotificationMessageEntry.prototype, "ts", undefined);
|
|
191
191
|
__decorate([
|
|
192
192
|
entity.property({ type: "string" }),
|
|
193
193
|
__metadata("design:type", String)
|
|
194
|
-
], exports.PushNotificationMessageEntry.prototype, "status",
|
|
194
|
+
], exports.PushNotificationMessageEntry.prototype, "status", undefined);
|
|
195
195
|
__decorate([
|
|
196
196
|
entity.property({ type: "object" }),
|
|
197
197
|
__metadata("design:type", Object)
|
|
198
|
-
], exports.PushNotificationMessageEntry.prototype, "error",
|
|
198
|
+
], exports.PushNotificationMessageEntry.prototype, "error", undefined);
|
|
199
199
|
exports.PushNotificationMessageEntry = __decorate([
|
|
200
200
|
entity.entity()
|
|
201
201
|
], exports.PushNotificationMessageEntry);
|
|
@@ -232,27 +232,27 @@ exports.SmsEntry = class SmsEntry {
|
|
|
232
232
|
__decorate([
|
|
233
233
|
entity.property({ type: "string", isPrimary: true }),
|
|
234
234
|
__metadata("design:type", String)
|
|
235
|
-
], exports.SmsEntry.prototype, "id",
|
|
235
|
+
], exports.SmsEntry.prototype, "id", undefined);
|
|
236
236
|
__decorate([
|
|
237
237
|
entity.property({ type: "string" }),
|
|
238
238
|
__metadata("design:type", String)
|
|
239
|
-
], exports.SmsEntry.prototype, "phoneNumber",
|
|
239
|
+
], exports.SmsEntry.prototype, "phoneNumber", undefined);
|
|
240
240
|
__decorate([
|
|
241
241
|
entity.property({ type: "integer" }),
|
|
242
242
|
__metadata("design:type", Number)
|
|
243
|
-
], exports.SmsEntry.prototype, "ts",
|
|
243
|
+
], exports.SmsEntry.prototype, "ts", undefined);
|
|
244
244
|
__decorate([
|
|
245
245
|
entity.property({ type: "string" }),
|
|
246
246
|
__metadata("design:type", String)
|
|
247
|
-
], exports.SmsEntry.prototype, "message",
|
|
247
|
+
], exports.SmsEntry.prototype, "message", undefined);
|
|
248
248
|
__decorate([
|
|
249
249
|
entity.property({ type: "string" }),
|
|
250
250
|
__metadata("design:type", String)
|
|
251
|
-
], exports.SmsEntry.prototype, "status",
|
|
251
|
+
], exports.SmsEntry.prototype, "status", undefined);
|
|
252
252
|
__decorate([
|
|
253
253
|
entity.property({ type: "object" }),
|
|
254
254
|
__metadata("design:type", Object)
|
|
255
|
-
], exports.SmsEntry.prototype, "error",
|
|
255
|
+
], exports.SmsEntry.prototype, "error", undefined);
|
|
256
256
|
exports.SmsEntry = __decorate([
|
|
257
257
|
entity.entity()
|
|
258
258
|
], exports.SmsEntry);
|
|
@@ -284,8 +284,6 @@ class EntityStorageMessagingEmailConnector {
|
|
|
284
284
|
/**
|
|
285
285
|
* Create a new instance of EntityStorageMessagingEmailConnector.
|
|
286
286
|
* @param options The options for the connector.
|
|
287
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
288
|
-
* @param options.messagingEmailEntryStorageConnectorType The type of entity storage connector to use for the email entries, defaults to "email-entry".
|
|
289
287
|
*/
|
|
290
288
|
constructor(options) {
|
|
291
289
|
if (core.Is.stringValue(options?.loggingConnectorType)) {
|
|
@@ -368,9 +366,6 @@ class EntityStorageMessagingPushNotificationConnector {
|
|
|
368
366
|
/**
|
|
369
367
|
* Create a new instance of EntityStorageMessagingPushNotificationConnector.
|
|
370
368
|
* @param options The options for the connector.
|
|
371
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
372
|
-
* @param options.messagingDeviceEntryStorageConnectorType The type of entity storage connector to use for the push notifications entries, defaults to "push-notification-device-entry".
|
|
373
|
-
* @param options.messagingMessageEntryStorageConnectorType The type of entity storage connector to use for the push notifications entries, defaults to "push-notification-message-entry".
|
|
374
369
|
*/
|
|
375
370
|
constructor(options) {
|
|
376
371
|
if (core.Is.stringValue(options?.loggingConnectorType)) {
|
|
@@ -475,8 +470,6 @@ class EntityStorageMessagingSmsConnector {
|
|
|
475
470
|
/**
|
|
476
471
|
* Create a new instance of EntityStorageMessagingSmsConnector.
|
|
477
472
|
* @param options The options for the connector.
|
|
478
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
479
|
-
* @param options.messagingSmsEntryStorageConnectorType The type of entity storage connector to use for the sms entries, defaults to "sms-entry".
|
|
480
473
|
*/
|
|
481
474
|
constructor(options) {
|
|
482
475
|
if (core.Is.stringValue(options?.loggingConnectorType)) {
|
package/dist/esm/index.mjs
CHANGED
|
@@ -43,35 +43,35 @@ let EmailEntry = class EmailEntry {
|
|
|
43
43
|
__decorate([
|
|
44
44
|
property({ type: "string", isPrimary: true }),
|
|
45
45
|
__metadata("design:type", String)
|
|
46
|
-
], EmailEntry.prototype, "id",
|
|
46
|
+
], EmailEntry.prototype, "id", undefined);
|
|
47
47
|
__decorate([
|
|
48
48
|
property({ type: "string" }),
|
|
49
49
|
__metadata("design:type", String)
|
|
50
|
-
], EmailEntry.prototype, "sender",
|
|
50
|
+
], EmailEntry.prototype, "sender", undefined);
|
|
51
51
|
__decorate([
|
|
52
52
|
property({ type: "array", itemType: "string" }),
|
|
53
53
|
__metadata("design:type", Array)
|
|
54
|
-
], EmailEntry.prototype, "recipients",
|
|
54
|
+
], EmailEntry.prototype, "recipients", undefined);
|
|
55
55
|
__decorate([
|
|
56
56
|
property({ type: "integer" }),
|
|
57
57
|
__metadata("design:type", Number)
|
|
58
|
-
], EmailEntry.prototype, "ts",
|
|
58
|
+
], EmailEntry.prototype, "ts", undefined);
|
|
59
59
|
__decorate([
|
|
60
60
|
property({ type: "string" }),
|
|
61
61
|
__metadata("design:type", String)
|
|
62
|
-
], EmailEntry.prototype, "message",
|
|
62
|
+
], EmailEntry.prototype, "message", undefined);
|
|
63
63
|
__decorate([
|
|
64
64
|
property({ type: "string" }),
|
|
65
65
|
__metadata("design:type", String)
|
|
66
|
-
], EmailEntry.prototype, "subject",
|
|
66
|
+
], EmailEntry.prototype, "subject", undefined);
|
|
67
67
|
__decorate([
|
|
68
68
|
property({ type: "string" }),
|
|
69
69
|
__metadata("design:type", String)
|
|
70
|
-
], EmailEntry.prototype, "status",
|
|
70
|
+
], EmailEntry.prototype, "status", undefined);
|
|
71
71
|
__decorate([
|
|
72
72
|
property({ type: "object" }),
|
|
73
73
|
__metadata("design:type", Object)
|
|
74
|
-
], EmailEntry.prototype, "error",
|
|
74
|
+
], EmailEntry.prototype, "error", undefined);
|
|
75
75
|
EmailEntry = __decorate([
|
|
76
76
|
entity()
|
|
77
77
|
], EmailEntry);
|
|
@@ -108,27 +108,27 @@ let PushNotificationDeviceEntry = class PushNotificationDeviceEntry {
|
|
|
108
108
|
__decorate([
|
|
109
109
|
property({ type: "string", isPrimary: true }),
|
|
110
110
|
__metadata("design:type", String)
|
|
111
|
-
], PushNotificationDeviceEntry.prototype, "id",
|
|
111
|
+
], PushNotificationDeviceEntry.prototype, "id", undefined);
|
|
112
112
|
__decorate([
|
|
113
113
|
property({ type: "string" }),
|
|
114
114
|
__metadata("design:type", String)
|
|
115
|
-
], PushNotificationDeviceEntry.prototype, "applicationId",
|
|
115
|
+
], PushNotificationDeviceEntry.prototype, "applicationId", undefined);
|
|
116
116
|
__decorate([
|
|
117
117
|
property({ type: "string" }),
|
|
118
118
|
__metadata("design:type", String)
|
|
119
|
-
], PushNotificationDeviceEntry.prototype, "deviceToken",
|
|
119
|
+
], PushNotificationDeviceEntry.prototype, "deviceToken", undefined);
|
|
120
120
|
__decorate([
|
|
121
121
|
property({ type: "integer" }),
|
|
122
122
|
__metadata("design:type", Number)
|
|
123
|
-
], PushNotificationDeviceEntry.prototype, "ts",
|
|
123
|
+
], PushNotificationDeviceEntry.prototype, "ts", undefined);
|
|
124
124
|
__decorate([
|
|
125
125
|
property({ type: "string" }),
|
|
126
126
|
__metadata("design:type", String)
|
|
127
|
-
], PushNotificationDeviceEntry.prototype, "status",
|
|
127
|
+
], PushNotificationDeviceEntry.prototype, "status", undefined);
|
|
128
128
|
__decorate([
|
|
129
129
|
property({ type: "object" }),
|
|
130
130
|
__metadata("design:type", Object)
|
|
131
|
-
], PushNotificationDeviceEntry.prototype, "error",
|
|
131
|
+
], PushNotificationDeviceEntry.prototype, "error", undefined);
|
|
132
132
|
PushNotificationDeviceEntry = __decorate([
|
|
133
133
|
entity()
|
|
134
134
|
], PushNotificationDeviceEntry);
|
|
@@ -169,31 +169,31 @@ let PushNotificationMessageEntry = class PushNotificationMessageEntry {
|
|
|
169
169
|
__decorate([
|
|
170
170
|
property({ type: "string", isPrimary: true }),
|
|
171
171
|
__metadata("design:type", String)
|
|
172
|
-
], PushNotificationMessageEntry.prototype, "id",
|
|
172
|
+
], PushNotificationMessageEntry.prototype, "id", undefined);
|
|
173
173
|
__decorate([
|
|
174
174
|
property({ type: "string" }),
|
|
175
175
|
__metadata("design:type", String)
|
|
176
|
-
], PushNotificationMessageEntry.prototype, "deviceAddress",
|
|
176
|
+
], PushNotificationMessageEntry.prototype, "deviceAddress", undefined);
|
|
177
177
|
__decorate([
|
|
178
178
|
property({ type: "string" }),
|
|
179
179
|
__metadata("design:type", String)
|
|
180
|
-
], PushNotificationMessageEntry.prototype, "title",
|
|
180
|
+
], PushNotificationMessageEntry.prototype, "title", undefined);
|
|
181
181
|
__decorate([
|
|
182
182
|
property({ type: "string" }),
|
|
183
183
|
__metadata("design:type", String)
|
|
184
|
-
], PushNotificationMessageEntry.prototype, "message",
|
|
184
|
+
], PushNotificationMessageEntry.prototype, "message", undefined);
|
|
185
185
|
__decorate([
|
|
186
186
|
property({ type: "integer" }),
|
|
187
187
|
__metadata("design:type", Number)
|
|
188
|
-
], PushNotificationMessageEntry.prototype, "ts",
|
|
188
|
+
], PushNotificationMessageEntry.prototype, "ts", undefined);
|
|
189
189
|
__decorate([
|
|
190
190
|
property({ type: "string" }),
|
|
191
191
|
__metadata("design:type", String)
|
|
192
|
-
], PushNotificationMessageEntry.prototype, "status",
|
|
192
|
+
], PushNotificationMessageEntry.prototype, "status", undefined);
|
|
193
193
|
__decorate([
|
|
194
194
|
property({ type: "object" }),
|
|
195
195
|
__metadata("design:type", Object)
|
|
196
|
-
], PushNotificationMessageEntry.prototype, "error",
|
|
196
|
+
], PushNotificationMessageEntry.prototype, "error", undefined);
|
|
197
197
|
PushNotificationMessageEntry = __decorate([
|
|
198
198
|
entity()
|
|
199
199
|
], PushNotificationMessageEntry);
|
|
@@ -230,27 +230,27 @@ let SmsEntry = class SmsEntry {
|
|
|
230
230
|
__decorate([
|
|
231
231
|
property({ type: "string", isPrimary: true }),
|
|
232
232
|
__metadata("design:type", String)
|
|
233
|
-
], SmsEntry.prototype, "id",
|
|
233
|
+
], SmsEntry.prototype, "id", undefined);
|
|
234
234
|
__decorate([
|
|
235
235
|
property({ type: "string" }),
|
|
236
236
|
__metadata("design:type", String)
|
|
237
|
-
], SmsEntry.prototype, "phoneNumber",
|
|
237
|
+
], SmsEntry.prototype, "phoneNumber", undefined);
|
|
238
238
|
__decorate([
|
|
239
239
|
property({ type: "integer" }),
|
|
240
240
|
__metadata("design:type", Number)
|
|
241
|
-
], SmsEntry.prototype, "ts",
|
|
241
|
+
], SmsEntry.prototype, "ts", undefined);
|
|
242
242
|
__decorate([
|
|
243
243
|
property({ type: "string" }),
|
|
244
244
|
__metadata("design:type", String)
|
|
245
|
-
], SmsEntry.prototype, "message",
|
|
245
|
+
], SmsEntry.prototype, "message", undefined);
|
|
246
246
|
__decorate([
|
|
247
247
|
property({ type: "string" }),
|
|
248
248
|
__metadata("design:type", String)
|
|
249
|
-
], SmsEntry.prototype, "status",
|
|
249
|
+
], SmsEntry.prototype, "status", undefined);
|
|
250
250
|
__decorate([
|
|
251
251
|
property({ type: "object" }),
|
|
252
252
|
__metadata("design:type", Object)
|
|
253
|
-
], SmsEntry.prototype, "error",
|
|
253
|
+
], SmsEntry.prototype, "error", undefined);
|
|
254
254
|
SmsEntry = __decorate([
|
|
255
255
|
entity()
|
|
256
256
|
], SmsEntry);
|
|
@@ -282,8 +282,6 @@ class EntityStorageMessagingEmailConnector {
|
|
|
282
282
|
/**
|
|
283
283
|
* Create a new instance of EntityStorageMessagingEmailConnector.
|
|
284
284
|
* @param options The options for the connector.
|
|
285
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
286
|
-
* @param options.messagingEmailEntryStorageConnectorType The type of entity storage connector to use for the email entries, defaults to "email-entry".
|
|
287
285
|
*/
|
|
288
286
|
constructor(options) {
|
|
289
287
|
if (Is.stringValue(options?.loggingConnectorType)) {
|
|
@@ -366,9 +364,6 @@ class EntityStorageMessagingPushNotificationConnector {
|
|
|
366
364
|
/**
|
|
367
365
|
* Create a new instance of EntityStorageMessagingPushNotificationConnector.
|
|
368
366
|
* @param options The options for the connector.
|
|
369
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
370
|
-
* @param options.messagingDeviceEntryStorageConnectorType The type of entity storage connector to use for the push notifications entries, defaults to "push-notification-device-entry".
|
|
371
|
-
* @param options.messagingMessageEntryStorageConnectorType The type of entity storage connector to use for the push notifications entries, defaults to "push-notification-message-entry".
|
|
372
367
|
*/
|
|
373
368
|
constructor(options) {
|
|
374
369
|
if (Is.stringValue(options?.loggingConnectorType)) {
|
|
@@ -473,8 +468,6 @@ class EntityStorageMessagingSmsConnector {
|
|
|
473
468
|
/**
|
|
474
469
|
* Create a new instance of EntityStorageMessagingSmsConnector.
|
|
475
470
|
* @param options The options for the connector.
|
|
476
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
477
|
-
* @param options.messagingSmsEntryStorageConnectorType The type of entity storage connector to use for the sms entries, defaults to "sms-entry".
|
|
478
471
|
*/
|
|
479
472
|
constructor(options) {
|
|
480
473
|
if (Is.stringValue(options?.loggingConnectorType)) {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { IMessagingEmailConnector } from "@twin.org/messaging-models";
|
|
2
|
+
import type { IEntityStorageMessagingEmailConnectorConstructorOptions } from "./models/IEntityStorageMessagingEmailConnectorConstructorOptions";
|
|
2
3
|
/**
|
|
3
4
|
* Class for connecting to the email messaging operations of the Entity Storage.
|
|
4
5
|
*/
|
|
@@ -14,13 +15,8 @@ export declare class EntityStorageMessagingEmailConnector implements IMessagingE
|
|
|
14
15
|
/**
|
|
15
16
|
* Create a new instance of EntityStorageMessagingEmailConnector.
|
|
16
17
|
* @param options The options for the connector.
|
|
17
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
18
|
-
* @param options.messagingEmailEntryStorageConnectorType The type of entity storage connector to use for the email entries, defaults to "email-entry".
|
|
19
18
|
*/
|
|
20
|
-
constructor(options?:
|
|
21
|
-
loggingConnectorType?: string;
|
|
22
|
-
messagingEmailEntryStorageConnectorType?: string;
|
|
23
|
-
});
|
|
19
|
+
constructor(options?: IEntityStorageMessagingEmailConnectorConstructorOptions);
|
|
24
20
|
/**
|
|
25
21
|
* Store a custom email using Entity Storage.
|
|
26
22
|
* @param sender The sender email address.
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { IMessagingPushNotificationsConnector } from "@twin.org/messaging-models";
|
|
2
|
+
import type { IEntityStorageMessagingPushNotificationConnectorConstructorOptions } from "./models/IEntityStorageMessagingPushNotificationConnectorConstructorOptions";
|
|
2
3
|
/**
|
|
3
4
|
* Class for connecting to the push notifications messaging operations of the Entity Storage.
|
|
4
5
|
*/
|
|
@@ -14,15 +15,8 @@ export declare class EntityStorageMessagingPushNotificationConnector implements
|
|
|
14
15
|
/**
|
|
15
16
|
* Create a new instance of EntityStorageMessagingPushNotificationConnector.
|
|
16
17
|
* @param options The options for the connector.
|
|
17
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
18
|
-
* @param options.messagingDeviceEntryStorageConnectorType The type of entity storage connector to use for the push notifications entries, defaults to "push-notification-device-entry".
|
|
19
|
-
* @param options.messagingMessageEntryStorageConnectorType The type of entity storage connector to use for the push notifications entries, defaults to "push-notification-message-entry".
|
|
20
18
|
*/
|
|
21
|
-
constructor(options?:
|
|
22
|
-
loggingConnectorType?: string;
|
|
23
|
-
messagingDeviceEntryStorageConnectorType?: string;
|
|
24
|
-
messagingMessageEntryStorageConnectorType?: string;
|
|
25
|
-
});
|
|
19
|
+
constructor(options?: IEntityStorageMessagingPushNotificationConnectorConstructorOptions);
|
|
26
20
|
/**
|
|
27
21
|
* Registers a device to an specific app in order to send notifications to it.
|
|
28
22
|
* @param applicationId The application address.
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { IMessagingSmsConnector } from "@twin.org/messaging-models";
|
|
2
|
+
import type { IEntityStorageMessagingSmsConnectorConstructorOptions } from "./models/IEntityStorageMessagingSmsConnectorConstructorOptions";
|
|
2
3
|
/**
|
|
3
4
|
* Class for connecting to the SMS messaging operations of the Entity Storage.
|
|
4
5
|
*/
|
|
@@ -14,13 +15,8 @@ export declare class EntityStorageMessagingSmsConnector implements IMessagingSms
|
|
|
14
15
|
/**
|
|
15
16
|
* Create a new instance of EntityStorageMessagingSmsConnector.
|
|
16
17
|
* @param options The options for the connector.
|
|
17
|
-
* @param options.loggingConnectorType The type of logging connector to use, defaults to no logging.
|
|
18
|
-
* @param options.messagingSmsEntryStorageConnectorType The type of entity storage connector to use for the sms entries, defaults to "sms-entry".
|
|
19
18
|
*/
|
|
20
|
-
constructor(options?:
|
|
21
|
-
loggingConnectorType?: string;
|
|
22
|
-
messagingSmsEntryStorageConnectorType?: string;
|
|
23
|
-
});
|
|
19
|
+
constructor(options?: IEntityStorageMessagingSmsConnectorConstructorOptions);
|
|
24
20
|
/**
|
|
25
21
|
* Send a SMS message to a phone number.
|
|
26
22
|
* @param phoneNumber The recipient phone number.
|
package/dist/types/index.d.ts
CHANGED
|
@@ -5,4 +5,7 @@ export * from "./entities/smsEntry";
|
|
|
5
5
|
export * from "./entityStorageMessagingEmailConnector";
|
|
6
6
|
export * from "./entityStorageMessagingPushNotificationConnector";
|
|
7
7
|
export * from "./entityStorageMessagingSmsConnector";
|
|
8
|
+
export * from "./models/IEntityStorageMessagingEmailConnectorConstructorOptions";
|
|
9
|
+
export * from "./models/IEntityStorageMessagingPushNotificationConnectorConstructorOptions";
|
|
10
|
+
export * from "./models/IEntityStorageMessagingSmsConnectorConstructorOptions";
|
|
8
11
|
export * from "./schema";
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Options for the entity storage messaging email connector.
|
|
3
|
+
*/
|
|
4
|
+
export interface IEntityStorageMessagingEmailConnectorConstructorOptions {
|
|
5
|
+
/**
|
|
6
|
+
* The type of logging connector to use, defaults to no logging.
|
|
7
|
+
*/
|
|
8
|
+
loggingConnectorType?: string;
|
|
9
|
+
/**
|
|
10
|
+
* The type of entity storage connector to use for the email entries.
|
|
11
|
+
* @default email-entry
|
|
12
|
+
*/
|
|
13
|
+
messagingEmailEntryStorageConnectorType?: string;
|
|
14
|
+
}
|
package/dist/types/models/IEntityStorageMessagingPushNotificationConnectorConstructorOptions.d.ts
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Options for the entity storage messaging push notification connector.
|
|
3
|
+
*/
|
|
4
|
+
export interface IEntityStorageMessagingPushNotificationConnectorConstructorOptions {
|
|
5
|
+
/**
|
|
6
|
+
* The type of logging connector to use, defaults to no logging.
|
|
7
|
+
*/
|
|
8
|
+
loggingConnectorType?: string;
|
|
9
|
+
/**
|
|
10
|
+
* The type of entity storage connector to use for the push notifications entries.
|
|
11
|
+
* @default push-notification-device-entry
|
|
12
|
+
*/
|
|
13
|
+
messagingDeviceEntryStorageConnectorType?: string;
|
|
14
|
+
/**
|
|
15
|
+
* The type of entity storage connector to use for the push notifications entries.
|
|
16
|
+
* @default push-notification-message-entry
|
|
17
|
+
*/
|
|
18
|
+
messagingMessageEntryStorageConnectorType?: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Options for the entity storage messaging SMS connector.
|
|
3
|
+
*/
|
|
4
|
+
export interface IEntityStorageMessagingSmsConnectorConstructorOptions {
|
|
5
|
+
/**
|
|
6
|
+
* The type of logging connector to use, defaults to no logging.
|
|
7
|
+
*/
|
|
8
|
+
loggingConnectorType?: string;
|
|
9
|
+
/**
|
|
10
|
+
* The type of entity storage connector to use for the sms entries.
|
|
11
|
+
* @default sms-entry
|
|
12
|
+
*/
|
|
13
|
+
messagingSmsEntryStorageConnectorType?: string;
|
|
14
|
+
}
|
package/docs/changelog.md
CHANGED
|
@@ -16,17 +16,11 @@ Create a new instance of EntityStorageMessagingEmailConnector.
|
|
|
16
16
|
|
|
17
17
|
#### Parameters
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
##### options?
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
• **options.loggingConnectorType?**: `string`
|
|
24
|
-
|
|
25
|
-
The type of logging connector to use, defaults to no logging.
|
|
21
|
+
[`IEntityStorageMessagingEmailConnectorConstructorOptions`](../interfaces/IEntityStorageMessagingEmailConnectorConstructorOptions.md)
|
|
26
22
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
The type of entity storage connector to use for the email entries, defaults to "email-entry".
|
|
23
|
+
The options for the connector.
|
|
30
24
|
|
|
31
25
|
#### Returns
|
|
32
26
|
|
|
@@ -62,19 +56,27 @@ Store a custom email using Entity Storage.
|
|
|
62
56
|
|
|
63
57
|
#### Parameters
|
|
64
58
|
|
|
65
|
-
|
|
59
|
+
##### sender
|
|
60
|
+
|
|
61
|
+
`string`
|
|
66
62
|
|
|
67
63
|
The sender email address.
|
|
68
64
|
|
|
69
|
-
|
|
65
|
+
##### recipients
|
|
66
|
+
|
|
67
|
+
`string`[]
|
|
70
68
|
|
|
71
69
|
An array of recipients email addresses.
|
|
72
70
|
|
|
73
|
-
|
|
71
|
+
##### subject
|
|
72
|
+
|
|
73
|
+
`string`
|
|
74
74
|
|
|
75
75
|
The subject of the email.
|
|
76
76
|
|
|
77
|
-
|
|
77
|
+
##### content
|
|
78
|
+
|
|
79
|
+
`string`
|
|
78
80
|
|
|
79
81
|
The html content of the email.
|
|
80
82
|
|
|
@@ -16,21 +16,11 @@ Create a new instance of EntityStorageMessagingPushNotificationConnector.
|
|
|
16
16
|
|
|
17
17
|
#### Parameters
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
##### options?
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
• **options.loggingConnectorType?**: `string`
|
|
24
|
-
|
|
25
|
-
The type of logging connector to use, defaults to no logging.
|
|
26
|
-
|
|
27
|
-
• **options.messagingDeviceEntryStorageConnectorType?**: `string`
|
|
28
|
-
|
|
29
|
-
The type of entity storage connector to use for the push notifications entries, defaults to "push-notification-device-entry".
|
|
30
|
-
|
|
31
|
-
• **options.messagingMessageEntryStorageConnectorType?**: `string`
|
|
21
|
+
[`IEntityStorageMessagingPushNotificationConnectorConstructorOptions`](../interfaces/IEntityStorageMessagingPushNotificationConnectorConstructorOptions.md)
|
|
32
22
|
|
|
33
|
-
The
|
|
23
|
+
The options for the connector.
|
|
34
24
|
|
|
35
25
|
#### Returns
|
|
36
26
|
|
|
@@ -66,11 +56,15 @@ Registers a device to an specific app in order to send notifications to it.
|
|
|
66
56
|
|
|
67
57
|
#### Parameters
|
|
68
58
|
|
|
69
|
-
|
|
59
|
+
##### applicationId
|
|
60
|
+
|
|
61
|
+
`string`
|
|
70
62
|
|
|
71
63
|
The application address.
|
|
72
64
|
|
|
73
|
-
|
|
65
|
+
##### deviceToken
|
|
66
|
+
|
|
67
|
+
`string`
|
|
74
68
|
|
|
75
69
|
The device token.
|
|
76
70
|
|
|
@@ -94,15 +88,21 @@ Send a push notification to a device.
|
|
|
94
88
|
|
|
95
89
|
#### Parameters
|
|
96
90
|
|
|
97
|
-
|
|
91
|
+
##### deviceAddress
|
|
92
|
+
|
|
93
|
+
`string`
|
|
98
94
|
|
|
99
95
|
The address of the device.
|
|
100
96
|
|
|
101
|
-
|
|
97
|
+
##### title
|
|
98
|
+
|
|
99
|
+
`string`
|
|
102
100
|
|
|
103
101
|
The title of the notification.
|
|
104
102
|
|
|
105
|
-
|
|
103
|
+
##### message
|
|
104
|
+
|
|
105
|
+
`string`
|
|
106
106
|
|
|
107
107
|
The message to send.
|
|
108
108
|
|
|
@@ -16,17 +16,11 @@ Create a new instance of EntityStorageMessagingSmsConnector.
|
|
|
16
16
|
|
|
17
17
|
#### Parameters
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
##### options?
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
• **options.loggingConnectorType?**: `string`
|
|
24
|
-
|
|
25
|
-
The type of logging connector to use, defaults to no logging.
|
|
26
|
-
|
|
27
|
-
• **options.messagingSmsEntryStorageConnectorType?**: `string`
|
|
21
|
+
[`IEntityStorageMessagingSmsConnectorConstructorOptions`](../interfaces/IEntityStorageMessagingSmsConnectorConstructorOptions.md)
|
|
28
22
|
|
|
29
|
-
The
|
|
23
|
+
The options for the connector.
|
|
30
24
|
|
|
31
25
|
#### Returns
|
|
32
26
|
|
|
@@ -62,11 +56,15 @@ Send a SMS message to a phone number.
|
|
|
62
56
|
|
|
63
57
|
#### Parameters
|
|
64
58
|
|
|
65
|
-
|
|
59
|
+
##### phoneNumber
|
|
60
|
+
|
|
61
|
+
`string`
|
|
66
62
|
|
|
67
63
|
The recipient phone number.
|
|
68
64
|
|
|
69
|
-
|
|
65
|
+
##### message
|
|
66
|
+
|
|
67
|
+
`string`
|
|
70
68
|
|
|
71
69
|
The message to send.
|
|
72
70
|
|
|
@@ -6,19 +6,25 @@ Initialize the schema for the messaging connector entity storage.
|
|
|
6
6
|
|
|
7
7
|
## Parameters
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
### options?
|
|
10
10
|
|
|
11
11
|
The options for the initialisation.
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
#### email
|
|
14
|
+
|
|
15
|
+
`boolean`
|
|
14
16
|
|
|
15
17
|
Should we register email schemas.
|
|
16
18
|
|
|
17
|
-
|
|
19
|
+
#### sms
|
|
20
|
+
|
|
21
|
+
`boolean`
|
|
18
22
|
|
|
19
23
|
Should we register sms schemas.
|
|
20
24
|
|
|
21
|
-
|
|
25
|
+
#### pushNotification
|
|
26
|
+
|
|
27
|
+
`boolean`
|
|
22
28
|
|
|
23
29
|
Should we register push notification schemas.
|
|
24
30
|
|
package/docs/reference/index.md
CHANGED
|
@@ -10,6 +10,12 @@
|
|
|
10
10
|
- [EntityStorageMessagingPushNotificationConnector](classes/EntityStorageMessagingPushNotificationConnector.md)
|
|
11
11
|
- [EntityStorageMessagingSmsConnector](classes/EntityStorageMessagingSmsConnector.md)
|
|
12
12
|
|
|
13
|
+
## Interfaces
|
|
14
|
+
|
|
15
|
+
- [IEntityStorageMessagingEmailConnectorConstructorOptions](interfaces/IEntityStorageMessagingEmailConnectorConstructorOptions.md)
|
|
16
|
+
- [IEntityStorageMessagingPushNotificationConnectorConstructorOptions](interfaces/IEntityStorageMessagingPushNotificationConnectorConstructorOptions.md)
|
|
17
|
+
- [IEntityStorageMessagingSmsConnectorConstructorOptions](interfaces/IEntityStorageMessagingSmsConnectorConstructorOptions.md)
|
|
18
|
+
|
|
13
19
|
## Functions
|
|
14
20
|
|
|
15
21
|
- [initSchema](functions/initSchema.md)
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Interface: IEntityStorageMessagingEmailConnectorConstructorOptions
|
|
2
|
+
|
|
3
|
+
Options for the entity storage messaging email connector.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### loggingConnectorType?
|
|
8
|
+
|
|
9
|
+
> `optional` **loggingConnectorType**: `string`
|
|
10
|
+
|
|
11
|
+
The type of logging connector to use, defaults to no logging.
|
|
12
|
+
|
|
13
|
+
***
|
|
14
|
+
|
|
15
|
+
### messagingEmailEntryStorageConnectorType?
|
|
16
|
+
|
|
17
|
+
> `optional` **messagingEmailEntryStorageConnectorType**: `string`
|
|
18
|
+
|
|
19
|
+
The type of entity storage connector to use for the email entries.
|
|
20
|
+
|
|
21
|
+
#### Default
|
|
22
|
+
|
|
23
|
+
```ts
|
|
24
|
+
email-entry
|
|
25
|
+
```
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Interface: IEntityStorageMessagingPushNotificationConnectorConstructorOptions
|
|
2
|
+
|
|
3
|
+
Options for the entity storage messaging push notification connector.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### loggingConnectorType?
|
|
8
|
+
|
|
9
|
+
> `optional` **loggingConnectorType**: `string`
|
|
10
|
+
|
|
11
|
+
The type of logging connector to use, defaults to no logging.
|
|
12
|
+
|
|
13
|
+
***
|
|
14
|
+
|
|
15
|
+
### messagingDeviceEntryStorageConnectorType?
|
|
16
|
+
|
|
17
|
+
> `optional` **messagingDeviceEntryStorageConnectorType**: `string`
|
|
18
|
+
|
|
19
|
+
The type of entity storage connector to use for the push notifications entries.
|
|
20
|
+
|
|
21
|
+
#### Default
|
|
22
|
+
|
|
23
|
+
```ts
|
|
24
|
+
push-notification-device-entry
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
***
|
|
28
|
+
|
|
29
|
+
### messagingMessageEntryStorageConnectorType?
|
|
30
|
+
|
|
31
|
+
> `optional` **messagingMessageEntryStorageConnectorType**: `string`
|
|
32
|
+
|
|
33
|
+
The type of entity storage connector to use for the push notifications entries.
|
|
34
|
+
|
|
35
|
+
#### Default
|
|
36
|
+
|
|
37
|
+
```ts
|
|
38
|
+
push-notification-message-entry
|
|
39
|
+
```
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Interface: IEntityStorageMessagingSmsConnectorConstructorOptions
|
|
2
|
+
|
|
3
|
+
Options for the entity storage messaging SMS connector.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### loggingConnectorType?
|
|
8
|
+
|
|
9
|
+
> `optional` **loggingConnectorType**: `string`
|
|
10
|
+
|
|
11
|
+
The type of logging connector to use, defaults to no logging.
|
|
12
|
+
|
|
13
|
+
***
|
|
14
|
+
|
|
15
|
+
### messagingSmsEntryStorageConnectorType?
|
|
16
|
+
|
|
17
|
+
> `optional` **messagingSmsEntryStorageConnectorType**: `string`
|
|
18
|
+
|
|
19
|
+
The type of entity storage connector to use for the sms entries.
|
|
20
|
+
|
|
21
|
+
#### Default
|
|
22
|
+
|
|
23
|
+
```ts
|
|
24
|
+
sms-entry
|
|
25
|
+
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/messaging-connector-entity-storage",
|
|
3
|
-
"version": "0.0.1-next.
|
|
3
|
+
"version": "0.0.1-next.8",
|
|
4
4
|
"description": "Messaging connector implementation using the Entity Storage",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"@twin.org/core": "next",
|
|
18
18
|
"@twin.org/entity": "next",
|
|
19
19
|
"@twin.org/logging-models": "next",
|
|
20
|
-
"@twin.org/messaging-models": "0.0.1-next.
|
|
20
|
+
"@twin.org/messaging-models": "0.0.1-next.8",
|
|
21
21
|
"@twin.org/nameof": "next"
|
|
22
22
|
},
|
|
23
23
|
"main": "./dist/cjs/index.cjs",
|