How to Easily Migrate Your SMS/MMS Application from Telnyx to Plivo

Migrating from Telnyx to Plivo is a seamless and painless process. The two companies’ API structures, implementation mechanisms, and SMS and MMS message processing are similar. We wrote this technical comparison between the Telnyx and Plivo APIs so that you can scope the changes for a seamless migration.

Understanding the differences between Telnyx and Plivo development

Most of the APIs and features that are available on Telnyx are also available on Plivo, and the steps involved are almost identical. This table gives a side-by-side comparison of the two companies’ features and APIs. An added advantage with Plivo is that not only can you code using the old familiar API method, you can also implement your use cases using PHLO (Plivo High Level Objects), a visual workflow builder that lets you create workflows by dragging and dropping components onto a canvas — no coding required.

Features and APIsTelnyxPlivoSimilaritiesImplementation Interface
SMS API: Send SMS messagesRequest and response variables’ structureAPI
PHLO
MMS API: Send MMS messagesRequest and response variables’ structureAPI
PHLO
10DLC: 10-digit long code (10DLC) phone numbersRegistration process and usageConsole
Managed number pool for US/CA MessagingPowerpackFeature parityAPI
Console
Phone number managementFeature parityAPI
Console
HTTP callbacksFeature parityAPI
XML
PHLO

Plivo account creation

Start by signing up for a free trial account that you can use to experiment with and learn about our services. The free trial account comes with free credits, and you can add more as you go along. You can also add a phone number to your account to start testing the full range of our voice and SMS features. A page in our support portal walks you through the signup process.

You can also port your numbers from Telnyx to Plivo, as we explain in this guide.

Migrating your SMS application

You can migrate your existing application from Telnyx to Plivo by refactoring the code, or you can try our intuitive visual workflow builder PHLO. To continue working with the APIs, use one of the quickstart guides to set up a development environment for your preferred language. Plivo offers server SDKs in seven languages: PHP, Node.js, .NET, Java, Python, Ruby, and Go. For another alternative that lets you evaluate Plivo’s SMS APIs and their request and response structure, use our Postman collections.

How to send an SMS message

Let’s take a look at the process of refactoring the code to migrate your app from Telnyx to Plivo to set up a simple cURL application to send an SMS message by changing just a few lines of code.

TelnyxPlivo
<div><pre>import telnyx 

telnyx.api_key = “<api_key>”

telnyx.Message.create( from_=’<sender_id>’, to=’<destination_number>’, text=”Hello, world!”, ) </code></pre></div> | <div><pre>import plivo

client = plivo.RestClient(‘<auth_id>’,’<auth_token>’) response = client.messages.create( src=’<sender_id>’, dst=’<destination_number>’, text=’Hello, from Python!’,) print(response) </code></pre></div> |

Alternatively, you can implement the same functionality using one of our PHLO templates. For example, if you want to send an SMS message, your PHLO would look like this.

Create PHLO for outbound SMS

Migrating your MMS application

How to send an MMS message

Let’s take a look at the process of refactoring the code to migrate another application from Telnyx to Plivo — a simple cURL application to send an MMS message — by changing just a few lines of code.

TelnyxPlivo
<div><pre>import requests 

profile_secret = ‘YOUR_MESSAGING_PROFILE_SECRET’

headers = { ‘x-profile-secret’: profile_secret, } url = ‘https://sms.telnyx.com/messages’ payload = { “from”: “<sender_id>”, “to”: “<destination_number>”, “body”: { “subject”: “Picture”, “media_urls”: [ {“img”: “https://media.giphy.com/media/26gscSULUcfKU7dHq/source.gif”} ] } }

response = requests.post( url, headers=headers, json=payload )

print(response.text) </code></pre></div> | <div><pre>import plivo client = plivo.RestClient('<auth_id>','<auth_token>')

response = client.messages.create(
    src='&lt;sender_id&gt;',
    dst='&lt;destination_number&gt;',
    Text ='Hello from Plivo MMS',
media_urls=['https://media.giphy.com/media/26gscSULUcfKU7dHq/source.gif'],
    type_='mms')
print(response) </code></pre></div> |

Alternatively, you can implement the same functionality using one of our PHLO templates. For example, if you want to send an MMS message, your PHLO would look like this.

Create PHLO for outbound MMS

More use cases

You can migrate applications for other use cases too:

Porting your existing numbers from Telnyx to Plivo

If you want to continue using your phone numbers from Telnyx, you can port the numbers to Plivo painlessly without having any downtime on your service for your customers. Our number porting guide shows you how to initiate the process.

Buy new phone numbers for your migrated app

Those are the basics for migrating from Telnyx to Plivo. Our simple APIs work in tandem with our comprehensive global network, using Plivo’s premium direct routes that guarantee the highest possible delivery rates and the shortest possible delivery times for your SMS messages, making Plivo the best Telnyx alternative. See for yourself — sign up for a free trial account.

comments powered by Disqus

By submitting this form, you agree we may contact you in the manner described in our Privacy Policy.