LogoLogo
My AppsLive demoNewsArticles
  • Introduction
  • πŸ“ŒProduct updates: 2025
    • 2024
    • 2023
  • Getting Started
    • Registration
    • Adding a space
    • Adding an app to the space
  • Basic Events & Custom Events
  • Integration
    • Expert Tips
      • What to track
      • Payments & Anti-cheat
      • Check your integration
    • Integration of SDK 2.0+
      • SDK Integration
        • Android
        • iOS
        • macOS
        • Windows
        • Web
          • Web SDK Integration
          • Web SDK Releases
        • Unity
        • Unreal Engine
        • Godot Engine
      • Automatic payment tracking
        • App Store
        • Google Play
      • Setting up Events
        • Basic methods
        • Secondary methods
        • User profile
        • Anticheat methods
        • Track sessions
      • Push notifications
        • Android
        • iOS
        • Windows (UWP)
        • Unity
          • Android
          • iOS
          • Windows (UWP/WSA)
        • Unreal Engine
      • A/B testing
        • Description of A/B testing on the SDK side
        • Working with A/B tests in the devtodev interface
        • A/B testing examples
    • Integration of SDK 1.0+ (deprecated)
      • SDK Integration
        • iOS
        • Android
        • Windows 8.1 and 10
        • Web
        • Unity
        • Mac OS
        • Adobe Air
        • UE4
      • Setting up Events
        • Basic methods
        • Secondary methods
        • User profile
        • Anti-cheat Methods
      • Push Notifications
        • IOS
        • Android
        • Windows 8.1 and Windows 10
        • Unity
        • Abode Air
        • UE4
    • Test Devices
    • Server API
      • Data API 2.0
      • Subscription API
      • Push API
        • IOS
        • Android
        • Windows UWP
        • Windows
      • Raw Export
      • Labels API
      • Data API
    • Import historical data via API
    • Data Export
      • Data Export to Cloud Storage (BigQuery / Amazon S3)
  • 3rd Party Sources
    • Attribution Trackers
      • AppsFlyer
      • Adjust
      • Branch.io
      • Kochava
      • Tenjin
      • Tune (MAT)
      • Singular
      • Custom postback API
      • Facebook Ads referral decryption
    • App Marketplace Data
      • App Store Connect Stats
      • App Store Subscriptions
      • Google Play Console Stats
      • Google Play Subscriptions
      • AppGallery Connect Stats
    • Ad revenue
      • AdColony
      • AdMob
      • Facebook
      • MoPub
      • Unity Ads
      • Vungle
      • Ad revenue API
    • Cohort export
  • Reports and Functionality
    • Space-related Reports and Functionality
      • Overview
      • Custom dashboards & Reports
      • SQL
        • SQL tips
        • SQL Query examples
      • Audience overlap
    • Project-related Reports and Functionality
      • Overview
        • Real-Time Dashboard
        • Acquisition reports
        • Engagement reports
        • Monetization reports
        • In-game analysis reports
        • Cohort analysis
      • Reports
      • Push Notifications
        • Android Notifications
        • IOS Notifications
        • Windows Notifications
        • Button Templates
      • Predictions
      • Users & Segments
      • Filters
      • A/B Testing
      • Tuning
      • Settings
  • Metrics and Glossary
    • Ad networks metrics
    • Market Metrics
    • Prediction Metrics
    • SDK Metrics
    • Subscription metrics
  • Space Management
  • User Profile Management
  • Limits
  • Scenarios and Best Practices
    • Analytics use cases
    • Match-3
    • MMORPG Games
    • Hyper-Casual games
    • Social Casino
    • RPG games
    • Farming games
    • Non-gaming app
    • Acquisition Example
  • FAQ
    • Identification
    • Raw Data
    • All about data discrepancies
  • Slack
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. On the go
  2. Integration of SDK v2.0+
  3. SDK Integration

Windows

1. NuGet Installation

Package Manager UI

Find the DevToDev.Analytics.Uwp package using the package manager search engine and click Install. The latest version of the package is recommended.

Package Manager Console

2. SDK Initialization

Initialize the library using the following code:

var config = new DTDAnalyticsConfiguration();
config.LogLevel = DTDLogLevel.Error;
DTDAnalytics.Initialize("App ID", config);
  • You can find the App ID in the settings of the respective app in devtodev (Settings β†’ SDK β†’ Integration β†’ Credentials).

  • config - is a DTDAnalyticsConfiguration object instance that is used for specifying additional properties during initialization.

