This Twitter bot is alive! It intelligently responds to @mentions with weather related information and selectively retweets interesting things from popular weather related accounts. Try things like: "What's the weather in London?" or "When will the sun set in San Francisco today?"
<img style="display:block;margin:0 auto;"src="http://i.imgur.com/ACxHvhk.jpg" width="400px"/>
##Preparation and installation
####Install Node.js
####API Keys
Create a Twitter Application and generate application keys.
Create an Wolfram Alpha account and generate an API Key.
You will have to update config.js
with the keys obtained from Twitter Dev and OpenWeatherMap.
####Downloading, Installing and Running Locally
Clone GitHub repo:
git clone https://github.com/brandoniscool/tweather2
Change directory, install the node module dependencies, start bot:
cd tweather2
npm install
npm start
##Deploying to Amazon's EC2
- Create an EC2 instance.
- Generate and download private key file.
- SSH into your instance.
- SFTP copy files into your instance.
- NPM install forever to allow your scripts to run continuously.
##Resources
- Twitter Developers - https://dev.twitter.com/
- Wolfram API Docs - http://products.wolframalpha.com/api/documentation.html
- Node.js official documentation - https://nodejs.org/api/
- Node NPM Package Manager - https://www.npmjs.com/
- Getting Started with Amazon EC2 Linux Instances - http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EC2_GetStarted.html