0

Here description how to set greeting text https://developers.facebook.com/docs/messenger-platform/thread-settings/greeting-text

As we can see at enter image description here greeting text is "Hi, Peter! ..." But how to set this personalisation info properly?

vinnitu
  • 4,234
  • 10
  • 41
  • 59

1 Answers1

2

I've also been looking at this issue for a while and it looks like there isn't official documentation for adding this personalization.

You can set the greeting message on the Facebook App Page by going through the following tabs: App FB page > Settings > Messaging > Show a Messenger Greeting. Here you can set the greeting message with the option to add personalization of the user's first, last or full name.

What isn't officially mentioned is that these are filled in through templating {{user_first_name}}, {{user_last_name}} & {{user_full_name}}, which we can leverage. You can make a POST request with these template slots and it correctly displays the name.

curl -X POST -H "Content-Type: application/json" -d '{
  "setting_type":"greeting",
  "greeting":{
    "text":"Hi {{user_first_name}}! Welcome to My Company!"
  }
}' "https://graph.facebook.com/v2.6/me/thread_settings?access_token=PAGE_ACCESS_TOKEN"

I've opened a Bug listing on Facebook Messenger support page and so now, I'm waiting to hear back if this is something that will be supported going forward.

Christian
  • 44
  • 2
  • 1
    I am having problems. This is my code: ´´´´ { "setting_type":"greeting", "greeting":{ "text":"Hi {{user_first_name}}! Welcome to My Company!" } } – Jonathan Prieto May 22 '20 at 16:15