Update the attributes of a domain
Custom DNS hostnames that can accept SIP traffic
Update the attributes of a domain
Path parameters
-
AccountSid
string Required The SID of the Account that created the SipDomain resource to update.
-
Sid
string Required The Twilio-provided string that uniquely identifies the SipDomain resource to update.
Body
-
ByocTrunkSid
string The SID of the BYOC Trunk(Bring Your Own Carrier) resource that the Sip Domain will be associated with.
Minimum length is
34
, maximum length is34
. Format should match the following pattern:^BY[0-9a-fA-F]{32}$
. -
DomainName
string The unique address you reserve on Twilio to which you route your SIP traffic. Domain names can contain letters, digits, and "-" and must end with
sip.twilio.com
. -
EmergencyCallerSid
string Whether an emergency caller sid is configured for the domain. If present, this phone number will be used as the callback for the emergency call.
Minimum length is
34
, maximum length is34
. Format should match the following pattern:^PN[0-9a-fA-F]{32}$
. -
EmergencyCallingEnabled
boolean Whether emergency calling is enabled for the domain. If enabled, allows emergency calls on the domain from phone numbers with validated addresses.
-
FriendlyName
string A descriptive string that you created to describe the resource. It can be up to 64 characters long.
-
Secure
boolean Whether secure SIP is enabled for the domain. If enabled, TLS will be enforced and SRTP will be negotiated on all incoming calls to this sip domain.
-
SipRegistration
boolean Whether to allow SIP Endpoints to register with the domain to receive calls. Can be
true
orfalse
.true
allows SIP Endpoints to register with the domain to receive calls,false
does not. -
VoiceFallbackMethod
string(http-method) The HTTP method we should use to call
voice_fallback_url
. Can be:GET
orPOST
.Values are
HEAD
,GET
,POST
,PATCH
,PUT
, orDELETE
. -
VoiceFallbackUrl
string(uri) The URL that we should call when an error occurs while retrieving or executing the TwiML requested by
voice_url
. -
VoiceMethod
string(http-method) The HTTP method we should use to call
voice_url
Values are
HEAD
,GET
,POST
,PATCH
,PUT
, orDELETE
. -
VoiceStatusCallbackMethod
string(http-method) The HTTP method we should use to call
voice_status_callback_url
. Can be:GET
orPOST
.Values are
HEAD
,GET
,POST
,PATCH
,PUT
, orDELETE
. -
VoiceStatusCallbackUrl
string(uri) The URL that we should call to pass status parameters (such as call ended) to your application.
-
VoiceUrl
string(uri) The URL we should call when the domain receives a call.
curl \
-X POST https://api.twilio.com/2010-04-01/Accounts/{AccountSid}/SIP/Domains/{Sid}.json \
--user "username:password" \
-H "Content-Type: application/x-www-form-urlencoded" \
-d 'ByocTrunkSid=string&DomainName=string&EmergencyCallerSid=string&EmergencyCallingEnabled=true&FriendlyName=string&Secure=true&SipRegistration=true&VoiceFallbackMethod=HEAD&VoiceFallbackUrl=https%3A%2F%2Fexample.com&VoiceMethod=HEAD&VoiceStatusCallbackMethod=HEAD&VoiceStatusCallbackUrl=https%3A%2F%2Fexample.com&VoiceUrl=https%3A%2F%2Fexample.com'
{
"ByocTrunkSid": "string",
"DomainName": "string",
"EmergencyCallerSid": "string",
"EmergencyCallingEnabled": true,
"FriendlyName": "string",
"Secure": true,
"SipRegistration": true,
"VoiceFallbackMethod": "HEAD",
"VoiceFallbackUrl": "https://example.com",
"VoiceMethod": "HEAD",
"VoiceStatusCallbackMethod": "HEAD",
"VoiceStatusCallbackUrl": "https://example.com",
"VoiceUrl": "https://example.com"
}
{
"ByocTrunkSid": "string",
"DomainName": "string",
"EmergencyCallerSid": "string",
"EmergencyCallingEnabled": true,
"FriendlyName": "string",
"Secure": true,
"SipRegistration": true,
"VoiceFallbackMethod": "HEAD",
"VoiceFallbackUrl": "https://example.com",
"VoiceMethod": "HEAD",
"VoiceStatusCallbackMethod": "HEAD",
"VoiceStatusCallbackUrl": "https://example.com",
"VoiceUrl": "https://example.com"
}
{
"account_sid": "string",
"api_version": "string",
"auth_type": "string",
"byoc_trunk_sid": "string",
"date_created": "string",
"date_updated": "string",
"domain_name": "string",
"emergency_caller_sid": "string",
"emergency_calling_enabled": true,
"friendly_name": "string",
"secure": true,
"sid": "string",
"sip_registration": true,
"subresource_uris": {},
"uri": "https://example.com",
"voice_fallback_method": "HEAD",
"voice_fallback_url": "https://example.com",
"voice_method": "HEAD",
"voice_status_callback_method": "HEAD",
"voice_status_callback_url": "https://example.com",
"voice_url": "https://example.com"
}
{
"account_sid": "string",
"api_version": "string",
"auth_type": "string",
"byoc_trunk_sid": "string",
"date_created": "string",
"date_updated": "string",
"domain_name": "string",
"emergency_caller_sid": "string",
"emergency_calling_enabled": true,
"friendly_name": "string",
"secure": true,
"sid": "string",
"sip_registration": true,
"subresource_uris": {},
"uri": "https://example.com",
"voice_fallback_method": "HEAD",
"voice_fallback_url": "https://example.com",
"voice_method": "HEAD",
"voice_status_callback_method": "HEAD",
"voice_status_callback_url": "https://example.com",
"voice_url": "https://example.com"
}