Unity User Profiles

User Profiles

Update User Profile(Push Profile)

Dictionary<string, string> Props = new Dictionary<string, string>();
Props.Add("Identity", "11102008");
Props.Add("Name", "Test Profile");
Props.Add("Email", "[email protected]");
Props.Add("Gender", "Male");

CleverTapBinding.ProfilePush(props);

Set Multi Values For Key

List<string> StringList = new List<string>();
StringList.Add("one");
StringList.Add("two");

CleverTapBinding.ProfileSetMultiValuesForKey("userProps", stringList);

Remove Multi Value For Key

List<string> StringList2 = new List<string>();
StringList2.Add("two");

CleverTapBinding.ProfileRemoveMultiValuesForKey("userProps", stringList2);

Add Multi Value For Key

List<string> StringList1 = new List<string>();
StringList1.Add("three");
StringList1.Add("four");

CleverTapBinding.ProfileAddMultiValuesForKey("multiIOS", stringList1);

Create a User profile when the user logs in (On User Login)

Dictionary<string, string> NewProps = new Dictionary<string, string>();
NewProps.Add("Email", "[email protected]");
NewProps.Add("Identity", "123456");
NewProps.Add("Name", "Test Profile");

CleverTapBinding.OnUserLogin(NewProps);

Get CleverTap Reference id

string CleverTapID = CleverTapBinding.ProfileGetCleverTapID();

Set Location to User Profile

CleverTapBinding.SetLocation(34.147785, -118.144516);

Increment a User Profile property

CleverTapBinding.ProfileIncrementValueForKey("add_int",2);
CleverTapBinding.ProfileIncrementValueForKey("add_double",3.5);

Decrement a User Profile property

CleverTapBinding.ProfileDecrementValueForKey("minus_int",2);
CleverTapBinding.ProfileDecrementValueForKey("minus_double",3.5);

Did this page help you?