Integrate Bot Press with Messager API

Lomana
Aug 5, 2024

--

How to send message from Bot Press to Messager API

Preparation

  • Bot Press server

Setup Bot Press

open Code Editor
  • Go to Code Editor
  • Add messaging in Current Bot/bot.config.json
"messaging": {
"channels": {
"messenger": {
"enabled": true,
"accessToken": "your_access_token",
"appSecret": "your_app_secret",
"verifyToken": "your_verify_token"
}
}
}
  • your_access_token from Generate access tokens section (should added page before)
  • your_app_secret from App settings > Basic > App secret
  • your_verify_token should same as Configure webhooks

Create app

Go to Create an app — Meta for Developers (facebook.com)

Setup Messager

Connect FB page

Add subscription

  • messages
  • messaging_postbacks

Setup webhook

Callback URL: <EXTERNAL_URL>/api/v1/messaging/webhooks/<YOUR_BOT_ID>/messenger

  • EXTERNAL_URL BotPress server url
  • YOUR_BOT_ID from Bot Configuration > General > Bot Id

Verify Token: token same as Current Bot/bot.config.json

Final rounds test your bot in Messager application

--

--