Create validation request

POST /2010-04-01/Accounts/{AccountSid}/OutgoingCallerIds.json

An OutgoingCallerId resource represents a single verified number that may be used as a caller ID when making outgoing calls via the REST API and within the TwiML verb.

Path parameters

  • AccountSid string Required

    The SID of the Account responsible for the new caller ID resource.

Body

  • CallDelay integer

    The number of seconds to delay before initiating the verification call. Can be an integer between 0 and 60, inclusive. The default is 0.

  • The digits to dial after connecting the verification call.

  • A descriptive string that you create to describe the new caller ID resource. It can be up to 64 characters long. The default value is a formatted version of the phone number.

  • PhoneNumber string(phone-number) Required

    The phone number to verify in E.164 format, which consists of a + followed by the country code and subscriber number.

  • StatusCallback string(uri)

    The URL we should call using the status_callback_method to send status information about the verification process to your application.

  • StatusCallbackMethod string(http-method)

    The HTTP method we should use to call status_callback. Can be: GET or POST, and the default is POST.

    Values are HEAD, GET, POST, PATCH, PUT, or DELETE.

Responses

  • Created

    Hide response attributes Show response attributes object
    • account_sid string | null

      The SID of the Account that created the resource

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^AC[0-9a-fA-F]{32}$.

    • call_sid string | null

      The SID of the Call the resource is associated with

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^CA[0-9a-fA-F]{32}$.

    • friendly_name string | null

      The string that you assigned to describe the resource

    • phone_number string(phone-number) | null

      The phone number to verify in E.164 format

    • validation_code string | null

      The 6 digit validation code that someone must enter to validate the Caller ID when phone_number is called

POST /2010-04-01/Accounts/{AccountSid}/OutgoingCallerIds.json
curl \
 -X POST https://api.twilio.com/2010-04-01/Accounts/{AccountSid}/OutgoingCallerIds.json \
 --user "username:password" \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -d 'CallDelay=42&Extension=string&FriendlyName=string&PhoneNumber=string&StatusCallback=https%3A%2F%2Fexample.com&StatusCallbackMethod=HEAD'
Request example
{
  "CallDelay": 42,
  "Extension": "string",
  "FriendlyName": "string",
  "PhoneNumber": "string",
  "StatusCallback": "https://example.com",
  "StatusCallbackMethod": "HEAD"
}
Request examples
{
  "CallDelay": 42,
  "Extension": "string",
  "FriendlyName": "string",
  "PhoneNumber": "string",
  "StatusCallback": "https://example.com",
  "StatusCallbackMethod": "HEAD"
}
Response examples (201)
{
  "account_sid": "string",
  "call_sid": "string",
  "friendly_name": "string",
  "phone_number": "string",
  "validation_code": "string"
}
Response examples (201)
{
  "account_sid": "string",
  "call_sid": "string",
  "friendly_name": "string",
  "phone_number": "string",
  "validation_code": "string"
}