@botonic/plugin-hubtype-analytics 0.28.2-alpha.3 → 0.28.2-alpha.4

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.
@@ -1,16 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.HtEvent = void 0;
4
- /* eslint-disable @typescript-eslint/naming-convention */
5
- const types_1 = require("../types");
6
- const excludedEvents = [
7
- types_1.EventAction.FeedbackCase,
8
- types_1.EventAction.FeedbackConversation,
9
- types_1.EventAction.FeedbackKnowledgebase,
10
- types_1.EventAction.FeedbackWebview,
11
- types_1.EventAction.WebviewStep,
12
- types_1.EventAction.WebviewEnd,
13
- ];
14
4
  class HtEvent {
15
5
  constructor(event, requestData) {
16
6
  this.chat_id = requestData.userId;
@@ -18,9 +8,7 @@ class HtEvent {
18
8
  this.chat_country = requestData.country;
19
9
  this.format_version = 2;
20
10
  this.action = event.action;
21
- if (!excludedEvents.includes(event.action)) {
22
- this.bot_interaction_id = requestData.botInteractionId;
23
- }
11
+ this.bot_interaction_id = requestData.botInteractionId;
24
12
  }
25
13
  }
26
14
  exports.HtEvent = HtEvent;
@@ -1 +1 @@
1
- {"version":3,"file":"ht-event.js","sourceRoot":"","sources":["../../../src/event-models/ht-event.ts"],"names":[],"mappings":";;;AAAA,yDAAyD;AACzD,oCAA4E;AAE5E,MAAM,cAAc,GAAG;IACrB,mBAAW,CAAC,YAAY;IACxB,mBAAW,CAAC,oBAAoB;IAChC,mBAAW,CAAC,qBAAqB;IACjC,mBAAW,CAAC,eAAe;IAC3B,mBAAW,CAAC,WAAW;IACvB,mBAAW,CAAC,UAAU;CACvB,CAAA;AAED,MAAa,OAAO;IAWlB,YAAY,KAAmB,EAAE,WAAwB;QACvD,IAAI,CAAC,OAAO,GAAG,WAAW,CAAC,MAAM,CAAA;QACjC,IAAI,CAAC,aAAa,GAAG,WAAW,CAAC,QAAQ,CAAA;QACzC,IAAI,CAAC,YAAY,GAAG,WAAW,CAAC,OAAO,CAAA;QACvC,IAAI,CAAC,cAAc,GAAG,CAAC,CAAA;QACvB,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAA;QAE1B,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE;YAC1C,IAAI,CAAC,kBAAkB,GAAG,WAAW,CAAC,gBAAgB,CAAA;SACvD;IACH,CAAC;CACF;AAtBD,0BAsBC"}
1
+ {"version":3,"file":"ht-event.js","sourceRoot":"","sources":["../../../src/event-models/ht-event.ts"],"names":[],"mappings":";;;AAGA,MAAa,OAAO;IAWlB,YAAY,KAAmB,EAAE,WAAwB;QACvD,IAAI,CAAC,OAAO,GAAG,WAAW,CAAC,MAAM,CAAA;QACjC,IAAI,CAAC,aAAa,GAAG,WAAW,CAAC,QAAQ,CAAA;QACzC,IAAI,CAAC,YAAY,GAAG,WAAW,CAAC,OAAO,CAAA;QACvC,IAAI,CAAC,cAAc,GAAG,CAAC,CAAA;QACvB,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAA;QAC1B,IAAI,CAAC,kBAAkB,GAAG,WAAW,CAAC,gBAAgB,CAAA;IACxD,CAAC;CACF;AAnBD,0BAmBC"}
@@ -1,13 +1,3 @@
1
- /* eslint-disable @typescript-eslint/naming-convention */
2
- import { EventAction } from '../types';
3
- const excludedEvents = [
4
- EventAction.FeedbackCase,
5
- EventAction.FeedbackConversation,
6
- EventAction.FeedbackKnowledgebase,
7
- EventAction.FeedbackWebview,
8
- EventAction.WebviewStep,
9
- EventAction.WebviewEnd,
10
- ];
11
1
  export class HtEvent {
12
2
  constructor(event, requestData) {
13
3
  this.chat_id = requestData.userId;
@@ -15,9 +5,7 @@ export class HtEvent {
15
5
  this.chat_country = requestData.country;
16
6
  this.format_version = 2;
17
7
  this.action = event.action;
18
- if (!excludedEvents.includes(event.action)) {
19
- this.bot_interaction_id = requestData.botInteractionId;
20
- }
8
+ this.bot_interaction_id = requestData.botInteractionId;
21
9
  }
22
10
  }
23
11
  //# sourceMappingURL=ht-event.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ht-event.js","sourceRoot":"","sources":["../../../src/event-models/ht-event.ts"],"names":[],"mappings":"AAAA,yDAAyD;AACzD,OAAO,EAAE,WAAW,EAAwC,MAAM,UAAU,CAAA;AAE5E,MAAM,cAAc,GAAG;IACrB,WAAW,CAAC,YAAY;IACxB,WAAW,CAAC,oBAAoB;IAChC,WAAW,CAAC,qBAAqB;IACjC,WAAW,CAAC,eAAe;IAC3B,WAAW,CAAC,WAAW;IACvB,WAAW,CAAC,UAAU;CACvB,CAAA;AAED,MAAM,OAAO,OAAO;IAWlB,YAAY,KAAmB,EAAE,WAAwB;QACvD,IAAI,CAAC,OAAO,GAAG,WAAW,CAAC,MAAM,CAAA;QACjC,IAAI,CAAC,aAAa,GAAG,WAAW,CAAC,QAAQ,CAAA;QACzC,IAAI,CAAC,YAAY,GAAG,WAAW,CAAC,OAAO,CAAA;QACvC,IAAI,CAAC,cAAc,GAAG,CAAC,CAAA;QACvB,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAA;QAE1B,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE;YAC1C,IAAI,CAAC,kBAAkB,GAAG,WAAW,CAAC,gBAAgB,CAAA;SACvD;IACH,CAAC;CACF"}
1
+ {"version":3,"file":"ht-event.js","sourceRoot":"","sources":["../../../src/event-models/ht-event.ts"],"names":[],"mappings":"AAGA,MAAM,OAAO,OAAO;IAWlB,YAAY,KAAmB,EAAE,WAAwB;QACvD,IAAI,CAAC,OAAO,GAAG,WAAW,CAAC,MAAM,CAAA;QACjC,IAAI,CAAC,aAAa,GAAG,WAAW,CAAC,QAAQ,CAAA;QACzC,IAAI,CAAC,YAAY,GAAG,WAAW,CAAC,OAAO,CAAA;QACvC,IAAI,CAAC,cAAc,GAAG,CAAC,CAAA;QACvB,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,CAAA;QAC1B,IAAI,CAAC,kBAAkB,GAAG,WAAW,CAAC,gBAAgB,CAAA;IACxD,CAAC;CACF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botonic/plugin-hubtype-analytics",
3
- "version": "0.28.2-alpha.3",
3
+ "version": "0.28.2-alpha.4",
4
4
  "description": "Plugin for tracking in the Hubtype backend to see the results in the Hubtype Dashbord",
5
5
  "main": "./lib/cjs/index.js",
6
6
  "module": "./lib/esm/index.js",
@@ -14,7 +14,7 @@
14
14
  },
15
15
  "dependencies": {
16
16
  "@babel/runtime": "^7.21.0",
17
- "@botonic/core": "0.28.2-alpha.1",
17
+ "@botonic/core": "0.28.2-alpha.2",
18
18
  "axios": "^1.7.2"
19
19
  },
20
20
  "devDependencies": {
@@ -1,15 +1,6 @@
1
1
  /* eslint-disable @typescript-eslint/naming-convention */
2
2
  import { EventAction, EventType, HtEventProps, RequestData } from '../types'
3
3
 
4
- const excludedEvents = [
5
- EventAction.FeedbackCase,
6
- EventAction.FeedbackConversation,
7
- EventAction.FeedbackKnowledgebase,
8
- EventAction.FeedbackWebview,
9
- EventAction.WebviewStep,
10
- EventAction.WebviewEnd,
11
- ]
12
-
13
4
  export class HtEvent {
14
5
  chat_id?: string
15
6
  type: EventType
@@ -27,9 +18,6 @@ export class HtEvent {
27
18
  this.chat_country = requestData.country
28
19
  this.format_version = 2
29
20
  this.action = event.action
30
-
31
- if (!excludedEvents.includes(event.action)) {
32
- this.bot_interaction_id = requestData.botInteractionId
33
- }
21
+ this.bot_interaction_id = requestData.botInteractionId
34
22
  }
35
23
  }