DataConnector | ComponentOne
ADO.NET provider for Google Analytics / Authentication
In This Topic
    Authentication
    In This Topic

    The ADO.NET provider for Google Analytics authenticates using the service account credentials. To get authorized you have to follow the steps below:

    1. Create and log in to the Google Console API using a Google account, and generate the service account credentials in the form of a JSON file or P12 file.
    2. Authorize the service account on the Google Analytics website to retrieve the analytics data.
    3. In the code, assign the JSON file path to the KeyFile property which contains the service account credentials in JSON format. Additionally, assign the ViewId property to the connection string, specifying the view from which you want to retrieve data.
    4. Finally, pass these two attributes in the connection string to make authorized access to Google Analytics data.

    Supported Authentication methods for Google Analytics provider

    Google Analytics supports authentication using service account credentials. This method enables access to Google Analytics data through the use of a JSON key file associated with a service account, providing secure authentication for accessing analytics data.

    Connection properties used on each type of authentication

    Service account credentials Authentication

    1. KeyFile: Specifies the path to the JSON key file for service account authentication with Google Analytics.
    2. ViewId: Specifies the Google Analytics view ID (profile ID) from which you want to fetch data.

    To know more about the implementation of the above, you can refer to the Quick Start topic.