@twin.org/messaging-connector-entity-storage 0.0.2-next.4 → 0.0.2-next.6

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.
@@ -269,7 +269,7 @@ class EntityStorageMessagingEmailConnector {
269
269
  /**
270
270
  * Runtime name for the class.
271
271
  */
272
- CLASS_NAME = "EntityStorageMessagingEmailConnector";
272
+ static CLASS_NAME = "EntityStorageMessagingEmailConnector";
273
273
  /**
274
274
  * The logging component.
275
275
  * @internal
@@ -297,14 +297,14 @@ class EntityStorageMessagingEmailConnector {
297
297
  * @returns True if the email was send successfully, otherwise undefined.
298
298
  */
299
299
  async sendCustomEmail(sender, recipients, subject, content) {
300
- core.Guards.stringValue(this.CLASS_NAME, "sender", sender);
301
- core.Guards.arrayValue(this.CLASS_NAME, "recipients", recipients);
302
- core.Guards.stringValue(this.CLASS_NAME, "subject", subject);
303
- core.Guards.stringValue(this.CLASS_NAME, "content", content);
300
+ core.Guards.stringValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "sender", sender);
301
+ core.Guards.arrayValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "recipients", recipients);
302
+ core.Guards.stringValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "subject", subject);
303
+ core.Guards.stringValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "content", content);
304
304
  try {
305
305
  await this._logging?.log({
306
306
  level: "info",
307
- source: this.CLASS_NAME,
307
+ source: EntityStorageMessagingEmailConnector.CLASS_NAME,
308
308
  ts: Date.now(),
309
309
  message: "emailSending",
310
310
  data: {
@@ -325,7 +325,7 @@ class EntityStorageMessagingEmailConnector {
325
325
  return true;
326
326
  }
327
327
  catch (err) {
328
- throw new core.GeneralError(this.CLASS_NAME, "sendCustomEmailFailed", undefined, err);
328
+ throw new core.GeneralError(EntityStorageMessagingEmailConnector.CLASS_NAME, "sendCustomEmailFailed", undefined, err);
329
329
  }
330
330
  }
331
331
  }
@@ -343,7 +343,7 @@ class EntityStorageMessagingPushNotificationConnector {
343
343
  /**
344
344
  * Runtime name for the class.
345
345
  */
346
- CLASS_NAME = "EntityStorageMessagingPushNotificationConnector";
346
+ static CLASS_NAME = "EntityStorageMessagingPushNotificationConnector";
347
347
  /**
348
348
  * The logging component.
349
349
  * @internal
@@ -375,12 +375,12 @@ class EntityStorageMessagingPushNotificationConnector {
375
375
  * @returns If the device was registered successfully.
376
376
  */
377
377
  async registerDevice(applicationId, deviceToken) {
378
- core.Guards.stringValue(this.CLASS_NAME, "applicationId", applicationId);
379
- core.Guards.stringValue(this.CLASS_NAME, "deviceToken", deviceToken);
378
+ core.Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "applicationId", applicationId);
379
+ core.Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "deviceToken", deviceToken);
380
380
  try {
381
381
  await this._logging?.log({
382
382
  level: "info",
383
- source: this.CLASS_NAME,
383
+ source: EntityStorageMessagingPushNotificationConnector.CLASS_NAME,
384
384
  ts: Date.now(),
385
385
  message: "deviceRegistering"
386
386
  });
@@ -396,7 +396,7 @@ class EntityStorageMessagingPushNotificationConnector {
396
396
  return id;
397
397
  }
398
398
  catch (err) {
399
- throw new core.GeneralError(this.CLASS_NAME, "deviceTokenRegisterFailed", { property: "applicationId", value: applicationId }, err);
399
+ throw new core.GeneralError(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "deviceTokenRegisterFailed", { property: "applicationId", value: applicationId }, err);
400
400
  }
401
401
  }
402
402
  /**
@@ -407,13 +407,13 @@ class EntityStorageMessagingPushNotificationConnector {
407
407
  * @returns If the notification was sent successfully.
408
408
  */
409
409
  async sendSinglePushNotification(deviceAddress, title, message) {
410
- core.Guards.stringValue(this.CLASS_NAME, "deviceAddress", deviceAddress);
411
- core.Guards.stringValue(this.CLASS_NAME, "title", title);
412
- core.Guards.stringValue(this.CLASS_NAME, "message", message);
410
+ core.Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "deviceAddress", deviceAddress);
411
+ core.Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "title", title);
412
+ core.Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "message", message);
413
413
  try {
414
414
  await this._logging?.log({
415
415
  level: "info",
416
- source: this.CLASS_NAME,
416
+ source: EntityStorageMessagingPushNotificationConnector.CLASS_NAME,
417
417
  ts: Date.now(),
418
418
  message: "pushNotificationSending"
419
419
  });
@@ -430,7 +430,7 @@ class EntityStorageMessagingPushNotificationConnector {
430
430
  return true;
431
431
  }
432
432
  catch (err) {
433
- throw new core.GeneralError(this.CLASS_NAME, "sendPushNotificationFailed", { value: deviceAddress }, err);
433
+ throw new core.GeneralError(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "sendPushNotificationFailed", { value: deviceAddress }, err);
434
434
  }
435
435
  }
