Facebook Messenger
The Facebook Channel connects Anyy to a Facebook Page. Messenger events arrive through a signed webhook, and replies use the Page access token.
What You Need
- a Meta app with Messenger enabled;
- a Facebook Page managed by that app;
- the Page ID and App ID;
- a Page access token;
- an owner-chosen webhook verify token;
- the Meta app secret; and
- a public HTTPS route to the Anyy Gateway.
Use Meta's current Messenger Platform getting-started guide for app review, Page subscription, and permission requirements.
Connect in Dashboard
- Open Dashboard → Channel → Add.
- Choose Facebook; the default entry uses Messenger webhook.
- Enter the Page ID and App ID.
- Add the Page access token, webhook verify token, and app secret.
- Save the account; change the DM policy through the CLI wizard when needed.
- Subscribe the Page to message events and complete the permissions shown by setup/doctor.
Enable the shared listener and HTTPS proxy as described under Webhook Platforms before registering the callback. The callback path is:
/channels/facebook/ACCOUNT_ID/webhook
The default account ID is page. Use the same verify token in Meta and Anyy.
Direct-Message Access
Facebook Messenger uses direct-message policies: pairing, open, allowlist, or disabled. The Anyy profile does not expose Facebook group conversations.
anyy channel pairing list
anyy channel pairing approve --request REQUEST_ID
Choose Facebook in the interactive anyy setup channel wizard to edit policy. Dashboard has no policy or pairing-approval list, and current setup actions do not edit Facebook allowlist entries. Pairing authorizes that sender to reach the assistant: verify the Page and sender identity, approve through the CLI, then ask for a new message.
Verify the Connection
anyy channel doctor facebook
anyy channel reload
Message the Page from a permitted account. Confirm the inbound event, pairing flow, and reply separately.
Before app review or wider release, use a Meta account that has an appropriate role on the app/Page. This separates Anyy configuration problems from platform access restrictions.
Troubleshooting
| Problem | Check |
|---|---|
| Meta cannot verify callback | HTTPS reachability and webhook verify token |
| Signed event is rejected | App secret and reverse-proxy preservation of headers/body |
| Page receives but cannot reply | Page access token and messaging permissions |
| Sender receives nothing | DM policy, pairing/allowlist, Gateway status |
| Works for admins only | Meta app mode, app review, and Page subscription |