web-chat

refresh Directline token after it got expired

风格不统一 提交于 2021-01-01 02:50:06
问题 I'm applying a token based authentication to bot webchat along with the chat being persisted but facing an issue after the token got expired. Unable to connect to bot. At first I'm generating a token and refreshing for 15 mins and every thing working fine till then. But, when user went offline with no internet connectivity, suppose for around 6-7 hours, due to offline the refresh token post call don't happen and there will be an expired token in the session storage. later than he wanted to

BotFramework V4: how to send an event from the bot and catch it in react WebChat?

隐身守侯 提交于 2020-12-09 04:22:42
问题 I send an event named "locationRequest" from my bot (.NET SDK) Activity activity = new Activity { Type = ActivityTypes.Event, Name = "locationRequest" }; await stepContext.Context.SendActivityAsync(activity, cancellationToken); I want to catch this event in the WebChat client application, based on the minizable-web-chat coded in React, and set a boolean locationRequested to True: const store = createStore({}, ({ dispatch }) => next => action => { if (action.type === 'DIRECT_LINE/CONNECT

How to format adaptive cards like the old version of webchat

非 Y 不嫁゛ 提交于 2020-05-31 03:30:09
问题 The new version of the standard webchat channel ("gemini") stripped out all of the formatting. I was able to replicate most of the old interface via tweaks in the botframework-webchat implementation, but I cannot get the adaptive card formatting to match. With the general formatting I was able to get it close, and the adaptiveCardHostConfig tweaks shown here on Github got a bit closer, but I still can't figure out how to replicate it. Specifically, the chat bubble (which is gray in my

Microsoft BotFramework-WebChat scrolling issues

你离开我真会死。 提交于 2020-05-15 10:13:50
问题 I'm using the microsoft/BotFramework-WebChat, but I'm having problems getting it to scroll properly. Often when the bot responds the user is forced to manually scroll to the bottom of the chat log. I can't find any documentation about hooks that would let me call an API to scroll it. Is there a way to get it so that the chat window scrolls automatically? HTML : <div id="bot-button" style="display:none" > <p id="need-help" class="triangle-isosceles">Hey! Need any help?</p> <div id="bot-open"

BotFramework v4: how to exchange informations with WebChat within ComponentDialog?

限于喜欢 提交于 2020-04-17 20:27:22
问题 I used BotFramework SDK v4 (.NET) and WebChat v4 (React minizable-web-chat) The context is in a ComponentDialog with WaterfallSteps: the bot is sending a ChoicePrompt "Would you like the bot to get your location ? YES/NO" If YES, the bot sends a "locationRequest" event WebChat receives the event and show a GetLocation button When user clicks on the button, it sends the geolocation to the bot and the dialog continue The ComponentDialog: public class FindNearestAgencyDialog : ComponentDialog {

How should a botframework webchat conversation be maintained for over an hour?

白昼怎懂夜的黑 提交于 2020-02-26 03:59:28
问题 I have looked through the documentation for botframework-webchat and have not been able to find any documentation on how conversations over 1 hour should be handled properly. This situation is most likely to occur if a web page is left idle in the background for an extended period of time. The directline connection is maintained as long as the webchat remains active on a web page. The problem occurs after a page refresh. The initial short term solution is to store the relevant conversation