Hacker News new | past | comments | ask | show | jobs | submit login
Show HN: Gosms – Your own local SMS gateway powered by Golang (haxpax.github.io)
101 points by Omie6541 on Feb 10, 2015 | hide | past | favorite | 40 comments

A simple SMS gateway that uses GSM Modems to send SMS, can be deployed locally, supports multiple devices and provides API over HTTP just like internet based messaging gateways.

// we both are full stack developers looking for full time jobs : https://github.com/omie, https://github.com/madhurjain

> // we both are full stack developers looking for full time jobs

You should definitely watch out for "Ask HN: Who is hiring?" posts by the "whoishiring" [1] bot on the 1st of every month.

The one for February was posted some days ago and is still active [2].

[1] https://news.ycombinator.com/user?id=whoishiring

[2] https://news.ycombinator.com/item?id=8980047

Very cool. I'm an existing twilio customer, wondering how cheaply I can implement something like this. What are some recommended GSM modems to use?

Any generic 2G/3G USB Data Card from Hauwei or ZTE or Netgear or DLink which shouldn't cost more than 30$ - 40$ Check this link http://www.flipkart.com/computers/network-components/data-ca...

Thanks for the info! How much would the cell phone plan cost that allows unlimited sms messaging?

Is there any reason to use twilio over something like this? Twilio costs 0.0075 / message

Choosing between twilio or this definitely depends on your use case. Gosms is handy when you have no internet connection, you require total control over the infrastructure and such. Use twilio when you don't want to worry about anything and just send messages. There could be more scenarios too.

Twilio's pricing schemes change per country, for us in India (where 1 Rupee = 100 Paisa and USD 1 = ~62 Rupees), twilio charges 60 paisa per message. At the same time, some tel-com providers have plans that cost only 5 paisa per message. India has other limits and regulations but for personal/in-house use they hardly matter.

To add to this, If you want to send fast worldwide SMS reliably and without much hassle, use twilio or plivo or other such web sms gateways. If you want to send SMS locally, for cheap and willing to hack your way around, give GoSMS a shot. Given the time a modem takes to send an SMS, with a single modem connected, the rate of sending SMS is low (~1 message / 5 second).

Many "Unlimited" providers would be unhappy if you were sending 10s of messages per second for sustained periods of times.

Ting charges $6/device plus $0.0025 per message.

Depends on the provider. Thirty bucks? But you'd better make sure their "unlimited" means "unlimited".

How this is different from gammu-smsd or gnokii smsd? I'm in the process of contemplating a web app (for internal use) that needs to send and receive sms messages. Though I didn't yet decided what to use for the actual communication.

I believe you already knew about the alternatives (gammu, gnokii, smslib, etc.), so what are the advantages of Gosms over others?

Correct me If I'm wrong but I believe the mentioned alternatives do not provide a REST API or other features like retry, throttling, support for multiple GSM modems.

Nice. The next problem is finding an SMS service provider with good pricing. Most mainstream cell providers will try to sell you some data/voice/SMS plan at upwards of $40 a month. There are SMS-only services for which you can buy SIM cards, but they're either in the price range of regular cell service[1] or kind of sketchy.[2] Twilio may be more cost-effective. If you have a big volume of SMS, Twilio or its competitors have more bandwidth (they're tied directly to the SS7 network) than a single GSM modem.

SMS tends to be an expensive way to send data. There are lots of devices that send and receive SMS. They're generally things like industrial air conditioners reporting their status to a maintenance service every hour or so. The data volume is thus low. If you need to send more than tiny amounts of data, it's probably better to get a device that gives you an Internet connection.

[1] http://www.embeddedworks.net/m2m-data.html [2] http://www.mrsimcard.com/s-textsim.html

It' so cool to see something like this in GO.

Few years back I tried to implement a prototype very similar to this in C#.

My startup was for sharing routes through out sms, however my tel-com company was very cringe-y about the idea, so I decided to write one of my own.

Good job folks.

we too were fed up of tel-com companies over here, limitations like no more 200 messages per sim per day to prevent spam! but we really needed something for internal uses, just built it. Multiple devices support takes care of per sim limiataion :)

It's nice to have another alternative SMS implementation. The existing ones (last I looked anyway) were a bit long in the tooth.

