Lalexi
GuideConnections

Facebook

How to connect a Facebook page (Messenger) through your own Meta app: the app ID and secret, a page token; verification and the webhook happen automatically.

This is messaging with a Facebook page through Messenger. It connects through your own Meta app, the same way WhatsApp Business does: the app and the page are yours, and Lalexi only receives and sends the messages. The app follows Meta's rules on your behalf, and Meta's decisions concern your app alone.

You cannot write first: Meta lets you reply to people who wrote themselves, within 24 hours of their last message.

What to prepare

All of this happens on Meta's side, before you open Lalexi:

  1. A Facebook page you are an admin of.
  2. An app in Meta for Developers (developers.facebook.com): My Apps → Create App, type Business, linked to your business portfolio. Add the Messenger product to it.
  3. The app ID and secret — on the app's App settings → Basic page: App ID and App Secret. Set the privacy policy URL there too, and switch the app to Live mode.
  4. A page token: Messenger → Messenger API Settings → Generate access tokens — connect the page and press Generate. The token needs pages_messaging and pages_manage_metadata. It must be a page token that does not expire, not a temporary user token: Lalexi checks this when you connect and tells you if something is off.

A workspace administrator connects it — see Team.

How to connect

  1. Open Settings → Inboxes and press Add Inbox.

  2. Choose Facebook.

  3. Fill in the form:

    FieldWhat to enter
    Inbox nameOptional. Left empty, the page's name is used.
    App IDThe App ID, digits only.
    App secretThe App Secret.
    Page access tokenThe token from step 4 above.
  4. Press Connect. Lalexi asks Meta whether the token is alive, issued by this app and belongs to a page, registers our webhook in your app and subscribes the page to it. You do not set the webhook up by hand.

  5. Add the inbox's agents, as with any standard inbox.

When the credentials stop working

A token can be revoked and an app secret reset. The inbox settings then show a warning. Open the Meta app tab, paste the new values under Replace credentials and save: the inbox and all its conversations stay.

If something goes wrong

MessageWhat to do
Meta rejected the app ID or the app secretCheck the App ID and App Secret on App settings → Basic.
The token was issued by a different appGenerate the page token in the same app whose ID you enter.
This is not a page access tokenUse a page token from Messenger API Settings, not a user token.
The token lacks permissionsGrant pages_messaging and pages_manage_metadata and generate the token again.
Already connected in another workspaceA page can live in one Lalexi workspace only.
Customers' messages do not arriveCheck the app is in Live mode. If only people with a role in the app get through, Meta requires App Review for pages_messaging.

On this page