YouTube Analytics

For Open Source Edition, an administrator must generate an API Key before this data source can be used. See Administer API Key for instructions.

Create the Connection

Follow the steps below to create a connection:

Watch Video: Connecting to a Database

This video might show an earlier version of the feature or operation that differs in minor ways from the current version.

  1. In the User Portal, press the top ‘Create’ button creation in the Portal, and select ‘Data Source’ database plus.

    uploadDriver2

    This opens the data source listing. To locate a data source, select the data source category in the left panel, or enter the data source name in the search field.

    datasourceList1

    If you see the ‘Create Visualization’ dialog box instead of the User Portal, press Connect to Data Source to display the data source listing.

    200

  2. Select the ‘YouTube Analytics’ data source, and press Create. This opens the data source definition screen.

    dataSourceNewYouTubeAnalytics2

  3. In the ‘Name’ field, enter a label for this connection.

  4. Enter the ‘Client ID’ and ‘Client Secret’. If you do not have a client ID and secret, you will need to create an app to generate these credentials. See Generate Credentials below.

  5. Press the Authorize button to populate the token fields.

  6. Optional: For a multi-tenant environment (Enterprise Edition only), assign any desired additional connections. See Add an Additional Connection for more information.

  7. Press OK.

    You may see the ‘Create Visualization’ dialog box at this step.

    200

    Press the ‘Close’ button close to continue with the steps below (recommended), or choose one of the following options:

    Create a Query

    Define a query based on the selected data source. See New Data Worksheet Dialog Box in Create a Data Worksheet for further instructions.

    Start from Scratch

    Open a blank Data Worksheet to build data blocks from fields of the selected data source. See Create Data Blocks in Create a Data Worksheet for further instructions.

  8. Verify that the data source you added is shown with a “check” icon submit, indicating that the connection was successful.

    dataSourceYouTubeAnalytics3

    If the database is shown with an ‘Error’ icon alert circle, this means that the connection was not successful.

    dataSourceYouTubeAnalytics4

    In this case, check the settings to make sure they are correct for your database. See Edit a Connection for information on how to change connection settings.

After you have created a connection to the database, you can proceed to define a data set. See YouTube Analytics Query.

Generate Credentials

To create the ‘Client ID’ and ‘Client Secret’ credentials for the YouTube Analytics connection, follow the steps below:

  1. Use the email associated with your YouTube account/channel to create a new Google Cloud project. See Create a Google Cloud project for full details.

  2. Navigate to APIs & Services  Enabled APIs and services and enable the ‘YouTube Analytics API’.

  3. Press Create credentials. For ‘Credential Type’, select ‘User Data’ and press Next.

  4. Enter the requested information for the OAuth Consent Screen. See Configure the OAuth consent screen and choose scopes for full details.

  5. Press Add or remove scopes and assign …​/auth/yt-analytics.readonly scope.

  6. For OAuth Client ID, select ‘Web application’ as the ‘Application type’.

  7. For Authorized redirect URIs, set the redirect URI to https://data.inetsoft.com/oauth.

  8. Press Create.

  9. Press Done.

  10. Navigate to the Credentials page and click on the client name to obtain your ‘Client ID’ and ‘Client Secret’.