ibm-cloudibm-watsonnode-redwatson-conversation

can't see response different from "text" as output from a watson assistant node in node-red


first of all let me tell you that I'm asking my first question here, so please forgive me if I do something wrong.

node response different from text, working on watson tryout environement

my node-red flow using watson assistant

I have a couple nodes using response types different from "text", i.e. using images and options, as shown in first picture I linked. When my flow (see pic 2) in node-red activates such a node response from the chatbot assistant, I do not have any output from the node.

Here is the json for one of the nodes I can't get coming through.

{"type":"standard",
 "title":"analisi sintomi computer",
 "output":{"generic":[{
           "title":"Quale modello di PC stai utilizzando?",
 "source":"http://pcsupport.lenovo.com/~/media/images/staticpages/thinkpad_ss.ashx?la=en",
"description":"puoi trovare il codice qui",
"response_type":"image"},
{"title":"Quale modello di PC stai utilizzando?","options":[{"label":"T470","value":{"input":{"text":"T470"}}},
{"label":"T450","value":{"input":{"text":"T450"}}},
{"label":"T230","value":{"input":{"text":"T230"}}}],"description":"(vedi qui sopra come individuare il codice esatto)","response_type":"option"},
{"values":[],"response_type":"text","selection_policy":"sequential"}]},"parent":"node_1_1536313247338","metadata":{},
"conditions":"$tipoDevice:computer","dialog_node":"node_2_1536588442374"}

Is it an issue with the node in node-red or am I missing something? thanks for your help


Solution

  • To me it seems like the Node for Watson Assistant / Watson Conversation is not using the required API version to return the multimedia responses:
    https://github.com/watson-developer-cloud/node-red-node-watson/blob/master/services/conversation/v1.js

    That file has the version "2018-02-16" encoded. However, you need API version "2018-07-10" for that, see the Release Notes.

    You can set the API version as msg.params.version.