facebookfacebook-graph-apifacebook-messengerfacebook-chatfacebook-chatbot

Is there an event or other way to handle the user first ever message to the bot on the Facebook Messenger Platform?


I have set up a welcome message to my chat bot on Facebook Messenger platform. Now I want to know when the user sends it's first ever message and handle this special case (typically by getting some more info about the user and storing it for future use and not query facebook graph API on every message).

Is there a special event when the user clicks the "Get started" CTA on messenger ? Any other easy way (except storing some data identifying the user myself) ?


Solution

  • This seems to be solved now with the latest additions from facebook: https://developers.facebook.com/docs/messenger-platform/thread-settings/get-started-button

    So you can just enter the specific payload for the "Get Started button" and act accordingly.