KalSMS is a small Android based SMS gateway I’ve released as open source. “Kal” is a Hebrew word meaning “lightweight” and “easy”, so it fits KalSMS’ primary goal of being very easy to install, maintain and work with.

KalSMS is a very thin layer between SMS to HTTP and back to SMS. For example, a simple SMS weather service works like this:

  1. A user sends an SMS “weather 10026” to a phone running KalSMS
  2. KalSMS intercepts the SMS message, and sends it to pre defined URL. In this case http://qkhack.appspot.com/weather?msg=weather+10026
  3. In this URL, a script uses Yahoo!Weather API to get the weather forecast for zip code 10025, and formats an XML response like:
        Fair 37F today, Mostly Clear 34F tomorrow, Partly Cloudy 37F Friday
  4. KalSMS parses the response, and sends an SMS back to the user with the weather forecast.

In effect the phone running KalSMS has now become an SMS server, running a weather application.

I’ve been working recently on applications that are meant to be used in places like India and Africa. This taught me that (a) SMS is accessible by a LOT more people worldwide than the web, and (b) it is MUCH harder to build an SMS app than a web app.

KalSMS tries to help this by leaving the heavy lifting to a web app, and just providing a simple, as thin as possible layer between SMS to the Web and back again. This means developers can work with the tools they already know, use state of art technologies like Heroku or App Engine that make launching a web app extremely simple and cheap, and just use an Android phone to enable the SMS part.

Current solutions require either collaboration from a local cellular provider, often a challenge for low budget projects, or setting up your own server – that is, an actual computer running the SMS gateway software connected to a cellular modem. This is non-trivial to install and maintain, and since the solutions out there are tightly coupled you have to write your actual application in a specific language or framework dictated by the SMS solution.

By being Android-based, KalSMS installation is a matter of scanning a barcode, maintenance means keeping the phone working – something almost all people in the world now know how to do. Basically an Android phone with KalSMS replaces a computer, network connection, cell modem, a UPS system and whole bunch of software.

I’ve got plenty of opinions on aid efforts and their effects over the years, but in keeping with the unwritten “produce or shut up” motto of this blog I’ll just say I think things will start to improve when more people pay attention to Bill Easterly than Bono. In my corner, I hope hackers will use KalSMS for various projects simply for its simplicity and reliability – and perhaps in time will seep into the developing world projects I had in mind when building it.


6 thoughts on “KalSMS

  1. Very, very cool. I’d be very interested to hear more about the use cases you see for this. And I wonder what sort of message volume an Android device could handle.

    Just one question: XML? Really? You aren’t sick and tired of it like I am? JSON would be sooo much nicer…

    • Thanks Avi! I’m no XML fan either, for such a small payload XML felt like a more readable choice, esp since this is meant to be simple for inexperienced devs who are used to generating HTML with PHP.

      (I may be wrong, fortunately the code is open ;))

      As for use cases, it ranged from various hacks (forward all SMS to a searchable archive, create a group-SMS server etc) to real applications – there’s a huge field of health & human rights SMS apps in developing regions, KalSMS can make developing/deploying them considerably easier.

  2. I love it. A simple and very clever tool that could be used in many different ways. I’d like to see how people pick this up and run with it.

  3. I used KalSMS and found it to be real good. However, I have two issues with it. The version I used did not have Key Words and if I recall it did not have the secret. So all messages sent to my Android phone got parsed to my server even though they were not relevant. Absence of the secret meant that any one could use my server URL and send messages to it.
    Hopefully this will get resolved in the newer versions if not done already.
    Great Show


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s