Connect a LoyJoy bot to Facebook Messenger
Every chatbot on the Facebook platform is manually checked by Facebook and only then is it activated. The steps required to set up and submit a chatbot are explained below. Some steps may have already been completed, so you can simply skip them. Setup is not always self-explanatory. LoyJoy has no influence on this procedure.
You need a Facebook page for your chatbot. Copy the page ID of your page, you will enter the ID afterwards at LoyJoy.
Create a Facebook app for your chat bot that goes here. Skip the quick start by clicking the "skip and create app ID" button.
Give your app a name (this will later be the name in Facebook Messenger) and choose a contact email address where you can be reached
Now you can select a "scenario" on Facebook. This is not necessary, scroll to the bottom of the page and click "skip"
Now set up your app for Facebook Messenger by selecting the Messenger tile and clicking "Set up"
Your app needs the pages_messaging feature to send and receive messages on Facebook. Add this to your submission.
If you want to submit pages_messaging, you need to add some details, click "Add details".
On the following page, you need to make four settings. Not visible in the screenshot is the commercial use setting located under the logo upload.
Then go to Messenger > Settings in the left menu. Here go to the Access Key section. Select the page you want to connect to the chatbot. Then click on the button "Edit permissions".
A new window will open, here you have to perform several steps. The prerequisite for this is that your company and you as a person / administrator have been personally verified on Facebook. If not already done, please perform the verifications. Then you can read on here.
After the verification (which is under review first) you will receive your page access key. Please copy it. Just like the App-ID shown above.
Now you can copy the three information from Facebook (page ID, app ID and page access key) into your LoyJoy bot. To do this, go to the "Integration" tab in the Bot (really in the Bot, not in an Experience!) and expand the "Facebook" area. Put the three pieces of information in the right place. Then copy the "Webhook URL" from LoyJoy.
You can now paste the webhook URL you just copied from LoyJoy into the "Callback URL" field on Facebook. Under Confirm token you can enter a random character string. Then hook the four options messages, message_deliveries, messaging_postbacks and message_reads. Then click "Confirm and save".
Your Facebook app is still in development mode, which you can only test internally. Customers are not yet able to access it. The app (i.e. your chatbot) still has to be activated. A team from Facebook will test the chat.
Scroll down to "Current submission". Click on "Add details".
Here you must first accept that you will not send any promotional messages via Messenger. You must also describe your chatbot experience in detail and create a screencast if necessary. You will find all information about this there. Please read the information on the Facebook page carefully.