# Incremental Activationスタンドアロンワークフロー Incremental Activationはベータ版リリースです。詳細については、カスタマーサクセス担当者にお問い合わせください。 このページでは、Audience Studioを使用せずにスタンドアロンワークフローとしてIncremental Activationを使用する方法を説明します。これにより、スケジュールベースで任意のTDテーブルから直接差分エクスポートを実行できます。 ## 概要 スタンドアロンワークフローとしてIncremental Activationを実行する場合、次のことができます。 - 任意のTDテーブルから差分の変更をエクスポート(セグメントデータだけでなく) - 送信先への定期的な差分エクスポートをスケジュール - Audience StudioのActivationフレームワーク外でデータを処理 **主な違い**: すべてのパラメータは、Audience Studioによって自動的に設定されないため、ワークフローで明示的に設定する必要があります。 ## 必須の追加パラメータ スタンドアロンモードでは、次の追加パラメータを設定する必要があります。 | パラメータ | 説明 | 例 | | --- | --- | --- | | `activation_actions_db` | ソースTDデータベース | `"my_database"` | | `activation_actions_table` | ソーステーブル名 | `"customer_profiles"` | | `result_connection_name` | コネクタ認証名 | `"my_snowflake_connection"` | | `result_connection_settings` | コネクタ設定オブジェクト | 以下の例を参照 | ## スタンドアロンワークフローテンプレート ```yaml timezone: "UTC" _export: params: # API endpoint - change based on your TD site api_endpoint: "https://integrations-gateway.us01.treasuredata.com" # Unique identifier column id_key: "customer_id" # Columns to check for changes delta_keys: ["email", "status", "tier"] # Delta mappings activation_mappings: [ { "delta_status": "new", "connector_field": "mode", "connector_field_value": "append" }, { "delta_status": "updated", "connector_field": "mode", "connector_field_value": "append" } ] # REQUIRED: Standalone mode parameters activation_actions_db: "my_database" activation_actions_table: "customer_profiles" result_connection_name: "my_snowflake_connection" result_connection_settings: type: "snowflake" database: "MARKETING_DB" schema: "PUBLIC" table: "CUSTOMER_SEGMENTS" mode: "append" # Fetch and execute incremental activation workflow +fetch_incremental_activation_wf: http_call>: "${params.api_endpoint}/integration_workflow/workflows/incremental_activation/fetch" method: POST headers: - Authorization: ${secret:td.apikey} - Content-Type: "application/json" content_type_override: application/x-yaml content: | { "database": "${params.activation_actions_db}", "source_table": "${params.activation_actions_table}", "id_key": "${params.id_key}", "delta_keys": ${JSON.stringify(params.delta_keys)}, "activation_mappings": ${JSON.stringify(params.activation_mappings)}, "result_connection_settings": ${JSON.stringify(params.result_connection_settings)}, "result_connection_name": "${params.result_connection_name}" } retry: true ``` ## コネクタ設定例 ### Snowflake ```yaml result_connection_settings: type: "snowflake" database: "MARKETING_DB" schema: "PUBLIC" table: "CUSTOMER_SEGMENTS" mode: "append" ``` ### MySQL ```yaml result_connection_settings: type: "mysql" database: "marketing" table: "customer_segments" mode: "append" ``` ### PostgreSQL ```yaml result_connection_settings: type: "postgresql" database: "marketing" schema: "public" table: "customer_segments" mode: "append" ``` ### Google Sheets ```yaml result_connection_settings: type: "google_sheets" spreadsheet_id: "1ABC...xyz" sheet_name: "Customer List" mode: "replace" ``` ## セットアップ手順 1. **TD Data Workbench > Workflowsで新しいユーザー定義ワークフローを作成**します 2. **上記のスタンドアロンテンプレートをコピー&ペースト**します 3. **すべての必須パラメータを設定**します: - TDサイトに合わせて`api_endpoint`を設定 - 一意の識別子カラムに`id_key`を設定 - 追跡したいカラムに`delta_keys`を設定 - `activation_actions_db`と`activation_actions_table`を設定 - 送信先に合わせて`result_connection_settings`を設定 - 認証に`result_connection_name`を設定 4. **ワークフローを保存**します 5. **手動で実行**するか、ワークフローを**スケジュール**します ## スケジューリング スケジュールに従ってワークフローを実行するには、スケジュール設定を追加します。 ```yaml schedule: daily>: 02:00:00 # Run daily at 2 AM UTC timezone: "UTC" _export: params: # ... rest of configuration ``` ## ユースケース ### 日次顧客プロファイル同期 毎晩変更された顧客プロファイルのみをデータウェアハウスにエクスポート: ```yaml schedule: daily>: 01:00:00 _export: params: api_endpoint: "https://integrations-gateway.us01.treasuredata.com" id_key: "customer_id" delta_keys: ["email", "phone", "address", "tier"] activation_actions_db: "customer_data" activation_actions_table: "unified_profiles" # ... connector settings ``` ### 時間単位の商品カタログ更新 商品カタログの変更をeコマースプラットフォームに同期: ```yaml schedule: hourly>: 00 _export: params: api_endpoint: "https://integrations-gateway.us01.treasuredata.com" id_key: "product_id" delta_keys: ["price", "stock_quantity", "availability"] activation_actions_db: "product_catalog" activation_actions_table: "products" # ... connector settings ``` ## Activation Actionモードとの違い | 側面 | Activation Actionモード | スタンドアロンモード | | --- | --- | --- | | トリガー | Audience Studioセグメントactivation | ワークフローのスケジュールまたは手動実行 | | データソース | セグメントシンジケーションテーブル(自動) | 任意のTDテーブル(手動設定) | | 自動設定されるパラメータ | あり(`activation_actions_db`、`activation_actions_table`、コネクタ設定) | なし(すべてのパラメータを設定する必要があります) | | ユースケース | セグメントからのマーケティングactivation | 任意のテーブルからのスケジュール済み差分エクスポート | ## 次のステップ - [Incremental Activation概要](/ja/products/customer-data-platform/audience-studio/activation/incremental-activation-overview) - [Incremental Activationパラメータ](/ja/products/customer-data-platform/audience-studio/activation/incremental-activation-parameters) - [ワークフローテンプレート](/ja/products/customer-data-platform/audience-studio/activation/incremental-activation-workflow-templates) ## 関連トピック - [Incremental Activationの設定](/ja/products/customer-data-platform/audience-studio/activation/configure-incremental-activation) - [Workflowの作成と編集](/products/customer-data-platform/data-workbench/workflows/getting-started-with-treasure-workflow)