coders4help / lagesonum

Number website for Lageso
MIT License
15 stars 7 forks source link

Email / SMS push notifications #92

Open mcplanner-zz opened 9 years ago

mcplanner-zz commented 9 years ago

Purpose: To allow newcomers to receive an email or SMS alert when their Waiting Number is called.

Constraints: Should not require a user account or password Must work with email and SMS Must require subscription confirmation Must allow subscription cancellation Must work with all supported languages SMS messages are limited to 160 characters

Choices: Only one Waiting Number allowed per subscription No limit on subscriptions per email address or phone number A single subscription can have both email and SMS notifications If one subscription has both email and SMS notifications, unsubscribing from one will not affect the other

Nomenclature: Waiting Number: the number a newcomer is tracking; issued by LASeGo Subscription: A subscription connects one Waiting Number to a phone and/or email address. Notification: The SMS or email message sent when a Waiting Number is called

Function A: Create a new notification 1 Require user to enter one Waiting Number 2 Require user to enter at least one of: email address, or phone number 3 Send a registration message to every subscribed notification channel. ⁃ SMS: “You have registered to receive notifications for LASeGO waiting number XXXX. Respond with YES to confirm.” ⁃ email: “You have registered to receive notifications for LASeGO waiting number XXXX. Click CONFIRM to confirm.” 4 Send a confirmation message to every subscribed notification channel. ⁃ SMS: “You are now confirmed to receive notifications for LASeGO waiting number XXXX. Reply with STOP at any time to cancel this notification.” ⁃ email: “You are now confirmed to receive notifications for LASeGO waiting number XXXX. Click UNSUBSCRIBE to cancel this notification.” 5 If the user does not confirm registration on the device, they will be not be subscribed.

Function B: Sending a notification 1 Push an alert as soon as the waiting number is first reported to the system. ⁃ SMS: “Someone reported seeing number XXXX at LASeGo at HH:MM on DD/MM. Respond with STOP to stop receiving notifications on this number.” ⁃ email: “Someone reported seeing number XXXX at LASeGo at HH:MM on DD/MM. You can continue receiving notifications about this number, or click UNSUBSCRIBE to stop.” 2 If the user responses with STOP/UNSUBSCRIBE, they will be removed from further notifications

jenka13all commented 9 years ago

We have now a working, validated form for entering number and contact info; if an email ist entered, a confirmation email is sent to the entered address.

jlev commented 9 years ago

SMS notifications are mostly working via Twilio in the feature/sms_notifications branch. Needs code review, proper translations via gettext, and a pull request.