[RELEASE] Telnyx SMS Notification Driver

Yet another SMS notification driver. :wink: This one supports Telnyx.

I use both Twilio & Telnyx at home and at work. Both are international carriers with global support. If you haven't aren't familiar with one, you probably know the other. They have similar base prices for a DID (phone number) but Telynx SMS rates (as of this writing) are about half of Twilio's ($0.0025 USD per SMS message). I use Telnyx for my primary VoIP transport with Twilio as a backup route.

The basis for this driver came from @ritchierich's Twilio driver set. As such, it also has a parent driver that creates child notification devices. You only need to configure the parent once no matter how many SMS recipients you may have.

Alphanumeric Senders are supported. This negates the need for an outbound phone number and allows you to have your messages come from "Hubitat" or "The House" instead of a number. Unfortunately, alphanumeric senders are not supported in the US or Canada.

To use this driver set:

  1. Create a Telnyx account if you don't already have one. That link contains my referral code which will give you a $20.00 credit. That should cover a phone number and about a 100 SMS messages a month 18 months. You don't have to use that link but that's a lot of free trial time! FULL DISCLOSURE: I get a referral credit as well.

  2. Purchase a local phone number and/or create a messaging profile if you don't already have one:

  3. Copy your API Key:

  4. Add both the [SMS container and SMS Device drivers] manually (Hubitat/Drivers/Telnyx at main ยท MHedish/Hubitat ยท GitHub) to your HE hub or via the Hubitat Package Manager (recommended).

  5. Create a new virtual device, selecting Telnyx SMS Container as the type and then save the device:

  6. Select the newly created device from your device list and then paste your Telnyx API Key from your Telnyx account. If you intend to use an Alpha Sender, move the slider. Click on Save Preferences. Once you do this, the driver will validate your API Key and retrieve each of the phone numbers associated with your account and/or the Messaging Profile IDs if you chose to use an Alpha Sender:

  7. Select the phone number or profile you wish to use and click Save Preferences.

  8. Enter a child Device Label and destination phone number and click on Create Device. The destination phone number must be entered in E.164 format (e.g. US and Canada: +18005550101, Cyprus: +35790863899). You can change the destination number directly in the child device without deleting and recreating the device if you ever need to change that number. No need to redo your rules or pistons.

  9. You can create multiple child notification devices from the same page. Each will use the same Telnyx API Key and sender information.

Once the child devices are created, you can add them as notification devices in Rule Machine, webCoRE, HSM, etc.

I haven't added text-to-speech capability to the driver yet. It's not something I would use and, unlike Twilio, Telnyx doesn't have their own server to support the necessary XML. It could be set up with other free services (e.g. Uguu or Heroku) but that's would end up with a more complicated configuration. If there's enough demand, I'll take another look at adding TTS capability.

2 Likes

i dont like that they dont advertise any price on their website without having to contact sales.. Seems flakey to me.. Depending on who you are they give you a different price.. Why wont they post their prices.
sorry i found the pricing on the bottom after scrolling down.

not for me i gues my own domain lgk.com doesnt work

i get this

You cannot register using an email address from this domain. Use another email address or contact our support team if you need additional help.

The pricing link is on the top of their site. Messaging Pricing - SMS/MMS & More

As for your domain issue, it might be the way you have that domain name set up. I just looked and there are a number of DNS, MX, and web issues there. I'll bet their automated systems couldn't verify that domain.

I've found their support very responsive if you want to reach out to them or, perhaps, one of the other SMS solutions is best for your configuration.

UPDATE: This driver is now available via Hubitat Package Manager (HPM) Thanks, @dman2306!

1 Like

I have some credit remaining with Twilio. I've signed up for Telnyx with your referral link. Once I've ran out of the credit with Twilio I'll be jumping over to Telnyx.
Thanks for this!

You're welcome! Thank you for using the link too! :wink: