How is BotFramework Emulator talking to locally hosted bot without BotConnector registration?

309 views Asked by At

As far as I understand, the Emulator is using the DirectLine API to talk to the locally hosted bot, i.e. with http://localhost:3978/api/messages.

How is this possible? To use DirectLine API one needs to

  1. register its bot in the BotConnector
  2. provide the Messaging endpoint
  3. enable DirectLine API and generate DirectLine API secret

The emulator fulfills only the messaging endpoint requirement (http://localhost:3978/api/messages) but still it works perfectly. Why do other channels require BotConnector registration?

1

There are 1 answers

0
Hola On

So, based on the podcast linked in the GitHub issue provided by @Ezequiel Jadib, the emulator is emulating BotConnector services and as such can directly communicate to the locally hosted bot.

Dan Driscoll explains it would be possible to avoid DiretLine API and talk directly to the bot, though this would mean operating outside the BotFramework ecosystem and you would need your way to deal with security (and probably other things as well)