Let's say you have a ContactUsDialog
, PizzaOrderDialog
as well as a MyOrderDialog
. The user sends a message like: 'how far along is my pizza order' - How would you know which dialog to start?
public async Task<HttpResponseMessage> Post([FromBody] Activity activity)
{
if (activity != null)
{
switch (activity.GetActivityType())
{
case ActivityTypes.Message:
await Conversation.SendAsync(activity, () => new ContactUsDialg());
await Conversation.SendAsync(activity, () => new PizzaOrderDialog());
await Conversation.SendAsync(activity, () => new MyOrderDialog());
break;
}
return new HttpResponseMessage(System.Net.HttpStatusCode.Accepted);
}