# Real-Time Triggered Activation の作成

この機能はベータ版です。詳細については、カスタマーサクセス担当者にお問い合わせください。

Real-time triggered activation を使用すると、毎日ではなく数分以内に潜在顧客や既存顧客とコミュニケーションを取ることができます。Real-time triggered activation は以下のイベントをサポートしています：

* [Wait Step](/ja/products/customer-data-platform/journey-orchestration/realtime/creating-a-wait-step-for-a-real-time-journey)：Journey のパスに複数の wait step を挿入して、プロファイルとやり取りするケイデンスを定義します。
* [Decision point](/ja/products/customer-data-platform/journey-orchestration/realtime/creating-a-realtime-decision-point)：1 つ以上の decision point を作成して、ユーザーをパーソナライズされたパスに誘導します。
* [Merge](/ja/products/customer-data-platform/journey-orchestration/realtime/creating-a-merge-for-a-real-time-journey)：複数の decision point を単一のポイントにマージします。


このトピックの内容：

* [Triggered Activation の作成](#create-triggered-activation)
* [Real-time Activation の詳細入力](#enter-real-time-activation-details)
* [Braze](#braze)
* [Sendgrid](#sendgrid)
* [Salesforce Marketing Cloud Output Data Streaming](#salesforce-marketing-cloud-output-data-streaming)
* [Webhook Output Streaming](#webhook-output-streaming)
* [Trigger Activation での Real-time 属性の使用](#using-real-time-attributes-in-trigger-activations)
* [Real-time 変数について](#about-real-time-variables)


## Triggered Activation の作成

1. Treasure コンソール を開きます。
2. Audience Studio に移動します。
3. 既存の real-time journey に移動して開くか、[real-time journey を作成](/ja/products/customer-data-platform/journey-orchestration/realtime/creating-a-real-time-journey)します。
4. ステージを選択します。
5. 左パネルで Triggered Activation を選択し、Journey キャンバスにドラッグアンドドロップします。


![](/assets/new-topic-6-2024-03-12.e6f8d83d02baeb64c9f88d42c672734439e22cf9f0dbb08020b38fb829e77c5f.9e7171ae.png)

または、ステージルールの末尾にあるプラス記号を選択し、**Add triggered activation** を選択します。

## Real-time Activation の詳細入力

マーケターは、正しい認証の詳細を特定するためにデータエンジニアに連絡する必要がある場合があります。

以下のストリーミングインテグレーションと連携するように triggered activation を設定できます：

* [Braze Output Streaming](https://docs.treasuredata.com/smart/project-integrations/braze-output-streaming-integration)
* [Salesforce Marketing Cloud Output Data Streaming](https://docs.treasuredata.com/smart/project-integrations/salesforce-marketing-cloud-output-data-streaming)
* [SendGrid Output Streaming](https://docs.treasuredata.com/smart/project-integrations/sendgrid-output-streaming-integration)
* [Realtime Webhook Activation](https://docs.treasuredata.com/smart/project-integrations/webhook-output-streaming-integration)


設定の詳細はインテグレーションによって異なりますが、提供する必要がある情報は一般的に以下のようにグループ化できます：

* Integration details -- ストリーミングデータの返し方を決定するインテグレーション固有の詳細。
* Payload -- ペイロードで返される情報を定義する設定。Treasure コンソール を使用して、Imported Attributes、Real-time Attributes、または Journey Name、Journey Stage Name、Audience Name などの Journey Metadata を指定できます。
* Timeouts and Retries -- インテグレーションがタイムアウト状態になった場合のリトライ方法を定義する設定。


Triggered activation を作成または更新するには：

1. 設定したい triggered activation を選択します ![](/assets/triggeredactivation.66e546b8c4cc774c0bdd804d0d099b63cf12b1916181d85d7c715be95bd61810.9e7171ae.png)。


![](/assets/detailstriggeredactivations.543b5576f6eee3be0b13f6ce47f5b851a5daa4159fe88a9181347dc644df88bc.9e7171ae.png)

1. triggered activation ウィンドウで、**Copy triggered activation from** ドロップダウンメニューから activation を選択します。
2. **Triggered activation name** を入力します。
3. activation の **Optional description** を入力します。
4. **Authentication** ドロップダウンメニューから、activation が使用する認証を選択します。


選択する認証のタイプによって、提供する必要がある詳細は異なります。詳細については、以下のインテグレーション固有のテーブルを参照してください。

1. Details ページのフィールドに必要な情報を確認または入力します。
2. Details の設定が完了したら、**Create** または **Update** を選択します。


以下のテーブルは、認証インテグレーションの設定フィールドについて説明しています。Add batch attributes オプションを含むフィールドについては、選択に使用されるプレフィックス表記法の詳細について [Trigger Activation での Real-time 属性の使用](/ja/products/customer-data-platform/journey-orchestration/realtime/creating-a-real-time-triggered-activation#rtatttrig) セクションを参照してください。

### Braze

| フィールド | アクション/説明 |
|  --- | --- |
| **Integration Details** |  |
| API-Triggered Delivery | API トリガー配信として **Campaign** または **Canvas** を選択します。 |
| Campaign ID | （必須）選択した配信に一致する Braze キャンペーンまたはキャンバス識別子を入力します。 |
| Send ID | （オプション）認証に関連付けられた Braze 送信識別子を入力します。 |
| Broadcast | このチェックボックスを選択すると、データがブロードキャストとして送信されます。*注意 -- ブロードキャストを有効にすると、意図せず予想より大きなオーディエンスにメッセージが送信される可能性があります。* |
| **Payload** |  |
| Trigger Properties | トリガープロパティの JSON ペイロードを入力します。**+ Add** を選択して、Imported attributes、Real-time attributes、または Journey Metadata（Journey Name、Journey ID、Journey Stage Name、Audience Name、Audience ID、Activation Timestamp in UNIX）を挿入します。 |
| Connected Audiences | （オプション）必要に応じて、activation 用の Braze connected audiences を設定します。 |
| Recipients | （オプション）Braze のセットアップに従って recipients セクションを設定します。 |
| **Timeouts and Retries** |  |
| Maximum Number of Retry | 失敗時に activation がリトライする回数を選択します。 |
| Initial Retry Delay (in seconds) | 最初のリトライまでに待機する秒数を入力します。 |
| Retry Delay Multiple | 各試行後にリトライ遅延を乗算する係数を入力します。 |


![](/assets/screenshot-2025-03-19-21-40-38.94ca6d6cba648a9248ff9145463ab9b56bdcadd742643bfaef60abf763aff4fb.9e7171ae.png)
`triggered_properties` オブジェクトの最大サイズ制限は 50 KB です。

### Sendgrid

| フィールド | アクション/説明 |
|  --- | --- |
| **Integration Details** |  |
| From Email | （必須）キャンペーン送信者のメールアドレスを入力します。 |
| From Name | 送信者の表示名を入力します。 |
| Subject | （必須）メールの件名を入力します。 |
| Template ID | パーソナライズされたメール本文の置換をオーバーライドするテンプレート ID を入力します。 |
| Unsubscribe Group ID | （オプション）受信者がキャンペーンから配信停止できるグループ ID を入力します。 |
| **Payload** |  |
| Personalized Email Body | パーソナライズされたメールコンテンツの JSON ペイロードを入力します。**+ Add** を選択して、Imported attributes、Real-time attributes、または Journey Metadata（Journey Name、Journey ID、Journey Stage Name、Audience Name、Audience ID、Activation Timestamp in UNIX）を含めます。 |
| Content | SendGrid `content` 設定の JSON ペイロードを入力します。 |
| Attachment | SendGrid 添付ファイルの JSON 設定を入力します。 |
| Mail Settings | SendGrid メール設定の JSON 設定を入力します。 |
| Tracking Settings | SendGrid トラッキング設定の JSON 設定を入力します。 |
| **Timeouts and Retries** |  |
| Maximum Number of Retry | 失敗時に activation がリトライする回数を選択します。 |
| Initial Retry Wait (in seconds) | 最初のリトライまでに待機する秒数を入力します。 |
| Maximum Retry Wait (in seconds) | リトライ間の最大待機時間を入力します。 |


![](/assets/screenshot-2025-03-19-21-40-38.94ca6d6cba648a9248ff9145463ab9b56bdcadd742643bfaef60abf763aff4fb.9e7171ae.png)
Personalized Email Body には、設定済みのメールテンプレートを入力します。`__column_name__` を使用して置換列またはエイリアスをマークします。すべての置換列とエイリアスはエクスポートされたデータに存在する必要があります。**ペイロードの制限：** **Attachment**、**Mail Settings**、**Tracking Settings** セクションは Journey Metadata 値を受け付けません。Journey Metadata が含まれている場合、activation は失敗します。

### Salesforce Marketing Cloud Output Data Streaming

| フィールド | アクション/説明 |
|  --- | --- |
| **Integration Details** |  |
| Trigger action | （必須）トリガーする Salesforce Marketing Cloud アクションを選択します：- Send an email- Trigger a journey |
| Definition Key | （必須）選択したトリガーアクションに関連付けられたキーを入力します：- Send an email：メールテンプレート定義キー- Trigger a journey：API エントリイベント定義キー |
| Contact Key | （必須）String、Batch attribute、Imported attribute、Real-time attribute、または Journey Metadata を選択し、Salesforce Marketing Cloud で使用される一意の受信者識別子を入力します。 |
| Recipient Email Address | **Send an email** が選択されている場合にのみ表示されます。以下のいずれかを選択します：- String -- メールアドレスを入力- Imported attribute -- imported attribute を選択- Real-time attribute -- real-time attribute を選択- Journey Metadata -- 使用するメタデータを選択 |
| **Payload** |  |
| Attributes | 属性の JSON ペイロードを入力します。**+ Add** を選択して、Imported attributes、Real-time attributes、または Journey Metadata（Journey Name、Journey ID、Journey Stage Name、Audience Name、Audience ID、Activation Timestamp in UNIX）を含めます。 |
| **Timeouts and Retries** |  |
| Maximum Number of Retry | 失敗時に activation がリトライする回数を選択します。 |
| Initial Retry Delay (in seconds) | 最初のリトライまでに待機する秒数を入力します。 |
| Retry Delay Multiple | 各試行後にリトライ遅延を乗算する係数を入力します。 |


![](/assets/screenshot-2025-03-19-21-40-38.94ca6d6cba648a9248ff9145463ab9b56bdcadd742643bfaef60abf763aff4fb.9e7171ae.png)
選択した各 batch attribute は、パーソナライゼーション用のキーと値のペアを作成します。Journey の場合、これらの値はトリガー用に定義された Salesforce Marketing Cloud データ拡張に保存されます。

### Webhook Output Streaming

| フィールド | アクション/説明 |
|  --- | --- |
| **Integration Details** |  |
| HTTP Method | API 呼び出しの HTTP メソッドを選択します。利用可能なオプション：GET、POST、PUT、DELETE、または PATCH。 |
| URL | サードパーティサービスの HTTPS エンドポイントを指定します。URL は認証の URL Prefix で定義されたベース URL を使用し、最大 2,048 文字まで指定できます。 |
| Custom Headers | API 呼び出しに必要なカスタムヘッダーを指定します（最大 32 ヘッダー、各 256 バイト以下）。キー（例：`content-type`）と値（例：`application/json`）の両方を入力します。 |
| **Payload** |  |
| Request Body | リクエストボディの JSON ペイロードを入力します。**+ Add** を選択して、Imported attributes、Real-time attributes、または Journey Metadata（Journey Name、Journey ID、Journey Stage Name、Audience Name、Audience ID、Activation Timestamp in Unix）を含めます。 |
| **Timeouts and Retries** |  |
| Retry Limit | 呼び出しがリトライする回数を指定する 0 から 64 までの整数。 |
| Connection Timeout (seconds) | 呼び出しが接続を確立するまでの待機時間を指定する 1 から 900 までの整数。 |
| Read Timeout (seconds) | 読み取りリクエストが完了するまでの待機時間を指定する 1 から 900 までの整数。 |
| Write Timeout (seconds) | 書き込みリクエストが完了するまでの待機時間を指定する 1 から 900 までの整数。 |


Webhook コネクタは重複ヘッダーをチェックしません。重複キーが定義されていないことを確認してください。

![](/assets/triggeredactivationsaddcontrol.10000058ceeb1d6e471d63c7122a7ebbd27b6cbecd378f3727e5cdc20a8b0ed4.9e7171ae.png) 最大リクエストボディサイズは 250 KB です。API Key フィールドから認証シークレットを `{{auth.api_key}}` として参照できます。

## Trigger Activation での Real-time 属性の使用

スライディングカウンター属性のサブデュレーションとリスト属性の集計には直接アクセスできません。代わりに、対応するサブ属性を使用してください。正しいフォーマットについては以下のテーブルを参照してください。

| 属性タイプ | 例 | 説明 |
|  --- | --- | --- |
| list | `{{list.first}}``{{list.list_attribute.first}}` | リスト集計を識別します。 |
| counter | `{{counter.inc_value}}``{{counter.inc_value.by_2}}``{{counter.sliding_counter_inc_value.perweek}}` | カウンターと、存在する場合はスライディングカウンターのサブデュレーションを識別します。 |
| single | `{{single.sliding_consent_inc1.first}}` | シングルバイト属性を識別します。 |
| imported | `{{imported.email}}``{{imported.order_id}}` | imported attributes に使用されるプレフィックス。 |


[real-time attributes の作成](/products/customer-data-platform/real-time/real-time-attributes-overview)について詳しく学んでください。

## Real-time 変数について

URL、HTTP ヘッダー、リクエストボディは認証変数を参照できます。triggered activation フィールドに変数を手動で入力します。

| 属性タイプ | 例 | 説明 |
|  --- | --- | --- |
| auth | `{{auth.api.key}}` | 認証によって提供される API キーを含みます。 |


Triggered activation フィールドはメタデータ変数も参照できます。

| 属性タイプ | 例 | 説明 |
|  --- | --- | --- |
| meta | `{{meta.time}}``{{meta.parent_segment_id}}``{{meta.journey_id}}` | Journey メタデータを提供します。`meta.time` は activation が送信されたときのタイムスタンプです。 |