2016-12-30 79 views
1

我想調用watson-conversation響應中的webservice,並將webservice返回的結果顯示給客戶端。如何從watson會話中調用webservice?

例如,如果我問沃森這個問題: 紐約2016-12-30天氣如何?

然後watson會調用天氣相關的webservice並將參數city(紐約)和date(2016-12-30)傳遞給webservice,webservice會返回消息「It is sunny,temperature is 30」。

客戶將得到「陽光充足,溫度30」作爲答案。

+0

見http://stackoverflow.com/questions/40263747/how-to-make-watson-conversation-api-invoke-a-web-application-url-when-user-enter – Dudi

回答

1

您可能想簽出使用Watson Conversation和Weather API構建的天氣機器人。 https://github.com/watson-developer-cloud/text-bot

+0

是否有可能調用部署在nodejs中的Watson對話應用程序中的SOAP API,[用於此示例](https://github.com/watson-developer-cloud/conversation-simple)? –