Skip to content

Messenger Channel

Use a Messenger channel when your audience already messages your Facebook Page and you want the agent to receive and answer directly in Messenger.

For Codeer, the important live endpoint is the Webhook URL. Publishing a Messenger channel mostly controls whether Codeer starts processing Messenger webhook events. The bound agent still answers with its current published version.

What you need before you start

  • One agent with at least one published version
  • Permission to edit channels in the workspace
  • A Facebook Page you can manage
  • A Meta app
  • Messenger or Messaging settings available in that Meta app
  • An access token that can send Page messages
  • A public HTTPS Codeer environment

Why public HTTPS matters

Meta only accepts webhooks that are reachable over public HTTPS. If the Webhook URL from Codeer is not publicly reachable, Meta will fail at the webhook verify step.

What you will prepare in Meta

  1. A Meta app

  2. A Facebook Page that will receive and send Messenger messages

  3. Messenger or Messaging settings

  4. A webhook configuration whose callback URL points to Codeer's Webhook URL

  5. A subscription for the Page's messaging events

  6. An access token that can send messages as that Page

Keep the Page, token, and webhook subscription aligned

Codeer checks incoming webhook events against the Facebook Page ID you enter for this channel. If the Page ID, Page access token, and webhook subscription do not belong to the same Page, messages may be ignored or Codeer may fail to reply.

Full setup flow

  1. Create the Codeer Messenger channel and copy the Webhook URL

    • In Codeer, publish the target agent from Editor first.
    • Open Channels.
    • Click New Channel.
    • Choose Messenger.
    • Give the channel a stable Name and Slug.
    • In the Messenger channel Configuration, copy the Webhook URL.
    • Do not publish the Codeer Messenger channel yet. First collect the required Meta-side values, save them in Codeer, and then return to Meta to configure and verify the webhook.
  2. Add Messenger or Messaging settings to the Meta app

    • Open Meta for Developers.
    • Open the Meta app you want to use for Messenger.
    • Add the Messenger or Messaging product or use case.
    • Connect the Facebook Page that users will message.
    • Confirm that the app has permission to manage messages for that Page.

    Meta dashboard labels may change

    Meta changes App Dashboard navigation and use case names over time. The important parts are: the app is connected to the right Page, webhook verification works, and the token can send Messenger messages as that Page.

  3. Get the Facebook Page ID

    • Find the Page ID in Facebook Page settings, Meta Business Suite, Meta App Dashboard, or Graph API tooling.
    • Copy the ID. You will paste it into Codeer as Facebook Page ID.
  4. Create a Webhook Verify Token

    • Generate a hard-to-guess string for this channel's Webhook Verify Token.
    • Keep it ready. You will enter the same value in Meta's webhook settings and in the Codeer form.

    Verify Token is not the Page access token

    Webhook Verify Token is a shared string you choose for Meta webhook verification. Page access token is the token Codeer uses to send messages as the Facebook Page. Do not reuse one as the other.

  5. Copy the Meta App Secret

    • In Meta App Dashboard, open App Settings > Basic.
    • Find and copy App Secret.
    • You will paste it into Codeer as Meta App Secret.

    Meta App Dashboard Basic settings page showing where to find App Secret

    Codeer uses App Secret to verify webhook signatures

    When Messenger webhooks reach Codeer, Codeer uses Meta App Secret to verify X-Hub-Signature-256. If the App Secret is wrong, events will be ignored.

  6. Create or get the Page access token

    • In Meta App Dashboard, Graph API Explorer, or your existing Meta token flow, get an access token that can send messages as the Facebook Page.
    • Confirm that the token belongs to the same Page you entered in Codeer as Facebook Page ID.
    • You will paste it into Codeer as Access Token.

    Messenger API settings page showing the Page access token generation area

    Confirm token and permission status before production

    If the app is still in development mode or you only have a test token, testing may be limited to people with app roles. Before serving normal users, confirm that the Meta app, permissions, and token match your production rollout plan.

  7. Save the Messenger configuration in Codeer

    • Return to the Codeer Messenger channel.
    • In Configuration, enter:
      • Facebook Page ID
      • Webhook Verify Token
      • Meta App Secret
      • Access Token
    • Choose the published agent that should answer Messenger messages.
    • Save the configuration.

    Save the Verify Token before verifying the webhook in Meta

    When Meta verifies the webhook, it calls Codeer's Webhook URL with the verify token you entered in Meta. Codeer compares that value with the Webhook Verify Token already saved on the channel, so this step must happen before Meta verify / save.

    Only published agents appear in the selector

    If the agent is missing, go back to Editor, publish it, and then return to the Messenger channel page.

  8. Configure the webhook in Meta

    • In the Meta app's Messenger / Webhooks settings, add a callback.
    • Paste Codeer's Webhook URL into Callback URL.
    • Enter the Webhook Verify Token you created earlier.
    • Click verify / save in Meta.
    • After verification succeeds, subscribe the Facebook Page that should receive messages.
    • Subscribe at least the Messenger messaging events so Codeer receives user messages.

    Messenger API settings page showing the webhook callback URL and verify token fields

  9. Publish the Codeer Messenger channel

    • After webhook, Page ID, credentials, and agent binding are ready, publish the channel.
    • Use Unpublish if you want Codeer to stop processing new Messenger events.

First live test

Before sharing the channel more widely, run through the full flow with a real Facebook account.

  1. Open the Messenger conversation for the Facebook Page.

  2. Send a realistic text message.

  3. Confirm that Messenger receives the agent reply.

  4. Go back to Codeer Histories and confirm that the conversation is recorded.

  5. Confirm that the reply comes from the bound agent's latest published version.

Troubleshooting

If Messenger is connected but the reply is wrong, check these in order:

  1. The correct agent version is published.

  2. The Messenger channel is published.

  3. Meta webhook verification succeeded.

  4. The webhook is subscribed to the correct Facebook Page.

  5. Facebook Page ID belongs to the same Page as the webhook event and Page access token.

  6. Webhook Verify Token exactly matches the value in Meta webhook settings.

  7. Meta App Secret comes from the same Meta app.

  8. Access Token is still valid and can send messages as that Page.