Git Product home page Git Product logo

townhall-sms-alerts's Introduction

townhall-SMS-alerts Node.js CI

Motivation: Many people want to know when their member of congress is holding a town hall. Currently they can access this information by going to townhallproject.com and by signing up for email alerts. We want to make this information even more readily available by allowing people to access it with their phones via SMS.

Running locally:

  • you will need a twilio number and a tunneling service, and a firebase database

Setting up twilio

  • tunneling service: follow directions here

Setting up firebase

  • the two endpoints you need are townHalls and zipToDistrict
  • make a new firebase database, add these endpoints and upload JSONS from data folder.

in your .env file

  • FIREBASE_PROJECT_ID : project id from firebase, usually your project name
  • FIREBASE_PRIVATE_KEY : private key provided by firebase
  • FIREBASE_CLIENT_ID : provided by firebase, it's the client email
  • PORT : defaults to 3000
  • SESSION_SECRET : for express-session

Running

  • run npm i
  • run npm start or nodemon, will tell you the port you are on
  • open new terminal window, run ./ngrok http [PORT]
  • text your twilio number

MVP:

User will text a number their zip code, in response they will get all upcoming events in their district (including Senate events). The event information will include the Member of congress, the title, and a link to directions.

  • Current testing phonenumber in production: 415-231-1324
  • Zip with events: 27278

Stretch Goals:

Ongoing SMS alerts

  • Users will be able to sign up for ongoing alerts in their area.
  • We will send texts when a new event is posted to the database.
  • First version:
    • add users with events to a temp queue endpoint, and then at ~1pm pacific time, send out all texts with events within a time cutoff (1 or 2 weeks), and delete from the queue.
  • Second version:
    • Be smarter about when we send texts, based on when and where the event is occuring
    • send out alerts when events are changed (but only date or location).

Database:

We will be using town hall project's firebase database. Firebase docs.

Messaging:

We will be using Twilio's API. Twilio docs.

townhall-sms-alerts's People

Contributors

ddavis1306 avatar dependabot[bot] avatar hanhthaoluu avatar jason94 avatar meganrm avatar moyaog avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

townhall-sms-alerts's Issues

Send test vol recruitment text

To 250 text subscribers. Ideally at 6pm ET or thereabouts.

Forward replies to Nathan (206.300.2296) in a way that lets Nathan reply in the same text chain.

COPY:

Hi [name]! This is Nathan with Town Hall Project. Our mission to hold our elected leaders accountable to the people they work for (the people!) is only possible with our volunteers.

We're less than a month away from a 5-week Congressional recess --when most of the town halls for the entire year are held, and we need YOUR help!

Can you volunteer just 1 hour / week to help us make sure Americans are informed of crucial opportunities to Show Up and Speak Out.

If you're interested, please contact us via this short form: bit.ly/2J3kQMD.

With your help, we can take back our democracy and make this the country we know it can be.

[+ the standard opt out text]

Send vol recruitment text to 39 states

Please send to:

Alabama
Alaska
Arkansas
California
Connecticut
Delaware
Georgia
Hawaii
Idaho
Illinois
Indiana
Iowa
Kansas
Kentucky
Louisiana
Massachusetts
Minnesota
Mississippi
Missouri
Montana
Nebraska
New Hampshire
New Jersey
New Mexico
New York
North Dakota
Ohio
Oklahoma
Oregon
Rhode Island
South Dakota
Tennessee
Texas
Utah
Vermont
Washington
West Virginia
Wisconsin
Wyoming


Hi! This is Nathan with Town Hall Project.

Hard to believe but Congress is only in session 12 more weeks in 2019. But there's still time for crucial legislation to pass with real constituent pressure.

Can you volunteer just 1 hour / week from your own home to help us make sure Americans are informed of crucial opportunities to Show Up and Speak Out?

To learn more, please reply back with YES

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.