0

I am building a bot for Twilio (SMS) channel. When I send a Simple plain SMS to a number in US, it gets delivered with status in twilio message log as Delivered.

But when I attach any image to the message to send MMS, the message never gets delivered, and its status in twilio log remains sent always.

Here is how I'm attaching media to MMS.

var msg = new builder.Message(session);
msg.attachmentLayout(builder.AttachmentLayout.list)
msg.attachments([
    new builder.HeroCard(session)
        .title("This is Title")
        .subtitle("This is sub title")
        .text("This is text")
        .images([builder.CardImage.create(session, 'http://www.readersdigest.ca/wp-content/uploads/2011/01/4-ways-cheer-up-depressed-cat.jpg')])
]);

session.send(msg).endDialog();

I have also used another way to build message as:

var msg = new builder.Message(session)
    .text("This is a title - which can be long and multiple line sometimes<br/><br/>The body of the text can be really really long sometimes with different formats with links <http://google.com|Google><br/><br/>some times with a footer with `formats`")
    .addAttachment({
        contentUrl: 'http://www.readersdigest.ca/wp-content/uploads/2011/01/4-ways-cheer-up-depressed-cat.jpg',
        contentType: 'image/png',
        name: 'BotFrameworkOverview.png'
    });

Both messages never get delivered.

But a simple message with no media is successfully delivered as-

var msg = new builder.Message(session)
   .text("This is a title - which can be long and multiple line sometimes<br/><br/>The body of the text can be really really long sometimes with different formats with links <http://google.com|Google><br/><br/>some times with a footer with `formats`")

Twilio Log:

enter image description here

Nicolas R
  • 13,812
  • 2
  • 28
  • 57
Planet-Zoom
  • 1,005
  • 2
  • 9
  • 20
  • You may be interested in Twilio's documentation about Sent messages not delivered: https://support.twilio.com/hc/en-us/articles/223181868-Troubleshooting-undelivered-Twilio-SMS-messages (last chapter). Can you check all these points? – Nicolas R Apr 18 '18 at 12:14
  • I did check all points. But as you may see, only messages with media are not delivered while plain SMS are delivered. Carrier is AT&T Number is MMS enabled – Planet-Zoom Apr 18 '18 at 12:34
  • 1
    Small thing, but you can give it a try; there is something inconsistent in your 2nd method: `contentUrl` is pointing to a jpg file while `contentType` is 'image/png', – Nicolas R Apr 18 '18 at 12:37
  • Thanks for pointing out. but no luck. status remains Sent. One thing to notice, from 2nd method, which contains text as well as Image, Only text segment is delivered but Image segment remains with status sent. – Planet-Zoom Apr 18 '18 at 12:48
  • 1
    I can only guess that you should try with a smaller image / other image format to see if there is any restriction around that. And with another carrier – Nicolas R Apr 18 '18 at 13:22
  • I was able to use your first HeroCard code sample and was able to get mine to be delivered (I am also, as info, using a trial account). I am also using AT&T and is MMS enabled as well. [This is what I received while testing.](http://v-jonru-nodebot-twilio.azurewebsites.net/images/twilio-kitty-test.jpg) – Abandoned Apr 18 '18 at 22:04
  • I don't know if it is relevant, but you can only send MMS messages with Twilio to numbers in the US and Canada. – philnash Apr 19 '18 at 04:04
  • @philnash.. yes , I know that, Number is in US – Planet-Zoom Apr 19 '18 at 06:24
  • It might be best to send the message SIDs that are only "sent" to [Twilio support](https://www.twilio.com/help/contact) and they can look deeper into it. – philnash Apr 19 '18 at 06:26
  • @NicolasR..Sorry for too many typo errors..Thanks for correction. :) – Planet-Zoom Apr 19 '18 at 06:34
  • @philnash..had chat with twilio support and this is the reply from them.... " I further investigated with our carrier and they confirmed that all MMS messages sent to +16507XXXXX on 4/18 were successfully delivered. May you please confirm that only MM3xxxxxxxxxxxxxxxx or other MMS messages were not delivered to +16507XXXXXX. If it's just MM3xxxxxxxxxxxxxxxx that was not delivered, I will recommend that the end user please restart their phone and please kindly retest." – Planet-Zoom Apr 19 '18 at 06:37
  • Finally got it working. The number of end user in US was not MMS enabled. – Planet-Zoom Apr 20 '18 at 09:23

0 Answers0