{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/ja/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"LINE OA Streaming Import連携","description":"LINE OAからTreasure AIへのストリーミングインポート連携で、メッセージングデータを簡単に収集し、マーケティング分析に活用できます。","siteUrl":"https://docs.treasure.ai","lang":"en-US","jsonLd":{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://www.treasure.ai/","name":"Treasure AI","url":"https://www.treasure.ai/","logo":"https://www.treasure.ai/hubfs/assets/images/logos/primary-logo.svg"},{"@type":"WebSite","@id":"https://docs.treasure.ai/#website","name":"Treasure AI Documentation","url":"https://docs.treasure.ai/","inLanguage":["en","ja"],"publisher":{"@id":"https://www.treasure.ai/"}}]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"line-oa-streaming-import連携","__idx":0},"children":["LINE OA Streaming Import連携"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["LINE Messaging公式アカウント(OA)は、顧客の会話データと行動データを収集し、分析、トリガー、マーケティング目的のパーソナライゼーションに活用できます。この連携により、LINE OAからのメッセージ/イベントデータをTreasure Dataにインポートできます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"サポートされるwebhookイベント","__idx":1},"children":["サポートされるWebhookイベント"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["この連携は、LINE Messaging APIから送信されるすべてのWebhookイベントを受信します。以下が含まれます:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["メッセージイベント(テキスト、画像、動画、音声、ファイル、位置情報、スタンプ)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["フォローイベント(ユーザーがアカウントを友だち追加したとき)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["アンフォローイベント(ユーザーがアカウントをブロックしたとき)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["参加イベント(アカウントがグループまたはルームに参加したとき)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["退出イベント(アカウントがグループまたはルームから退出したとき)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["メンバー参加/退出イベント"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["ポストバックイベント"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["ビーコンイベント"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["アカウント連携イベント"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["デバイス連携/連携解除イベント"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Webhookイベントの完全なリストとデータ構造については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.line.biz/en/docs/messaging-api/receiving-messages/#webhook-event-types"},"children":["LINE Messaging APIドキュメント"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"前提条件","__idx":2},"children":["前提条件"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Treasure Dataの基礎知識"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["LINE Messaging公式アカウントの基礎知識"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"要件と制限事項","__idx":3},"children":["要件と制限事項"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["会話データの取得をサポート"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["LINE WebhookとLINE Messaging APIが有効化されている必要があります"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Webhook URLを正しく設定する必要があります"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["データを取り込むテーブルにデータを取り込む前に、Plazmaでデータベースとテーブルを作成する必要があります"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["LINE Messaging APIでは、チャネルごとに1つのWebhook URLのみ許可されています。Webhookを必要とする複数のツールを使用したり、既存のシステム連携がある場合は、ZapierなどのWebhookイベントをTreasure Dataを含む複数の宛先に配信する中間サービスを使用する必要があります"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"treasure-data-integration-の静的-ip-アドレス","__idx":4},"children":["Treasure Data Integration の静的 IP アドレス"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["セキュリティポリシーで IP ホワイトリストが必要な場合は、接続を成功させるために Treasure Data の IP アドレスを許可リストに追加する必要があります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["リージョンごとに整理された静的 IP アドレスの完全なリストは、次のリンクにあります:"," ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/apis/endpoints/ip-addresses-integrations-result-workers"},"children":["IP Addresses for Integrations"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"treasure-コンソールからline-oaをインポート","__idx":5},"children":["Treasure コンソールからLINE OAをインポート"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"認証の作成","__idx":6},"children":["認証の作成"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["認証情報セットを使用して新しい認証を作成するには、以下の手順を実行します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Integrations Hubを選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Catalogを選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["カタログで連携を検索し、アイコンにマウスカーソルを合わせて、Create Authenticationを選択します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/line-oa-streaming-catalog.314a9b0d8b23acf95027c9dc75a247358e8b4336d85fc7ea249646f02d3e0567.31dabd9a.png","alt":"line oa streaming catalog"},"children":[]}]},{"$$mdtype":"Tag","name":"ol","attributes":{"start":5},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Credentialsタブが選択されていることを確認し、連携の認証情報を入力します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"新しい認証フィールド","__idx":7},"children":["新しい認証フィールド"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/line-oa-streaming-new-authentication.9abe5dfbbc7bb85144f17059e4c0b18056bb6987820fccbf22b89a089059b0e0.31dabd9a.png","alt":"line oa streaming new authentication"},"children":[]}]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"パラメータ"},"children":["パラメータ"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"説明"},"children":["説明"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Treasure API Key"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Treasure APIキー、書き込み専用キー"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Channel Secret Key"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["LINEチャネルシークレットキー"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"sourceの作成","__idx":8},"children":["Sourceの作成"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Treasure コンソールを開きます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Integrations Hub > Authenticationsに移動します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["新しく作成した認証を見つけて、New Sourceを選択します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/authentications-new-source.621b09d88ddca37f2d5826f1ea05a8e8337b7865d1dcda6d1ff8936cc7e94751.31dabd9a.png","alt":"Authentications page with New Source button"},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"接続の作成","__idx":9},"children":["接続の作成"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"パラメータ"},"children":["パラメータ"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"説明"},"children":["説明"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Data Transfer Name"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["転送の名前を定義できます。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Authentication"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["転送に使用される認証名。"]}]}]}]}]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Data Transfer Nameフィールドにソース名を入力します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Nextを選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Create SourceページがSource Tableタブが選択された状態で表示されます。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ソーステーブルの指定","__idx":10},"children":["ソーステーブルの指定"]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"warning"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["続行する前に、Plazmaでデータベースとテーブルを作成したことを確認してください。この連携では、LINE OAデータを保存するための既存のデータベースとテーブルが必要です。"]}]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["LINE OAデータを保存する宛先テーブルを設定します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/create-source-data-settings.fbece41c29532c128468ca51329d9d10158f40cf02e91018d092b96925c8866f.31dabd9a.png","alt":"Create Source data settings"},"children":[]}]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"パラメータ"},"children":["パラメータ"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"説明"},"children":["説明"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Datastore"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Plazmaが使用可能なオプションです。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Tags"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["オプション。タグを使用してこのソースを検索できます。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Database"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["データをインポートするTreasure Data内のデータベースを指定します。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Raw Table"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["生のメッセージデータを配置するデータベース内のテーブルを指定します。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Events Table"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["イベントデータを配置するデータベース内のテーブルを指定します。"]}]}]}]}]},{"$$mdtype":"Tag","name":"ol","attributes":{"start":2},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Nextを選択します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"data-preview","__idx":11},"children":["Data Preview"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["インポートを実行する前に、Generate Preview を選択してデータの",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/customer-data-platform/integration-hub/batch/import/previewing-your-source-data"},"children":["プレビュー"]},"を表示できます。Data preview はオプションであり、選択した場合はダイアログの次のページに安全にスキップできます。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]}," を選択します。Data Preview ページが開きます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["データをプレビューする場合は、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Generate Preview"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["データを確認します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"data-placement","__idx":12},"children":["Data Placement"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データの配置について、データを配置したいターゲット database と table を選択し、インポートを実行する頻度を指定します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]}," を選択します。Storage の下で、インポートされたデータを配置する新しい database を作成するか、既存の database を選択し、新しい table を作成するか、既存の table を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Database"]}," を選択 > ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Select an existing"]}," または ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create New Database"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["オプションで、database 名を入力します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Table"]}," を選択 > ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Select an existing"]}," または ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create New Table"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["オプションで、table 名を入力します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データをインポートする方法を選択します。"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Append"]}," (デフォルト) - データインポートの結果は table に追加されます。"," ","table が存在しない場合は作成されます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Always Replace"]}," - 既存の table の全体の内容をクエリの結果出力で置き換えます。table が存在しない場合は、新しい table が作成されます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Replace on New Data"]}," - 新しいデータがある場合のみ、既存の table の全体の内容をクエリの結果出力で置き換えます。"]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Timestamp-based Partition Key"]}," 列を選択します。"," ","デフォルトキーとは異なるパーティションキーシードを設定したい場合は、long または timestamp 列をパーティショニング時刻として指定できます。デフォルトの時刻列として、add_time フィルターで upload_time を使用します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データストレージの ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Timezone"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Schedule"]}," の下で、このクエリを実行するタイミングと頻度を選択できます。"]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"一度だけ実行","__idx":13},"children":["一度だけ実行"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Off"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Scheduling Timezone"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create & Run Now"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"定期的に繰り返す","__idx":14},"children":["定期的に繰り返す"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["On"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Schedule"]}," を選択します。UI では、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["@hourly"]},"、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["@daily"]},"、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["@monthly"]},"、またはカスタム ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["cron"]}," の 4 つのオプションが提供されます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Delay Transfer"]}," を選択して、実行時間の遅延を追加することもできます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Scheduling Timezone"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create & Run Now"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["転送が実行された後、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Data Workbench"]}," > ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Databases"]}," で転送の結果を確認できます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ソースidのコピー","__idx":15},"children":["ソースIDのコピー"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ソースID(UUID v4)は、ソース作成時に発行されます。"]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["不正使用を防ぐため、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["ソースID"]},"は権限のない者に開示しないでください。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ソース作成後、自動的にソース一覧ページに移動します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["作成したソースを検索します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["同じ行の「...」をクリックし、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Copy Unique ID"]},"を選択します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/sources-copy-unique-id.aad8c1ff1b526b1bccfdb0eaa0fd1f511265f4ba93f52e97f74f09de9262361f.31dabd9a.png","alt":"Sources listing with Copy Unique ID option"},"children":[]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["このユニークIDが、LINE Messaging APIでWebhook URLを設定する際に必要なソースIDです。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"line-messaging-apiでwebhook-urlを設定","__idx":16},"children":["LINE Messaging APIでWebhook URLを設定"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure DataでLINE OAイベントを受信するには、LINE Messaging APIの設定でWebhook URLを設定する必要があります。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.line.biz/console/"},"children":["LINE Developers Console"]},"にログインします。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["LINE公式アカウントチャネルを選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Messaging API"]},"タブに移動します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Webhook settings"]},"セクションで、Webhook URLを入力します:"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["米国リージョンの場合:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"https://line-in-streaming.treasuredata.com/v1/task/{source_id}\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["東京リージョンの場合:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"https://line-in-streaming.treasuredata.co.jp/v1/task/{source_id}\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["{source_id}"]},"を前の手順でコピーしたソースIDに置き換えます。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Verify"]},"をクリックしてWebhook接続をテストします。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Use webhook"]},"トグルを有効にします。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["オプションで、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Webhook redelivery"]},"を有効にして、失敗したWebhook配信を再試行できるようにします。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Update"]},"をクリックして設定を保存します。"]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/line-webhook-settings.7f5609dd3d02450625e08b14fe39121bedd65e1a281d76839ca529dfe56b8fa2.31dabd9a.png","alt":"LINE Developers Console webhook settings"},"children":[]}]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Webhookを有効にする前に、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Webhook URL"]},"が正しく設定され、検証されていることを確認してください。他のリージョンのホスト名も同じパターンに従いますが、リージョン固有のドメインになります。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"データの取り込み","__idx":17},"children":["データの取り込み"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Webhook設定とソース作成が完了した後、最初のイベントがトリガーされると、コネクタはすぐにLINE OAイベントデータをTreasure Dataに取り込み始めることができます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"データスキーマ","__idx":18},"children":["データスキーマ"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"eventsテーブルのスキーマ","__idx":19},"children":["Eventsテーブルのスキーマ"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Eventsテーブルには、LINE Messaging APIからの詳細なWebhookイベントデータが含まれます。各行は、以下の構造を持つ単一のWebhookイベントを表します："]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"カラム名"},"children":["カラム名"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"データ型"},"children":["データ型"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"説明"},"children":["説明"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_mode"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["イベントモードのステータス（例：「active」）"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_type"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Webhookイベントのタイプ（例：「message」、「postback」、「follow」、「unfollow」）"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_deliverycontext"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JSON string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["isRedeliveryフラグを含む配信コンテキスト情報"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_timestamp"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["long"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["イベントが発生した時のUnixタイムスタンプ（ミリ秒）"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["destination"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Webhookを受信したLINE公式アカウントのユーザーID"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_source"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JSON string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["userIdとtype（user、group、またはroom）を含むソース情報"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_postback"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JSON string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["ポストバックイベントデータ（ポストバックイベントのみ）。dataとparamsを含む"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_webhookeventid"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["LINEからの一意のWebhookイベントID"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_replytoken"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["イベントに応答するためのリプライトークン"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["record_uuid"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["このレコードに対してTreasure Dataが生成した一意の識別子"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["event_message"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JSON string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["text、markAsReadToken、quoteToken、メッセージID、typeを含むメッセージイベントデータ"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["time"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["long"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["レコードがTreasure Dataに取り込まれた時のUnixタイムスタンプ"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"イベントデータの例","__idx":20},"children":["イベントデータの例"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["メッセージイベントの例："]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"event_mode\": \"active\",\n  \"event_type\": \"message\",\n  \"event_deliverycontext\": \"{\\\"isRedelivery\\\":false}\",\n  \"event_timestamp\": 1764739548058,\n  \"destination\": \"U26272c69eb9c705cdb310034a13d8a2c\",\n  \"event_source\": \"{\\\"userId\\\":\\\"U7df7e1515baea0a9898c2d8553d016d1\\\",\\\"type\\\":\\\"user\\\"}\",\n  \"event_webhookeventid\": \"01KBHAS125354QY30EQDB80MXV\",\n  \"event_replytoken\": \"a24d6cd95f4e4cceb74505a3c67fa1f0\",\n  \"record_uuid\": \"c32f42c1-6464-312e-8a73-64b19c6c8116\",\n  \"event_message\": \"{\\\"text\\\":\\\"Hello\\\",\\\"id\\\":\\\"590404062261018659\\\",\\\"type\\\":\\\"text\\\"}\",\n  \"time\": 1764739556\n}\n","lang":"json"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["ポストバックイベントの例："]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"event_mode\": \"active\",\n  \"event_type\": \"postback\",\n  \"event_deliverycontext\": \"{\\\"isRedelivery\\\":false}\",\n  \"event_timestamp\": 1764739548788,\n  \"destination\": \"U26272c69eb9c705cdb310034a13d8a2c\",\n  \"event_source\": \"{\\\"userId\\\":\\\"U7df7e1515baea0a9898c2d8553d016d1\\\",\\\"type\\\":\\\"user\\\"}\",\n  \"event_postback\": \"{\\\"data\\\":\\\"second-menu\\\",\\\"params\\\":{\\\"newRichMenuAliasId\\\":\\\"second-menu\\\",\\\"status\\\":\\\"SUCCESS\\\"}}\",\n  \"event_webhookeventid\": \"01KBHAS1TNJ9W3GZZSAYG8WSEW\",\n  \"event_replytoken\": \"e6a713af40ed416e8844db6638705d01\",\n  \"record_uuid\": \"5289e93e-d7c2-3a7d-9ba0-8de86cc53e4f\",\n  \"time\": 1764739552\n}\n","lang":"json"},"children":[]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["event_source"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["event_message"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["event_postback"]},"などのJSON文字列カラムには、ネストされたJSONデータが含まれています。クエリでTreasure DataのJSON関数を使用して、特定のフィールドを抽出できます。"]}]}]},"headings":[{"value":"LINE OA Streaming Import連携","id":"line-oa-streaming-import連携","depth":1},{"value":"サポートされるWebhookイベント","id":"サポートされるwebhookイベント","depth":2},{"value":"前提条件","id":"前提条件","depth":2},{"value":"要件と制限事項","id":"要件と制限事項","depth":2},{"value":"Treasure Data Integration の静的 IP アドレス","id":"treasure-data-integration-の静的-ip-アドレス","depth":2},{"value":"Treasure コンソールからLINE OAをインポート","id":"treasure-コンソールからline-oaをインポート","depth":2},{"value":"認証の作成","id":"認証の作成","depth":3},{"value":"新しい認証フィールド","id":"新しい認証フィールド","depth":3},{"value":"Sourceの作成","id":"sourceの作成","depth":3},{"value":"接続の作成","id":"接続の作成","depth":3},{"value":"ソーステーブルの指定","id":"ソーステーブルの指定","depth":3},{"value":"Data Preview","id":"data-preview","depth":3},{"value":"Data Placement","id":"data-placement","depth":3},{"value":"一度だけ実行","id":"一度だけ実行","depth":4},{"value":"定期的に繰り返す","id":"定期的に繰り返す","depth":4},{"value":"ソースIDのコピー","id":"ソースidのコピー","depth":3},{"value":"LINE Messaging APIでWebhook URLを設定","id":"line-messaging-apiでwebhook-urlを設定","depth":3},{"value":"データの取り込み","id":"データの取り込み","depth":3},{"value":"データスキーマ","id":"データスキーマ","depth":2},{"value":"Eventsテーブルのスキーマ","id":"eventsテーブルのスキーマ","depth":3},{"value":"イベントデータの例","id":"イベントデータの例","depth":3}],"frontmatter":{"seo":{"title":"LINE OA Streaming Import連携","description":"LINE OAからTreasure AIへのストリーミングインポート連携で、メッセージングデータを簡単に収集し、マーケティング分析に活用できます。"}},"lastModified":"2026-06-17T07:22:53.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/ja/int/line-oa-streaming-import-integration","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}