Session Variables in Botkit

Suppose I have a session variable context.session.UserSession.xyz and I wanted to update this variable after end of each dialog. Can I do it using botkit? I mean can I change the session variables in on_event function and send it back to the bot?

Hi

Can you please help me on this as I’ve been waiting for a reply for 4 days

@tprameela10
The entire context is available in the botkit under data.context… so if you want to update context.session.UserSession.xyz, you will need to modify data.context.session.UserSession.xyz in either on user message or on bot message events.