Git Product home page Git Product logo

clebillbot-tweepy's Introduction

This is the code that runs the @CleBillBot twitter acccount. This README assumes some familiarity with AWS, Lambda, S3, and Python.

Flask is used to create and deploy the application to Amazon's Lambda and API platforms. Tweepy is used to interact with Twitter's platform via python. Boto3 is necessary if you want to use the S3 file saving system (the info for every legislative item is also saved to a CSV file for further analysis, but it not necessary for the Twitter functions; in the code you'll see where you can comment out certain lines). Requests allow python to connect with websites and download data. LXML is a python parser of XML and HTML code. Pytz is used for timezone control (this app is for Cleveland so we're -0500).

Your Twitter bot API keys are stored in the foo/secrets.py file. Rename the foo/secrets.sample.py to foo/secrets.py and add your four key tokens you are given from the Twitter Developer dashboard. (There are many guides online explaining how to set up a Twitter bot account and handle.)

Also ensure that your zappa_settings.json file includes all of the keys contained in the zappa_settings.sample.json file in this repo.

This script can be deployed with zappa. To set it up on your own computer, first install zappa: pip install zappa

Then install all the script dependencies: pip install tweepy boto3 lxml requests pytz flask

You can then deploy to Amazon AWS: zappa deploy dev to deploy your code the very first time, and
zappa update dev to push updates to your deployment.

clebillbot-tweepy's People

Contributors

trivisonno avatar

Watchers

 avatar

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.