I have a PizzaBot. After getting the order I save the data to the UserState. After that the user gets a button(ActionTypes.OpenUrl) to pay the order on a different system. Everything works fine till now.
However, when the payment service call my api, I cannot get the UserState data anymore. I have tried to send a Proactive notification, the "You have paid successfully" message is being shown, but I cannot retrieve UserData.
I get my conversation id conversationReference, but I have no idea what I should call in the BotCallback to resume to the conversation.
foreach (var conversationReference in _conversationReferences.Values)
{
await ((BotAdapter)_adapter).ContinueConversationAsync(_appId, conversationReference, BotCallback, default);
}
Do you have any example of that for me?
I have fixed this issue thanks to George.
On the UserState documentation page this is written:
User state is available in any turn that the bot is conversing with that user on that channel, regardless of the conversation.
This means if my NotificationController is called the UserState is there somewhere. So, I have created a proactive MainDialog on the BotCallback with an option: see: Starting A Dialog From From A Proactive Message and read UserState data if the option is filled and coming from my NotificationController