{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/ja/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"Hubspot Import Integration CLI","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":"hubspot-import-integration-cli","__idx":0},"children":["Hubspot Import Integration CLI"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"td-コマンド-v0119-以降のインストール","__idx":1},"children":["'td' コマンド v0.11.9 以降のインストール"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["最新の",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://toolbelt.treasuredata.com/"},"children":["TD Toolbelt"]},"をインストールできます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td --version\n0.15.0\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"設定ファイルの作成","__idx":2},"children":["設定ファイルの作成"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["HubSpotアカウントのアクセス情報を含む設定ファイル（例：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["load.yml"]},"）を以下の例のように準備します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"in:\n  type: hubspot\n  client_id: xxxxxxxxxxxxx\n  client_secret: xxxxxxxxxxxxx\n  refresh_token: xxxxxxxxxxxxx\n  target: contacts\n  additional_properties: prop_1, prop_2, prop_3\n  retry_intial_wait_msec: 500\n  retry_limit: 3\n  max_retry_wait_msec: 30000\n  from_date: 2016-09-01\n  fetch_days: 2\n  incremental: true\n  connect_timeout_millis: 60000\n  idle_timeout_millis: 60000\nout:\n  mode: replace\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["この例はHubSpotの",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Contact"]},"オブジェクトをダンプします："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["client_id"]}," および ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["client_secret"]},"：HubSpotアプリの認証情報（文字列、必須）"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["refresh_token"]},"：HubSpot OAuth2のrefresh_token。HubSpotユーザーアカウントを使用してHubSpotアプリへのアクセスを許可する必要があります（文字列、必須）"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target"]},"：インポートするHubSpotオブジェクト。サポートされる値：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contacts"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["engagements"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["companies"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contact_lists"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["email_events"]},"、deals、properties、search"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["additional_properties"]},"：カンマ区切りの追加カスタムプロパティのリスト。このフィールドはほとんどの場合必要ありません。この設定は",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contacts"]},"、companies、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["deals"]},"のターゲットでのみ有効です。指定したリストはHubSpot APIからのカスタムプロパティのリストとマージされます（文字列、オプション）"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["custom_properties_chunk_size"]},"：カスタムプロパティのリストが大きすぎる場合（> 200）、コネクタは複数のリクエストに分割します。このパラメータを使用して、各リクエストのカスタムプロパティリストのパーティションサイズを定義します（整数、オプション、デフォルト：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["200"]},"）"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["object_names：カンマ区切りのHubSpotオブジェクトのリスト。これはpropertiesターゲットにのみ必要です。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["object_name：HubSpotオブジェクト。これはsearchターゲットにのみ必要です。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["fetch_all_properties：searchターゲットのすべてのプロパティを取得するフラグ。これはsearchターゲットにのみ必要です。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["incremental_column：dateまたはdatetime型のみをサポートします。これはsearchターゲットに必要です。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["start_time：検索オブジェクトの開始時刻。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["end_time：検索オブジェクトの終了時刻。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["retry_intial_wait_msec：初回のリトライ待機時間（ミリ秒）。デフォルト：1000。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["retry_limit"]},"：最大リトライ回数。デフォルト：7"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["max_retry_wait_msec"]},"：最大リトライ待機時間（ミリ秒）。デフォルト：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["30000"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["from_date"]},"：この日付からデータをインポートします。フォーマット：YYYY-MM-DD。これはcontacts、companies、deals、email_eventsに必要です。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["fetch_days"]},"：データをインポートする日数。デフォルト：1。これはcontacts、companies、deals、email_eventsに必要です。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental"]},"：データインポートが継続的か1回限りかを決定します。デフォルト：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false（非増分）"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["connect_timeout_millis：接続が宛先に接続するまでの最大時間（ミリ秒）。デフォルト：60000。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["idle_timeout_millis"]},"：接続がアイドル状態（つまり、どちらの方向にもデータトラフィックがない状態）になる最大時間（ミリ秒）。デフォルト：60000。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["利用可能な",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["out"]},"モードの詳細については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"#modes-for-out-plugin"},"children":["Modes for Out Plugin"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"オプションインポートするデータのプレビュー","__idx":3},"children":["（オプション）：インポートするデータのプレビュー"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["td connector: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":4},"children":["ロードジョブの実行"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ロードジョブを送信します。データサイズによっては数時間かかる場合があります。ユーザーはデータが保存されるデータベースとテーブルを指定する必要があります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataのストレージは時間で分割されているため、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--time-column"]},"オプションを指定することをお勧めします。このオプションが指定されていない場合、データコネクタは最初の",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["long"]},"または",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["timestamp"]},"列を分割時間として選択します。--time-",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["column"]},"で指定される列の型は、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["long"]},"型または",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["timestamp"]},"型のいずれかである必要があります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データに時間列がない場合は、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["add_time"]},"フィルタオプションを使用して追加できます。詳細については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://docs.treasuredata.com/smart/project-product-documentation/add_time-filter-function"},"children":["add_time Filter Function"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:issue load.yml --database td_sample_db --table td_sample_table --time-column updated_date\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["上記のコマンドは、*database(td_sample_db)",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["と"]},"table(td_sample_table)*がすでに作成されていることを前提としています。データベースまたはテーブルがTDに存在しない場合、このコマンドは成功しないため、データベースとテーブルを",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://docs.treasuredata.com/smart/project-product-documentation/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 updated_date --auto-create-table\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["--time-columnオプションを使用して、時刻フォーマット列を「パーティショニングキー」に割り当てることができます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"増分ロード","__idx":5},"children":["増分ロード"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["HubSpot APIは、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Contacts"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Companies"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Email Events"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Deals"]},"、および",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Search"]},"の増分ロードをサポートしています。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Companies"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Contacts"]},"、および",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Deals"]},"は、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["過去30日間"]},"に変更されたレコード、または最近変更された10,000件のレコードのみを返します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incrementalがtrueに設定されている場合、"]},"データコネクタはfrom_dateとfetch_daysで指定された日付と日数に従ってレコードをロードします。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["例："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"  from_date: 2016-09-01T00:00:00.000Z\n  fetch_days: 2\n"},"children":[]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["1回目の反復：データコネクタは",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Sep 01 00:00:00 UTC 2016"]},"から",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Sep 03 00:00:00 UTC 2016"]},"までのレコードを取得します"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["2回目の反復：データコネクタは",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Sep 03 00:00:00 UTC 2016"]},"から開始し、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Sep 03 00:00:00 UTC 2016"]},"から",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Sep 05 00:00:00 UTC 2016"]},"までのレコードを取得します。指定されたターゲットに対して次の増分も同様に続きます。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incrementalがfalseに設定されている場合、"]},"データコネクタは指定されたターゲットのすべてのレコードをロードします。これは1回限りのアクティビティです。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["API v3 Search"]},"ターゲットの場合、異なる増分設定を使用します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"linenumbers trueincremental_column: createdatestart_time: 2016-09-01T00:00:00.000Zend_time: 2017-09-01T00:00:00.000Z\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"ページネーション","__idx":6},"children":["ページネーション"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ほとんどのHubSpot APIエンドポイントは1ページあたり250レコードを返します。ただし、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["deals"]},"は増分エンドポイントで1ページあたり100レコード、非増分エンドポイントで1ページあたり250レコードを返します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Email Eventsの場合、HubSpot APIは各キャンペーンIDとアプリIDに属するイベントをサポートします。イベントは、キャンペーンとアプリのすべての組み合わせに対してページごとに取得されます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"ターゲット名","__idx":7},"children":["ターゲット名"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["HubSpot API がサポートするオブジェクトには、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Contacts"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Contact Lists"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Companies"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Engagements"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Email Events"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["API v3 Properties"]},"、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["API v3 Search"]}," があります。これらは以下の形式でターゲット名として指定する必要があります。"]},{"$$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":["HubSpot オブジェクト"]}]},{"$$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":["Contacts"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["contacts"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Contact Lists"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["contact_lists"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Companies"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["companies"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Engagements"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["engagements"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Email Events"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["email_events"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Deals"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["deals"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["API v3 Properties"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["properties"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["API v3 Search"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["search"]}]}]}]}]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"warning","name":"Contact Lists v1 サンセット — 対応が必要です"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["HubSpotはContact Lists v1 APIを2026-04-30にサンセットしました。",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contact_lists"]},"ターゲットは現在",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["POST /crm/v3/lists/search"]},"を呼び出し、v1とは異なるv3スキーマを返します："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["削除されたカラム"]},"：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["metaData"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["archived"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["internalListId"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["dynamic"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["filters"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["portalId"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["deleteable"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["listType"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["型の変更"]},"：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["listId"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["createdAt"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["updatedAt"]},"は",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["STRING"]},"になりました（v3は文字列IDとISO-8601タイムスタンプを返します。以前は",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["LONG"]},"）"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["新しいカラム"]},"：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["listVersion"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["processingType"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["processingStatus"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["objectTypeId"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["filtersUpdatedAt"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["createdById"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["updatedById"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["additionalProperties"]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["v1のカラム名や数値型の",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["listId"]},"/",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["createdAt"]},"/",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["updatedAt"]},"に依存している下流のテーブルおよびクエリは更新が必要です。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["参考：",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.hubspot.com/changelog/extension-contact-lists-api-v1-sunset-moved-to-april-30-2026"},"children":["Contact Lists v1 サンセット"]}," · ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://developers.hubspot.com/docs/api-reference/legacy/crm/lists/v1-migration-guide"},"children":["v1 → v3 移行ガイド"]}]}]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info","name":"API v1ターゲットからAPI v3 Searchへの移行"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["以下のAPI v1ターゲットは引き続き動作しますが、HubSpotによるv1のサンセットが順次進められています。将来の動作停止を避けるため、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["search"]},"ターゲット（API v3）への切り替えを推奨します："]},{"$$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":"code","attributes":{},"children":["target: contacts"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target: search"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object_name: contacts"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental_column: lastmodifieddate"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target: companies"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target: search"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object_name: companies"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental_column: hs_lastmodifieddate"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target: deals"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target: search"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object_name: deals"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["incremental_column: hs_lastmodifieddate"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target: engagements"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["エンゲージメントタイプごとに別ジョブに分割 — ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["target: search"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object_name: calls"]},"（または ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["emails"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["meetings"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["notes"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["tasks"]},"）"]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["注意："]}," v3スキーマはv1とは異なります。出力先テーブルのカラム名と型が変わります。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"custom-properties","__idx":8},"children":["Custom Properties"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データコネクタは Custom Property をサポートしています。データコネクタは、サポートされているターゲット（",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contacts"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["companies"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["deals"]},"）のすべての Custom Properties のデータを自動的に取得します。この機能はデフォルトで有効になっているため、新しい Custom Property を作成する際に特別な操作は必要ありません。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ほとんどの場合、すべての Custom Properties が HubSpot API から自動的に取得されるため、「Additional Custom Properties」フィールドを指定する必要はありません。インポートされたデータに一部の Custom Properties が欠落していると思われる場合は、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["prop_1, prop_2, prop_3,..."]}," の形式（カンマ区切り）で「Additional Custom Properties」を指定できます。"]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["入力したリストは HubSpot API からの Custom Properties のリストとマージされます。最終的な Custom Properties のリストが十分に大きい場合（> 200）、HubSpot API が ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GET"]}," メソッドを使用するため、データコネクタは URL の長さ制限を回避するために各リクエストを複数に分割します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["「New Transfer」を作成する際、「Advanced Settings」でリストを分割するサイズを決定できます。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image-20191021-164124.1bcdf50665706a70827ab3a15c1fc448728726fc0f8b66cccf0c6b08cd278237.d9a10a69.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"スケジュール実行","__idx":9},"children":["スケジュール実行"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["定期的な HubSpot インポートのために、データコネクタの定期実行をスケジュールできます。高可用性を確保するため、スケジューラーは慎重に設定されています。この機能を使用することで、ローカルデータセンターに ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["cron"]}," デーモンを配置する必要がなくなります。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"スケジュールの作成","__idx":10},"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_hubspot_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":"p","attributes":{},"children":["デフォルトでは、スケジュールは UTC タイムゾーンで設定されます。-t または --timezone オプションを使用して、タイムゾーンでスケジュールを設定できます。--timezone オプションは、Asia/Tokyo、America/Los_Angeles などの拡張タイムゾーン形式のみをサポートします。PST、CST などのタイムゾーンの略語はサポートされておらず、予期しないスケジュールになる可能性があります。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"スケジュールのリスト表示","__idx":11},"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+-----------------------+--------------+----------+-------+--------------+-----------------+----------------------------+\n| Name                  | Cron         | Timezone | Delay | Database     | Table           | Config                     |\n+-----------------------+--------------+----------+-------+--------------+-----------------+----------------------------+\n| daily_hubspot_import  | 10 0 * * *   | UTC      | 0     | td_sample_db | td_sample_table | {\"type\"=>\"hubspot\", ... }  |\n+-----------------------+--------------+----------+-------+--------------+-----------------+----------------------------+\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"スケジュールの設定と履歴の表示","__idx":12},"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_hubspot_import\nName     : daily_hubspot_import\nCron     : 10 0 * * *\nTimezone : UTC\nDelay    : 0\nDatabase : td_sample_db\nTable    : td_sample_table\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":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"% td connector:history daily_hubspot_import\n+--------+---------+---------+--------------+-----------------+----------+---------------------------+----------+\n| JobID  | Status  | Records | Database     | Table           | Priority | Started                   | Duration |\n+--------+---------+---------+--------------+-----------------+----------+---------------------------+----------+\n| 578066 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-18 00:10:05 +0000 | 160      |\n| 577968 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-17 00:10:07 +0000 | 161      |\n| 577914 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-16 00:10:03 +0000 | 152      |\n| 577872 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-15 00:10:04 +0000 | 163      |\n| 577810 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-14 00:10:04 +0000 | 164      |\n| 577766 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-13 00:10:04 +0000 | 155      |\n| 577710 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-12 00:10:05 +0000 | 156      |\n| 577610 | success | 10000   | td_sample_db | td_sample_table | 0        | 2015-04-11 00:10:04 +0000 | 157      |\n+--------+---------+---------+--------------+-----------------+----------+---------------------------+----------+\n8 rows in set\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"スケジュールの削除","__idx":13},"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_hubspot_import\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"out-plugin-のモード","__idx":14},"children":["Out Plugin のモード"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["load.yml ファイルの out セクションでファイルインポートモードを指定できます。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["out: セクションは、Treasure Data テーブルへのデータのインポート方法を制御します。たとえば、Treasure Data の既存のテーブルにデータを追加したり、データを置き換えたりすることができます。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["|  | モード | 説明 | 例 |"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["| --- | --- | --- |"," ","| Append | レコードがターゲットテーブルに追加されます。 | ​in: ...  out:  mode: append |"," ","| Always Replace | ターゲットテーブルのデータを置き換えます。ターゲットテーブルに対して行われた手動のスキーマ変更はそのまま残ります。 | in:  ...  out:  mode: replace |"," ","| Replace on new data | 新しいデータがインポートされる場合にのみ、ターゲットテーブルのデータを置き換えます。 | in: ...  out:  mode: replace_on_new_data |"]}]},"headings":[{"value":"Hubspot Import Integration CLI","id":"hubspot-import-integration-cli","depth":1},{"value":"'td' コマンド v0.11.9 以降のインストール","id":"td-コマンド-v0119-以降のインストール","depth":2},{"value":"設定ファイルの作成","id":"設定ファイルの作成","depth":2},{"value":"（オプション）：インポートするデータのプレビュー","id":"オプションインポートするデータのプレビュー","depth":2},{"value":"ロードジョブの実行","id":"ロードジョブの実行","depth":2},{"value":"増分ロード","id":"増分ロード","depth":2},{"value":"ページネーション","id":"ページネーション","depth":2},{"value":"ターゲット名","id":"ターゲット名","depth":2},{"value":"Custom Properties","id":"custom-properties","depth":2},{"value":"スケジュール実行","id":"スケジュール実行","depth":2},{"value":"スケジュールの作成","id":"スケジュールの作成","depth":3},{"value":"スケジュールのリスト表示","id":"スケジュールのリスト表示","depth":3},{"value":"スケジュールの設定と履歴の表示","id":"スケジュールの設定と履歴の表示","depth":3},{"value":"スケジュールの削除","id":"スケジュールの削除","depth":3},{"value":"Out Plugin のモード","id":"out-plugin-のモード","depth":2}],"frontmatter":{"seo":{"title":"Hubspot Import Integration CLI"}},"lastModified":"2026-05-18T03:41:08.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/ja/int/hubspot-import-integration-cli","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}