Context with Teams Toolkit (MS Teams Bot)- all information is gone on bot update

76 views Asked by At

So, im building a teams bot using teams toolkit extension in vs code. This is a organization internal use application and the issue that im running into is that whenever i update the bot it loses the context for all the members. The only way to get it back is to message the bot in the general channel with everyone in it. Is there a workaround here? I can imagine im the first one with this problem. My understanding of the issue is that with each update, the cache is cleared and by messaging in the general channel we are generating a context for each user (aka the member object i am targetting to send the notification)

**First time posting- please let me know if more information is required

I have already tried storing the conversation_id and conversationReference object to target and send notifications. I have also tried using ms graph to target users for notification from the backend. None of this seems to have worked. This is essentially a notification bot solely- the frontend submits a request, pings the backend and if a notification needs to be sent out, the backend hits the bots endpoints with the appropriate payload.

1

There are 1 answers

1
KIMI On

Seems you're using the default local file storage, Azure web app and Azure Functions clean up the local file during a restart or redeploy. You need to implement your own storage to persist the conversation reference.

You can refer to the Add Storage part of this documentation for more info.