botframework-sdk icon indicating copy to clipboard operation
botframework-sdk copied to clipboard

Waterfall Model in a Proactive Bot

Open officialdharam opened this issue 10 years ago • 3 comments

I have written a proactive bot, which works fine. Unfortunately, I am not able to get the waterfall model working. Somehow, it never goes to the waterfall step after user responds back to a Prompt.

Here is the code:

function notify(mode, oid){ 
   if(mode == "skype"){
      bot.beginDialog({
    to: { "address": "8:live:officialdharam", "channelId": "skype" , "id": "7JitRpa2At5", "isBot": false},
    from: { "address": "notificationbot", "channelId": "skype", "id": "notificationbot", "isBot": true},
    text: "Review Usecase"
     }, '/');
  }
}


dialog.on('Review', [function(session, args) {
    Util.logger.log('info', 'Received a Review intent with args %s', args);
    builder.Prompts.text(session, "We just received an urgent order. Would you like to review it?");    
}, function(session, results){
    console.log(results.response);
}]);

When my nodejs program starts, it invokes the notify method, which begins a dialog and resolves to the Review intent.

This makes it prompt a message. When I respond back to the message in skype, it never prints the response.

Any help in this regard would be highly appreciated. Thanks

officialdharam avatar Jun 13 '16 16:06 officialdharam

Closing this issue due to age. @officialdharam - please open a new issue if this issue is not fixed and needs further discussion. Thanks!

v-thgratMSGit avatar Jul 25 '16 19:07 v-thgratMSGit

There was a bug preventing this from working correctly. Please try again with v3.2.3. I'll re-open the issue if it's still not working.

Stevenic avatar Aug 06 '16 20:08 Stevenic

@Stevenic this is a good news... Thanks a lot of your help!

officialdharam avatar Aug 07 '16 05:08 officialdharam