Appoxee SDK - Unity Bridge API
General Warning
Compile time error will happen if you will not implement IAppoxeeCallable in your Main Camera Unity Script.
Android Users - Be aware of the following :
If appoxee-unity-plugin.jar is missing, the AppoxeePlugin will fail at init, raising a null pointer exception, thus all API calls will fail.
Alias
Set device alias.
public void SetDeviceAlias(String alias);
Set device's alias - a unique identifier tor this device
Set Alias - Example
appoxeePlugin.SetDeviceAlias("MyAlias");
...
//Matching Callback Method from IAppoxeeCallable, message is true/false (is operation successful)
void OnSetAlias (String message) {
//Your code...
}
Get device alias.
public void GetDeviceAlias();
Get device's alias.
Get Alias - Example
appoxeePlugin.GetDeviceAlias();
...
//Matching Callback Method from IAppoxeeCallable, message is the Alias
void OnGetAlias (String message) {
//Your code after getting the alias
}
Remove Alias
public void RemoveDeviceAlias();
Remove device's alias.
Remove Alias - Example
appoxeePlugin.RemoveDeviceAlias();
...
//Matching Callback Method from IAppoxeeCallable, message is true/false (is operation successful)
void OnRemoveAlias(String message) {
//Your code after removing the alias
}
Device API
Device Information
public String GetApplicationID();
Get Application ID, result as String
Get Application ID - Example
public String GetDeviceOsNumber();
Get Operating System Version Number, result as String
Get OS Number - Example
public String GetHardwareType();
Get Hardware (Device) Type, result as String
Get Hardware Type
public String GetDeviceCountry();
Get Device Country, result as String
Get Device Country - Example
public String GetDeviceOsName();
Get Device Platform, result as String
Get Device Platform - Example
public bool IsPushEnabled();
Is Device Push Enabled, result as Boolean (true / false)
Is Device Push Enabled - Example
Tags API
Tags are not available for DMC customers yet (coming soon)
Remove Tags
public void RemoveTagsFromDevice(String tags);
Remove Device Tags
Remove Device Tags - Example
Set Tags
public void AddTagsToDevice(String tags);
Set Tags to Device
Set Device Tags - Example
Get Device Tags
public void GetDeviceTags();
Get Device's Tags
Get Device Tags - Example
Application Tags
public void GetTagList();
Get Application's Tags, from which Device Tags can be taken from.
Get Application Tags - Example
Push API
Enable/Disable Push
public void SetPushEnabled(boolean flag);
Soft Opt In / Out for Push .
flag - set true to enable , false to disable
Push Opt Out - Example
Custom Fields API
Set Custom Date Field
public void SetDateField(String fieldName,DateTime fieldValue);
fieldName - name of custom field to set.
fieldValue - value of custom date field to set
Set Custom Field - Example
Set Custom Numeric Field
public void SetNumericField(String fieldName,Decimal fieldValue);
fieldName - name of custom field to set.
fieldValue - value of custom field to set.
Set Custom Field - Example
Set String Field
public void SetStringField(String fieldName,String fieldValue);
fieldName - name of custom field to set.
fieldValue - value of custom field to set.
Set Custom Field - Example
Get Custom Field
Gets Custom Field.
public void GetCustomFieldAsString(String fieldName);
fieldName - name of custom field to get.
Get Custom Field - Example
Notifications
Last Push Payload Received
public String GetLastPush();
Gets last push payload from last incoming push notification. Deletes it after returning.
Last Push Payload Received - Example
Set Application Badge Number (iOS only)
public void setApplicationBadgeNumber(int bdageNumber);
Set the application badge number, where 0 will remove the badge, and any other number will display it, or update a displayed badge.