Establish Connectivity to Google Drive

This article describes how to connect to your profile Google Drive in order to use the files from this Data Soure as a basis for the future External Reports in Metric Insigths.

The procedure incudes:

  1. Creating a Google Service Account
  2. Sharing your Google Drive files with Metric Insights
  3. Metric Insights' Side Authorization

1. Create a Google Service Account

For this scenario you need aservice account, which is an account that belongs to your application instead of to an individual end user. Follow the instrunctions below to set it up. For more details, refer to Google Documentation.

1.1. Access Google Developers Console

https://console.developers.google.com/projectselector/iam-admin/iam

When logged in from the account that contains the required files on a Google Drive, follow the link above.

1.2. Service Accounts > Create

  1. On the left side of the screen in the IAM & admin panel select Service accounts
  2. In the pop-up menu choose Create.

1.3. Service Account Settings

  1. Service account name: Define a name for your service account.
  2. Service account ID: is going to be generatd automatically after you define a service account name.
  3. Furnish a new private key: Check this box to create a new private key. The required key type is JSON.
  4. At the bottom of the pop-up click Create.

NOTE: Once you click Create, the JSON key is generated and automatically downloaded to your computer. Remember the file location.

1.4. Put the JSON file into the directory on your server

The generated key has been downloaded to your computer as a JSON file. Place this JSON file on some directory on your server. For example:

opt/mi/config/google_drive.json

2. Share your Google Drive files with Metric Insights

Once you are done with creating a service account, you need to make sure that all the files that should be accessible by Metric Inisights are shared with this account.

  1. Access the file location
  2. At the upper right corner of the screen click Share. The Share with others pop-up opens.
  3. In the People field specify the Service account ID. See Step 1.3 for more details.
  4. Click Send.

3. Metric Insights' Side Authorization

After setting up the Google Side, create a Google Drive Data Source in Metric Insights:

3.1. Access Admin > Data Sources > [ + New Data Source ]

  1. The Select the Type of New Data Source pop-up opens.
  2. Select Other Data Source Type and choose Google Drive from the drop-down list.
  3. Proceed with creating a Data Source by moving to the Next step.

3.2. Provide the Required Google Drive Parameters

  1. Data Source Name will default, but you may modify if needed
  2. Google Service Account Email: Define a service account email. See Step 1.3 for details.
  3. Key Path: Define the path to the directory where you placed the JSON file with a generated private key in Step 1.4.
  4. Save your settings.

3.3. Refresh the list of the reports

  1. Access Google Drive Report List tab
  2. Click Refresh List

The shared files are to be displayed in this tab.

4. Create an External Report Using this file as a Source

In Metric Insights access New > External Report > Google Drive.

  1. Give your new report a Name
  2. Define whether you want report content to be updated manually or automatically. In case you choose Automatic Collection, define the following settings:
    • Define the Report Image Triggerfrom drop-down list.
    • Select an existing Plugin Connection Profile that we have created in Step 3.
    • Select a File available for that connection profile.
  3. Click Next: define details to proceed with Report creation.
  4. Collect image
  5. Enable and Publish

0 Comments

Add your comment

E-Mail me when someone replies to this comment