436
436
  }
@@ -448,7 +448,7 @@ class EntityStorageMessagingSmsConnector {
448
448
  /**
449
449
  * Runtime name for the class.
450
450
  */
451
- CLASS_NAME = "EntityStorageMessagingSmsConnector";
451
+ static CLASS_NAME = "EntityStorageMessagingSmsConnector";
452
452
  /**
453
453
  * The logging component.
454
454
  * @internal
@@ -474,12 +474,12 @@ class EntityStorageMessagingSmsConnector {
474
474
  * @returns If the SMS was sent successfully.
475
475
  */
476
476
  async sendSMS(phoneNumber, message) {
477
- core.Guards.stringValue(this.CLASS_NAME, "phoneNumber", phoneNumber);
478
- core.Guards.stringValue(this.CLASS_NAME, "message", message);
477
+ core.Guards.stringValue(EntityStorageMessagingSmsConnector.CLASS_NAME, "phoneNumber", phoneNumber);
478
+ core.Guards.stringValue(EntityStorageMessagingSmsConnector.CLASS_NAME, "message", message);
479
479
  try {
480
480
  await this._logging?.log({
481
481
  level: "info",
482
- source: this.CLASS_NAME,
482
+ source: EntityStorageMessagingSmsConnector.CLASS_NAME,
483
483
  ts: Date.now(),
484
484
  message: "smsSending"
485
485
  });
@@ -495,7 +495,7 @@ class EntityStorageMessagingSmsConnector {
495
495
  return true;
496
496
  }
497
497
  catch (err) {
498
- throw new core.GeneralError(this.CLASS_NAME, "sendSMSFailed", undefined, err);
498
+ throw new core.GeneralError(EntityStorageMessagingSmsConnector.CLASS_NAME, "sendSMSFailed", undefined, err);
499
499
  }
500
500
  }
501
501
  }
@@ -267,7 +267,7 @@ class EntityStorageMessagingEmailConnector {
267
267
  /**
268
268
  * Runtime name for the class.
269
269
  */
270
- CLASS_NAME = "EntityStorageMessagingEmailConnector";
270
+ static CLASS_NAME = "EntityStorageMessagingEmailConnector";
271
271
  /**
272
272
  * The logging component.
273
273
  * @internal
@@ -295,14 +295,14 @@ class EntityStorageMessagingEmailConnector {
295
295
  * @returns True if the email was send successfully, otherwise undefined.
296
296
  */
297
297
  async sendCustomEmail(sender, recipients, subject, content) {
298
- Guards.stringValue(this.CLASS_NAME, "sender", sender);
299
- Guards.arrayValue(this.CLASS_NAME, "recipients", recipients);
300
- Guards.stringValue(this.CLASS_NAME, "subject", subject);
301
- Guards.stringValue(this.CLASS_NAME, "content", content);
298
+ Guards.stringValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "sender", sender);
299
+ Guards.arrayValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "recipients", recipients);
300
+ Guards.stringValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "subject", subject);
301
+ Guards.stringValue(EntityStorageMessagingEmailConnector.CLASS_NAME, "content", content);
302
302
  try {
303
303
  await this._logging?.log({
304
304
  level: "info",
305
- source: this.CLASS_NAME,
305
+ source: EntityStorageMessagingEmailConnector.CLASS_NAME,
306
306
  ts: Date.now(),
307
307
  message: "emailSending",
308
308
  data: {
@@ -323,7 +323,7 @@ class EntityStorageMessagingEmailConnector {
323
323
  return true;
324
324
  }
325
325
  catch (err) {
326
- throw new GeneralError(this.CLASS_NAME, "sendCustomEmailFailed", undefined, err);
326
+ throw new GeneralError(EntityStorageMessagingEmailConnector.CLASS_NAME, "sendCustomEmailFailed", undefined, err);
327
327
  }
328
328
  }
329
329
  }
@@ -341,7 +341,7 @@ class EntityStorageMessagingPushNotificationConnector {
341
341
  /**
342
342
  * Runtime name for the class.
343
343
  */
344
- CLASS_NAME = "EntityStorageMessagingPushNotificationConnector";
344
+ static CLASS_NAME = "EntityStorageMessagingPushNotificationConnector";
345
345
  /**
346
346
  * The logging component.
347
347
  * @internal
@@ -373,12 +373,12 @@ class EntityStorageMessagingPushNotificationConnector {
373
373
  * @returns If the device was registered successfully.
374
374
  */
375
375
  async registerDevice(applicationId, deviceToken) {
376
- Guards.stringValue(this.CLASS_NAME, "applicationId", applicationId);
377
- Guards.stringValue(this.CLASS_NAME, "deviceToken", deviceToken);
376
+ Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "applicationId", applicationId);
377
+ Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "deviceToken", deviceToken);
378
378
  try {
379
379
  await this._logging?.log({
380
380
  level: "info",
381
- source: this.CLASS_NAME,
381
+ source: EntityStorageMessagingPushNotificationConnector.CLASS_NAME,
382
382
  ts: Date.now(),
383
383
  message: "deviceRegistering"
384
384
  });
@@ -394,7 +394,7 @@ class EntityStorageMessagingPushNotificationConnector {
394
394
  return id;
395
395
  }
396
396
  catch (err) {
397
- throw new GeneralError(this.CLASS_NAME, "deviceTokenRegisterFailed", { property: "applicationId", value: applicationId }, err);
397
+ throw new GeneralError(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "deviceTokenRegisterFailed", { property: "applicationId", value: applicationId }, err);
398
398
  }
399
399
  }
400
400
  /**
@@ -405,13 +405,13 @@ class EntityStorageMessagingPushNotificationConnector {
405
405
  * @returns If the notification was sent successfully.
406
406
  */
407
407
  async sendSinglePushNotification(deviceAddress, title, message) {
408
- Guards.stringValue(this.CLASS_NAME, "deviceAddress", deviceAddress);
409
- Guards.stringValue(this.CLASS_NAME, "title", title);
410
- Guards.stringValue(this.CLASS_NAME, "message", message);
408
+ Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "deviceAddress", deviceAddress);
409
+ Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "title", title);
410
+ Guards.stringValue(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "message", message);
411
411
  try {
412
412
  await this._logging?.log({
413
413
  level: "info",
414
- source: this.CLASS_NAME,
414
+ source: EntityStorageMessagingPushNotificationConnector.CLASS_NAME,
415
415
  ts: Date.now(),
416
416
  message: "pushNotificationSending"
417
417
  });
@@ -428,7 +428,7 @@ class EntityStorageMessagingPushNotificationConnector {
428
428
  return true;
429
429
  }
430
430
  catch (err) {
431
- throw new GeneralError(this.CLASS_NAME, "sendPushNotificationFailed", { value: deviceAddress }, err);
431
+ throw new GeneralError(EntityStorageMessagingPushNotificationConnector.CLASS_NAME, "sendPushNotificationFailed", { value: deviceAddress }, err);
432
432
  }
433
433
  }
434
434
  }
