Typing indicator not showing for message and entity nodes sometimes

There were some issues reported where typing Indicator was not showing up.
image

Issue 1: The typing Indicator shows up for some time but stops before the message is actually displayed.

Solution: In the websdk code, refer to web-sdk (UI/chatWindow.js => renderMessage function ) web-kore-sdk/chatWindow.js at master · Koredotcom/web-kore-sdk · GitHub

Issue 2: For a bot flow like below:


The typing indicator time-out is set to 30 seconds ( as mentioned in the solution of #1 ) but after the message node, it stops and even though the bot is busy before showing the entity node, it does not show typing indicator.

Solution: The web-SDK shows typing indicator only between when the user types a message and till the time it gets a response (or its timeout - whichever is earlier). The websdk will need to be instructed to wait for the next message. A special message node is required here. Check the “delayedTemplate” message in the screenshot above.

The below code needs to be used. When the web-SDK receives “template_type”: “wait_for_response” it keeps showing the typing indicator.

var message = { "type": "template", "payload": { "template_type": "wait_for_response" } } print(JSON.stringify(message));

Then the typing indicator will continue to show even after message0001 is delivered and the bot is waiting for the service node to finish and until the entity message is shown.

Thanks, @rajasekhar.balla for the solution.

2 Likes