An alias is a unique, user-specific identifier, set by the application owner (for example, the user's email or an internal system ID number).
Aliases have the following uses:
- The app owner and Appoxee both use the same alias to identify the user.
- All devices owned by a specific user (an iPhone, an iPad etc.) are identified by the same alias.
- Aliases are used to create segments of application users, based on user-specific properties (as opposed to application-specific properties).
Note the difference between aliases and tags:
- Aliases are user-specific, and each user can only have one alias (shared by all the user's devices).
- Tags are app-specific, and you can assign multiple tags to the same device.
The alias API enables you to perform actions on a device's alias.
All the methods are callable through "Appoxee.methodName", since they are all public static methods.
Alias API Methods
setDeviceAlias
Sets the device alias, replacing the current alias value.
Syntax
public static boolean setDeviceAlias(String alias) |
Parameters
String alias– the new string alias to be set. This alias overrides the existing alias.
Returns
true if the specified alias was set successfully; false otherwise.
removeDeviceAlias
Removes the device alias.
Syntax
public static boolean removeDeviceAlias() |
Returns
true if the device alias was removed successfully; false otherwise.
getDeviceAlias
Returns the device alias.
Syntax
public static String getDeviceAlias() |
Returns
A string containing the device alias.
cleanAliasCache
Removes the alias from the device's local cache.
Syntax
public static boolean cleanAliasCache() |
Returns
true if the device alias was successfully removed from the local device cache; false otherwise.