Facebook Messenger Custom integration for personal use

In order to configure the sending of notifications via Messenger, the user must have a Facebook account verified with e-mail and phone number, a created Facebook application (bot) and a published Facebook page linked to it.

View detailed instructions on how to create a Facebook page and app for Messenger Custom integration >>

But for everything to work, you need to pre-configure the integration and enable subscription in the properties of the desired channel.

If at least one of these items has not been configured, you will see the following message at the stage of subscribing to the channel:

1 Setting up integration - Configure Integration message.png

Step 1. Configure integration

  1. Go to the Integration screen. This can be done via the dropdown menu in the upper right corner of the screen. Make sure you are logged in to the system.
  2. 2 Setting up integration - go to integrations.png
  3. Click on the Create button.
  4. 3 Setting up integration - create integration.png
  5. Click on the Facebook Messenger Custom card.
  6. 4 Setting up integration - select Messenger.png
  7. Set a custom name for the integration, if necessary, and enter the the Page Access Token. To get it, on the Meta for Developers portal (formerly Facebook for Developers), select the application you want and follow the path: Messenger> Settings> Access Tokens.
  8. 5 Setting up integration - edit integration.png
  9. Check the box next to Incoming messages processing (and allow subscribing through the Notify.Events interface).
  10. 6 Setting up integration - fill out the fields.png
  11. Personal Incoming Message URL will be generated automatically. It must be inserted into the Callback URL field in the Facebook page settings in the Meta for Developers interface: App> Messenger> Setting> Webhooks.
  12. Next, fill in the Page User Name field. If the page has a set username, you will find it in the page settings: Page> Settings> Page_info> Username. Or just copy the page ID from the URL.
  13. Enter any set of numbers and / or letters in the Verify Token field. The Verify Token fields in the Notify.Events and Facebook interfaces (App> Messenger> Setting> Webhooks) must match.
  14. 7 Setting up integration - filled out fields.png
  15. After clicking the Save button, the created integration will appear on the Integration screen.
  16. 8 Setting up integration - integration added.png

Not sure how to create a Facebook page and app for Messenger Custom integration? Read the instructions below >>

Step 2. Allow subscription

  1. Go to the channel properties via the Edit button on the main screen of the Control Panel or on the channel screen.
  2. 9 Allow subscription - channel settings.png
  3. Check the box next to Facebook Messenger Custom in the Allow subscription via integration field and click the Save button. Facebook Messenger Custom will be displayed in this field only after successfully completing Step 1.
  4. 10 Allow subscription - allow Messenger.png

In the next step, you can add custom integration to the channel.

Step 3. Add the custom integration to the channel

After you have configured the Facebook Messenger Custom integration and allowed the subscription, you can add it to the selected channel as a recipient.

  1. On the channel screen, click the Subscribe button in the Recipients section.
  2. 11 NE Interface - subscribe.png
  3. On the Channel subscription screen, select Facebook Messenger Custom.
  4. 12 NE Interface - choose Messenger.png
  5. Click the button to add the bot to your contact list.
  6. 13 NE Interface - add bot.png
  7. After that, a dialog with your bot will automatically open in a new window. Log in to Messenger through the Facebook account under which the bot and the page were created.
  8. 14 Messenger Bot - chat.png
  9. Copy the subscribe command and send it to the dialog.
  10. 15 Messenger Bot - subscribe.png

Ready! The subscription will now appear in the Recipients section of the channel screen, and you will receive notifications from the chosen services in Messenger.

16 NE Interface - Messenger integration added.png

Setting up a Facebook app and page

How to create a Facebook application (bot)?

  1. Log in or register to the Meta for Developers portal (formerly Facebook for Developers) using your Facebook account.
  2. 17 Meta for Developers.png
  3. On the Apps screen, click the Create App button.
  4. 18 Create an app - create app.png
  5. Select the application type None.
  6. 19 Create an app - choose type.png
  7. Enter the name of your application in the Display name field and check your contact email in the corresponding field. You do not need to specify a Business Account. After that click on the Create App button.
  8. 19.1 Create an app - add details.png
  9. On the screen that opens, click the Set Up button in the Messenger card.
  10. 20 Create an app - add a product.png

Congratulations! You have created your own Messenger bot. Now you need to create a page and link it to the bot to start using it.

How to create a Facebook page and link it to the bot?

  1. From the app dashboard, go to Messenger> Settings in the right side menu. Scroll down to the Access Tokens section and click the Create New Page button to create a new page.
  2. 21 Create an app - create app.png
  3. In the new window, enter the name of the page in the Page name field and select the appropriate category in the Category field. It is optional to fill in the Description field. Then click the Create Page button, and after receiving a message about successful creation - the Save button.
  4. 22 Create a page - add a name.png
  5. On the Manage page screen that opens, select Settings from the left side menu.
  6. 23 Create a page -  go to settings.png
  7. In the Page Info section, enter a username in the appropriate field. This step is optional.
  8. 24 Create a page - add username.png
  9. Return to the application window and click the Add or Remove Pages button in the Access Token section to link the page you just created.
  10. 25 Create a page - add or remove pages.png
  11. Select the created page from the list and click Next.
  12. 26 Create a page - link the page.png
  13. Make sure that the slider in the Manage and access Page conversations in Messenger line is set to Yes, and click the Done button, and then OK in the new pop-up window that opens.
  14. 27 Create a page -  approve actions.png
  15. Go back to the App Dashboard and in the Webhooks section click the Add Callback URL button. At this point, to get the Callback URL and Verify Token, you need to go to the Notify.Events interface.
  16. 28 Create a page - add callback url.png
  17. Go to the Facebook Messenger Custom Integration on the Integrations page.
  18. 29 NE Interface - choose the Messenger integration.png
  19. Enter the name of the created page in the Page User Name field. If you did not create it, use the page ID from its URL.
  20. 30 NE Interface - edit the integration.png
  21. Copy the auto-generated link from the Incoming Message Url field and paste it into the Callback URL field. In the Verify Token fields in the Notify.Events and Facebook interfaces, enter the same random set of numbers and / or letters. Then click the Verify and Save button.
  22. 31 Create a page - edit callback url.png
  23. On the app screen, under Webhooks, click the Add Subscriptions button.
  24. 32 Create a page - add subscriptions.png
  25. In the pop-up window that opens, check the boxes next to the messages and messaging_postbacks lines and click the Save button.
  26. 33 Create a page - edit page subscriptions.png
  27. On the app screen, in the Access Tokens section, click the Generate Token button.
  28. 34 Create a page - generate token.png
  29. In the pop-up window, check the box next to I Understand.
  30. 35 Create a page - token generated.png
  31. Copy the received token and paste it into the field in the Facebook Messenger Custom integration settings in the Notify.Events interface. Click the Save button to complete the integration setup. On the Facebook interface, click the Done button.
  32. 36 NE intefrace - Save the integration.png

Good job, you've created a page for your Messenger bot! You can now go back to the top of the instruction and set up the Facebook Messenger Custom integration to start receiving notifications through your Messenger bot.