Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Native
Skip to main content

Interface IIdentifiers

interface IIdentifiers
Extends com.amazon.apmf.IStandard The IIdentifiers interface provides utilities for managing various identifiers and device-related metadata in the context of an application and user persona. It includes functionality for generating, retrieving, and managing unique identifiers such as UUIDs, User Agent strings, and friendly device names.

Methods

generateUuidV4()

com.amazon.apmf.Uuid generateUuidV4()
Generates a new UUID (version 4). For custom identifiers.

Returns

com.amazon.apmf.Uuid A new UUID.

getVendorTrackingId()

com.amazon.apmf.Uuid getVendorTrackingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Gets the tracking identifier UUID for the vendor signing the callers application. The tracking identifier is resettable by the user and allows for tracking across all applications from a single vendor. This identifier is available only with user opt-in. Users are opted-in by default. However, they can chose to opt-out.

Returns

com.amazon.apmf.Uuid A tracking identifier UUID if the user has opted in, or a null UUID (0000-0000-0000-0000) if the user has opted out.

Throws


enableVendorTrackingId()

void enableVendorTrackingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Enables the vendor tracking identifier for the current user if it was previously opted out. This method has no effect if tracking is already enabled. This method requires the privilege: com.amazon.kepler.identifiers.privilege.tracking-id.modify.

Throws


disableVendorTrackingId()

void disableVendorTrackingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Disables the vendor tracking identifier for the current user. This method has no effect if tracking is already disabled. This method requires the privilege: com.amazon.kepler.identifiers.privilege.tracking-id.modify.

Throws


getAdvertisingId()

com.amazon.apmf.Uuid getAdvertisingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Gets the advertising identifier for the current persona. The advertising identifier is used for cross-app tracking and is resettable by the user. This identifier is available only with user opt-in.

Returns

com.amazon.apmf.Uuid A UUID representing the advertising ID if the user has opted in, or a null UUID (0000-0000-0000-0000) if the user has opted out.

Throws


enableAdvertisingId()

void enableAdvertisingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Enables advertising identifier support for a specified user while opting-in. If not previously set, this method generates a new UUID for the advertising identifier. This method requires the privilege: com.amazon.kepler.identifiers.privilege.advertising-id.modify.

Throws


disableAdvertisingId()

void disableAdvertisingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Disables advertising identifier support for a specified user. This method has no effect if the advertising ID is already disabled. This method requires the privilege: com.amazon.kepler.identifiers.privilege.advertising-id.modify.

Throws


getUserAgent()

string getUserAgent()
Gets the User Agent string that is used to identify devices. The User Agent string is profile dependent and contains information such as device model and OS version. Example: “Amazon-TV/1.0 (<system-information>) <platform> (<platform-details>) <extensions>”. The semantics of User Agent string could vary based on multiple factors. Note: It is recommended to use the string value as it is and not rely on it for any kind of parsing.

Returns

string A string representing the User Agent of the current device.

Throws


getFriendlyDeviceName()

string getFriendlyDeviceName()
Gets the friendly name of the device for the current persona. This name is shared across applications and can be modified by the user. Returns one of:
  • The user-customized device name if it exists and the caller has the “com.amazon.devconf.privilege.identifiers.device-friendly-name” run-time privilege
  • The device model name if either:
    • No user-customized name has been set
    • The caller lacks the required privilege

Returns

string The friendly name of this device - either the user-customized name (if set and privileged) or the device model name.

Throws


setFriendlyDeviceName()

void setFriendlyDeviceName(string name)
Sets a new friendly name for the device, applicable to the current persona.

Parameters

name
string — Required The new friendly name for the device. Must be 2 to 60 bytes in UTF-8 encoding. This method requires the privilege: com.amazon.devconf.privilege.identifiers.device-friendly-name.write.

Throws


resetVendorTrackingId()

void resetVendorTrackingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Resets the vendor tracking identifier to a new UUID. This method requires the privilege: com.amazon.kepler.identifiers.privilege.tracking-id.modify.

Throws


resetAdvertisingId()

void resetAdvertisingId()
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Resets the advertising identifier to a new UUID. This method requires the privilege: com.amazon.kepler.identifiers.privilege.advertising-id.modify

Throws


addVendorTrackingIdListener()

com.amazon.apmf.ISubscription* addVendorTrackingIdListener(IVendorTrackingIdListener* listener)
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Adds a listener for changes to the vendor tracking identifier.

Parameters

listener
IVendorTrackingIdListener* — Required The listener to be notified when the vendor tracking identifier changes.

Returns

com.amazon.apmf.ISubscription* ISubscription object that can be used to unsubscribe from the event.

Throws


addAdvertisingIdListener()

com.amazon.apmf.ISubscription* addAdvertisingIdListener(IAdvertisingIdListener* listener)
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Adds a listener for changes to the advertising identifier.

Parameters

listener
IAdvertisingIdListener* — Required The listener to be notified when the advertising identifier changes.

Returns

com.amazon.apmf.ISubscription* ISubscription object that can be used to unsubscribe from the event.

Throws


addFriendlyDeviceNameListener()

com.amazon.apmf.ISubscription* addFriendlyDeviceNameListener(IFriendlyDeviceNameListener* listener)
Note: Currently not supported, throws exception apmf::iface::com::amazon::apmf::NotSupportedError. Adds a listener for changes to the friendly device name.

Parameters

listener
IFriendlyDeviceNameListener* — Required The listener to be notified when the friendly device name changes.

Returns

com.amazon.apmf.ISubscription* ISubscription object that can be used to unsubscribe from the event.

Throws


Last modified on October 29, 2026