@@ -446,7 +446,7 @@ class EntityStorageMessagingSmsConnector {
446
446
  /**
447
447
  * Runtime name for the class.
448
448
  */
449
- CLASS_NAME = "EntityStorageMessagingSmsConnector";
449
+ static CLASS_NAME = "EntityStorageMessagingSmsConnector";
450
450
  /**
451
451
  * The logging component.
452
452
  * @internal
@@ -472,12 +472,12 @@ class EntityStorageMessagingSmsConnector {
472
472
  * @returns If the SMS was sent successfully.
473
473
  */
474
474
  async sendSMS(phoneNumber, message) {
475
- Guards.stringValue(this.CLASS_NAME, "phoneNumber", phoneNumber);
476
- Guards.stringValue(this.CLASS_NAME, "message", message);
475
+ Guards.stringValue(EntityStorageMessagingSmsConnector.CLASS_NAME, "phoneNumber", phoneNumber);
476
+ Guards.stringValue(EntityStorageMessagingSmsConnector.CLASS_NAME, "message", message);
477
477
  try {
478
478
  await this._logging?.log({
479
479
  level: "info",
480
- source: this.CLASS_NAME,
480
+ source: EntityStorageMessagingSmsConnector.CLASS_NAME,
481
481
  ts: Date.now(),
482
482
  message: "smsSending"
483
483
  });
@@ -493,7 +493,7 @@ class EntityStorageMessagingSmsConnector {
493
493
  return true;
494
494
  }
495
495
  catch (err) {
496
- throw new GeneralError(this.CLASS_NAME, "sendSMSFailed", undefined, err);
496
+ throw new GeneralError(EntityStorageMessagingSmsConnector.CLASS_NAME, "sendSMSFailed", undefined, err);
497
497
  }
498
498
  }
499
499
  }
@@ -11,7 +11,7 @@ export declare class EntityStorageMessagingEmailConnector implements IMessagingE
11
11
  /**
12
12
  * Runtime name for the class.
13
13
  */
14
- readonly CLASS_NAME: string;
14
+ static readonly CLASS_NAME: string;
15
15
  /**
16
16
  * Create a new instance of EntityStorageMessagingEmailConnector.
17
17
  * @param options The options for the connector.
@@ -11,7 +11,7 @@ export declare class EntityStorageMessagingPushNotificationConnector implements
11
11
  /**
12
12
  * Runtime name for the class.
13
13
  */
14
- readonly CLASS_NAME: string;
14
+ static readonly CLASS_NAME: string;
15
15
  /**
16
16
  * Create a new instance of EntityStorageMessagingPushNotificationConnector.
17
17
  * @param options The options for the connector.
@@ -11,7 +11,7 @@ export declare class EntityStorageMessagingSmsConnector implements IMessagingSms
11
11
  /**
12
12
  * Runtime name for the class.
13
13
  */
14
- readonly CLASS_NAME: string;
14
+ static readonly CLASS_NAME: string;
15
15
  /**
16
16
  * Create a new instance of EntityStorageMessagingSmsConnector.
17
17
  * @param options The options for the connector.
package/docs/changelog.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # @twin.org/messaging-connector-entity-storage - Changelog
2
2
 
3
+ ## [0.0.2-next.6](https://github.com/twinfoundation/messaging/compare/messaging-connector-entity-storage-v0.0.2-next.5...messaging-connector-entity-storage-v0.0.2-next.6) (2025-10-09)
4
+
5
+
6
+ ### Features
7
+
8
+ * add validate-locales ([5eeff9b](https://github.com/twinfoundation/messaging/commit/5eeff9b9bf6cecf93b249b56c4bb74b4c5bf86c9))
9
+
10
+
11
+ ### Dependencies
12
+
13
+ * The following workspace dependencies were updated
14
+ * dependencies
15
+ * @twin.org/messaging-models bumped from 0.0.2-next.5 to 0.0.2-next.6
16
+
17
+ ## [0.0.2-next.5](https://github.com/twinfoundation/messaging/compare/messaging-connector-entity-storage-v0.0.2-next.4...messaging-connector-entity-storage-v0.0.2-next.5) (2025-10-02)
18
+
19
+
20
+ ### Miscellaneous Chores
21
+
22
+ * **messaging-connector-entity-storage:** Synchronize repo versions
23
+
24
+
25
+ ### Dependencies
26
+
27
+ * The following workspace dependencies were updated
28
+ * dependencies
29
+ * @twin.org/messaging-models bumped from 0.0.2-next.4 to 0.0.2-next.5
30
+
3
31
  ## [0.0.2-next.4](https://github.com/twinfoundation/messaging/compare/messaging-connector-entity-storage-v0.0.2-next.3...messaging-connector-entity-storage-v0.0.2-next.4) (2025-09-29)
4
32
 
5
33
 
@@ -38,14 +38,10 @@ The namespace for the connector.
38
38
 
39
39
  ### CLASS\_NAME
40
40
 
41
- > `readonly` **CLASS\_NAME**: `string`
41
+ > `readonly` `static` **CLASS\_NAME**: `string`
42
42
 
43
43
  Runtime name for the class.
44
44
 
45
- #### Implementation of
46
-
47
- `IMessagingEmailConnector.CLASS_NAME`
48
-
49
45
  ## Methods
50
46
 
51
47
  ### sendCustomEmail()
@@ -38,14 +38,10 @@ The namespace for the connector.
38
38
 
39
39
  ### CLASS\_NAME
40
40
 
41
- > `readonly` **CLASS\_NAME**: `string`
41
+ > `readonly` `static` **CLASS\_NAME**: `string`
42
42
 
43
43
  Runtime name for the class.
44
44
 
45
- #### Implementation of
46
-
47
- `IMessagingPushNotificationsConnector.CLASS_NAME`
48
-
49
45
  ## Methods
50
46
 
51
47
  ### registerDevice()
@@ -38,14 +38,10 @@ The namespace for the connector.
38
38
 
39
39
  ### CLASS\_NAME
40
40
 
41
- > `readonly` **CLASS\_NAME**: `string`
41
+ > `readonly` `static` **CLASS\_NAME**: `string`
42
42
 
43
43
  Runtime name for the class.
44
44
 
45
- #### Implementation of
46
-
47
- `IMessagingSmsConnector.CLASS_NAME`
48
-
49
45
  ## Methods
50
46
 
51
47
  ### sendSMS()
package/locales/en.json CHANGED
@@ -1,19 +1,26 @@
1
1
  {
2
2
  "info": {
3
- "entityStorageMessagingConnector": {
4
- "emailSending": "Sending email",
5
- "smsSending": "Sending SMS",
3
+ "entityStorageMessagingSmsConnector": {
4
+ "smsSending": "Sending SMS"
5
+ },
6
+ "entityStorageMessagingPushNotificationConnector": {
6
7
  "deviceRegistering": "Registering device",
7
8
  "pushNotificationSending": "Sending push notification"
9
+ },
10
+ "entityStorageMessagingEmailConnector": {
11
+ "emailSending": "Sending email"
8
12
  }
9
13
  },
10
14
  "error": {
11
- "entityStorageMessagingConnector": {
12
- "sendCustomEmailFailed": "Failed to send custom email",
13
- "readEmailEntryFailed": "Failed to read email entry",
14
- "sendSMSFailed": "Failed to send SMS",
15
+ "entityStorageMessagingSmsConnector": {
16
+ "sendSMSFailed": "Failed to send SMS"
17
+ },
18
+ "entityStorageMessagingPushNotificationConnector": {
15
19
  "deviceTokenRegisterFailed": "Failed to register device token",
16
20
  "sendPushNotificationFailed": "Failed to send push notification"
21
+ },
22
+ "entityStorageMessagingEmailConnector": {
23
+ "sendCustomEmailFailed": "Failed to send custom email"
17
24
  }
18
25
  }
19
26
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twin.org/messaging-connector-entity-storage",
3
- "version": "0.0.2-next.4",
3
+ "version": "0.0.2-next.6",
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.2-next.4",
20
+ "@twin.org/messaging-models": "0.0.2-next.6",
21
21
  "@twin.org/nameof": "next"
22
22
  },
23
23
  "main": "./dist/cjs/index.cjs",
@@ -37,5 +37,24 @@
37
37
  "dist/types",
38
38
  "locales",
39
39
  "docs"
40
- ]
40
+ ],
41
+ "keywords": [
42
+ "twin",
43
+ "trade",
44
+ "iota",
45
+ "framework",
46
+ "blockchain",
47
+ "messaging",
48
+ "entity",
49
+ "storage",
50
+ "persistence",
51
+ "database",
52
+ "connector",
53
+ "adapter",
54
+ "integration"
55
+ ],
56
+ "bugs": {
57
+ "url": "git+https://github.com/twinfoundation/messaging/issues"
58
+ },
59
+ "homepage": "https://twindev.org"
41
60
  }