0

I am working on fb chatbot and use postback in the generic templates buttons. However, there is no response after I click the postback button.

enter image description here

"buttons": [
                {
                    "type": "web_url",
                    "url": "https://maps.google.com/?q={lat},{lon}".format(lat=store['coordinates']['lat'], lon=store['coordinates']['lon']),
                    "title": u"店家位置"
                },
                {
                    "type": "postback",
                    "payload": Function.sendGourmetComments + "_{id}".format(id=store["id"]),
                    "title": u"觀看評論"
                },
                {
                    "type": "postback",
                    "payload": Function.sendStoreHearts + "_{upload}".format(upload=None) + "_{id}".format(id=store["id"]) + "_{push}".format(push=None) + "_{edit}".format(edit=None) + "_{search}".format(search=True),
                    "title": u"撰寫評論"
                }
            ]

I guess I didn't check the message_postback event, however, I did. I didn't even receive any response from my webhook. So it's kind of mysterious to me what's going on.

It was working fine before, but it doesn't work without change after restart my computer. I am using ngork to expose my server API as callback url.

Brady Huang
  • 1,852
  • 20
  • 23

1 Answers1

0

I've this problem two days ago. You need the page_messaging facebook's approve to receive it Facebook's approved page_messaging permission

Mac Thu
  • 1
  • 1
  • 1
  • Thanks for your reply. The postback works without change any code before, so I think it may not be that problem. Besides, I think page_messaging is like the situation you want to submit your bot to other user, therefore postback should work before submit. To test it, I open a NEW app and check only message and message_postback events. Afterwards, it can receive postback event. – Brady Huang Feb 28 '18 at 06:00