メニュー

Rate this page:

Thanks for rating this page!

We are always striving to improve our documentation quality, and your feedback is valuable to us. How could this documentation serve you better?

トランク

トランクリソースは、Twilio アカウントの SIP トランクを表します。トランクは、クレデンシャルリストIP アクセスコントロールリストオリジネーション URL、および電話番号を所有します。

SIP トランクの作成および使用方法については、クイックスタートガイドをご覧ください。

アクション

リソースのプロパティ

Names in PHP format
accountSid
sid<AC> Not PII

The SID of the Account that created the Trunk resource.

domainName
文字列 Not PII

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 pstn.twilio.com. See Termination Settings for more information.

disasterRecoveryMethod
http_method Not PII

The HTTP method we use to call the disaster_recovery_url. Can be: GET or POST.

disasterRecoveryUrl

The URL we call using the disaster_recovery_method if an error occurs while sending SIP traffic towards the configured Origination URL. We retrieve TwiML from this URL and execute the instructions like any other normal TwiML call. See Disaster Recovery for more information.

friendlyName
文字列 Not PII

The string that you assigned to describe the resource.

secure
boolean Not PII

Whether Secure Trunking is enabled for the trunk. If enabled, all calls going through the trunk will be secure using SRTP for media and TLS for signaling. If disabled, then RTP will be used for media. See Secure Trunking for more information.

recording
オブジェクト Not PII

The recording settings for the trunk. Can be: do-not-record, record-from-ringing, record-from-answer. If set to record-from-ringing or record-from-answer, all calls going through the trunk will be recorded. See Recording for more information.

cnamLookupEnabled
boolean Not PII

Whether Caller ID Name (CNAM) lookup is enabled for the trunk. If enabled, all inbound calls to the SIP Trunk from the United States and Canada automatically perform a CNAM Lookup and display Caller ID data on your phone. See CNAM Lookups for more information.

authType
文字列 Not PII

The types of authentication mapped to the domain. Can be: IP_ACL and CREDENTIAL_LIST. If both are mapped, the values are returned in a comma delimited list. If empty, the domain will not receive any traffic.

authTypeSet
string[] Not PII

Reserved.

dateCreated
date_time<iso8601> Not PII

The date and time in GMT when the resource was created specified in RFC 2822 format.

dateUpdated
date_time<iso8601> Not PII

The date and time in GMT when the resource was last updated specified in RFC 2822 format.

sid
sid<TR> Not PII

The unique string that we created to identify the Trunk resource.

url
url Not PII

The absolute URL of the resource.

links
uri_map Not PII

The URLs of related resources.


すべてのトランクをリストする

先頭に戻る

GET /Trunks

Get a paged listing of all SIP Trunks for your account:

        
        
        
        


        SIPトランクを作成する

        先頭に戻る

        POST /Trunks
        

        Create a new SIP Trunk:

              
              
              
              
              Names in PHP format
              friendlyName
              オプション
              post 文字列 Not PII

              A descriptive string that you create to describe the resource. It can be up to 64 characters long.

              domainName
              オプション
              post 文字列 Not PII

              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 pstn.twilio.com. See Termination Settings for more information.

              disasterRecoveryUrl
              オプション
              post url PII MTL: 30 DAYS

              The URL we should call using the disaster_recovery_method if an error occurs while sending SIP traffic towards the configured Origination URL. We retrieve TwiML from the URL and execute the instructions like any other normal TwiML call. See Disaster Recovery for more information.

              disasterRecoveryMethod
              オプション
              post http_method Not PII

              The HTTP method we should use to call the disaster_recovery_url. Can be: GET or POST.

              recording
              オプション
              post enum:recording_setting Not PII

              The recording settings for the trunk. Can be: do-not-record, record-from-ringing, record-from-answer. If set to record-from-ringing or record-from-answer, all calls going through the trunk will be recorded. See Recording for more information.

              secure
              オプション
              post boolean Not PII

              Whether Secure Trunking is enabled for the trunk. If enabled, all calls going through the trunk will be secure using SRTP for media and TLS for signaling. If disabled, then RTP will be used for media. See Secure Trunking for more information.

              cnamLookupEnabled
              オプション
              post boolean Not PII

              Whether Caller ID Name (CNAM) lookup should be enabled for the trunk. If enabled, all inbound calls to the SIP Trunk from the United States and Canada automatically perform a CNAM Lookup and display Caller ID data on your phone. See CNAM Lookups for more information.


              SIP トランクを取得する

              先頭に戻る

              GET /Trunks/{Trunk SID}
              

              Get instance data for a particular SIP Trunk:

                    
                    
                    
                    


                    SIP トランクをアップデートする

                    先頭に戻る

                    POST /Trunks/{Trunk SID}
                    

                    Update the properties of a SIP Trunk:

                          
                          
                          
                          
                          Names in PHP format
                          sid
                          必須
                          post sid<TR> Not PII

                          The unique string that we created to identify the OriginationUrl resource to update.

                          friendlyName
                          オプション
                          post 文字列 Not PII

                          A descriptive string that you create to describe the resource. It can be up to 64 characters long.

                          domainName
                          オプション
                          post 文字列 Not PII

                          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 pstn.twilio.com. See Termination Settings for more information.

                          disasterRecoveryUrl
                          オプション
                          post url PII MTL: 30 DAYS

                          The URL we should call using the disaster_recovery_method if an error occurs while sending SIP traffic towards the configured Origination URL. We retrieve TwiML from the URL and execute the instructions like any other normal TwiML call. See Disaster Recovery for more information.

                          disasterRecoveryMethod
                          オプション
                          post http_method Not PII

                          The HTTP method we should use to call the disaster_recovery_url. Can be: GET or POST.

                          recording
                          オプション
                          post enum:recording_setting Not PII

                          The recording settings for the trunk. Can be: do-not-record, record-from-ringing, record-from-answer. If set to record-from-ringing or record-from-answer, all calls going through the trunk will be recorded. See Recording for more information.

                          secure
                          オプション
                          post boolean Not PII

                          Whether Secure Trunking is enabled for the trunk. If enabled, all calls going through the trunk will be secure using SRTP for media and TLS for signaling. If disabled, then RTP will be used for media. See Secure Trunking for more information.

                          cnamLookupEnabled
                          オプション
                          post boolean Not PII

                          Whether Caller ID Name (CNAM) lookup should be enabled for the trunk. If enabled, all inbound calls to the SIP Trunk from the United States and Canada automatically perform a CNAM Lookup and display Caller ID data on your phone. See CNAM Lookups for more information.


                          トランクを削除する

                          先頭に戻る

                          DELETE /Trunks/{Trunk SID}
                          

                          Remove a SIP trunk instance from your account:

                                
                                
                                
                                

                                レスポンス例

                                リクエストが成功すると、HTTP ステータスコード 204 と空の本文が返されます。

                                Rate this page:

                                ヘルプが必要ですか?

                                We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd browsing the Twilio tag on Stack Overflow.