Create an IncomingPhoneNumber resource

Provision a Phone Number and Area Code

Path Params
string
required

The Main Account SID that will create the resource. Pattern: ^AC[0-9a-fA-F]{32}$ Min length: 34 Max length: 34

Form Data
string
required

The desired area code for your new incoming phone number. Can be any three-digit, US or Canada area code. We will provision an available phone number within this area code for you. You must provide an area_code or a phone_number. (US and Canada only).

string
required

The phone number to purchase specified in E.164 format. E.164 phone numbers consist of a + followed by the country code and subscriber number without punctuation characters. For example, +14155551234.

string

The API version to use for incoming calls made to the new phone number. The default is 2010-04-01.

string

A descriptive string that you created to describe the new phone number. It can be up to 64 characters long. By default, this is a formatted version of the new phone number.

string

The SID of the application that should handle SMS messages sent to the new phone number. If an smsapplication_sid is present, we ignore all of the `sms*_urlurls and use those set on the application. Pattern:^AP[0-9a-fA-F]{32}$Min length:34Max length:34`

string
enum

The HTTP method that we should use to call sms_fallback_url. Can be: GET or POST and defaults to POST.

Allowed:
string

The URL that we should call when an error occurs while requesting or executing the TwiML defined by sms_url.

string
enum

The HTTP method that we should use to call sms_url. Can be: GET or POST and defaults to POST. Possible values: GET POST

Allowed:
string

The URL we should call when the new phone number receives an incoming SMS message.

string
enum

The HTTP method we should use to call status_callback. Can be: GET or POST and defaults to POST. Possible values: GET POST

Allowed:
string

The SID of the application we should use to handle calls to the new phone number. If a voice_application_sid is present, we ignore all of the voice urls and use only those set on the application. Setting a voice_application_sid will automatically delete your trunk_sid and vice versa. Pattern: ^AP[0-9a-fA-F]{32}$ Min length: 34 Max length: 34

boolean

Whether to lookup the caller's name from the CNAM database and post it to your app. Can be: true or false and defaults to false.

string
enum

The HTTP method that we should use to call voice_fallback_url. Can be: GET or POST and defaults to POST. Possible values: GET POST

Allowed:
string

The URL that we should call when an error occurs retrieving or executing the TwiML requested by url.

string
enum

The HTTP method that we should use to call voice_url. Can be: GET or POST and defaults to POST. Possible values: GET POST

Allowed:
string

The URL that we should call to answer a call to the new phone number. The voice_url will not be called if a voice_application_sid or a trunk_sid is set.

string
enum

The parameter displays if emergency calling is enabled for this number. Active numbers may place emergency calls by dialing valid emergency numbers for the country. Possible values: Active Inactive

Allowed:
string

The SID of the emergency address configuration to use for emergency calling from the new phone number. Pattern: ^AD[0-9a-fA-F]{32}$ Min length: 34 Max length: 34

string

The SID of the Trunk we should use to handle calls to the new phone number. If a trunk_sid is present, we ignore all of the voice urls and voice applications and use only those set on the Trunk. Setting a trunk_sid will automatically delete your voice_application_sid and vice versa. Pattern: ^TK[0-9a-fA-F]{32}$ Min length: 34 Max length: 34

string

The SID of the Identity resource that we should associate with the new phone number. Some regions require an identity to meet local regulations. Pattern: ^RI[0-9a-fA-F]{32}$ Min length: 34 Max length: 34

string

The SID of the Address resource we should associate with the new phone number. Some regions require addresses to meet local regulations. Pattern: ^AD[0-9a-fA-F]{32}$ Min length: 34 Max length: 34

string
enum

The configuration parameter for the new phone number to receive incoming voice calls or faxes. Can be: fax or voice and defaults to voice. Possible values: voice fax

Allowed:
string

The SID of the Bundle resource that you associate with the phone number. Some regions require a Bundle to meet local Regulations. Pattern: ^BU[0-9a-fA-F]{32}$ Min length: 34 Max length: 34

Responses

Language
Credentials
Basic
base64
:
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json