The Hosted Phone Numbers API is currently in development and not intended for use by new customers. This documentation exists to support customers who are already using the API. A new version of this API will be released as a generally available (GA) product in the near future. New customers should wait for the Hosted Phone Numbers GA release.
A Hosted Number provides a method for customers to use Twilio's Programmable Messaging, Functions, and Studio products to send and receive messages on voice-enabled numbers they already own as part of an established voice application.
No, Hosted Number does not affect your voice capabilities of the number. Hosted Number only registers the number for messaging to route in and out of Twilio's platform.
Hosted Number supports US and Canada numbers. Mobile numbers are not supported. Numbers already owned by a Twilio account for voice services cannot be hosted on another Twilio account for messaging services.
You can initiate the hosting of your number using the Twilio Console or programmatically with an API. Twilio will require the end-user to complete ownership verification and LoA (Letter of Authorization) signature.
Twilio currently provides the ability to verify ownership of a number. It is a phone call that the end-user answers and passes back a security token to Twilio.
By submitting a phone number to the Hosted Numbers API or Console, the phone number will be evaluated for eligibility. Eligibility is determined by the number's country of origin and if the number is currently messaging enabled.
If you would like to check a number's eligibility before it is submitted, Twilio offers Lookup, a tool to see information about the number. If a number is not of type mobile
, then the number is eligible to be Hosted for SMS. For toll-free numbers, if type is null
, generally, the number is eligible to be Hosted for messaging.
For example, here is a lookup for an eligible Canadian local number:
1{2"caller_name": null,3"country_code": "CA",4"phone_number": "+19029052034",5"national_format": "(902) 905-2034",6"carrier": {7"mobile_country_code": null,8"mobile_network_code": null,9"name": "Iristel Inc. - ON",10"type": "landline",11"error_code": null12},13"add_ons": null,14"url": "https://lookups.twilio.com/v1/PhoneNumbers/+19029052034?Type=carrier"15}
And here is an example lookup for an ineligible Canadian number:
1{2"caller_name": null,3"country_code": "CA",4"phone_number": "+19029052032",5"national_format": "(902) 905-2032",6"carrier": {7"mobile_country_code": null,8"mobile_network_code": null,9"name": "Twilio - SMS-Sybase365/MMS-SVR",10"type": "voip",11"error_code": null12},13"add_ons": null,14"url": "https://lookups.twilio.com/v1/PhoneNumbers/+19029052032?Type=carrier"15}1617
Twilio requires the following information before you can host a number:
Twilio is compliant with the General Data Protection Regulation (GDPR) and only collects Personally Identifiable Information (PII) that is mandated by the North American Numbering Plan (NANP) SMS registrars. Twilio keeps PII information for 90 days, depending on the requirement timeframe set for by sections of GDPR.
After you submit your Hosted Number request, the number goes through a three-stage onboarding process:
Preliminary eligibility check — Twilio verifies that the number is in a valid format, from an allowed country, and of a valid type.
If the number passes this check, Twilio creates a Hosted Number entry for it in your Twilio Console in the twilio-processing
status.
SMS eligibility check — Twilio verifies that the number is not already messaging-enabled. A number that is already marked as messaging-enabled
with its current provider cannot be used for Hosted SMS on Twilio. If the number is not currently messaging-enabled
, the Hosted Number Order will move to the received
status.
Verify Ownership — Once a number passes both eligibility checks, you will be able to browse to the number in your Hosted Numbers list in the Console and place a verification call to the number.
Sign an electronic LoA — After the number has been verified, you will need to create an electronic LoA that will be sent to the email address specified for signature.
Enable Hosted SMS — When the LoA is signed, the number's status will become carrier-processing
: the carrier will register the number for SMS and then test it for inbound connectivity. Once the test passes, the number will be provisioned to your account.
received
status.
pending-verification
via the API, or initiating the call on the Console's Hosted Number Order page.carrier-processing
status.
testing
status for a short period, to ensure inbound messaging connectivity is functional.completed
and your Hosted Number will move to in-use
.
If you are using a verification phone call, an NANP landline number can take up to one business day to SMS enable, test inbound connectivity, and provision to your account.
Toll-Free numbers can take up to three business days to update. If you are the RespOrg of the Toll-Free number, you are able to speed the request by accepting Twilio's request to messaging-enable the number. If you are not the RespOrg, please inform your service provider to prevent any denial of Twilio's text provisioning request.
When a number moves into action-required
, a failure reason is exposed in both the public API and in the Console to help you diagnose and resolve the issue. If the issue is internal to Twilio, a Contact Hosted Numbers Support panel will be displayed in the Console. If you are using the API, please send your Hosted Number Order SID to [email protected] for support.
Here are some typical failure reasons:
If you receive any of these, please contact [email protected].
You can verify numbers behind Interactive Voice Responses (IVRs) using both the above methods by including w
characters in the Extension
parameter. Each w
tells Twilio to wait half a second instead of playing a digit. This lets you adjust when the digits begin playing to suit the phone system you are dialing.
For example, the Extension
value wwww2wwwwww5wwwwww9
waits two seconds before sending the digit 2, followed by a three-second wait before sending the 5, and finally another three-second wait before sending a 9. You will need to tune the extension to the IVR system to be able to programmatically verify numbers behind IVR menus.
Yes! Hosted SMS works with Co-Pilot/Messaging Service.
Unfortunately, Proxy does not currently work with Hosted SMS, but Twilio expects to add support in the future.
Flex supports Hosted Number via Flex Conversations. Hosted Number is not available on Flex Legacy Messaging.
Yes, a Hosted Number is capable of making outbound calls over Twilio's network, as well as two-way messages.
If an account already has an active Verified Caller-ID and then the account requests to host the same number for messaging, the Verified Caller-ID will be deleted and the number will bypass the proof of ownership since the Verified Caller-ID is already validated ownership with a two-factor authentication call.
If you have completed the Hosted Number Order process but no longer want to host a number on Twilio, you can disassociate the number from Twilio by sending a DELETE
request on the IncomingPhoneNumbers instance resource, or by removing the number from your account on the Hosted Number instance page in the Console's Manage Active Numbers section. The number will be in the released status for three days until the number is no longer registered to Twilio's network.
US and Canadian local and toll-free can be hosted for SMS and MMS.
A Hosted Number can be transferred using the Subaccounts Public API. This functionality is not available in the Console.
You will need to generate a new port request. The new port request will generate a new Phone Number SID (PNxxx
) as soon as a port is submitted. This means there will be two numbers with the same phone_number
value, but different SIDs.
Ensure that you configure the new phone number right way with the appropriate SMS incoming URL to prevent downtime for your customers.
You can configure the number using the API or the Console. You can use the Phone Number API and the E.164 format filter to find the new phone number's SID. After finding the SID of the porting number, use the Phone Number API to configure the SMS and Voice URL.