I have created two intents “response_success” and “response_failure” with enough data samples and created stories for responding with utter actions for these intents. I am using slack integration to check it and confirmed this is working fine and bot is responding correctly when I send the user input as text.
But, when I create a button action with these intents, the buttons are appearing correctly in the slack but no action is being performed, when I click on these button. My domain.yml code is given below.
utter_check_feedback:
- text: Was my response helpful?
buttons:
- title: "Yes"
payload: '/response_success'
- title: "No"
payload: '/response_failure'
I couldn’t see much help from the rasa doc regarding this. Kindly note that I confirmed these intents “response_success” and “response_failure” are working fine by sending the user input as text from slack. Only the button action is not working. So, please help me if I am missing something here.
@erohmensing I updated the code based on that fix and the buttons are still not responding. But, I just noticed that, even the request is not received in “def webhook():” method, when I click the button from slack. Is there anything I need to do from slack side for this? Any idea?
I’m actually a little confused though. What did you change in core 0.14.3 to get it working? I’ve just looked at the code, and it seems the changes are already incorporated. E.g. herehere and here all references to payload[0] have been removed. Did you add them back in (i.e. the opposite of the suggested change in the forum post?
Sorry I just mean to ask how you specifically fixed it. E.g. in that fix, it tells you that you should change all instances of ['payload'][0] to ['payload']. But in 0.14.3, these changes are already made. Did you do the opposite and add the [0] back in to make it work?
The mistake was in my side only. I think I had played with slack.py by replacing it with an old version to verify the button action and forgot to replace it with the recent version again. That means, I was trying with the old version of slack.py.
I just replaced it with 0.14.3 and tried the button action again. This is working fine for me now. To summarize, there is no code change required in 0.14.3 version to make the button action work.