DTDAnalyticsConfiguration

Parameter

Type

Description

currentLevel

Integer

The player level at the moment of devtodev SDK initialization. It’s optional but we recommend using it for improving data accuracy.

userId

String

A custom user ID assigned by the developer. In the case of default calculation by device IDs, the identifier can be used for searching users in devtodev. In case the project uses calculation by user IDs, the parameter is mandatory because it becomes the principal calculation ID in devtodev.

trackingAvailability

DTDTrackingStatus (enum)

The property allows or disallows devtodev tracking of the user. By default, it is set to DTDTrackingStatus.Enable. SDK stores the previously assigned value. Pass DTDTrackingStatus.Disable if the user opted out of tracking in line with GDPR.

logLevel

DTDLogLevel (enum)

The level of logging the SDK activity. The DTDLogLevel.No value is used by default. For troubleshooting during integration, it is recommended to set it to DTDLogLevel.Debug, and either switch it off DTDLogLevel.No or use it only for error handling DTDLogLevel.Error in the release version.

Example:

var config = new DevToDev.Analytics.DTDAnalyticsConfiguration();
config.LogLevel = DTDLogLevel.Error;
config.CurrentLevel = 2;
config.UserId = "CustomUserId";
config.TrackingAvailability = DTDTrackingStatus.Enable;
DevToDev.Analytics.DTDAnalytics.Initialize("App ID", config);

1. NuGet Installation

Package Manager UI

Find the DevToDev.Analytics package using the package manager search engine and click Install. The latest version of the package is recommended.

Package Manager Console

2. SDK Initialization

Initialize the library using the following code:

var config = new DTDAnalyticsConfiguration();
config.LogLevel = DTDLogLevel.Error;
DTDAnalytics.Initialize("App ID", config);
  • You can find the App ID in the settings of the respective app in devtodev (Settings β†’ SDK β†’ Integration β†’ Credentials).

  • config - is a DTDAnalyticsConfiguration object instance that is used for specifying additional properties during initialization.

DTDAnalyticsConfiguration

Parameter

Type

Description

currentLevel

Integer

The player level at the moment of devtodev SDK initialization. It’s optional but we recommend using it for improving data accuracy.

userId

String

A custom user ID assigned by the developer. In the case of default calculation by device IDs, the identifier can be used for searching users in devtodev. In case the project uses calculation by user IDs, the parameter is mandatory because it becomes the principal calculation ID in devtodev.

trackingAvailability

DTDTrackingStatus (enum)

The property allows or disallows devtodev tracking of the user. By default, it is set to DTDTrackingStatus.Enable. SDK stores the previously assigned value. Pass DTDTrackingStatus.Disable if the user opted out of tracking in line with GDPR.

logLevel

DTDLogLevel (enum)

The level of logging the SDK activity. The DTDLogLevel.No value is used by default. For troubleshooting during integration, it is recommended to set it to DTDLogLevel.Debug, and either switch it off DTDLogLevel.No or use it only for error handling DTDLogLevel.Error in the release version.

ApplicationVersion

String

The app version during the devtodev SDK initialization. It is recommended that you set the app version before the initialization to make the collection of app version statistics more precise.

Example:

var config = new DevToDev.Analytics.DTDAnalyticsConfiguration();
config.LogLevel = DTDLogLevel.Error;
config.CurrentLevel = 2;
config.UserId = "CustomUserId";
config.TrackingAvailability = DTDTrackingStatus.Enable;
config.ApplicationVersion = "1.2.34";
DevToDev.Analytics.DTDAnalytics.Initialize("App ID", config);

3. SDK Activity

The SDK can’t control app activity hence this responsibility is passed on to the developer. During the SDK initialization, the activity is triggered automatically, and later the activity status will not change automatically. For tracking app activity, the developer can use the DTDAnalytics.StartActivity and DTDAnalytics.StopActivity methods. It is recommended that you use the DTDAnalytics.StopActivity method to stop the activity when the app goes into the background or being closed. If the window is re-opened from the taskbar it is recommended to renew the activity by using the DTDAnalytics.StartActivity method.

1

Last updated 3 years ago

Was this helpful?