microsoft / BotFramework-Services

Microsoft Bot Framework Services
Creative Commons Attribution 4.0 International
38 stars 11 forks source link

Guidance needed for DirectLine Integration with Bot Composer #331

Closed jacobpoly73 closed 2 years ago

jacobpoly73 commented 2 years ago

I am hoping to get some guidance on implementing DirectLine with a Bot Composer generated Bot. I haven't got any responses elsewhere and so was hoping maybe I could get some help on this forum.

I would like to add the DirectLine Token integration into my Bot Composer project so that I can retrieve tokens dynamically and not have to hardcode the Bot Secret into the Embed Code. Few things,

How do I go about this? There is some guidance when using the Bot API Framework here -> https://docs.microsoft.com/en-us/azure/bot-service/rest-api/bot-framework-rest-direct-line-3-0-authentication?view=azure-bot-service-4.0#generate-token

The example Code shows a HomeController that does communication with the DirectLine API to generate token. I have added this Controller to my Bot Composer project via Visual studio.

How do I integrate this within the bot flow process now?

Thanks in advance, Jake.

InfinytRam commented 2 years ago

Hi @jacobpoly73,

Have you had a chance to follow Direct Line Token Sample documentation? This sample demonstrates how to integrate Web Chat in C# and JavaScript.

Let me know if the above doc helped.

InfinytRam commented 2 years ago

Closing due to inactivity, feel free to re-open if you are still having issues.