Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

cordova-plugin-adid-idfv

ionic-lab271.0.7

Cordova Advertising ID (IDFA) Plugin for Android using Google Play Services API

cordova, idfa, google, google play, advertising id, idfa for android, cordova plugin, advertiserId, advertisingId for android, advertising id for android, advertising id for android using google play, advertising id for android using google play services, android, download, install, ecosystem:cordova, cordova-android

readme

cordova-plugin-android-idfa

Phonegap, Cordova, Intel XDK plugin to get Advertising Id Info

Advertising ID (IDFA) Plugin for Android using Google Play Services

This plugin depends on com.google.play.services. Cordova (PhoneGap) 3.0+ Plugin to get Adertising ID (IDFA) on Adnroid device using Google Play Sercies API. Obtains advertising id (IDFA) info.

This Plugin is clone of cordova-plugin-android-idfa(https://github.com/praves77/cordova-plugin-android-idfa/) plugin with removed some build issue.

Prerequisites:

  • A Cordova 3.0+ project for Android
  • Google Play Services API

Platform SDK supported

  • Android, using Google Play Services for Android
  • iOS

Quick start

To install this plugin, follow the Command-line Interface Guide. You can use one of the following command lines:

  • cordova plugin add cordova-plugin-adid-idfv
  • cordova plugin add https://github.com/ionic-lab/cordova-plugin-adid-idfv.git

Make sure to review the Google Play Developer Program policy and terms


Javascript API

Note: All success callbacks are in the form 'function () {}', and all failure callbacks are in the form 'function (err) {}' where err is a String explaining the error reason.

Advertising id info

getAdInfo(success, error);

Gets the advertising id (IDFA) info (id and limit ad tracking flag).

  • {function()} success: success callback with {idfa: <advertising id (IDFA)>, limitAd: <boolean>} as object argument.
  • {function()} failure: failure callback.

Advertising id

getAdId(success, error);

Gets the advertising id (IDFA).

  • {function()} success: success callback with {idfa: <advertising id (IDFA)>} as object argument.
  • {function()} failure: failure callback.

Limit Ad Flag

getLimitAdFlag(success, error);

Gets the limit ad tracking flag.

  • {function()} success: success callback with { limitAd: <boolean> } as object argument.
  • {function()} failure: failure callback.