在 Twilo 中拨打电话时可以使用子账户的号码吗 [英] Can I use a subaccount's number when making outgoing calls in Twilo

查看:20
本文介绍了在 Twilo 中拨打电话时可以使用子账户的号码吗的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Twilio,有一个主账户 m 和一个子账户 s.我想使用主帐户的凭据 c_m 拨打电话,但使用在 s 注册的号码作为我的 from_number.我认为既然 ms 的主人,那是有可能的,但事实并非如此.

I am using Twilio, with a master account m and a subaccount s. I would like to make an outgoing call using the master account's credentials c_m, but using the number registered with s as my from_number. I assume that since m is the master of s, it would be possible, but that does not seem to be the case.

你们有遇到过类似的情况吗?请指教.

Have any of you faced a similar situation? Please advise.

推荐答案

Animesh,我是来自 Twilio 的 Megan.

Animesh, I'm Megan from Twilio.

您可以使用您的主 Twilio 帐户凭据(AccountSid 和 AuthToken)访问 Twilio 的主帐户的 REST API 以及您的任何 子帐户.

You can use your master Twilio Account credentials (AccountSid and AuthToken) to access Twilio's REST API for your master account as well as any of your subaccounts.

这将包括进行出站 API 调用,您可以在底部看到 的一些示例本页.

This would include making an outbound API call, which you can see some examples of at the bottom of this page.

诀窍是在 URI 中使用子帐户资源,但在 POST 正文中使用主凭据.

The trick is to use the subaccount resource in the URI, but the master credentials in the POST body.

人们通过使用主帐户 sid 作为凭据和 URI 一直遇到此错误.在这种情况下,您可能会遇到的错误是 编号 x 不是与帐户 y 关联的有效‘发件人’编号".

People run into this error all the time by using the master account sid for both the credentials and the URI. The error you'll likely get in this case is "number x is not a valid ‘from’ number associated with account y".

希望这有帮助!

这篇关于在 Twilo 中拨打电话时可以使用子账户的号码吗的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