public class IncomingPhoneNumberCreator extends Creator<IncomingPhoneNumber>
Constructor and Description |
---|
IncomingPhoneNumberCreator(PhoneNumber phoneNumber)
Construct a new IncomingPhoneNumberCreator.
|
IncomingPhoneNumberCreator(String areaCode)
Construct a new IncomingPhoneNumberCreator.
|
IncomingPhoneNumberCreator(String ownerAccountSid,
PhoneNumber phoneNumber)
Construct a new IncomingPhoneNumberCreator.
|
IncomingPhoneNumberCreator(String ownerAccountSid,
String areaCode)
Construct a new IncomingPhoneNumberCreator.
|
Modifier and Type | Method and Description |
---|---|
IncomingPhoneNumber |
execute(TwilioRestClient client)
Make the request to the Twilio API to perform the create.
|
IncomingPhoneNumberCreator |
setApiVersion(String apiVersion)
Calls to this phone number will start a new TwiML session with this API
version..
|
IncomingPhoneNumberCreator |
setFriendlyName(String friendlyName)
A human readable descriptive text for this resource, up to 64 characters
long.
|
IncomingPhoneNumberCreator |
setSmsApplicationSid(String smsApplicationSid)
The 34 character sid of the application Twilio should use to handle SMSs sent
to this number.
|
IncomingPhoneNumberCreator |
setSmsFallbackMethod(HttpMethod smsFallbackMethod)
The HTTP method Twilio will use when requesting the above URL.
|
IncomingPhoneNumberCreator |
setSmsFallbackUrl(String smsFallbackUrl)
The URL that Twilio will request if an error occurs retrieving or executing
the TwiML from `SmsUrl`..
|
IncomingPhoneNumberCreator |
setSmsFallbackUrl(URI smsFallbackUrl)
The URL that Twilio will request if an error occurs retrieving or executing
the TwiML from `SmsUrl`..
|
IncomingPhoneNumberCreator |
setSmsMethod(HttpMethod smsMethod)
The HTTP method Twilio will use when making requests to the `SmsUrl`.
|
IncomingPhoneNumberCreator |
setSmsUrl(String smsUrl)
The URL Twilio will request when receiving an incoming SMS message to this
number..
|
IncomingPhoneNumberCreator |
setSmsUrl(URI smsUrl)
The URL Twilio will request when receiving an incoming SMS message to this
number..
|
IncomingPhoneNumberCreator |
setStatusCallback(String statusCallback)
The URL that Twilio will request to pass status parameters (such as call
ended) to your application..
|
IncomingPhoneNumberCreator |
setStatusCallback(URI statusCallback)
The URL that Twilio will request to pass status parameters (such as call
ended) to your application..
|
IncomingPhoneNumberCreator |
setStatusCallbackMethod(HttpMethod statusCallbackMethod)
The HTTP method Twilio will use to make requests to the `StatusCallback` URL.
|
IncomingPhoneNumberCreator |
setVoiceApplicationSid(String voiceApplicationSid)
The 34 character sid of the application Twilio should use to handle phone
calls to this number.
|
IncomingPhoneNumberCreator |
setVoiceCallerIdLookup(Boolean voiceCallerIdLookup)
Look up the caller's caller-ID name from the CNAM database ($0.01 per look
up).
|
IncomingPhoneNumberCreator |
setVoiceFallbackMethod(HttpMethod voiceFallbackMethod)
The HTTP method Twilio will use when requesting the `VoiceFallbackUrl`.
|
IncomingPhoneNumberCreator |
setVoiceFallbackUrl(String voiceFallbackUrl)
The URL that Twilio will request if an error occurs retrieving or executing
the TwiML requested by `Url`..
|
IncomingPhoneNumberCreator |
setVoiceFallbackUrl(URI voiceFallbackUrl)
The URL that Twilio will request if an error occurs retrieving or executing
the TwiML requested by `Url`..
|
IncomingPhoneNumberCreator |
setVoiceMethod(HttpMethod voiceMethod)
The HTTP method Twilio will use when requesting the above `Url`.
|
IncomingPhoneNumberCreator |
setVoiceUrl(String voiceUrl)
The URL Twilio will request when this phone number receives a call.
|
IncomingPhoneNumberCreator |
setVoiceUrl(URI voiceUrl)
The URL Twilio will request when this phone number receives a call.
|
public IncomingPhoneNumberCreator(PhoneNumber phoneNumber)
phoneNumber
- The phone numberpublic IncomingPhoneNumberCreator(String ownerAccountSid, PhoneNumber phoneNumber)
ownerAccountSid
- The owner_account_sidphoneNumber
- The phone numberpublic IncomingPhoneNumberCreator(String areaCode)
areaCode
- The desired area code for the new numberpublic IncomingPhoneNumberCreator setApiVersion(String apiVersion)
apiVersion
- The Twilio Rest API version to usepublic IncomingPhoneNumberCreator setFriendlyName(String friendlyName)
friendlyName
- A human readable description of this resourcepublic IncomingPhoneNumberCreator setSmsApplicationSid(String smsApplicationSid)
smsApplicationSid
- Unique string that identifies the applicationpublic IncomingPhoneNumberCreator setSmsFallbackMethod(HttpMethod smsFallbackMethod)
smsFallbackMethod
- HTTP method used with sms fallback urlpublic IncomingPhoneNumberCreator setSmsFallbackUrl(URI smsFallbackUrl)
smsFallbackUrl
- URL Twilio will request if an error occurs in
executing TwiMLpublic IncomingPhoneNumberCreator setSmsFallbackUrl(String smsFallbackUrl)
smsFallbackUrl
- URL Twilio will request if an error occurs in
executing TwiMLpublic IncomingPhoneNumberCreator setSmsMethod(HttpMethod smsMethod)
smsMethod
- HTTP method to use with sms urlpublic IncomingPhoneNumberCreator setSmsUrl(URI smsUrl)
smsUrl
- URL Twilio will request when receiving an SMSpublic IncomingPhoneNumberCreator setSmsUrl(String smsUrl)
smsUrl
- URL Twilio will request when receiving an SMSpublic IncomingPhoneNumberCreator setStatusCallback(URI statusCallback)
statusCallback
- URL Twilio will use to pass status parameterspublic IncomingPhoneNumberCreator setStatusCallback(String statusCallback)
statusCallback
- URL Twilio will use to pass status parameterspublic IncomingPhoneNumberCreator setStatusCallbackMethod(HttpMethod statusCallbackMethod)
statusCallbackMethod
- HTTP method twilio will use with status callbackpublic IncomingPhoneNumberCreator setVoiceApplicationSid(String voiceApplicationSid)
voiceApplicationSid
- The unique sid of the application to handle this
numberpublic IncomingPhoneNumberCreator setVoiceCallerIdLookup(Boolean voiceCallerIdLookup)
voiceCallerIdLookup
- Look up the caller's caller-IDpublic IncomingPhoneNumberCreator setVoiceFallbackMethod(HttpMethod voiceFallbackMethod)
voiceFallbackMethod
- HTTP method used with fallback_urlpublic IncomingPhoneNumberCreator setVoiceFallbackUrl(URI voiceFallbackUrl)
voiceFallbackUrl
- URL Twilio will request when an error occurs in TwiMLpublic IncomingPhoneNumberCreator setVoiceFallbackUrl(String voiceFallbackUrl)
voiceFallbackUrl
- URL Twilio will request when an error occurs in TwiMLpublic IncomingPhoneNumberCreator setVoiceMethod(HttpMethod voiceMethod)
voiceMethod
- HTTP method used with the voice urlpublic IncomingPhoneNumberCreator setVoiceUrl(URI voiceUrl)
voiceUrl
- URL Twilio will request when receiving a callpublic IncomingPhoneNumberCreator setVoiceUrl(String voiceUrl)
voiceUrl
- URL Twilio will request when receiving a callpublic IncomingPhoneNumber execute(TwilioRestClient client)
execute
in class Creator<IncomingPhoneNumber>
client
- TwilioRestClient with which to make the requestCopyright © 2011 Twilio, Inc. All Rights Reserved.