Skip to content

Channels

Messenger

Answer people who message your Facebook Page, with text, media and reply buttons.

Requirements#

  • A Facebook Page.
  • A Facebook account with full control of the Page, to grant OmniMessage access to its messaging.

Connect the channel#

Messenger channels are connected in the console by signing in with Facebook:

  1. Open Channels, choose Connect channel and pick Messenger.
  2. Choose Continue with Facebook. A Facebook window opens; sign in and grant access to the Pages you want to use.
  3. Back in the console, the Pages you manage are listed. Pick one and choose Connect Page.
  4. The channel shows as pending for a moment and then as connected.

There are no credentials to copy, and POST /v1/channels does not accept this type: creating a Messenger channel with an API key is not available. The identifier of the channel is the Page ID. If the Facebook login later loses access, open the channel and choose Reconnect.

Recipients#

to is the page-scoped user ID (PSID) of the person. A PSID is specific to your Page and cannot be derived from a phone number or profile URL.

You obtain it from the from field of a message.received event when the person writes to your Page. A Page therefore cannot message someone who has never contacted it.

Supported message types#

TypeUse it for
textPlain text of up to 4096 characters.
attachmentsOne image, video, document, audio file, voice note or sticker, fetched from an HTTPS URL.
buttonText with one to three quick-reply buttons.

This channel also accepts the pass-through types carousel, product_list, receipt. Their content is forwarded in the provider format without validation: see Channel-specific types.

Channel rules#

  • Meta applies a standard messaging window: you can answer with free-form content for 24 hours after the last message from the person. Each new inbound message restarts the window.
  • A message sent outside the window is refused by Meta and fails with a provider_error or 422 policy_violation. It is not charged.
  • button messages show up to three reply buttons. A tap arrives as a message.received event carrying the button id.
  • Content must comply with the Meta Platform Terms and Messenger policies.

Example request#

curl https://api.omnimessage.co/v1/messages \
  -H "Authorization: Bearer om_live_xxxxxxxxxxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "channel": "ch_1kL4jH7fD0sA3gB6vN9m",
    "to": "6543210987654321",
    "type": "text",
    "text": {
      "body": "Thanks for your message. Your order #1042 ships tomorrow."
    }
  }'

Delivery statuses#

Messenger reports sent, delivered and read.

Pricing#

Each accepted outbound message on a messenger channel consumes one package credit or the messenger price from the wallet. Read your effective price from GET /v1/pricing. Inbound messages are free. Fees charged by the provider are separate. See Billing.

    Loading