I've been working on a simple appointment reminder flow in Twilio Studio and it has worked great, until I decided to use a content template specifying the Template SID:
The specified content template has been approved already, and the flow was working through whatsapp properly before using a custom message rather than with the content template.
In the flow log there's a deliveryFailure error when launching the flow with the following output:
To: whatsapp:+57xxxxx
From: whatsapp:+14xxxxx
Content Sid: HX9f1xxxxxxxxxxxxxxxxxxxx
Content Variables: {"1":xxxx, "2": xxxxxxxx}
Failure sending message: A text message body or media urls must be specified.
It's worth to mention again that the content template has been already sent to Meta and it's approved to be used:
Any guidance on this matter will be appreciated, since the error is quite ambiguous.
After contacting the awesome Twilio Support Team, they pointed out the issue with my flow. It ended up being a mistake on my side when triggering the execution of the Flow via a REST API. For the Send and Wait for Reply widget to work properly you need:
MG32xxxxxxxxxxxxx
:So after triggering the flow execution via API REST and changing the
From
parameter to use the Messaging Service SID instead of the number, it worked perfectly. I'm using PHP to trigger the Flow, so my code looks like this:It's not easy to deduct this, specially when you're new with the Twilio Tools, but hope this helps someone using the same widget in Twilio Studio.