Zapier Twilio integration is very slow. Is there a way to filter with Zapier and send SMS with Twilio with no delay? - twilio

I have created a Zap to send an SMS to a mobile number every time a new email, with a specific subject, is received.
I've created two tasks:
1st. Zapier Filter, filters the emails by the right subject.
2nd. Twilio send this email as SMS.
I find that it takes up to 10 minutes or more for that email to be sent as an SMS, and time is very relevant in this automation. Is there a way to speed up the process so Twilio sends the SMS as soon as the email arrives and Zapier has filtered it?
I am not 100% sure where us this delay happening. Zapier or Twilio?
Thanks,
Aitor

There is a Twilio You Tube Tutorial which shows you how to set-up email to SMS, this could be another way to set-up the same requirement.
How to forward email to text messages using Twilio and SendGrid
To identify your current issue, you can send the email, record the time, and then check the Twilio Console messaging logs to find the SMS message associted with that email and record the time; then compare the time differences.

This delay is only happening because of the plan you have on zapier.
If you upgrade your plan, their event listeners can run <1 minute, but on the lower tier plans, you can except 5-10 minute delays. Check out their pricing page & look at the update time:
Zapier pricing
If you want this to run faster & don't want to upgrade zapier plans, the option above is a great choice.

Related

Restrict outgoing Twilio SMS messages to Verified Caller IDs

By default, Twilio trial accounts can only send SMS to numbers that are listed as Verified Caller IDs in the Twilio console. These numbers have to be added manually, and require a verification message before they can receive SMS. This is an excellent feature for development, as it prevents accidentally sending SMS to wrong numbers.
My problem, is that I am developing for a client whose account is already out of trial status. I don't want the software in development to be able to send text messages to any number, because there is a risk of sending dev messages to the client's actual customers. However, we need to be able to send to some numbers for testing. Is there any way to turn the trial behavior back on? That is, can we somehow configure Twilio to only allow sending SMS to verfied numbers, even if it is not a trial account?
If this isn't possible, I think I can query the Outgoing Caller IDs resource from my program to verify the recipient number against the list before sending. However, this puts the responsibility back on my development team, and the possibility for mistakes remains. I'd like to be able to block the behavior at the Twilio level.
This behavior is only applied for trial accounts, however I'll pass this feedback on internally.
You'll need to replicate this behavior yourself for your applications using an upgraded account.
As you mentioned, you can query the Outgoing Caller IDs to get the phone numbers you have already verified with Twilio and use that as an accept list.
However, for your use case, you can store and fetch the accept list using whatever way is most convenient for you, like in code, file, database, etc.
Depending on your needs, you could embed this logic directly into your app, or use a single shared library, or create a web API that all other apps have to use to send texts.
Good luck! We can't wait to see what you build!
Update after getting internal feedback.
You can create a new trial account, even with the same Twilio profile, which would give you promotional credits and the same verified Caller ID limits again.
The promotional credit should last you a long time for test scenarios.

How to track Twilio sms message relationships in my application

I am dev'ing a project where someone creates an event, and a group of people get an sms message inviting them. I want the recipient to be able to rsvp via sms. So if they respond "yes" I want to know what event_id they are responding to0.
I am passing a:
"statusCallback" => "https://cbd5-67-183-175-137.ngrok.io/receive-note/12345"
(not a real event id, just testing)
I don't care about the message status at this point, just if a response comes in. What parameter can I pass to the create message call that will allow me to dynamically track what event this invite was for? Is it a webhook or some kind of grouping?
Twilio developer evangelist here.
There is no concept of replying to a specific message in SMS, messages are just chronological.
The statusCallback URL for an SMS will only report on the status of the message you are sending to the end user, from queuing the message to be sent all the way through to delivery.
When a user sends an SMS to your Twilio number it triggers the incoming message webhook.
The incoming message webhook has no connection to an outbound message at all. So you will have to work out what message you think the user is replying to. A simple way to do this is to assume that they are replying to the last message you sent to them or the last event invite.
You are probably already considering what might happen if a user is sent invites to more than one event at the same time. How can you distinguish which event they are replying about. You have a couple of options here.
You can only ever send one SMS about an invite at a time, up until a timeout of sorts. That way, when a user replies you can always assume it's about the latest message.
Or, you can send invite message from different Twilio numbers. If you then store the outbound number with the invite you can look up replies based on the user's number and the number they replied to and calculate which invite they are responding to. To achieve this, you need more than one Twilio number, but you should only need as many numbers as the maximum estimated number of events a user might be invited to at one time.
Finally, you could ask the user to include an event ID or similar in their reply which you can then parse out, but this is likely to be a difficult ask of users.
This exists in SendGrid and is very useful. I don't understand how it's not implemented in Twilio.

Fraud messages were sent by my Twilio number

I am a big fan of Twilio and I love to use Twilio
Since a month ago, some unexpected things occurred on my Twilio account,
Fraud messages were sent by my Twilio number around 4 times so far,
Every time, the fraud happened, Twilio suspended my account to ask me to investigate this fraud,
I tried to find something wrong with me, but I wasn't able to find what is wrong here
I never shared my credentials, but fraud messages were sent by my Twilio number.
Here is a number of things I want to mention
Only one number was used for each time
I released the numbers used for fraud when I found the fraud, but another number was used for the fraud again
3,000 fraud messages were sent at once
The fraud messages were related to some other services like Amazon ads, Apple ads, etc.
What I think
I don't think someone hacked my account and send this fraud message using my Twilio number since only one number is used for this Fraud
Maybe these numbers are shared by other VoIP services, meaning two services are using one number at the same time
I want to know
if someone could send messages using my number without auth token and account sid on Twilio?
if Twilio doesn't know how to prevent this fraud?
if anyone else has this experience on Twilio?
what is the best and secure service for SMS, I am considering Telnyx, any idea?
Thanks in advance

Twilio - Clarification on the number of Whatsapp messages that the sandbox can handle

I would like to build an app with twilio that requires to send the same message to 10 people at the same time.
However, on the documentation it is said:
Sandbox numbers are restricted to 1 message every 3 seconds.
So, does it mean that if I send the text: "Hello" to then person, the last person will receive the text after 30 seconds or so?
Yes, You're restricted to send a message at a time.
One thing, If you are using Twilio's WhatsApp sandbox then you can't send a free-form message like "hello". You can only able to use their pre-approved message template.
There are 2 reasons:
You are trying to send a message to a user who has not joined your sandbox.
You are sending a free form message outside the WhatsApp session to the user. A WhatsApp session lasts for 24 hours after the last inbound message you receive from a user. Outside a WhatsApp session, you may only send a pre-approved template message to the user, any message that doesn't match a pre-approved template will be sent by Twilio as a free form message. See a list of templates pre-approved for the sandbox here!.
For more details, you can see this FAQ https://www.twilio.com/docs/whatsapp/best-practices-and-faqs#sandbox

send text message to mobile number by free service

There is any way for send text message to mobile number by any free service.
I have done that by twilio, but I don't want to purchase any thing,
Is there any in-build functionality in rails, to send text message in phone number like email ?
There is No build-in functionality in rails for sending text messages.
Instead of that you can use third party services. (msg91, sendgrid,
gupshup). In that Per account they will give 100 free sms per month.
You can use that service without buying anything.
If you want to send more messages you have to purchase paid services.
.

Resources