'Prompting the user asynchronously
I am trying to develop a custom chatbot to replace the interface of a CLI tool. The tool "prompts" the user for input with built-in validation for type and value. This prompting is done asynchronously at various points during the execution.
The CLI tool is built with TypeScript so I'm using the same SDK for compatibility.
When prompting, the tool provides a list of questions (name, type, choice options, default, validation function) which I have been able to integrate with using the WaterfallDialog
although this only works via integration tests but not in the complete bot context where it only asks the first question in the list then resumes the parent dialog.
I am new to building ChatBots and would appreciate some guidance on how this can be done.
Thanks in advance.
Solution 1:[1]
Proactive Messaging might be the answer. Proactive messages can be sent by the bot to users who have previously messaged the bot. The sample's default implementation messages all users, so you would need to also implement user auth and identify users to message them individually.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | AP01 |