Code Monkey home page Code Monkey logo

facebook-bot-autoresponder's Introduction

⚡ AUTORESPONDER FOR FACEBOOK

Created by Jelle VDV

Repo for all the code talked about in this blogpost: https://vandevliet.me/bot-automatically-responds-comments-facebook/.

This code monitors all the comments of a Facebook post, and then comments on the comments with a custom photo. In this code there is an example on how you can make it respond with an image that includes the orginal commenter's profile picture.

This code is just a demo :) Especially with HTTP requests there should be some error handling. But that shouldn't be too hard to implement!

Requirements

  • Python 3 and all the requirements in the requirements.txt file
  • A (published) Facebook page
  • A Facebook app
  • An access token (In the blogpost you'll learn how to get a long-lived access token)

Accompanying blogpost

Need more info? I created a whole blogpost to explain the code and how you can change it to suit your needs.

Link to the blogpost

License

This code is released under MIT license

Thanks

Special thanks to Inti De Ceukelaire, who was the first one to write (I think) to write such a tool. You can find more info about how he implemented it here (in Dutch).

facebook-bot-autoresponder's People

Contributors

dependabot[bot] avatar gmjelle avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

facebook-bot-autoresponder's Issues

Tutorial update

I really appreciate you sharing this tutorial, just wanted to point out a couple things.

In order to give the manage_pages and publish_pages permission Facebook requires that you send a screencast of showing off how the app works for someone in the review team to check the process. I'm assuming the app won't work without those permissions, so there is a catch 22 situation here. Maybe Facebook hasn't realized yet they have an imposible requirement.

Also, they require specifying a platform, so I selected website, since it's the one that seems less complicated to setup, since other options like mobile app or Facebook game might require some other information that I don't have at hand.

For getting the Access Token once I've entered the website information, they require passing the website URL as a parameter and the clientid parameter was renamed to clien_id, but when I pass all that information I get the error shown bellow, even when I've already added the domain to the app settings:

Can't load URL: The domain of this URL isn't included in the app's domains. To be able to load this URL, add all domains and sub-domains of your app to the App Domains field in your app settings.

Keep up the good work.

'from' KeyError

image

I found this error when running the script. I couldn't find the solution for it.

Support for tagging the bot?

I wonder whether is posible to have the bot to auto reply to tags (aka mentions) on any post, is that posible?

Keep up the good work.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.