メニュー

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?

クレデンシャルリソース

Credentialリソースは、特定のプッシュ通知チャネルに対する単一のクレデンシャルレコードを表します。 現時点ではAPNS、FCM、およびGCMがサポートされています。 クレデンシャルはプッシュのベンダーにより異なり、ベンダー自身によって発行されます。 このリソースで、プッシュ通知に使用されるべきTwilioクレデンシャルを送信できるようになります。

ベンダー固有のクレデンシャルのプロビジョニングについては、下記のドキュメントをご覧ください。

Twilio コンソール

You can manage the Credentials for use with Programmable Chat using your Twilio console when logged in to the console.

プロパティ

各クレデンシャルリソースに次のプロパティがあります。

Names in PHP format
sid
sid<CR> Not PII

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

accountSid
sid<AC> Not PII

The SID of the Account that created the Credential resource.

friendlyName
文字列 PII MTL: 120 DAYS

The string that you assigned to describe the resource.

type
enum:push_service Not PII

The type of push-notification service the credential is for. Can be: gcm, fcm, or apn.

sandbox
文字列 Not PII

[APN only] Whether to send the credential to sandbox APNs. Can be true to send to sandbox APNs or false to send to production.

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.

url
url Not PII

The absolute URL of the Credential resource.

        
        
        
        
        Names in PHP format
        type
        必須
        post enum:push_service Not PII

        The type of push-notification service the credential is for. Can be: gcm, fcm, or apn.

        friendlyName
        オプション
        post 文字列 PII MTL: 120 DAYS

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

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

        [APN only] The URL encoded representation of the certificate. For example, -----BEGIN CERTIFICATE----- MIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A== -----END CERTIFICATE-----

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

        [APN only] The URL encoded representation of the private key. For example, -----BEGIN RSA PRIVATE KEY----- MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR. -----END RSA PRIVATE KEY-----

        sandbox
        オプション
        post boolean Not PII

        [APN only] Whether to send the credential to sandbox APNs. Can be true to send to sandbox APNs or false to send to production.

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

        [GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.

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

        [FCM only] The Server key of your project from the Firebase console, found under Settings / Cloud messaging.

              
              
              
              

              クレデンシャルを取得する

              GET /Credentials/{Credential SID}
              
                    
                    
                    
                    

                    クレデンシャルを更新する

                    POST /Credentials/{Credential SID}
                    

                    パラメーター

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

                    The Twilio-provided string that uniquely identifies the Credential resource to update.

                    friendlyName
                    オプション
                    post 文字列 PII MTL: 120 DAYS

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

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

                    [APN only] The URL encoded representation of the certificate. For example, -----BEGIN CERTIFICATE----- MIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A== -----END CERTIFICATE-----

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

                    [APN only] The URL encoded representation of the private key. For example, -----BEGIN RSA PRIVATE KEY----- MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR. -----END RSA PRIVATE KEY-----

                    sandbox
                    オプション
                    post boolean Not PII

                    [APN only] Whether to send the credential to sandbox APNs. Can be true to send to sandbox APNs or false to send to production.

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

                    [GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.

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

                    [FCM only] The Server key of your project from the Firebase console, found under Settings / Cloud messaging.

                          
                          
                          
                          

                          クレデンシャルを削除する

                          DELETE /Credentials/{Credential SID}
                          
                                
                                
                                
                                
                                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.