A very simple PHP Messenger Bot API wrapper for sending messages
Switch branches/tags
Nothing to show
Clone or download
Failed to load latest commit information.
.gitignore add new methods and fix tabs Nov 4, 2017
Messenger.php add new methods and fix tabs Nov 4, 2017
README.md fix type on readme Mar 11, 2017
examples.php add readme Feb 18, 2017



A very simple PHP Messenger Bot API for sending messages.
Based on Telegram Bot API by Eleirbag89.


For the WebHook:

  • An SSL certificate (Facebook API requires this). You can use Cloudflare's Free Flexible SSL which crypts the web traffic from end user to their proxies if you're using CloudFlare DNS.


  • Copy Messenger.php into your server and include it in your new bot script
$facebook = new Messenger($bot_id);

Configuration (WebHook)

Navigate to https://developers.facebook.com/apps/YOUR_APP_ID/messenger/ and add the webhook.


$facebook = new Messenger($bot_id);
$text = $facebook->Text();
$chat_id = $facebook->ChatID();
$message_id = $facebook->EntryID();
$message = "Hello World";
$result = $facebook->sendMessage($chat_id, $message);

See examples.php for the complete example.


For a list of emoticons to use in your bot messages, please refer to the column Bytes of this table: http://apps.timwhitlock.info/emoji/tables/unicode


Q: Can you implement <???> function?

A: I can try. Open a issue and I'll see what I can do.

Q: Your code is awesome. How can I help?

A: Thank you! You can help by codding more features, creating pull requests, or donating using Bitcoin: 1BdL9w4SscX21b2qeiP1ApAFNAYhPj5GgG


Free. Don't forget to star :D and send pull requests. :D

Free Software, Hell Yeah!