Twilio Conversations群组MMS不起作用。

huangapple go评论113阅读模式
英文:

Twilio Conversations Group MMS not working

问题

我有一个启用了SMS/MMS功能的Twilio试用账户,并拥有一个号码。

我想在一个群组MMS聊天中使用这个号码。我在Tut上的教程后创建了一个非常基本的测试。

我尝试发送消息的两个号码已经经过验证。我可以单独发送消息给这些号码,但不能在群聊中发送。请查看下面的代码:

const accountSid = "ACCOUNT_SID";
const authToken = "AUTHO_TOKEN";
const client = require('twilio')(accountSid, authToken);

(async () => {
    const conversation = await client.conversations.v1.conversations.create({ friendlyName: 'TEST' });
    const participant = await client.conversations.v1.conversations(conversation.sid)
        .participants
        .create({
            identity: 'realEstateAgent',
            'messagingBinding.projectedAddress': '+TWILIO_NUMBER'
        });

    const one = await client.conversations.v1.conversations(conversation.sid)
        .participants
        .create({ 'messagingBinding.address': '+NUM_1' });

    const two = await client.conversations.v1.conversations(conversation.sid)
        .participants
        .create({ 'messagingBinding.address': '+NUM_2' });

    const msg = await client.conversations.v1.conversations(conversation.sid)
        .messages
        .create({
            body: 'This is a test message',
            author: 'realEstateAgent'
        })
        .then(message => console.log(message.sid));
})();

一切似乎都成功运行,并且 message.sid 得到了记录。然而,没有一个号码收到消息。但是,如果我只发送给一个号码,这段代码可以正常工作。

消息日志显示消息已经被sent发送到两个号码,但没有被交付。它没有显示任何其他信息,这让我相信可能发生了错误。

有什么见解吗?

谢谢!

英文:

I have a Twilio Trial account with a number that has SMS/MMS enabled.

I want to use the number in a group MMS chat.
I have a very basic test that I created after following the tutorial on Tut

The two numbers I'm attempting to send to have been verified. I'm able to send messages to these numbers individually, just not in a group chat. Please see code below

const accountSid = "ACCOUNT_SID";
const authToken = "AUTHO_TOKEN";
const client = require('twilio')(accountSid, authToken);

(async () => {
    const conversation = await client.conversations.v1.conversations.create({ friendlyName: 'TEST' });
    const participant = await client.conversations.v1.conversations(conversation.sid)
        .participants
        .create({
            identity: 'realEstateAgent',
            'messagingBinding.projectedAddress': '+TWILIO_NUMBER'
        });

const one = await client.conversations.v1.conversations(conversation.sid)
    .participants
    .create({ 'messagingBinding.address': '+NUM_1' });

const two = await client.conversations.v1.conversations(conversation.sid)
    .participants
    .create({ 'messagingBinding.address': '+NUM_2' });


const msg = await client.conversations.v1.conversations(conversation.sid)
    .messages
    .create({
        body: 'This is a test message',
        author: 'realEstateAgent'
    })
    .then(message => console.log(message.sid));

})();

Everything appears to run successfully and the message.sid gets logged out. However, none of the numbers receive the message. But, this same code works if I just send to one number.

Messaging logs show that message has been sent to both numbers, but not delivered. It doesn't say anything else making me believe an error occurred.

Any Insights?

Thanks!

答案1

得分: 1

我没有看到任何额外的新闻发布,所以这很可能是你的问题1。 Twilio在运营商级别遇到了问题,并阻止了所有新客户的群组短信。 所以如果你有一个旧帐户(或者能访问一个旧帐户),你可能可以使用它,但根据他们最后的声明,你目前还不能使用它。

我看到的解决方法是使用对话并通过一对多渠道分发消息,但我自己没有尝试过,也不熟悉其中的局限性。

此外,电话号码也有限制。

英文:

I have not seen any additional press release, so this is likely your issue. Twilio had issues at the carrier level and blocked groupmms for all new customers. So if you have an older account(or access to one) you can potentially use it, bit otherwise as of their last statement you cant use it at the moment still.

The work around ive seen is to use conversations and distributed it a message via a one to many channel, but i have not tried this myself and im not familiar with the drawback.

Also their are limitations on the phone numbers as well

huangapple
  • 本文由 发表于 2023年7月12日 23:26:59
  • 转载请务必保留本文链接:https://go.coder-hub.com/76672202.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定