接続の確立
接続プロファイルの設定
[CData]リボンから[データの取得]をクリックし、[取得元:HubDB]> 設定済みの接続 を選択してCData クエリウィンドウを起動します。新しい接続を設定するには、[新しいHubDB 接続]をクリックします。ここでは、接続の設定、接続のテスト、および接続プロファイルの保存を行うことができます。
Connecting to HubDB
There are two authentication methods available for connecting to HubDB data source: OAuth Authentication with a public HubSpot application and authentication with a Private application token.
OAuth
AuthScheme must be set to OAuth in all OAuth flows. The following OAuth flows assume you have done so.
Desktop Applications
You must create a custom OAuth application to connect. See Creating a Custom OAuth App a procedure.Get and Refresh the OAuth Access Token
After setting the following, you are ready to connect:
- OAuthClientId: Set this to the client Id assigned when you registered your application.
- OAuthClientSecret: Set this to the client secret assigned when you registered your application.
- CallbackURL: Set this to the redirect URI defined when you registered your application.
Private App
To connect using a Hubspot private application token, set the AuthScheme property to PrivateApp.
You can generate a private application token by following the steps below:
- In your HubDB account, click the settings icon (the gear) in the main navigation bar.
- In the left sidebar menu, navigate to Integrations > Private Apps.
- Click Create private app.
- On the Basic Info tab, configure the details of your application (name, logo, and description).
- On the Scopes tab, select Read or Write for each scope you want your private application to be able to access.
- A minimum of hubdb and crm.objects.owners.read is required to access tables.
- After you are done configuring your application, click Create app in the top right.
- Review the info about your application's access token, click Continue creating, and then Show token.
- Click Copy to copy the private application token.
To connect, set PrivateAppToken to the private application token you retrieved.
接続プロパティ
最後に、Connection プロパティを参照してください。接続の確立に使用できるさまざまなオプションの説明があります。
接続の管理
HubDB への認証に成功すると、インポートするデータをカスタマイズすることができます。詳しくは、接続の管理 を参照してください。
関連項目
- データのクエリ:[データ選択]ウィザードを使用してスプレッドシートにデータをプルします。また、ここではスケジュールされたデータのリフレッシュも設定できます。
- Excel アドインの使用:利用可能なCData Excel 関数 を使用するなど、HubDB データとやり取りする他の方法が見つかります。