Skip to content
This repository has been archived by the owner on Dec 19, 2019. It is now read-only.

bikeindex/stolen_bike_alerter

Repository files navigation

Stolen bike alerter

Build Status Test Coverage

Takes api_url POSTed to it and creates a media tweet in the stolenbikecity twitter account where the bike was stolen. Sends an email back to BikeIndex to tell the bike owner what happened and to retweet.

Set up

To get this to work locally you'll have to create an app on Twitter and add environmental variables OMNIAUTH_CONSUMER_KEY and OMNIAUTH_CONSUMER_SECRET.

Twitter doesn't accept http://localhost as a callback url, so use http://127.0.0.1 - e.g. my callback url is http://127.0.0.1:3001/users/auth/twitter/callback

How to add a new twitter account to the app

Stolen Bike Alerter now uses omniauth twitter and has an actual interface!

Authenticate with twitter using the site and you'll be able to manage your account yourself!


DEPRECATED - Legacy documentation for old accounts

  1. Create the new account on twitter -- it has to have a unique email. Write the email and the password in the Google Doc.

  2. While signed in to your new account, create a twitter app at apps.twitter.com. It should probably be called stolenbikesXXX if you want to keep with our naming theme.

  3. In the Keys and Access Tokens tab you need the Consumer Key, Consumer Secret, and click on Generate Access Token and get the key and secret that that gives you as well.

  4. Record the above values in the google doc.

  5. Add the above values to the seeds file.

  6. Log in to the heroku with 'heroku run rails c production' and add the above values to the twitter_accounts table (see seed file for the proper column names.)

About

Tweets to regional twitter accounts when someone registers a stolen bike on BikeIndex.org

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages