Connect a Messaging Platform: FB Messenger
Connect an AI agent to Messenger for a Facebook Page, including permission prerequisites, the authorization process, and FAQs
Before You Connect
MaiAgent preparation
You have created an “AI agent” on the MaiAgent platform.
Facebook permission preparation
Your Facebook account has been invited to or has created a business portfolio.
You have full control of that business portfolio.
Page permission check
If the Page is already in the business portfolio: No additional changes are required.
If the Page is not in the business portfolio: You must be an administrator of the Page and have full control.
A Page can be connected to only one messaging platform. To connect it to another AI agent, first delete the original messaging platform, then connect it again. To connect Instagram Direct for the same Page, create a separate Instagram messaging platform.

Start Connecting
1. Go to the messaging platform page in MaiAgent and select “Connect Messaging Platform”
a. Select Connect Messaging Platform in the upper-right corner.

b. Select Messenger.

c. Click Log in with Facebook and sign in with the Facebook account that manages the Page. MaiAgent accesses only messages from the Pages you authorize and does not access your personal messages.
Make sure your browser allows pop-ups. Otherwise, it may block the Facebook login window.

2. Select a business and select (claim) the Page.
In the Facebook authorization window, first select the business portfolio to authorize, then check the Page you want to host (claim).
Confirm the authorization. Once the connection is created successfully, hosting is complete.

3. AI agent settings
Messaging platform name
Give this connection a name so you can identify it easily.
AI agent
Select the AI agent that will reply to Messenger messages.
Select Page
In the list under Messenger channel, select the Page you just claimed.
Enable reset commands
(Optional) When enabled, you can configure one or more commands. When a user sends one of these commands in Messenger, a new conversation begins, such as “Start over.”

4. Verify the connection
Next, try sending a test message to this messaging platform from an internal MaiAgent conversation. If the AI agent replies normally, the connection was successful.

You can also open a conversation with the AI agent from the Page and send a test message. If the bot replies normally, the connection was successful.

After the connection succeeds, MaiAgent automatically subscribes to message events for the Page through Meta. You do not need to configure a separate Webhook.
Supported Message Types
User → AI agent
Text, images, videos, voice messages, and stickers; OCR can be used with images.
AI agent → User
Text and images
FAQ
Q: Why is the Page list empty after authorization?
The Facebook account you used to log in does not have full control of the Page, or the Page was not selected during authorization. Follow Before You Connect to check the permissions, log in again as a Page administrator, and make sure the correct Page is selected in the authorization window.
Q: Why does “This Page ID is already in use” appear when I save?
The same Page is already connected to another messaging platform in the organization. Delete the original messaging platform, then create it again.
Q: Why hasn't MaiAgent received a user's message?
Make sure the authorized Facebook account is still an administrator of the Page and that the Page remains in the business portfolio selected during authorization. If the authorization has expired or the Page permission has been removed, delete the messaging platform and connect it again.
Q: Can Messenger and Instagram use the same AI agent?
Yes. They are separate messaging platforms and can be linked to the same AI agent, or you can configure different options for each platform. For instructions on connecting Instagram, see Connect a Messaging Platform: Instagram.
Last updated
Was this helpful?