Skip to content

Adding the Facebook Messenger Channel

To add the Facebook Messenger channel to your Virtual Assistant, you need a Facebook Developer account. With this account, you can configure the connection between Facebook Messenger and Kore.ai. Enabling the Facebook Messenger Channel on the Bot Builder helps your users chat with the Virtual Assistant using their Facebook accounts.

The steps to enable this channel are simple and summarized below:

  1. Create and set up a Facebook Messenger App.
  2. Configure the Webhook or Callback URL to send and receive messages.
  3. Subscribe to the app on the Facebook page using the Client ID and Client Secret.
  4. Submit the App for Approval.
  5. Enable the channel and complete the configuration on the Kore.ai XO Platform.

Step 1: Create and Set up a Facebook Messenger App

  1. Log in to the Facebook Developer Portal and click the My Apps top menu option.  Facebook app

    Note

    New users should register on the Facebook Developer Portal. Learn more.

  2. In the My Apps section, click Create App.  Facebook My apps

  3. In the Select an App Type window, select the Business tab, and click Next.  Facebook Business

  4. In the Details section, enter the required details, and click Create App.  Facebook create app

  5. Provide your account password in the Please re-enter your password window when prompted, and click Submit.

  6. Your App is now created and you are redirected to the Add products to your app page.
  7. Click Set Up on the Messenger tab.  Facebook add products

  8. You now need to associate a page with the app. If you do not have a page, click Create New Page in the Access Tokens panel.  Facebook access token

  9. Click Add or Remove Pages and follow the instructions to add your page.  Facebook remove pages

  10. Click Generate Token.  Facebook generate token

  11. In the Token Generated window, select I understand and click Copy to copy the page Access Token.  Facebook generated token

  12. Click Done.

  13. Copy the Page ID of the Facebook page.  Facebook configuration

  14. On the Kore.ai XO Platform, navigate to Channels & Flows > Channels > Digital > All > Facebook Messenger.

  15. Click the Configurations tab, and paste the Page Access Token and Page ID values you’ve copied.  Facebook page access

  16. Navigate to Settings > Basic and configure the Privacy Policy URL and Terms of Service URL fields for the app.  Facebook Privacy

  17. Click Save Changes.

  18. Enable the deployment of the app by changing App Mode: Development to Live.  Facebook Save Changes

Step 2: Configure the Webhook/Callback URL

To set up the webhook URL, follow the steps below:

  1. Copy the Webhook URL and Verify Token from the Kore.ai XO Platform’s channel configuration panel.  Facebook Webhook URL

  2. On the Messenger Settings page of the Facebook Developer Portal, click Add Callback URL. Copy Facebook Webhook URL

  3. Paste the copied values in the Edit Callback URL window, and click Verify and Save. Edit Facebook Callback URL

  4. The webhook URL is successfully set up.

  5. Click Add Subscriptions. Facebook add subscriptions

  6. Select messages, messaging_postbacks, messaging_optins, message_deliveries, and message_reads in the Edit Page Subscriptions window to select the webhook services. Facebook details

  7. Click Save.

Step 3: Set up App ID and Secret

To configure the Client ID and Client Secret for the app, follow the steps below:

  1. On the Facebook Messenger Developer Portal, navigate to Settings > Basic.
  2. Copy the App ID and App Secret values. Facebook Messenger Developer

  3. On the Kore.ai Bot Builder, navigate to the Configurations section of the Facebook Messenger channel and paste these values in their respective fields. Facebook messenger channel

Step 4: Submit the App for Approval

Configure any other settings that Facebook might require, then submit the app for approval. Learn more.

Once approved, you can enable the Facebook Messenger channel for your assistant with the steps mentioned below.

Step 5: Enable the Channel

On the Kore.ai XO Platform, enable the Facebook Messenger channel to complete the integration. To enable follow the steps below:

  1. Navigate to Channels & Flows > Channels > Digital > All > Facebook Messenger.
  2. Click the Configurations tab, and select YES for Enable Channel. Enable Facebook channel

  3. Click Save.

After enabling the channel and verifying all the configurations, you can optionally publish the assistant for the new channel. Learn more about Publishing your Virtual Assistant.

To learn more about working with Channels within the Kore.ai XO Platform, please see Channel Enablement.