{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/ja/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"Instagram User And Media Insights Import Integration","description":"Treasure Data Product Documentation · Collect and Unify · Segment and Activate · Experiment and Analyze · Decisioning Automate with AI Scale and Trust.","siteUrl":"https://docs.treasuredata.com","lang":"en-US","llmstxt":{"hide":false,"sections":[{"title":"Table of contents","includeFiles":["**/*"],"excludeFiles":[]}],"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"instagram-user-and-media-insights-import-integration","__idx":0},"children":["Instagram User And Media Insights Import Integration"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Instagram Businessを使用すると、Instagramのメディアオブジェクトやユーザーアカウントアクティビティに関するインサイトを取得できます。Treasure Dataのコネクタを使用して、InstagramインサイトデータをTreasure Dataに取り込むことができます。"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["email_contacts-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["follower_count-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["get_directions_clicks-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["impressions-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["impressions-days_28"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["impressions-week"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["online_followers-lifetime"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["phone_call_clicks-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["profile_views-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["reach-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["reach-days_28"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["reach-week"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["text_message_clicks-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["website_clicks-day"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["engaged_audience_demographics-lifetime"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["reached_audience_demographics-lifetime"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["follower_demographics-lifetime"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"メディアタイプ","__idx":1},"children":["メディアタイプ"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["media_all"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["story_metrics"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["carousel_album_metrics"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["photo_and_videos_metrics"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"facebook-page-idの取得","__idx":2},"children":["Facebook Page IDの取得"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Instagram BusinessアカウントにリンクされているFacebook Page IDを入力してください。ユーザーがInstagramアカウントを作成またはビジネスアカウントに変換する際、そのInstagramアカウントをFacebookページにリンクする必要があります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/336497.cac8a0f1fc3b4512a0297fa392903780898b4a3f5bc31a5ceb8ada06ee882018.632f0615.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"拡張ユーザーアクセストークン","__idx":3},"children":["拡張ユーザーアクセストークン"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Facebookユーザーアクセストークンは、デフォルトでは短期間有効なアクセストークンです。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataプラットフォームでスケジュールジョブを実行するには、長期間有効なアクセストークンを取得してください:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Facebookツールを使用して長期間有効なユーザーアクセストークンを取得するには、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://medium.com/@yasithlokuge/how-to-generate-a-never-expiring-facebook-page-access-token-24ac5c1a95f1"},"children":["こちらの記事"]},"の手順に従ってください"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Facebook APIを使用して長期間有効なトークンを取得するには、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.facebook.com/docs/facebook-login/access-tokens/refreshing/#long-via-code"},"children":["こちらの手順"]},"に従ってください"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure コンソールを使用してジョブを実行する場合、コネクタはすでに長期間有効なアクセストークンを交換しています。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["次の権限(スコープ)が必要です:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["public_profile"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["email manage_pages"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["pages_show_list"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["instagram_basic"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["instagram_manage_insights"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["instagram_manage_comments"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ads_management"]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"treasure-コンソールを使用してconnectionを作成する","__idx":4},"children":["Treasure コンソールを使用してConnectionを作成する"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"新しいauthenticationの作成","__idx":5},"children":["新しいAuthenticationの作成"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データ接続を設定する際、統合にアクセスするための認証情報を提供します。Treasure Dataでは、認証を設定してからソース情報を指定します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Treasure コンソール"]},"を開きます。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Integrations Hub"]}," > ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Catalog"]},"に移動します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Instagram User & Media Insightsを検索して選択します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/346839.ee32ae0da32e939b3c4f56cb895a09f0196480f8440dbc46303efdd4dcb73029.632f0615.png","alt":""},"children":[]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Instagram Insights用の既存のOAuth connectionを選択するか、OAuth connection下のリンクをクリックして新しいものを作成します。"]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/340124.41ba2178ddc99c2667229ae9b9d27903cab4cd1d99ea49070f366e3355bcb0bc.632f0615.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"新しいoauth-connectionの作成","__idx":6},"children":["新しいOAuth connectionの作成"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Instagram OAuthはFacebook OAuthを使用するため、Facebook OAuthページに移動します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Facebookアカウントにログインします:"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/336496.80059c6423a8d92d27cb49bd300af0d3436814b00b725b9c89379848252cb7aa.632f0615.png","alt":""},"children":[]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Continue as"]},"ボタンを選択して、Treasure Dataアプリへのアクセスを許可します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/107151981.6f84dbb50833f1a0d34749bf1e6b3c74a19b784bc4c7c408ba001cb3d66bc3cb.632f0615.png","alt":""},"children":[]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Catalogページにリダイレクトされます。最初の手順(",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Create a new authentication"]},{"$$mdtype":"Tag","name":"strong","attributes":{},"children":[")"]}," を繰り返し、新しいOAuth connectionを選択します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/346842.38ecd49598afe0e60d146b958c428d5898d8ca3b016cd75a7066de870ae905f2.632f0615.png","alt":""},"children":[]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["新しいauthenticationに名前を付けます。",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Done"]},"を選択します。"]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/346849.a31ad0b10449c8a5d7510c26666e7dfc9bd5ee063dff96e235ecc59cd20dfcc7.632f0615.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"instagramアカウントデータをtreasure-dataに転送する","__idx":7},"children":["InstagramアカウントデータをTreasure Dataに転送する"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["認証済み接続を作成すると、自動的に",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Authentications"]},"に移動します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["作成したconnectionを検索します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["New Source"]},"を選択します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/336498.14b8458af014163f0a82d4912a4ef9ed05bbd4e8a2b4f94cc18faa3bdc788d39.632f0615.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"connection","__idx":8},"children":["Connection"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Connection"]}," ページが開きます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Data Transfer"]}," フィールドにソースの名前を入力します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/340128.f8d0eb8bccd8ee1a9dbac475fa37783e5a3328dadc1a30c96d54c322e50bec51.632f0615.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ソーステーブル","__idx":9},"children":["ソーステーブル"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]}," を選択します。",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Source Table"]}," ページが開きます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["ソーステーブルで以下のパラメータを編集します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/340139.022c91f9270bb1b0468979e20a78416cc2dbcdc12ec04650538c8d7280e2abaa.632f0615.png","alt":""},"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":"strong","attributes":{},"children":["パラメータ"]}]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":""},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["説明"]}]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Facebook Page ID"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["必須。Instagram Business アカウントにリンクされている Facebook ページ ID。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Data type"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["必須。データタイプのいずれかを選択します"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["User"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["インサイトは、Instagram Business アカウントについて収集されるメトリクスです（impressions、follower_count*、website_clicks、audience_locale など）。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Media"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["インサイトは、Instagram Business アカウントに投稿されたコンテンツから収集されるメトリクスです（engagement、impressions、reach、saved など）。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Comments"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["オーガニックな Instagram コメントを表します。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Media List"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Instagram の写真、動画、ストーリー、アルバムを表します"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Tags"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["別の Instagram ユーザーによって ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.facebook.com/docs/instagram-platform/instagram-graph-api/reference/ig-user"},"children":["IG User"]}," がタグ付けされた ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.facebook.com/docs/instagram-platform/reference/instagram-media/"},"children":["IG Media"]}," オブジェクトのコレクションを表します。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Start Date & End Date"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["User"]}," データタイプには必須。開始日と終了日は次の形式に従う必要があります：YYYY-MM-DD。例：2017-11-21   - ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Start Date"]}," は包含的で、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["End Date"]}," は排他的です。    - 指定されていない場合、終了日は ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Instagram Business Account Local Time"]}," の現在時刻がデフォルトになります。   - 指定されていない場合、開始日は終了日の 2 日前がデフォルトになります。デフォルトは Facebook API によって設定されます。   データは毎日の終わりに集計されるため、2017-01-01 のインサイトは end_time = 2017-01-02 00:00:00 になります。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Use Individual Metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["インポートするメトリクスデータを選択する場合に選択します。ドロップダウンには、選択したデータタイプのすべての個別メトリクスが一覧表示されます。複数のメトリクスを選択できます。   - Media メトリクスは [period: lifetime] のみをサポートします - User メトリクスは day、week、days_28、lifetime をサポートします。 - メトリクスのリスト（engaged_audience_demographics、reached_audience_demographics、follower_demographics）には、以下の追加設定が必要です：   - breakdown: 複数の値を入力でき、カンマで区切ります。サポートされる値（age、country、city、gender）   - metric_type: total_value を選択   - Timeframe: 期間の値を選択します。サポートされる値（last_14_days、last_30_days、last_90_days、prev_month、this_month、this_week）"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Preset User Metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["デフォルトは Week metrics です。以下のプリセット User メトリクスから選択できます：   - Week metrics [period: week] - Days 28 metrics [period: days_28] - Day metrics [period: day] - Lifetime metrics [period: lifetime]、増分インポートをサポートしません"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Preset Media metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["デフォルトは All media metrics です。以下のプリセット Media メトリクスから選択できます：   - All media metrics. すべての Media メトリクスは、Instagram アカウント内のすべてのコンテンツのメトリクスをインポートします - Story metrics. Instagram Story のメトリクスをインポートします - Carousel metrics. Instagram Carousel のメトリクスをインポートします - Photo and video metrics は Instagram の画像と動画のメトリクスのみをインポートします*"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Import media metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["メトリクスが複数のメディアオブジェクト（例：IMAGE、VIDEO、STORY など）でサポートされている場合、それらすべてのメディアオブジェクトのメトリクス値がインポートされます。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Import user metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["User メトリクスは day、week、days_28、lifetime をサポートします"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Incremental Loading"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["反復的に実行されるジョブをスケジュールできます。ジョブ実行の各反復は開始日と終了日の値に基づいて計算され、ギャップや重複なく毎回新しい値がインポートされます。  次の例では、開始日と終了日の間の 9 日間の範囲を使用します：  ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Start Date: 2017-10-01 End Date: 2017-10-11"]},"  各ジョブは、開始日と終了日の間の期間によって決定される同じ時間範囲を持ちます。メトリクスの転送は、前のジョブの完了時から開始され、期間が現在の日付（デフォルトの終了日）を過ぎるまで続きます。さらなる転送は、完全な期間が利用可能になるまで遅延され、その時点でジョブが実行され、次の期間が利用可能になるまで一時停止します。  1回目の実行: 開始 end_time: 2017-10-01 07:00:00 終了 end_time: 2017-10-10 07:00:00  2回目の実行: 開始 end_time: 2017-10-11 07:00:00 終了 end_time: 2017-10-20 07:00:00  3回目の実行: 開始 end_time: 2017-10-21 07:00:00 終了 end_time: 2017-10-30 07"]}]}]}]}]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["*2021年5月9日現在、Facebook API ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.facebook.com/docs/graph-api/changelog/version9.0#instagram"},"children":["変更ログ"]},"によると、IG ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["follower_count"]}," は2年間ではなく最大30日間のデータを返すようになりました。User ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["follower_count"]}," の値は、Instagram アプリに表示される対応する値とより密接に一致します。したがって、User follower_count メトリクスが個別に選択された場合、クエリ時間は30日以内である必要があります。User オブジェクト全体をインポートする場合、クエリ時間が過去30日間（現在の日を除く）より古い場合、User follower_count メトリクスは空の値として返されます。  **online_followers メトリクスを除き、lifetime メトリクスでは、Incremental Loading チェックボックスのチェックを外し、Start Date と End Date フィールドを空にする必要があります。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"データ設定","__idx":10},"children":["データ設定"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データ設定では、転送をカスタマイズできます。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]}," を選択します。"," ","Data Settings ページが開きます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["必要に応じてデータ設定を編集するか、このダイアログページをスキップします。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/346805.21314f971d9d2103f4d9a50c34dd1f46be132d5583720162d3a5d1954ae8a13a.632f0615.png","alt":""},"children":[]}]},{"$$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":1,"id":"コマンドラインを使用した接続の作成","__idx":15},"children":["コマンドラインを使用した接続の作成"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"td-コマンドのインストール","__idx":16},"children":["'td' コマンドのインストール"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["最新の ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/tools/cli-and-sdks/td-toolbelt"},"children":["Treasure Data Toolbelt"]}," をインストールします。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"シード設定ファイルの作成seedyml","__idx":17},"children":["シード設定ファイルの作成（seed.yml）"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"in:\n  access_token: EAAZAB0rX...EOdIc5YqAZDZD\n  type: instagram_insight\n  facebook_page_name: 172411252833693\n  data_type: user\n  incremental: true\n  since: 2020-03-20\n  until: 2020-04-10\n  use_individual_metrics: true\n  incremental_user_metrics:\n    - value: email_contacts-day\n    - value: impressions-days_28\nout:\n  mode: append\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"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":"Config key"},"children":["Config key"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Type"},"children":["Type"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Required"},"children":["Required"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["access_token"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Facebook の長期間有効なユーザーアクセストークン。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["facebook_page_name"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Instagram Business アカウントにリンクされている Facebook ページ ID。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["data_type"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["user, media, comments, media_list or tags"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["use_individual_metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["インポートするメトリクスデータを手動で選択するオプション。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental_user_preset_metric"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["増分ロードが ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["true"]}," に設定されている場合の User プリセットメトリクス"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental_user_metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["array"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["増分ロードが ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["true"]}," に設定されている場合にインポートする User メトリクス"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["non_incremental_user_preset_metric"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["増分ロードが ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false"]}," に設定されている場合にインポートする User プリセットメトリクス"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["non_incremental_user_metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["array"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["増分ロードが ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false"]}," に設定されている場合にインポートする User メトリクス"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["media_metrics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["array"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["転送する個別の Media メトリクスを選択"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["media_preset_metric"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["転送する Media プリセットメトリクスを選択"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["boolean"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["繰り返し実行される場合、最後のインポート以降のデータのみが収集されます。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["since"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["この日付以降のデータのみをインポートします。Date Range Import を参照してください"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["until"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["この日付までのデータのみをインポートします"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["throttle_wait_in_millis"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["int"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["API 制限に達すると、Facebook は API 呼び出しをスロットル（ブロック）します。API を再度呼び出す前に、指定された時間だけ待つ必要があります。デフォルト：3600000"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["maximum_retries"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["int"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["各 API 呼び出しの最大リトライ回数を指定します。デフォルト：3"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["initial_retry_interval_millis"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["int"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["最初のリトライの待機時間を指定します。デフォルト：20000"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["maximum_retries_interval_millis"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["int"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["リトライ間の最大時間を指定します。デフォルト：120000"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["connect_timeout_in_millis"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["int"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["no"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["API 呼び出しを行う際に接続がタイムアウトするまでの時間を指定します。デフォルト：30000"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["idle_timeout_in_millis"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["int"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["not"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["プール内で接続がアイドル状態を維持できる時間を指定します。デフォルト：60000"]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["利用可能な ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["out"]}," モードの詳細については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/ja/int/instagram-user-and-media-insights-import-integration#InstagramUserandMediaInsightsImportIntegration-ModesfortheOutPlugin"},"children":["Appendix"]}," を参照してください。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"フィールドの推測loadyml-の生成","__idx":18},"children":["フィールドの推測（load.yml の生成）"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["connector:guess"]}," を使用します。このコマンドは、対象データを自動的に読み取り、欠落している部分をインテリジェントに推測します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"$ td connector:guess seed.yml -o load.yml\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["load.yml"]}," ファイルを開くと、推測された設定が表示されます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"---in:  access_token: EAAZA.....dIc5YqAZDZD  type: instagram_insight  facebook_page_name: '172411252833693'  data_type: user  incremental: true  since: '2020-03-20'  until: '2020-04-10'  use_individual_metrics: true  incremental_user_metrics:  - {value: email_contacts-day}  - {value: impressions-days_28}out: {mode: append}exec: {}filters:- from_value: {mode: upload_time}  to_column: {name: time}  type: add_time\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["次に、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["preview"]}," コマンドを使用してデータをプレビューできます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:preview load.yml\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"ロードジョブの実行","__idx":19},"children":["ロードジョブの実行"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ロードジョブを送信します。データサイズによっては、数時間かかる場合があります。ユーザーは、データが保存されるデータベースとテーブルを指定する必要があります。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"$ td connector:issue load.yml --database td_sample_db --table td_sample_table\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["上記のコマンドは、すでに ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["database(td_sample_db)"]}," と ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["table(td_sample_table)"]}," を作成していることを前提としています。データベースまたはテーブルが TD に存在しない場合、このコマンドは成功しませんので、データベースとテーブルを",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/customer-data-platform/data-workbench/databases/data-management"},"children":["手動で"]},"作成するか、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td connector:issue"]}," コマンドで ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--auto-create-table"]}," オプションを使用してデータベースとテーブルを自動的に作成します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:issue load.yml --database td_sample_db --table td_sample_table --time-column created_at --auto-create-table\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["「--time-column」オプションで、時刻フォーマット列を「パーティショニングキー」に割り当てることができます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"スケジュール実行","__idx":20},"children":["スケジュール実行"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["定期的なデータコネクタ実行をスケジュールできます。高可用性を確保するため、スケジューラーを慎重に設定しています。この機能を使用することで、ローカルデータセンターで ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["cron"]}," デーモンを使用する必要がなくなります。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"スケジュールの作成","__idx":21},"children":["スケジュールの作成"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["新しいスケジュールは、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td connector:create"]}," コマンドを使用して作成できます。スケジュールの名前、cron 形式のスケジュール、データが保存されるデータベースとテーブル、およびデータコネクタ設定ファイルが必要です。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:create \\    daily_users_import \\    \"10 0 * * *\" \\    td_sample_db \\    td_sample_table \\    load.yml\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["cron"]}," パラメータは、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["@hourly"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["@daily"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["@monthly"]}," の3つの特別なオプションも受け付けます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"インクリメンタルスケジューリング","__idx":22},"children":["インクリメンタルスケジューリング"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental"]}," オプションを設定することで、レコードを段階的にロードできます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"in: type: instagram_insight ... incremental: trueout: mode: append\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["スケジュール実行を使用している場合、コネクタは最後のインポート時刻 ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["time_created"]}," 値を自動的に保存し、内部で保持します。そして、次回のスケジュール実行時に使用されます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"in:  type: instagram_insight  ...out:  ...Config Diff---in:  time_created: '2020-02-02T15:46:25Z'\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"スケジュールの一覧表示","__idx":23},"children":["スケジュールの一覧表示"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["スケジュールされたエントリのリストは、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td connector:list"]}," で確認できます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:list\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"スケジュールの設定と履歴の表示","__idx":24},"children":["スケジュールの設定と履歴の表示"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td connector:show"]}," は、スケジュールエントリの実行設定を表示します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:show daily_leads_import\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td connector:history"]}," は、スケジュールエントリの実行履歴を表示します。個々の実行結果を調査するには、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td job jobid"]}," を使用します。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"スケジュールの削除","__idx":25},"children":["スケジュールの削除"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td connector:delete"]}," は、スケジュールを削除します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:delete daily_users_import\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"out-プラグインのモード","__idx":26},"children":["Out プラグインのモード"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["load.yml ファイルの out セクションでファイルインポートモードを指定できます。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["out: セクションは、データが Treasure Data テーブルにどのようにインポートされるかを制御します。"," ","たとえば、Treasure Data の既存のテーブルにデータを追加するか、データを置き換えるかを選択できます。"]},{"$$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":"strong","attributes":{},"children":["モード"]}]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":""},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["説明"]}]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":""},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["例"]}]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Append"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["レコードは対象テーブルに追加されます。"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["in:   ... out:   mode: append"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Always Replace"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["対象テーブルのデータを置き換えます。対象テーブルに対して手動で行われたスキーマ変更はそのまま保持されます。"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["in:   ... out:   mode: replace"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Replace on new data"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["新しいデータがインポートされる場合にのみ、対象テーブルのデータを置き換えます。"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["in:   ... out:   mode: replace_on_new_data"]}]}]}]}]}]}]},"headings":[{"value":"Instagram User And Media Insights Import Integration","id":"instagram-user-and-media-insights-import-integration","depth":1},{"value":"メディアタイプ","id":"メディアタイプ","depth":4},{"value":"Facebook Page IDの取得","id":"facebook-page-idの取得","depth":1},{"value":"拡張ユーザーアクセストークン","id":"拡張ユーザーアクセストークン","depth":1},{"value":"Treasure コンソールを使用してConnectionを作成する","id":"treasure-コンソールを使用してconnectionを作成する","depth":1},{"value":"新しいAuthenticationの作成","id":"新しいauthenticationの作成","depth":2},{"value":"新しいOAuth connectionの作成","id":"新しいoauth-connectionの作成","depth":3},{"value":"InstagramアカウントデータをTreasure Dataに転送する","id":"instagramアカウントデータをtreasure-dataに転送する","depth":2},{"value":"Connection","id":"connection","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":"コマンドラインを使用した接続の作成","depth":1},{"value":"'td' コマンドのインストール","id":"td-コマンドのインストール","depth":2},{"value":"シード設定ファイルの作成（seed.yml）","id":"シード設定ファイルの作成seedyml","depth":2},{"value":"フィールドの推測（load.yml の生成）","id":"フィールドの推測loadyml-の生成","depth":2},{"value":"ロードジョブの実行","id":"ロードジョブの実行","depth":2},{"value":"スケジュール実行","id":"スケジュール実行","depth":1},{"value":"スケジュールの作成","id":"スケジュールの作成","depth":2},{"value":"インクリメンタルスケジューリング","id":"インクリメンタルスケジューリング","depth":2},{"value":"スケジュールの一覧表示","id":"スケジュールの一覧表示","depth":2},{"value":"スケジュールの設定と履歴の表示","id":"スケジュールの設定と履歴の表示","depth":2},{"value":"スケジュールの削除","id":"スケジュールの削除","depth":2},{"value":"Out プラグインのモード","id":"out-プラグインのモード","depth":1}],"frontmatter":{"seo":{"title":"Instagram User And Media Insights Import Integration"}},"lastModified":"2026-06-01T09:34:27.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/ja/int/instagram-user-and-media-insights-import-integration","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}