简体   繁体   中英

Can I trigger a proactive message in Bot Framework Emulator only by notify endpoint?

I am trying to build a simple Microsoft Bot Framework v4 bot with Python that will send me a proactive message using the Bot Framework Emulator. For example, when a deadline for submitting a work is less than a day. I had a look in the documentation and found the following sentence: "The application logic for initiating a proactive message is outside the scope of the SDK. For this sample, a notify endpoint, in addition to a standard messages endpoint, is used to trigger the proactive turn.". Does this mean I need to define a method that triggers the notify endpoint to send a proactive message or how else could I trigger a proactive message?

Yes, In addition to the standard api/messages/ endpoint, you will need api/notify endpoint and trigger the proactive turn.

Here is a sample bot with a messages endpoint, and an additional notify endpoint that is used to send proactive messages to the user.

Here is a C# .NET Core proactive message sample project

Check out BotBuilder-Samples repo for more samples.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM