adjust-icon

Get device information

The Adjust SDK contains helper methods that return device information. Use these methods to add details to your callbacks and improve your reporting.

Adjust device identifier

Method signature
getAdid: (callback: (adid: string) => void) => void

Adjust generates a unique Adjust Device ID (ADID) for each device. Call the getAdid method to return this ID as a string.

Adjust.getAdid((adid) => {
console.log("ADID = " + adid);
});

ID For Advertisers

Method signature
getIdfa: (callback: (idfa: string) => void) => void

The ID for Advertisers (IDFA) is a device-specific identifier for Apple devices. Call the getIdfa method to return this ID as a string.

Adjust.getIdfa((idfa) => {
console.log("IDFA = " + idfa);
});

Google Play Services Advertising ID

Method signature
getGoogleAdId: (callback: (adid: string) => void) => void

The Google Play Services Advertising ID (GPS ADID) is a device-specific identifier for Android devices.

Users can opt out of sharing their GPS ADID by toggling the “Opt out of Ads Personalization” setting on their device. When a user enables this setting, the Adjust SDK returns a string of zeros when trying to read the GPS ADID.

You can access this value by calling the getGoogleAdId method in a background thread. Assign a delegate function to access the GPS ADID value.

Adjust.getGoogleAdId((googleAdId) => {
console.log("Google Ad ID = " + googleAdId);
});

Amazon Advertiser ID

Method signature
getAmazonAdId: (callback: (adid: string) => void) => void

The Amazon Advertising ID (Amazon Ad ID) is a device-specific identifier for Android devices. Call the getAmazonAdId method to return this ID as a string.

Adjust.getAmazonAdId((amazonAdId) => {
console.log("Amazon Ad ID = " + amazonAdId);
});