O'Reilly logo

Node Cookbook Second Edition by David Mark Clements

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Sending an SMS

Being able to send SMS text messages to our users is another way for us to connect with them.

It is possible to connect our computer to a GSM modem, interact with specialized libraries (such as Asterisk, asterisk.org, combined with ngSMS, ozekisms.com), and interface with the libraries and the telephony equipment to send SMS messages.

There are easier ways though. Services like Twilio provide gateway SMS services, where we contact them via an HTTP REST API and they handle the SMS sending for us.

Note

For detailed information on REST architecture, see http://en.wikipedia.org/wiki/REST.

In this recipe, we'll convert our newsletter mail out app into a blanket SMS service using the twilio module.

Getting ready

This recipe requires a Twilio ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required