Git Product home page Git Product logo

twitter-blocker's Introduction

Twitter Blocker App

A simple Twitter bot to help block users more efficiently

Setup

Ensure you have Python 3 installed on your device, as well as MySQL.

  1. Git clone this repo
  2. Obtain consumer key and secret from the Twitter Developer portal. The app should be configured to enable Sign in with Twitter:
  3. cd twitter-app.
  4. On your local setup, create an .env and Set env variables:
APP_NAME
APP_URL

APP_CONSUMER_KEY
APP_CONSUMER_SECRET
APP_ACCESS_TOKEN
APP_ACCESS_TOKEN_SECRET

DB_HOST
DB_NAME
DB_USER
DB_PASSWORD
  1. Create database
  2. Setup a pipenv environment, and install dependencies:
    1. virtualenv twitter-app
    2. source ../twitter-app/bin/activate on mac or ../twitter-app/bin/activate windows
    3. pip install -r requirements.txt
  3. Start the app:
    1. python app.py; or
    2. gunicorn app:app

Note: A Procfile is included for deployment to cloud solutions.

Finally, revisit the dev portal, and add your app's callback URL (https://your-deployed-url/callback e.g http://127.0.0.1:8000/callback) to the callback URL whitelist setting. Once saved, follow the instructions on the app's web UI to click through the demo pages.

Reference

Twitter Developer Portal
Flask
python-oauth2
Bootstrap

Credits

Original version by Zacchaeus Bolaji

Contributing

  • Fork the project
  • Pull to your local device
  • Make your changes and push
  • Create a Pull Request using this template

twitter-blocker's People

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.