as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support

AdIdRetriever

AdIdRetriever provides APIs for retrieving advertising IDs and advertising tracking state.

Constructors

new AdIdRetriever()

new AdIdRetriever(): AdIdRetriever

Returns

AdIdRetriever

Methods

fetchAdvertisingId()

static fetchAdvertisingId(): string

Get the advertising ID.

Return the advertising ID regardless of the advertising tracking state. Advertising ID is effective in bidding for "interest-based advertisements" only when advertising tracking is enabled. See more details on when to use advertising ID: https://developer.amazon.com/docs/policy-center/advertising-id.html#when-to-use-the-advertising-id

Returns

string


getMajorVersion()

static getMajorVersion(): number

Get the Major version of the underlying native module. This can be used to make version checks.

Returns

number


getMinorVersion()

static getMinorVersion(): number

Get the Minor version of the underlying native module. This can be used to make version checks.

Returns

number


getPatchVersion()

static getPatchVersion(): number

Get the patch version of the underlying native module. This can be used to make version checks.

Returns

number


isAdvertisingTrackingEnabled()

static isAdvertisingTrackingEnabled(): boolean

Get the advertising tracking state.

Return true if the user enables advertising tracking. When enabled, the user will see "interest-based advertisements". When disabled, the user will see "contextual advertisements" (which means the user selected to "opt-out" of interest-based advertisements). See how "opt-out" controls interest-based advertisements: https://developer.amazon.com/docs/policy-center/advertising-id.html#when-to-use-the-advertising-id

Returns

boolean


Last updated: Sep 30, 2025