General functionality understanding of slack interactive component (button)

Hey guys,

So I have developed a rasa chatbot that is integrated in slack. The chatbot shows a button as answer.

This buttons is formatted as block kit json string and is shown properly. It is NOT defined in rasa core files, but rather directly given as json_message over the action server.

Also, in the slack app (under interactivity) I have given the correct rasa server url.

Now I am wondering: How do I handle a button press? Is it possible to call a function / action on my rasa action server when the user presses the button? If so, how do I make this work?

Edit: I just found out (by accident) that I can make the button invoke an intent by setting its ‘value’ field to ‘/intent_name’. Is this behavior intended / Is it the proper way to handle a button press?

Yes. You can find out more at Responses

In my experience, if you want to trigger specific actions on your Rasa action server from a button press, you can create custom actions that correspond to those values. Just ensure your action server is set up to recognize and handle those intents properly.

Also, if you’re thinking about expanding your project or using more tools, you might want to check out ways to get a slack discount on any services you’re considering.