User data is set like this:
BotData response = await stateClient.BotState.SetUserDataAsync(activity.ChannelId, activity.From.Id, botData);
From the documentation, it is unclear to me where and how the user data is store. Is it encrypted? Is this data cached on the user client? When I request to delete the user data, is there a possibility that not all user data got removed (e.g. cached copies)?
Hi @miaosenwang, it depends on how you implement your bot.
If you implement your own bot state store, the store can be encrypted, deleted, and completely controlled by you. This approach is suitable if you're concerned about where your data is stored, for performance or compliance reasons.
If you use our free bot state API, the data is stored encrypted on our servers. We delete the data when you send a delete request.
Most implementers switch to using their own bot state store. You can use our BotBuilder-Azure package to implement your own state store based on your own Azure table or DocDB storage: https://github.com/Microsoft/BotBuilder-Azure
some extra information about state storage: https://docs.botframework.com/en-us/technical-faq/#where-is-conversation-state-stored
@dandriscoll @willportnoy Thank you for the response. They are very informative.
Closing as it looks like we've answered the question. Please feel free to at-mention or open a new issue if you'd like other details.
Most helpful comment
some extra information about state storage: https://docs.botframework.com/en-us/technical-faq/#where-is-conversation-state-stored