How to write custom actions in action.py

How to write custom actions in actions.py file like I want to write a function that If user is not typing anything for 2 minutes or more I want quit the chat. So how to write function and execute it. Please tell me with example code so that I will be having some idea for other custom functions. thank you.

Hi @skjainmiah

Please have a look at our documentation about custom actions: Actions. To execute a function after two minutes that cancels when the user types, use a reminder: Reminders and External Events. The latter docs page also refers to the example project “reminderbot” for a bot with reminders.

1 Like