TwilioDevEd / notifier-node

ARCHIVED - Notifier and SMS Notifications with Express and Twilio
6 stars 4 forks source link
twilio-sms

Twilio

Archived - Notifier and SMS Notifications with Twilio Notify

Please see the docs for Twilio Notify to try out notifications.

Description

Tag users and send group notifications with one request. Twilio alerts everyone that matches the specified tags.

Local Development

This project is build using Express web framework.

  1. First clone this repository and cd into it.

    $ git clone git@github.com:TwilioDevEd/notifier-node.git
    $ cd notifier-node
  2. Install dependencies.

    $ npm install
  3. Copy the .env.example file to .env, and edit it including your credentials for the Twilio API (found at https://www.twilio.com/console). You will also need a Twilio Number.

    You can find your TWILIO_NOTIFICATION_SERVICE_SID in your Twilio console under services.

    Run source .env to export the environment variables.

  4. Make sure the tests succeed.

    $ npm test
  5. Start the server.

    $ npm start
  6. Check it out at http://localhost:3000.

How to Demo

For Help Instructions

  1. Text your Twilio number "help me". e.g.

    Help me
  2. Receive a message with instructions.

To Create a Subscription

  1. Text your Twilio number the name of the tag that you want to subscribe to. e.g.

    Rogue One

    Note: The available movies are "Han Solo Spinoff", "Rogue One", and "Episode VIII".

  2. Receive a confirmation message.

To Delete a Subscription

  1. Text your Twilio number with "unsub tag". e.g.

    unsub Rogue One
  2. Receive a confirmation message.

Meta