@tiledesk/tiledesk-tybot-connector 0.2.62-rc3 → 0.2.62

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/CHANGELOG.md CHANGED
@@ -5,8 +5,12 @@
5
5
  available on:
6
6
  ▶️ https://www.npmjs.com/package/@tiledesk/tiledesk-tybot-connector
7
7
 
8
- # v0.2.62-rc3
9
- - Added n8n action (webrequest)
8
+
9
+ # v0.2.62
10
+ - Whatsapp fix (transcript error whitout "senderFullname")
11
+
12
+ # v0.2.62-rc4
13
+ - Whatsapp fix (transcript error whitout "senderFullname")
10
14
 
11
15
  # v0.2.62-rc1
12
16
  - Added VXML actions (speech_form, play_prompt)
@@ -32,9 +36,6 @@ available on:
32
36
  - added flow attribute "decodedCustomJWT"
33
37
 
34
38
  # v0.2.57
35
- - Changed env variables for AskGPT actions
36
- - Added support for temperature, top_k, max_tokens and context for AskGPTV2 action
37
- - Added support for context with variables for GptTask action
38
39
  - fixed catching reply error in index.js: reply = await chatbot.replyToMessage(message);
39
40
  - Added context and top_k parameter in DirAskGPTV2
40
41
 
@@ -335,8 +335,11 @@ class TiledeskChatbotUtil {
335
335
  }
336
336
 
337
337
  static async updateConversationTranscript(chatbot, message) {
338
+ if (!message || !message.senderFullname) { // not a conversation, can it be an Automation invocation?
339
+ return null;
340
+ }
341
+
338
342
  const chatbot_name = chatbot.bot.name.trim();
339
-
340
343
  if (message && message.text && message.text.trim() !== "" && message.sender !== "_tdinternal" && !this.isHiddenMessage(message)) {
341
344
  let transcript = await chatbot.getParameter("transcript");
342
345
  // console.log("transcript got:", transcript);
@@ -354,6 +357,9 @@ class TiledeskChatbotUtil {
354
357
  }
355
358
 
356
359
  function name_of(message, chatbot_name) {
360
+ if (!message.senderFullname) {
361
+ return null;
362
+ }
357
363
  let fullName = message.senderFullname;
358
364
  if (fullName.trim() === chatbot_name) {
359
365
  fullName = "bot:" + fullName;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tiledesk/tiledesk-tybot-connector",
3
- "version": "0.2.62-rc3",
3
+ "version": "0.2.62",
4
4
  "description": "Tiledesk Tybot connector",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -727,19 +727,6 @@ class DirectivesChatbotPlug {
727
727
  this.process(next_dir);
728
728
  })
729
729
  }
730
- else if (directive_name === Directives.N8N) {
731
- new DirWebRequestV2(context).execute(directive, async (stop) => {
732
- if (context.log) { console.log("stop on condition?", stop);}
733
- if (stop == true) {
734
- if (context.log) { console.log("Stopping Actions on:", JSON.stringify(directive));}
735
- this.theend();
736
- }
737
- else {
738
- let next_dir = await this.nextDirective(this.directives);
739
- this.process(next_dir);
740
- }
741
- });
742
- }
743
730
  else {
744
731
  //console.log("Unhandled Post-message Directive:", directive_name);
745
732
  let next_dir = await this.nextDirective(this.directives);
@@ -40,7 +40,6 @@ class Directives {
40
40
  static HUBSPOT = 'hubspot';
41
41
  static CUSTOMERIO = 'customerio';
42
42
  static BREVO = 'brevo';
43
- static N8N = 'n8n';
44
43
  /**** VOICE CHANNEL ****/
45
44
  static DTMF_FORM = 'dtmf_form';
46
45
  static DTMF_MENU = 'dtmf_menu';