Settings

Theme

I Built an SMS Gateway with a $20 Android Phone – Jonno.nz

jonno.nz

96 points by jonnonz 22 days ago · 46 comments

Reader

pnm45678 21 days ago

As others have pointed out, this kind of automated business use is very much against the T&Cs of carriers, so if you do this heavily you can expect to run into issues.

They can and do detect this kind of thing. In a similar vein there is also a whole industry in "sim boxes". Effectively a box of SIM cards / radio equipment that acts as a server. These can similarly be set up as servers to send SMS through carriers ( https://en.wikipedia.org/wiki/SIM_box ), though seemingly the popular use is to bridge VOIP calls to local destinations and sell "minutes" to others. There is also apparently a whole industry in software to manage them. These days that management software allegedly includes measures to have the SIMs behave like humans to evade detection (the sims text each other, browse around, sleep for hours of the day, and so on).

skrtskrt 21 days ago

Starting with > Twilio charges around $0.05–0.06 per SMS round-trip

Well - use an dedicated telecom API provider that doesn't squeeze you on pricing uselessly: https://telnyx.com/pricing/messaging

Twilio is the DataDog / Microsoft of telecom APIs. The only reason you buy them is because it's the biggest name, or you have already integrated them so deeply that you're unwilling to rip it out. Their price structure also has a huge floor because they're not a carrier so they have to buy everything from real carriers.

Telnyx is actually a registered carrier so other carriers are forced by law to peer with them at lower prices.

There are other low-cost SMS API providers but AFAIK none are actual carriers and they maintain the cost by only doing messaging and relying on enormous volume to make up for tiny margins - their profitability and therefore longevity are tenuous IMO.

  • toast0 21 days ago

    > Telnyx is actually a registered carrier so other carriers are forced by law to peer with them at lower prices.

    > There are other low-cost SMS API providers but AFAIK none are actual carriers and they maintain the cost by only doing messaging and relying on enormous volume to make up for tiny margins - their profitability and therefore longevity are tenuous IMO.

    Depending on what you're doing, chances are you're better off ignoring everything an aggregator tells you. Measure delivery through actual user measures and cost keep active accounts with multiple providers and shift traffic where the cost/success is best for a given group of users (country/carrier/etc).

    All the aggregators will tell you they have global coverage and that they use 100% direct routes, and they're all lieing.

    • skrtskrt 17 days ago

      While this is somewhat true, the point of being a registered carrier is that most countries regulate that registered carriers must peer with each other at much lower costs. It is nearly-impossible to get "direct routes" everywhere, mostly because of the logistics of signing all those agreements.

      But you will generally be much better off with an actual registered carrier because they have better access to direct agreements with regulated pricing.

  • dwedge 20 days ago

    After what twilio did to authy and almost locked me out of my 2fa (and for what benefit to them?) I wouldn't use them if they were the only option

  • sumedh 21 days ago

    Is it US only?

thunderbong 21 days ago

There are so many interesting things that can be done with an Android phone. Tomorrow, if the Google Play store decides not to publish this app, I can still install it via the APK file. I wonder how many of these apps will be usable after Google's new rules about sideloading.

kotaKat 21 days ago

I can feel the 10DLC violations in the US already running through my blood. You will be eviscerated by the carriers for doing this for anything longer than a single day.

I hope your disaster recovery (or 'didn't realize') strategy includes a drawer full of additional burner Android phones and SIM cards.

  • elevation 21 days ago

    I had a client once who used a USB SIM modem as an out of band alert system set to text IT staff if certain monitoring thresholds were detected connected —useful if the Internet post were damaged. At the time, 10DLC wasn’t a concern in the system was reliable (but low volume.)

    Would such a system be untenable these days? Is it possible to provision a physical SIM that cannot legally be shut off, but is whitelisted to only 10 consenting numbers at a time?

    • kotaKat 21 days ago

      I feel like people can fly under the radar on individual small scale use in-house, but the second you're trying to run a full scale public facing service with hundreds of thousands of messages originating off one SIM card you'll get lit hard.

inhumantsar 22 days ago

definitely a great setup for development, tho probably a good idea to have the Twilio integration ready to go.

legitimate messages or not, this will look like spam if you get a surprise burst of traffic. and providers will nuke your SIM, maybe blacklist your phone's IMEI, if they suspect you're using it for spam.

also is it weird that "That's its whole life now." made feel a bit sorry for the phone? might be spending too much time in opencode...

vladsanchez 21 days ago

* FreeSwitch Messaging API - https://signalwire.com/pricing/messaging

Can/will do the trick for fractions of a penny... B)

Check their UseCases... * https://signalwire.com/products/cloud-messaging#message-use-...

Also, if you're a real PBX nerd, check Asterisk.org which pre-dates and may have sparked if/not powered early-Twilio.

ajsnigrutin 21 days ago

Easier to just use a usb/minipcie modem and operate directly from the 'server' - no batteries, no OS to crash, no nothing, simple AT commands on linux "middleware" (modemmanager etc.)

  • elevation 21 days ago

    I remember having an old Nokia phone that would expose the AT command set over a USB tty, yet still be useful as a handset. This feature wasn’t advertised in the box, I found it accidentally. Would love to find a low cost phone like this again.

jqpabc123 22 days ago

Unlimited texts.

Nope. Sorry, it is unlimited texts for *personal* use --- as defined by the carrier.

Send "too many" and your account can be suspended.

Some carriers offer an email to SMS gateway so if you can send email, you can skip the $20 Android phone.

https://20somethingfinance.com/how-to-send-text-messages-sms...

  • jonway 21 days ago

    You lose the authz of a phone number to send from. SMS gateways are super jank in my experience.

    Wish we could axe sms and rcs, too

  • JimsonYang 21 days ago

    If I’m not wrong a lot of the email gateways have died because people would spam

  • billynomates 21 days ago

    What in god's name is that cookie consent form

baconomatic 21 days ago

I used to work at a place about 10 years ago where we had a cluster of six Android devices that we had used for our SMS gateway. At the time it worked fantastic, we eventually rolled off it to a different service. Somehow, we never ran into issues with carrier.

loloquwowndueo 21 days ago

Nice ai-written article but what I missed among all the slop is : where do I get a $20 phone?

EDIT: it’s a lie. At the bottom of the page : Dedicated device: Use a cheap Android phone ($100–200) with a prepaid SIM.

  • TGower 21 days ago

    Prepaid mobile carriers offer "free" phones with one month of service. $25 a piece for Samsung a16 4-pack from Metro, if you only want 1 you can do $45 for a moto g power (8gb RAM) from Straight Talk. I've been using these as alternatives for SBC projects, cheap, battery and screen can be nice, most GPIO needs can be achieved by slapping on a $2 ESP32 clone over usb-serial. The supply will probably dry up soon, I think they might be eating a loss on just the RAM BOM.

  • childintime 21 days ago

    In Kenya you can get a Safaricom Smart Neon 4G phone for $22. It's actually not bad at all. It is an operator sponsored phone, but there is no monthly plan. Safaricom sustains its digital payment system (mpesa) with it.

  • bijowo1676 21 days ago

    There is this called called "Obama phone" (free cellphone and free service for low income people).

    You can get one if you know some people

    https://en.wikipedia.org/wiki/Lifeline_(FCC_program)

tjpnz 21 days ago

I worked with a guy (also in NZ) who did something very similar in the 2000s. A Nokia 5180 I believe, on the Telecom Ten Dollar Text plan which was theoretically unlimited (and predictably didn't last long).

dwedge 20 days ago

I considered doing something like this, but unless you're running it on your main phone, you also need to factor in the monthly price for a second sim

flemhans 21 days ago

Brings back memories of Gammu hooked up to a Nokia 6150 over serial. It was already questionable back then but never got caught by the telco

peter_d_sherman 20 days ago

Brilliant idea!

Heck, a brilliant potential bootstrapped-from-virtually-nothing-except-a-cell-phone business idea!

snvzz 21 days ago

Maybe next he'll learn about sim900 and derivatives.

$20 and full android stack seems a massive waste for this, nevermind unreliable.

  • Daviey 21 days ago

    Find a 4g/5g board cheaper than an old phone?

    • snvzz 21 days ago

      Check newer sim900 variants on aliexpress.

      Definitely cheaper, and far more reliable than a complex device running a full android stack.

    • itopaloglu83 21 days ago

      Keep in mind though you may need to deal with encoding, chunking, and other low level issues.

      • snvzz 21 days ago

        Not hard. I have such a thing as just a few lines of quickly put together python code, using pyserial, dockerized. Has run for an entire year w/o issue. ASCII and Unicode.

        It replaced a very unreliable, problematic setup somebody else had set up in the past, which was based on an android phone.

        Once I got the sim900-derived device from aliexpress, I moved the sim over and had it working in less than an hour. Polished the code and its setup during the first few days of use, and hadn't had to touch it since.

mindo 21 days ago

I've done this on symbian phone many many moons ago, for sms and mms messages. We all been there :)

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection