サービスリソース
When messages are sent using a Messaging Service, enabled Copilot features assist to improve message performance.
開発者は電話番号、ショートコード、そして英数字の送信者IDをMessaging Serviceのインスタンスに関連づけることができます。 その電話番号およびショートコードに対するすべての送受信の挙動はServiceの構成によって決定されます。
Twilio コンソール
Messaging ServiceはTwilio Consoleにログインして管理可能です。
Messaging Servicesリソース
MessagingのServicesリソースはメッセージの送受信に関係する一連の構成を表します。
サブリソース
ServicesリソースにはそのServiceに関連づけられた電話番号、ショートコード、および英文字の送信者IDを管理するためのphone numbers、shortcodes、およびalpha sender IDsサブリソースががあります。
リソースURI
このドキュメント中のすべてのURLは下記のベースURLを使用しています:
https://messaging.twilio.com/v1
Service properties
Names in REST API format | |
---|---|
sid
|
The unique string that we created to identify the Service resource. |
account_sid
|
The SID of the Account that created the Service resource. |
friendly_name
|
The string that you assigned to describe the resource. |
date_created
|
The date and time in GMT when the resource was created specified in ISO 8601 format. |
date_updated
|
The date and time in GMT when the resource was last updated specified in ISO 8601 format. |
inbound_request_url
|
The URL we call using |
inbound_method
|
The HTTP method we use to call |
fallback_url
|
The URL that we call using |
fallback_method
|
The HTTP method we use to call |
status_callback
|
The URL we call to pass status updates about message delivery. |
sticky_sender
|
Whether to enable Sticky Sender on the Service instance. |
mms_converter
|
Whether to enable the MMS Converter for messages sent through the Service instance. |
smart_encoding
|
Whether to enable Smart Encoding for messages sent through the Service instance. |
scan_message_content
|
Reserved. |
fallback_to_long_code
|
Whether to enable Fallback to Long Code for messages sent through the Service instance. |
area_code_geomatch
|
Whether to enable Area Code Geomatch on the Service Instance. |
synchronous_validation
|
Reserved. |
validity_period
|
How long, in seconds, messages sent from the Service are valid. Can be an integer from |
url
|
The absolute URL of the Service resource. |
links
|
The absolute URLs of related resources. |
Create a Service resource
https://messaging.twilio.com/v1/Services
パラメーター
Names in REST API format | |
---|---|
friendly_name
必須
|
A descriptive string that you create to describe the resource. It can be up to 64 characters long. |
inbound_request_url
オプション
|
The URL we should call using |
inbound_method
オプション
|
The HTTP method we should use to call |
fallback_url
オプション
|
The URL that we should call using |
fallback_method
オプション
|
The HTTP method we should use to call |
status_callback
オプション
|
The URL we should call to pass status updates about message delivery. |
sticky_sender
オプション
|
Whether to enable Sticky Sender on the Service instance. |
mms_converter
オプション
|
Whether to enable the MMS Converter for messages sent through the Service instance. |
smart_encoding
オプション
|
Whether to enable Smart Encoding for messages sent through the Service instance. |
scan_message_content
オプション
|
Reserved. |
fallback_to_long_code
オプション
|
Whether to enable Fallback to Long Code for messages sent through the Service instance. |
area_code_geomatch
オプション
|
Whether to enable Area Code Geomatch on the Service Instance. |
validity_period
オプション
|
How long, in seconds, messages sent from the Service are valid. Can be an integer from |
synchronous_validation
オプション
|
Reserved. |
例
Fetch a Service resource
https://messaging.twilio.com/v1/Services/{Sid}
パラメーター
Names in REST API format | |
---|---|
sid
Path
|
The SID of the Service resource to fetch. |
例
Read multiple Service resources
https://messaging.twilio.com/v1/Services
例
Update a Service resource
https://messaging.twilio.com/v1/Services/{Sid}
1つ以上の上記のオプションパラメーターを指定して、Serviceの対応するプロパティーを更新できます。 リクエストで指定されなかったパラメーターは更新されません。
パラメーター
Names in REST API format | |
---|---|
sid
Path
|
The SID of the Service resource to update. |
friendly_name
オプション
|
A descriptive string that you create to describe the resource. It can be up to 64 characters long. |
inbound_request_url
オプション
|
The URL we should call using |
inbound_method
オプション
|
The HTTP method we should use to call |
fallback_url
オプション
|
The URL that we should call using |
fallback_method
オプション
|
The HTTP method we should use to call |
status_callback
オプション
|
The URL we should call to pass status updates about message delivery. |
sticky_sender
オプション
|
Whether to enable Sticky Sender on the Service instance. |
mms_converter
オプション
|
Whether to enable the MMS Converter for messages sent through the Service instance. |
smart_encoding
オプション
|
Whether to enable Smart Encoding for messages sent through the Service instance. |
scan_message_content
オプション
|
Reserved. |
fallback_to_long_code
オプション
|
Whether to enable Fallback to Long Code for messages sent through the Service instance. |
area_code_geomatch
オプション
|
Whether to enable Area Code Geomatch on the Service Instance. |
validity_period
オプション
|
How long, in seconds, messages sent from the Service are valid. Can be an integer from |
synchronous_validation
オプション
|
Reserved. |
例
Delete a Service resource
https://messaging.twilio.com/v1/Services/{Sid}
Serviceが削除されるとき、Service内のすべての電話番号およびショートコードはアカウントに戻ります。
パラメーター
Names in REST API format | |
---|---|
sid
Path
|
The SID of the Service resource to delete. |
例
ヘルプが必要ですか?
誰しもが一度は考える「コーディングって難しい」。そんな時は、お問い合わせフォームから質問してください。 または、Stack Overflow でTwilioタグのついた情報から欲しいものを探してみましょう。