Capture server-side data with .NET SDK

The Sitefinity Insight .NET SDK enables you to easily perform many Sitefinity Insight-related tasks, such as data collection, personalization, obtaining information about touchpoints, goals, AB Tests, and other artifacts in your Sitefinity Insight data center. The .NET SDK is developed with extensibility in mind, so you can implement your own functionality, as well.

The following sections provide you with information about how to get the SDK, use its clients, and how to extend them.

For a list with all .NET SDK data types, along with their constructors, properties, methods, and fields, see .NET SDK data types.

Install the .NET SDK

You can install the .NET SDK by downloading the NuGet package from Sitefinity CMS NuGet repository using the following command:

Install-Package Telerik.DigitalExperienceCloud.Client

Get started

When working with the .NET SDK, you need to be aware that all functionality, related to the SDK, is grouped into the so-called clients. For example, there is an interaction client for reporting data to Sitefinity Insight, scoring client for handling personas and lead scoring features, including personalization, and so on. The following table summarizes the common characteristics of .NET SDK clients.

Characteristic Description
Data center key

All clients need the API key of the data center they are targeting. To get the API key of a data center:

  1. Log in https://insight.sitefinity.com
  2. Navigate to Administration » Your data center » API Key.

Alternatively, you can use the datacenters endpoint. For more information, see Obtain the data center API key.

Access token

All clients, apart from the Data collection ones, access secured Sitefinity Insight functionality. Thus, when you initialize them, you need to provide a valid access token.

PREREQUISITES: To obtain a valid access token, you need to generate an access key. For more information, see Connect your sites to Insight.

Using your access key that you generated in the Sitefinity Insight web app, you can create an access token in the .NET SDK in the following way:

AccessToken accessToken = new AccessToken("{Access Key}");

Asynchronous methods All .NET SDK clients' methods that retrieve or report Sitefinity Insight data, are asynchronous.

 

Was this article helpful?