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
  • User ID
  • Replace
  • Current user level
  • Cheater
  • Tester
  • Reserved user properties
  • Custom user property
  • Unset user property
  • Unset all user properties

Was this helpful?

Export as PDF
  1. Integration
  2. Integration of SDK 2.0+
  3. Setting up Events

User profile

PreviousSecondary methodsNextAnticheat methods

Last updated 18 days ago

Was this helpful?

User ID

This method is used to initialize the user in applications where you have set calculation by user ID specified by the developer.

You can also use this method when calculating by device ID (by default) to pass in the user ID used on your servers so that you can easily find the user on devtodev.

We recommend that you pass this parameter in the initialization configuration (userId property of an instance of theDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the setUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the setUserId method.

DTDAnalytics.setUserId(userId: "Custom User ID")

To get the current value of the user ID, use the asynchronous method getDeviceId(_ completionHandler: @escaping (String) -> Void)

DTDAnalytics.getUserId { userId in
  // your code
}

We recommend that you pass this parameter in the initialization configuration (userId property of an instance of theDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the setUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the setUserId method.

[DTDAnalytics userId:@"Custom User ID"];

To get the current value of the user ID, use the asynchronous method (void)deviceIdHandler:( void (^ _Nonnull)(NSString * _Nonnull))completion-Handler;

[DTDAnalytics userIdHandler:^(NSString * _Nonnull userId) {
  // your code
}];

We recommend that you pass this parameter in the initialization configuration (userId property of an instance of theDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the setUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the setUserId method.

DTDAnalytics.setUserId(userId = "Custom User ID")

To get the current value of the user ID, use the asynchronous method getDeviceId(block: (String) -> Unit)

DTDAnalytics.getUserId { userId ->
  // your code
}

We recommend that you pass this parameter in the initialization configuration (userId property of an instance of theDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the setUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the setUserId method.

DTDAnalytics.INSTANCE.setUserId("Custom User ID");

To get the current value of the user ID, use the asynchronous method getDeviceId(block: (String) -> Unit)

DTDAnalytics.INSTANCE.getUserId(userID ->
      // your code
      null
);

We recommend that you pass this parameter in the initialization configuration (userId property of an instance of theDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the SetUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the SetUserId method.

DTDAnalytics.SetUserId(userId: "Custom User ID")

To get the current value of the user ID, use the asynchronous method:

var userId = await DTDAnalytics.GetUserId();

We recommend that you pass this parameter in the initialization configuration (userId property of an instance of theDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the SetUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the SetUserId method.

DTDAnalytics.SetUserId(userId: "Custom User ID")

To get the current value of the user ID, use the asynchronous method:

DTDAnalytics.GetUserId(id =>
{
  //your code
});

We recommend that you pass this parameter in the initialization configuration (userId property in config object).

Do not pass an empty string ("") to the setUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the setUserId method.

window.devtodev.setUserId("Custom User ID")

To get the current value of the user ID, use the getUserIdmethod

var userId = window.devtodev.getUserId()

We recommend that you pass this parameter in the initialization configuration (UserId property of an instance of the FDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the SetUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use method:

Arguments
Type
Description

userId

FString

User ID.

UDTDAnalyticsBPLibrary::SetUserId("Name");

To get the current value of the user ID, use the asynchronous method:

Arguments
Type
Description

onResult

  • FAnalyticsDynamicGetterStringDelegate

  • FDTDGetterStringDelegate

Callback

auto onResult = new FDTDGetterStringDelegate();
onResult->BindLambda([](const FString& value)
{
	// Your code...
});
UDTDAnalyticsBPLibrary::GetUserId(*onResult);

We recommend that you pass this parameter in the initialization configuration (userId property of an instance of the GDDTDAnalyticsConfiguration class).

Do not pass an empty string ("") to the setUserID method as the user ID. Assigning an empty string is a command to assign a default value to the user ID (it is equal to the current device ID). In applications with calculation by user ID, this can lead to unnecessary registrations.

To set a new value as the user ID, use the SetUserId method.

DTDAnalytics.SetUserId("Custom User ID")

To get the current value of the user ID, use the asynchronous method DTDAnalytics.GetUserId(onResult: Callable)

DTDAnalytics.GetUserId(getUserIdHandler)

func getUserIdHandler(userId: String): 
  print(userId)

In order to track a user on several devices you can switch the identification method to identification by Custom User Id. This switch can be done only by devtodev – you just need to write a request to the support (use the Contact Us form), specifying the space name and project name. You must set the user IDs for all users before changing the identification method.

Please note: changing the idetification method is irreversible and you will not be able to switch back to the device identifiers in the future!

Replace

This method is used in very rare cases. It is applicable in the case when the calculation of users in the project is carried out by the user ID specified by the developer. In this case, the application can change this identifier. For example, calculation in the application is carried out by user emails and in the application, it is possible to change this email to another one. At the time of replacement, you need to call this method, specifying the user's previous email and the one with which it was replaced.

DTDAnalytics.replace(fromUserId: "Old user id", toUserId: "New user id")
[DTDAnalytics replaceFromUserId:@"Old user id" toUserId:@"New user id"];
DTDAnalytics.replaceUserId(
    fromUserId = "Old user id", 
    toUserId = "New user id"
)
DTDAnalytics.INSTANCE.replaceUserId("Old user id", "New user id");
DTDAnalytics.Replace(fromUserId: "Old user id", toUserId: "New user id");
DTDAnalytics.Replace(fromUserId: "Old user id", toUserId: "New user id");
window.devtodev.replace( "Old user id", "New user id")

Arguments
Type
Description

fromUserId

FString

From user ID

toUserId

FString

To user ID

UDTDAnalyticsBPLibrary::ReplaceUserId("UserIdBefore", "UserIdAfter");
DTDAnalytics.ReplaceUserId("Old user id", "New user id")

Do not use this method to re-login as a different user! The setUserId method is used for relogging.

Current user level

This method is used in cross-platform and data synchronized applications. The method is required to update user level data.

To set the current value to the user level, use setCurrentLevel(currentLevel: Int) method:

DTDAnalytics.setCurrentLevel(value: 2)

To get the user-level value stored by the SDK, use getCurrentLevel(completionHandler: @escaping (Int) -> Void) method

DTDAnalytics.getCurrentLevel { level in
  // your code
}

To set the current value to the user level, use (void)currentLevel:(NSInteger)currentLevel; method:

[DTDAnalytics currentLevel:2];

To get the user-level value stored by the SDK, use (void)currentLevelHandler:( void (^ _Nonnull)(NSInteger))completionHandler; method

[DTDAnalytics currentLevelHandler:^(NSInteger level) {
  // your code
}];

To set the current value to the user level, use method:

DTDAnalytics.setCurrentLevel(currentLevel = 2)

To get the user-level value stored by the SDK, use getCurrentLevel(completionHandler: @escaping (Int) -> Void) method

DTDAnalytics.getCurrentLevel { level ->
  // your code
}

To set the current value to the user level, use method:

DTDAnalytics.INSTANCE.setCurrentLevel(2);

To get the user-level value stored by the SDK, use getCurrentLevel(completionHandler: @escaping (Int) -> Void) method

DTDAnalytics.INSTANCE.getCurrentLevel ( currentLevel ->
       // your code 
       null
);

To set the current value to the user level, use method:

DTDAnalytics.SetCurrentLevel(level: 3);

To get the user-level value stored by the SDK, use GetCurrentLevel method:

var currentLevel = await DTDAnalytics.GetCurrentLevel();

To set the current value to the user level, use method:

DTDAnalytics.SetCurrentLevel(level: 3);

To get the user-level value stored by the SDK, use GetCurrentLevel method:

DTDAnalytics.GetCurrentLevel(level =>
{
  //your code
});

To set the current value to the user level, use method:

window.devtodev.setCurrentLevel(2)

To get the user-level value stored by the SDK, use getCurrentLevel method.

var currentLevel = window.devtodev.getCurrentLevel()

To set the current value to the user level, use method:

Arguments
Type
Description

level

int32

Current level.

UDTDAnalyticsBPLibrary::SetCurrentLevel(7);

To get the user-level value stored by the SDK, use method:

Arguments
Type
Description

onResult

  • FAnalyticsDynamicGetterIntDelegate

  • FDTDGetterIntDelegate

Callback

auto onResult = new FDTDGetterIntDelegate();
onResult->BindLambda([](int32 value)
{
	// Your code...
});
UDTDAnalyticsBPLibrary::GetCurrentLevel(*onResult);

To set the current value to the user level, use SetCurrentLevel(level: int) method:

DTDAnalytics.SetCurrentLevel(2)

To get the user-level value stored by the SDK, use GetCurrentLevel(onResult: Callable) method

DTDAnalytics.GetCurrentLevel(getCurrentLevelHandler)

func getCurrentLevelHandler(level: int):
    print("result is: " + str(level))

Cheater

If you have your own methods for detecting cheaters in the application, you can tag such users. Actions taken by these users will not be counted in statistics.

DTDUserCard.setCheater(cheater: true)
[DTDUserCard setCheater:true];
DTDUserCard.setCheater(cheater = true)
DTDUserCard.INSTANCE.setCheater(true);
DTDUserCard.SetCheater(cheater: true);
DTDUserCard.SetCheater(cheater: true);
window.devtodev.user.setCheater(true)
Arguments
Type
Description

cheater

bool

Cheater flag

UDTDUserCardBPLibrary::SetCheater(true);
DTDUserCard.SetCheater(true)

Tester

Use this method to tag a user as a tester. Events performed by testers will not be included in statistics.

DTDUserCard.setTester(tester: true)
[DTDUserCard setTester:true];
DTDUserCard.setTester(tester = true)
DTDUserCard.INSTANCE.setTester(true);
DTDUserCard.SetTester(tester: true);
DTDUserCard.SetTester(tester: true);
window.devtodev.user.setTester(true)
Arguments
Type
Description

tester

bool

Tester flag

UDTDUserCardBPLibrary::SetTester(true);
DTDUserCard.SetTester(true)

Reserved user properties

Attention! These properties have been removed since the devtodev SDK versions: iOS & macOS 2.4.0, Android 2.5.0, Unity SDK 3.8.0, Godot 1.0.0, Web 2.1

Attention! We strongly discourage the storage of personal user data! If you plan to pass this data, be sure to indicate this in the ‘Nutrition label’ when submitting the application to the App Store review.

Property

Getter

Setter

Name

setName(name: String)

getName(completionHandler: @escaping (String?) -> Void)

Email

setEmail(email: String)

getEmail(completionHandler: @escaping (String?) -> Void)

Phone

setPhone(phone: String)

getPhone(completionHandler: @escaping (String?) -> Void)

Photo

setPhoto(photo: String)

getPhoto(completionHandler: @escaping (String?) -> Void)

Gender

setGender(gender: DTDGender)

getGender(completionHandler: @escaping (DTDGender) -> Void)

Age

setAge(age: Int)

getAge(completionHandler: @escaping (Int) -> Void

Attention! We strongly discourage the storage of personal user data! If you plan to pass this data, be sure to indicate this in the ‘Nutrition label’ when submitting the application to the App Store review.

Property

Setter

Getter

Age

[DTDUserCard setAge:(NSInteger)];

[DTDUserCard getAgeHandler:^(NSInteger age) { }]

Email

[DTDUserCard setEmail:(NSString * _Nonnull)];

[DTDUserCard getEmailHandler:^(NSString * email) { }];

Gender

[DTDUserCard setGender:(enum Gender)];

[DTDUserCard getGenderHandler:^(enum Gender gender) { }];

Name

[DTDUserCard setName:(NSString * _Nonnull)];

[DTDUserCard getNameHandler:^(NSString * name) { }];

Phone

[DTDUserCard setPhone:(NSString * _Nonnull)];

[DTDUserCard getPhoneHandler:^(NSString * phone) { }];

Photo

[DTDUserCard setPhoto:(NSString * _Nonnull)];

[DTDUserCard getPhotoHandler:^(NSString * photo) { }];

Property

Getter

Setter

Name

setName(name: String)

getName(handler: (String) -> Unit)

Email

setEmail(email: String)

getEmail(handler: (String) -> Unit)

Phone

setPhone(phone: String)

getPhone(handler: (String) -> Unit)

Photo

setPhoto(photo: String)

getPhoto(handler: (String) -> Unit)

Gender

setGender(gender: DTDGender)

getGender(handler: (DTDGender) -> Void)

Age

setAge(age: Int)

getAge(handler: (String) -> Unit)

Property

Getter

Setter

Name

setName(name: String)

getName(handler: (String) -> Unit)

Email

setEmail(email: String)

getEmail(handler: (String) -> Unit)

Phone

setPhone(phone: String)

getPhone(handler: (String) -> Unit)

Photo

setPhoto(photo: String)

getPhoto(handler: (String) -> Unit)

Gender

setGender(gender: DTDGender)

getGender(handler: (DTDGender) -> Void)

Age

setAge(age: Int)

getAge(handler: (String) -> Unit)

Property

Getter

Setter

Name

SetName(name: string)

Task<string> GetName();

Email

SetEmail(email: string)

Task<string> GetEmail()

Phone

SetPhone(phone: string)

Task<string> GetPhone()

Photo

SetPhoto(photo: string)

Task<string> GetPhoto()

Gender

SetGender(gender: DTDGender)

Task<DTDGender> GetGender()

Age

SetAge(age: long)

Task<long> GetAge()

Attention! We strongly discourage the storage of personal user data! If you plan to pass this data, be sure to indicate this in the ‘Nutrition label’ when submitting the application to the App Store review.

Property

Getter

Setter

Name

SetName(name: string)

GetName(Action<string> onGetName)

Email

SetEmail(email: string)

GetEmail(Action<string> onGetEmail)

Phone

SetPhone(phone: string)

GetPhone(Action<string> onGetPhone)

Photo

SetPhoto(photo: string)

GetPhoto(Action<string> onGetPhoto)

Gender

SetGender(gender: DTDGender)

GetGender(Action<DTDGender> onGetGender)

Age

SetAge(age: long)

GetAge(Action<string> onGetAge)

Property

Getter

Setter

Type

Name

getName()

setName("John Doe")

String

Email

getEmail()

setEmail("email@me.com")

String

Phone

getPhone()

setPhone("+15555555555")

String

Photo

getPhoto()

setPhoto("https://domain.com/photo.jpg")

String

Gender

getGender()

setGender(gender)

Age

getAge()

setAge(age)

Int

Attention! We strongly discourage the storage of personal user data! If you plan to pass this data, be sure to indicate this in the ‘Nutrition label’ when submitting the application to the App Store review.

Property
Setter
Getter

Name

SetName(name: FString)

  • GetName(delegate: FUserCardDynamicGetterStringDelegate)

  • GetName(delegate: FDTDGetterStringDelegate)

Email

SetEmail(email: FString)

  • GetEmail(delegate: FUserCardDynamicGetterStringDelegate)

  • GetEmail(delegate: FDTDGetterStringDelegate)

Phone

SetPhone(phone: FString)

  • GetPhone(delegate: FUserCardDynamicGetterStringDelegate)

  • GetPhone(delegate: FDTDGetterStringDelegate)

Photo

SetPhoto(photo: FString)

  • GetPhoto(delegate: FUserCardDynamicGetterStringDelegate)

  • GetPhoto(delegate: FDTDGetterStringDelegate)

Gender

SetGender(gender: EDTDGender)

  • GetGender(delegate: FUserCardDynamicGetterGenderDelegate)

  • GetGender(delegate: FDTDGetterGenderDelegate)

Age

SetAge(age: int64)

  • GetAge(delegate: FUserCardDynamicGetterLongDelegate)

  • GetAge(delegate: FDTDGetterLongDelegate)

Example:

UDTDUserCardBPLibrary::SetEmail("Email");
auto onResult = new FDTDGetterStringDelegate();
onResult->BindLambda([](const FString& value)
{
	// Your code...
});
UDTDUserCardBPLibrary::GetEmail(*onResult);

Custom user property

Each devtodev project can have up to 30 custom user properties. User custom property values can be a number, a string (up to 500 symbols), or a boolean value.

This is how you can set properties on the current user profile:

DTDUserCard.set(key: "key for string value", value: "string value")
DTDUserCard.set(key: "key for int value", value: 10)
DTDUserCard.set(key: "key for double value", value: 12.5)
DTDUserCard.set(key: "key for bool value", value: true)

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use the method:

getValue(key: String, _completionHandler: @escaping (Any) -> Void)

DTDUserCard.getValue(key: "key for value") { value in
  // your code
}

When using the getValue method, note that the Any return type will need to be cast to the data type you want.

This is how you can set properties on the current user profile:

[DTDUserCard setString:@"key for string value" value:@"string value"];
[DTDUserCard setInt:@"key for int value" value:10];
[DTDUserCard setDouble:@"key for double value" value:12.5];
[DTDUserCard setBool:@"key for bool value" value:true];

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use the method:

(void)getValueWithKey:(NSString * _Nonnull)key :(void (^ _Nonnull)(id _Nullable))completionHandler;

[DTDUserCard getValueWithKey:@"key for value" :^(id object) {
  // your code
}];

When using the getValue method, note that the Anyreturn type will need to be cast to the data type you want.

This is how you can set properties on the current user profile:

DTDUserCard.set(key = "key for string value", value = "string value")
DTDUserCard.set(key = "key for int value", value = 10)
DTDUserCard.set(key = "key for double value", value = 12.5)
DTDUserCard.set(key = "key for bool value", value = true)

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use the method:

getValue(key: String, handler: (Any?) -> Unit)

DTDUserCard.getValue(key = "key for value") { value ->
  // your code
}

When using the getValue method, note that the Anyreturn type will need to be cast to the data type you want.

This is how you can set properties on the current user profile:

DTDUserCard.INSTANCE.set("key for string value", "string value");
DTDUserCard.INSTANCE.set("key for int value", 10);
DTDUserCard.INSTANCE.set("key for double value", 12.5);
DTDUserCard.INSTANCE.set("key for bool value", true);

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use the method:

getValue(key: String, handler: (Any?) -> Unit)

DTDUserCard.INSTANCE.getValue("key for value", value ->
       // your code
       null
);j

When using the getValue method, note that the Anyreturn type will need to be cast to the data type you want.

This is how you can set properties on the current user profile:

DTDUserCard.Set(key: "key for string value", value: "string value");
DTDUserCard.Set(key: "key for int value", value: 10);
DTDUserCard.Set(key: "key for double value", value: 12.5);
DTDUserCard.Set(key: "key for bool value", value: true);

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use the method:

var value = await DTDUserCard.Get(key: "key for value");
switch (value)
{
    case bool boolValue:
        break;
    case long longValue:
        break;
    case double doubleValue:
        break;
    case string stringValue:
        break;
}

When using the Get method, note that the object return type will need to be cast to the data type you want.

This is how you can set properties on the current user profile:

DTDUserCard.Set(key: "key for string value", value: "string value");
DTDUserCard.Set(key: "key for int value", value: 10);
DTDUserCard.Set(key: "key for double value", value: 12.5);
DTDUserCard.Set(key: "key for bool value", value: true);

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use the method:

DTDUserCard.GetValue("key", value =>
{
    switch (value)
    {
    case bool boolValue:
        break;
    case long longValue:
        break;
    case double doubleValue:
        break;
    case string stringValue:
        break;
    }             
})
DTDUserCard.Get(key: "key for value");

When using the Get method, note that the object return type will need to be cast to the data type you want.

This is how you can set properties on the current user profile:

window.devtodev.user.set("key for string value",  "string value")
window.devtodev.user.set("key for int value", 10)
window.devtodev.user.set("key for double value", 12.5)
window.devtodev.user.set("key for bool value", true)

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use the method:

window.devtodev.user.getValue("key for value") 

This is how you can set properties on the current user profile:

Arguments
Type
Description

key

FString

Parameter key.

value

bool

Parameter value.

UDTDUserCardBPLibrary::SetBool("BoolKey", true);

Arguments
Type
Description

key

FString

Parameter key.

value

float

Parameter value.

UUDTDUserCardBPLibrary::SetFloat("FloatKey", 3.333);

Arguments
Type
Description

key

FString

Parameter key.

value

int64

Parameter value.

UDTDUserCardBPLibrary::SetLong("LongKey", 1000);

Arguments
Type
Description

key

FString

Parameter key.

value

FString

Parameter value.

UDTDUserCardBPLibrary::SetString("StringKey", "StringValue");

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current value stored in the user profile on the SDK, you need to use methods:

Arguments
Type
Description

key

FString

Parameter key.

onResult

  • FUserCardDynamicGetterOptionalBoolDelegate

  • FDTDGetterOptionalBoolWithKeyDelegate

Callback.

FString key = FString(TEXT("Key"));
auto onResult = new FDTDGetterOptionalBoolWithKeyDelegate();
onResult->BindLambda([](bool success, const FString& key, bool value)
{
	// Your code...
});
UDTDUserCardBPLibrary::TryGetBool(key, *onResult);

Arguments
Type
Description

key

FString

Parameter key.

onResult

  • FUserCardDynamicGetterOptionalFloatDelegate

  • FDTDGetterOptionalFloatWithKeyDelegate

Callback.

FString key = FString(TEXT("Key"));
auto onResult = new FDTDGetterOptionalFloatWithKeyDelegate();
onResult->BindLambda([](bool success, const FString& key, float value)
{
	// Your code...
});
UDTDUserCardBPLibrary::TryGetFloat(key, *onResult);

Arguments
Type
Description

key

FString

Parameter key.

onResult

  • FUserCardDynamicGetterOptionalLongDelegate

  • FDTDGetterOptionalLongWithKeyDelegate

Callback.

FString key = FString(TEXT("Key"));
auto onResult = new FDTDGetterOptionalIntWithKeyDelegate();
onResult->BindLambda([](bool success, const FString& key, int64 value)
{
	// Your code...
});
UDTDUserCardBPLibrary::TryGetLong(key, *onResult);

Arguments
Type
Description

key

FString

Parameter key.

onResult

  • FUserCardDynamicGetterOptionalStringDelegate

  • FDTDGetterOptionalStringWithKeyDelegate

Callback.

FString key = FString(TEXT("Key"));
auto onResult = new FDTDGetterOptionalStringWithKeyDelegate();
onResult->BindLambda([](bool success, const FString& key, const FString& value)
{
	// Your code...
});
UDTDUserCardBPLibrary::TryGetString(key, *onResult);

This is how you can set properties on the current user profile:

DTDUserCard.SetString("key for string value", "string value")
DTDUserCard.SetInt("key for int value", 10)
DTDUserCard.SetFloat("key for double value", 12.5)
DTDUserCard.SetBool("key for bool value", true)

It is important to remember that the key for custom user properties has a length limit. If the limit is exceeded (from 1 to 64 characters), the key will be truncated to the maximum allowed length

To get the current values stored in the user profile on the SDK, you need to use the methods:

TryGetBool(key: String, callback: Callable)

TryGetFloat(key: String, callback: Callable)

TryGetInt(key: String, callback: Callable)

TryGetString(key: String, callback: Callable

DTDUserCard.TryGetInt("intKey", getIntHandler)
DTDUserCard.TryGetString("intKey", getStringHandler)
DTDUserCard.TryGetFloat("intKey", getFloatHandler)
DTDUserCard.TryGetBool("intKey", getBoolHandler)

func getIntHandler(isValid: bool, value: int):
	print("isValid = " + str(isValid) + " integer = " + str(value))

func getStringHandler(isValid: bool, value: String):
	print("isValid = " + str(isValid) + " string = " + value)
	
func getFloatHandler(isValid: bool, value: float):
	print("isValid = " + str(isValid) + " float = " + str(value))
	
func getBoolHandler(isValid: bool, value: bool):
	print("isValid = " + str(isValid) + " bool = " + str(value))

The isValid parameter is responsible for the presence of the requested key in the user card.

Unset user property

It removes a property or a list of properties and their values from the current user profile.

DTDUserCard.unset(property: "key for string value")
DTDUserCard.unset(properties: ["key for string value", 
                               "key for int value"])
[DTDUserCard unsetProperty:@"key for string value"];
[DTDUserCard unset:@[@"key for string value",
                     @"key for int value"]];
DTDUserCard.unset(property = "key for string value")
DTDUserCard.unset(property = listOf("key for string value", "key for int value"))
DTDUserCard.INSTANCE.unset( "key for string value");

ArrayList<String> properties = new ArrayList<>();
properties.add("key for string value");
properties.add("key for int value");
DTDUserCard.INSTANCE.unset(properties);
DTDUserCard.Unset(keys: "key 1");
DTDUserCard.Unset(keys: "key 1", "key 2", "key 3");
DTDUserCard.Unset(keys: "key 1");
DTDUserCard.Unset(keys: "key 1", "key 2", "key 3");
window.devtodev.user.unset("key for string value")
window.devtodev.user.unset(["key for string value", "key for int value"])

Arguments
Type
Description

key

FString

Parameter key.

UDTDUserCardBPLibrary::Unset("Key");

Arguments
Type
Description

keys

TArray<FString>

Parameter keys.

TArray<FString> keys;
keys.Add("Key1");
keys.Add("Key2");
UDTDUserCardBPLibrary::UnsetArray(keys);
DTDUserCard.Unset("intKey")

var arrayOfKeys = ["floatKey", "boolKey"]
DTDUserCard.UnsetArray(arrayOfKeys)

Unset all user properties

To remove all properties from the user card, use:

DTDUserCard.clearUser()
[DTDUserCard clearUser];
DTDUserCard.clearUser()
DTDUserCard.INSTANCE.clearUser();
DTDUserCard.ClearUser();
DTDUserCard.ClearUser();
window.devtodev.user.clearUser()

UDTDUserCardBPLibrary::ClearUser();
DTDUserCard.ClearUser()

We recommend that you use the setCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the DTDAnalyticsConfiguration).

Do not use the setCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the setCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the DTDAnalyticsConfiguration).

Do not use the setCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the setCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the DTDAnalyticsConfiguration).

Do not use the setCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the setCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the DTDAnalyticsConfiguration).

Do not use the setCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the SetCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the DTDAnalyticsConfiguration).

Do not use the SetCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the SetCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the DTDAnalyticsConfiguration).

Do not use the SetCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the setCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the DTDAnalyticsConfiguration).

Do not use the setCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the SetCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the EDTDAnalyticsConfiguration).

Do not use the SetCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We recommend that you use the SetCurrentLevel method immediately after using the method or specify the current user level in the initialization configuration (the level property of an instance of the GDDTDAnalyticsConfiguration).

Do not use the SetCurrentLevel method when the user reaches a new level. In this case, you must use the method.

We strongly recommend not to use these properties because they refer to .

Attention! We strongly recommend that you do not use these properties to transfer and store data that fits the definition of !

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

Keep in mind that the cheater mark is not cleared from the user card; you can only uncheck the mark manually using the method.

personal data
personal data
setUserID
setUserID
setUserID
setUserID
SetUserID
SetUserID
setUserID
SetUserID
SetUserID
setCheater
setCheater
setCheater
setCheater
SetCheater
SetCheater
setCheater
SetCheater
setCheater

If you need to exclude transactions from such users from statistics, go to Users & Segments section in devtodev interface and manually. When you mark the user in devtodev interface, the system removes their transactions for the last 7 days the reports and recalculates the metrics.

If you need to exclude transactions from such users from statistics, go to Users & Segments section in devtodev interface and manually. When you mark the user in devtodev interface, the system removes their transactions for the last 7 days the reports and recalculates the metrics.

levelUp
levelUp
levelUp
levelUp
LevelUp
LevelUp
levelUp
LevelUp
LevelUp
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
Blueprint
mark the user
mark the user