claudiajs / claudia-bot-builder

Create chat bots for Facebook Messenger, Slack, Amazon Alexa, Skype, Telegram, Viber, Line, GroupMe, Kik and Twilio and deploy to AWS Lambda in minutes

Home Page:https://claudiajs.com/claudia-bot-builder.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Facebook generic template button value not working ..

ajith007 opened this issue · comments

commented

The below code displays the button correctly in Facebook Messenger, but upon clicking the button, it sends 'Say Hello' instead of 'hello'.

let sayhello = new fbTemplate.Generic();
sayhello.addBubble('Hello');
sayhello.addButton('Say Hello','hello');

*** Expected behaviour:**
Clicking the 'Say Hello' button should send the button value, 'hello' as the postback

*** What actually happens:**
Upon clicking the button it sends the button title/caption, 'Say Hello' as the postback.

*** Which bot engine (facebook, skype...):**
Facebook Messenger

  • Link to a minimal, executable project that demonstrates the problem:

  • Steps to install the project:

*** Steps to reproduce the problem:**
Try the above code snippet in a Messenger bot.

commented

I missed to add messaging_postbacks webhook earlier. Postback is working now but it's still sending 'Say Hello' instead of 'hello'.

commented

Looks like that's by the design. My bad! :(