(I've been using pushover recently, but have been looking for a good local (modern) sms gateway).

Since golang can be compiled for android, have you considered wrapping this up as an android app, which runs as a background api service? Technically you can use the android provided SMS calls.

(or is there already such an app?).

golang support on android is very limited. in fact net package is still not there, so won't be able to run on android as is for now. we thought of adding android phones support in other way. simply expose the queue over http endpoint and write an android app that will fetch-send-repeat when its started. Just short on time, and contributions are welcome :)

I'm not 100% sure how most people could use this service. While in Lithuania I could get unlimited text messages (to send inside the country) for less than 5 euros (that's probably like $6), I doubt it would go for long since the text messages would be one-way and they would block me.

Surely, all providers with cheapish text messaging plans would have clauses for commercial uses?

- This is not another messaging service, this is a software that powers such services. - People could host this on their own and use it for their applications instead of opting for other such services if it suits their use cases

Thanks for the reply!

I do understand it - you stick your own SIM card to a GSM modem and use this application to send messages via it.

I'm just contemplating that most providers would not allow endless one-way text messaging. Unless you have some sort of a business plan that allows this sort of thing.

Just looking at some use cases where this could replace Twilio/Nexmo but it seems like you would just get blocked by the carrier if you tried to send quite a handful of text messages.

P.S. I have nothing against the app and I think it's wonderful and I just MIGHT use it sometime if I'll need to send messages inside my own country. And I'll probably get blocked but it might just be worth it as I could just swap SIM cards as I could get 3000SMS for about 2.5 euros. But that's some black stuff happening in my mind now!

I've tried and failed to get gammu wammu to work. Tried both an old usb stick and and old mobile phone.

Can you recommend any usb stick that works with your program that cost less then $100 and can be ordered from the EU ? It has to support micro sim and both send and receive SMS.

@z3t4 data cards from phone providers are carrier locked and don't allow third party softwares to access modem via AT commands. We've tried with some generic data cards from Huawei and ZTE and they work great

For example http://www.amazon.co.uk/HUAWEI-E3256s-Wireless-Mobile-Broadb... or http://www.amazon.co.uk/computers/dp/B004VU09BU/

You'll have to check for micro SIM support though. I haven't come across a stick which supports micro SIM yet.

Have you tried reaching out to local carrier? They usually provide what you need. (Or do you need multiple carrier, multiple country support?)

So to set something up that can send thousands of sms (not spam, part of an app) a day, all I would need is a modem, a server, and this app? Would I need a cell phone plan or something?

yup! the GSM Modem you use will need a SIM card which needs an active plan

Nice, but what could I use this for? Try to put this information in your website.

Can be used to send SMS, where you don't have access to internet or cannot use web sms gateways or want to save some money per SMS, or have minimal requirements for personal/internal use and such. thanks though, will push to readme

Can you expand some more - does this software connect to a modem to send SMS's to nearby phones? Is this software similar to a stingray device, or am I misunderstanding this?

By modem we mean any GSM Modem device. Like a USB Data Card used for internet access, or a mobile phone connected via USB. You can send SMS anywhere. Software just allows you to use your phone / usb data card to send messages.

It just connects to the cell phone network like any other mobile device you have and then sends the SMS using the standard infrastructure.

If you don't know what it's useful for, then it's not for you.

That's a bit condescending. Twilio and similar services may not be of obvious use to everyone, for example. However, once I explained what it could be used for (and the recent patio11 Twilio presentation helps), most of my friends, while perhaps not needing it, grokked why I was interested. Some saw the utility for their own projects, as well. A more useful response would be to explain what you would use this for and why it might better/different than other solutions. Even a short, one or two sentence project synopsis is more useful than a condescending response like this.

@swah @Jtsummers Thanks for your comments guys. Updated the README https://github.com/haxpax/gosms#whats-the-use-

Thanks for writing this up - that was indeed my point.

On a sidenode, my comments on this website haven't been well received. Maybe I'm not considering that writing does not have intonation?

I thought my comment above was friendly and easy to understand, and in reality it was completely missed.

It wasn't condescending. It was a succinct, insightful and on point comment.

Basically what I was trying to say is that if you aren't aware of your need for such software (from a pretty good description in my opinion), then the software isn't for you. Just a few seconds of review of the website makes it quite obvious what the software is intended for. Meh.

Charlesnw: One of the moderators of stack overflow, ladies and gentlemen!

Even if what you say is true, the person wasn't asking whether it would be useful to him or her, just what it could be used for.

Why would anyone want to deny the opportunity to teach someone who wants to learn?

Recent patio11 Twilio presentation?

that's really nice that you already have support for multiple devices. really awesome project.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact