0

i)What's the workflow of an Azure Bot Framework Program that is written in Node.js?

ii)Does it always include a Dialog to run through? Or is there any other way to run my program without Dialogs?

Nicolas R
  • 13,812
  • 2
  • 28
  • 57

1 Answers1

0

i)What's the workflow of an Azure Bot Framework Program that is written in Node.js?

Generally speaking, bot applications require botbuilder sdk, and this sdk in node.js is kinda built on Expressjs or Restifyjs middlewares. The bot's connector need to listen a specific route for capturing incoming requests.

As server.post('/api/messages', connector.listen()); is required in bot application.

And we can have a glance from listen() which wraps the middleware, if you are familiar with Expressjs or Restifyjs.

After being handled inside bot application, the botbuilder sdk will post the response activity message via DirectLine Restful API to Bot Connector service, which will dispatch the activity to your channel. Refer to the postMessage() source code for more details.

ii)Does it always include a Dialog to run through? Or is there any other way to run my program without Dialogs?

Yes, always.

Gary Liu
  • 13,758
  • 1
  • 17
  • 32