Set up your first SMS operation - API V1

In this article we will explain in detail how to set up your first SMS Operation.

Telnyx Sales avatar
Written by Telnyx Sales
Updated over a week ago

NOTE: You will need to be Level 2 Verified to send SMS or MMS via Alphanumeric Sender ID

A Step by Step Guide for an Echo SMS Service

Let's start with sending SMS

  1. Buy a SMS-enabled number.

  2. Set up a Messaging Profile. No need to do anything on the inbound side yet. We will do that later.

At this stage, you are ready to send SMS.

  1. In "Headers", set your "x-profile-secret" to the secret under your Messaging Profile.

  2. In the "Body", you can paste in the following:

"from": "+1[your messaging-enabled number]",
"to": "+1[intended recipient]",
"body": "Hello World"

Here is a video demo showing the POSTMAN setup & SMS action

You have sent your first SMS!

Now let's build an echo SMS receive server.

  1. You need a domain

  2. You need a host

  3. You need the domain name to resolve to the said host

  4. You need to configure your firewall such that outside traffic can access your host, please allow the subnet

  5. In your particular messaging profile, under "Inbound", put in your URL:

The above steps will make sure Telnyx knows where to deliver your messages and the messages won't be dropped by your firewall. As a sanity check, ssh into your host and start a simple HTTP server that does nothing yet.

user@sms-demo:~$ sudo python -m SimpleHTTPServer 80
Serving HTTP on port 80 ...

Send an SMS to your SMS-enabled number and you should see something similar to the following: - - [27/Jul/2017 19:15:33] code 501, message Unsupported method ('POST') - - [27/Jul/2017 19:15:33] "POST / HTTP/1.1" 501 -

Now, you actually need to write a server that handles the POST request that comes in from Telnyx. If you need help to set up your first server, please use this GitHub repository as a starting point.

Here is a demo video of receiving SMS by configuring a Web-hook to messaging profile.

Sending SMS through Alphanumeric ID

Alphanumeric Sender ID allows you to set your brand or company's name as the Sender ID when sending one-way SMS.

Alphanumeric Sender ID can be set dynamically on the POST request to our API when sending an SMS. You just need to set a valid alphanumeric ID in the FROM field and we will use that.

Consider that you need to have your account verified to Level 2 in order to use this feature. Also USA and Canadian carriers block Alphanumeric ID so this feature will not work in USA and Canada.


If you want a more in depth discussion on our messaging services, check out our webinar below.

Can't find what you're looking for? Click the chat bubble at your lower right hand corner and start a chat!

Did this answer your question?