Close

SMS Garge Door Status - Attempt #3

A project log for Home Automation - Garage Door Opener

Extract best practices from existing garage door projects. Build version that suites my needs; eventually integrate into other HA efforts.

luffmanbluffmanb 04/21/2016 at 18:000 Comments

This is part 3 of searching for an SMS notification solution. See SMS Garge Door Status - Attempt #1 of this project log for part 1.

Twilio.com

This is a company that a lot of various projects requiring SMS use. They not only provide SMS gateway service but offer options for tying voice, SMS, and/or MMS (Multimedia Messaging Service) into homemade projects and professional business services alike. It's much like what we used to have with Google Voice, but the downside is it isn't free. That said, it also isn't particularly expensive for what you get.

The "trial account" is free, but to send a text you'll have to upgrade to a paying account. To get started, that means prepaying a minimum of $20 and then adding a new phone number to it for $1/number. That leaves you w/ a $19 balance to charge each msg against. The going rate is not bad either: only $0.0075 per "text." So it should last me a while.

Twilio provides official API libraries/SDKs for PHP, Ruby, Python, C#, Java, Node.js, and Salesforce. They also link to community-provided libraries for Django, Go, and C++. It's REST API are protected w/ HTTP Basic authentication, requiring account SIDs and authentication tokens--this is one way of not only preventing someone else from boosting your account and burning your balance, but also a means to prevent the spamming problem that Textbelt is currently experiencing.

Anyway, I downloaded their sample PHP code, tweaked it a bit, and confirmed that works. Now I just have to integrate it into the rest of my project pieces.


Phase 2: Send SMS notification of new door status... CHECK!


Thanks to this project for first time I saw Twilio suggested...
http://www.instructables.com/id/Raspberry-Pi-SMS-Garage-Door-Butler/?ALLSTEPS

Discussions