Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cordova-plugin-appsflyer-sdk

Package Overview
Dependencies
Maintainers
8
Versions
124
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cordova-plugin-appsflyer-sdk - npm Package Compare versions

Comparing version 6.12.10 to 6.13.0-rc1

Cordova SDK v6.13.0-releasenotes.txt

155

docs/API.md

@@ -13,42 +13,45 @@ # API

| method name| params| description|
| ----------- |-----------------------------|--------------|
| [`initSdk`](#initSdk) | `(Object args, function success, function error)` | Initialize the SDK|
| [`logEvent`](#trackEvent) | `(String eventName, Object eventValue, function success, function error)` | Track rich in-app events |
| [`registerOnAppOpenAttribution`](#registerOnAppOpenAttribution) | `(function success, function error)` | Get the deeplink data |
| [`registerDeepLink`](#registerDeepLink) | `(function callBack)` | Get unified deep link data |
| [`setCurrencyCode`](#setCurrencyCode) | `(String currencyId)` | Set currency code |
| [`setAppUserId`](#setAppUserId) | `(String customerUserId)` | Set custom_user_id |
| [`setGCMProjectNumber`](#initSdk) | `(String gcmProjectNumber)` | |
| [`getAppsFlyerUID`](#getAppsFlyerUID) | `(function success)` | Get AppsFlyer’s proprietary Device ID |
| [`anonymizeUser`](#deviceTrackingDisabled) | `(Boolean isDisabled)` | Anonymize user data |
| [`Stop`](#stopTracking)| `(Boolean isStopTracking)` | Shut down all SDK tracking |
| [`updateServerUninstallToken`](#updateServerUninstallToken) | `(String token)` | (Android) Pass GCM/FCM Tokens |
| [`registerUninstall`](#registerUninstall) | `(String token)` | (iOS) Pass APNs Tokens |
| [`setAppInviteOneLinkID`](#setAppInviteOneLinkID) | `(Object args)` | Set AppsFlyer’s OneLink ID |
| [`generateInviteLink`](#generateInviteLink) | `(Object args, function success, function error)` | Error callback |
| [`logCrossPromotionImpression`](#trackCrossPromotionImpression) | `(String appId, String campaign)` | Track cross promotion impression |
| [`logCrossPromotionAndOpenStore`](#trackAndOpenStore) | `(String appId, String campaign, Object params)` | Launch the app store's app page (via Browser) |
| [`handleOpenUrl`](#deep-linking-tracking) | `(String url)` | |
| [`getSdkVersion`](#getSdkVersion) | `((function success)` | Get the current SDK version |
| [`setSharingFilterForAllPartners`](#setSharingFilterForAllPartners) | | Used by advertisers to exclude all networks/integrated partners from getting data |
| [`setSharingFilter`](#setSharingFilter) | `(partners)` | Used by advertisers to exclude specified networks/integrated partners from getting data |
| [`setSharingFilterForPartners`](#setSharingFilterForPartners) | `(partners)` | Used by advertisers to exclude specified networks/integrated partners from getting data |
| [`validateAndLogInAppPurchase`](#validateAndLogInAppPurchase) | `(Object purchaseInfo, function success, function error)` | API for server verification of in-app purchases |
| [`setUseReceiptValidationSandbox`](#setUseReceiptValidationSandbox) | `(boolean isSandbox, function success, function error)` | In app purchase receipt validation Apple environment |
| [`disableCollectASA`](#disableCollectASA) | `(boolean collectASA, function success)` | **iOS** - set the SDK to load OR not to load iAd.framework dynamically|
| [`setDisableAdvertisingIdentifier`](#setDisableAdvertisingIdentifier) | `(boolean disableAdvertisingIdentifier, function success)` | Disable collection of Apple, Google, Amazon and Open advertising ids (IDFA, GAID, AAID, OAID). |
| [`setOneLinkCustomDomains`](#setOneLinkCustomDomains) | `(domains, function success, function error)` | Set Onelink custom/branded domains |
| [`enableFacebookDeferredApplinks`](#enableFacebookDeferredApplinks) | `(boolean isEnabled)` | support deferred deep linking from Facebook Ads |
| [`setUserEmails`](#setUserEmails) | `(emails, function success)` | Set user emails for FB Advanced Matching |
| [`setPhoneNumber`](#setPhoneNumber) | `(String phoneNumber, function success)` | Set phone number for FB Advanced Matching |
| [`setHost`](#setHost) | `(String hostPrefix, String hostName)` | Set custom host prefix and host name |
| [`addPushNotificationDeepLinkPath`](#addPushNotificationDeepLinkPath) | `(path)` | configure push notification deep link resolution |
| [`setResolveDeepLinkURLs`](#setResolveDeepLinkURLs) | `(urls)` | get the OneLink from click domains |
| [`disableSKAD`](#disableSKAD) | `(boolean disableSkad)` | disable or enable SKAD |
| [`setCurrentDeviceLanguage`](#setCurrentDeviceLanguage) | `(string language)` | Set the language of the device. |
| [`setAdditionalData`](#setAdditionalData) | `(Object additionalData)` | Allows you to add custom data to events sent from the SDK. |
| [`setPartnerData`](#setPartnerData) | `(partnerId, data)` | Allows sending custom data for partner integration purposes. |
| [`sendPushNotificationData`](#sendPushNotificationData) | `(Object data)` | Measure and get data from push-notification campaigns.|
| [`setDisableNetworkData`](#setDisableNetworkData) | `(boolean disable)` | Use to opt-out of collecting the network operator name (carrier) and sim operator name from the device.|
| method name | params | description |
|-----------------------------------------------------------------------|---------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------|
| [`initSdk`](#initSdk) | `(Object args, function success, function error)` | Initialize the SDK |
| [`startSdk`](#startSdk) | `()` | Starts the SDK - Must call initSdk first in order to make this work |
| [`logEvent`](#trackEvent) | `(String eventName, Object eventValue, function success, function error)` | Track rich in-app events |
| [`registerOnAppOpenAttribution`](#registerOnAppOpenAttribution) | `(function success, function error)` | Get the deeplink data |
| [`registerDeepLink`](#registerDeepLink) | `(function callBack)` | Get unified deep link data |
| [`setCurrencyCode`](#setCurrencyCode) | `(String currencyId)` | Set currency code |
| [`setAppUserId`](#setAppUserId) | `(String customerUserId)` | Set custom_user_id |
| [`setGCMProjectNumber`](#initSdk) | `(String gcmProjectNumber)` | |
| [`getAppsFlyerUID`](#getAppsFlyerUID) | `(function success)` | Get AppsFlyer’s proprietary Device ID |
| [`anonymizeUser`](#deviceTrackingDisabled) | `(Boolean isDisabled)` | Anonymize user data |
| [`Stop`](#stopTracking) | `(Boolean isStopTracking)` | Shut down all SDK tracking |
| [`updateServerUninstallToken`](#updateServerUninstallToken) | `(String token)` | (Android) Pass GCM/FCM Tokens |
| [`registerUninstall`](#registerUninstall) | `(String token)` | (iOS) Pass APNs Tokens |
| [`setAppInviteOneLinkID`](#setAppInviteOneLinkID) | `(Object args)` | Set AppsFlyer’s OneLink ID |
| [`generateInviteLink`](#generateInviteLink) | `(Object args, function success, function error)` | Error callback |
| [`logCrossPromotionImpression`](#trackCrossPromotionImpression) | `(String appId, String campaign)` | Track cross promotion impression |
| [`logCrossPromotionAndOpenStore`](#trackAndOpenStore) | `(String appId, String campaign, Object params)` | Launch the app store's app page (via Browser) |
| [`handleOpenUrl`](#deep-linking-tracking) | `(String url)` | |
| [`getSdkVersion`](#getSdkVersion) | `((function success)` | Get the current SDK version |
| [`setSharingFilterForAllPartners`](#setSharingFilterForAllPartners) | | Used by advertisers to exclude all networks/integrated partners from getting data |
| [`setSharingFilter`](#setSharingFilter) | `(partners)` | Used by advertisers to exclude specified networks/integrated partners from getting data |
| [`setSharingFilterForPartners`](#setSharingFilterForPartners) | `(partners)` | Used by advertisers to exclude specified networks/integrated partners from getting data |
| [`validateAndLogInAppPurchase`](#validateAndLogInAppPurchase) | `(Object purchaseInfo, function success, function error)` | API for server verification of in-app purchases |
| [`setUseReceiptValidationSandbox`](#setUseReceiptValidationSandbox) | `(boolean isSandbox, function success, function error)` | In app purchase receipt validation Apple environment |
| [`disableCollectASA`](#disableCollectASA) | `(boolean collectASA, function success)` | **iOS** - set the SDK to load OR not to load iAd.framework dynamically |
| [`setDisableAdvertisingIdentifier`](#setDisableAdvertisingIdentifier) | `(boolean disableAdvertisingIdentifier, function success)` | Disable collection of Apple, Google, Amazon and Open advertising ids (IDFA, GAID, AAID, OAID). |
| [`setOneLinkCustomDomains`](#setOneLinkCustomDomains) | `(domains, function success, function error)` | Set Onelink custom/branded domains |
| [`enableFacebookDeferredApplinks`](#enableFacebookDeferredApplinks) | `(boolean isEnabled)` | support deferred deep linking from Facebook Ads |
| [`setUserEmails`](#setUserEmails) | `(emails, function success)` | Set user emails for FB Advanced Matching |
| [`setPhoneNumber`](#setPhoneNumber) | `(String phoneNumber, function success)` | Set phone number for FB Advanced Matching |
| [`setHost`](#setHost) | `(String hostPrefix, String hostName)` | Set custom host prefix and host name |
| [`addPushNotificationDeepLinkPath`](#addPushNotificationDeepLinkPath) | `(path)` | configure push notification deep link resolution |
| [`setResolveDeepLinkURLs`](#setResolveDeepLinkURLs) | `(urls)` | get the OneLink from click domains |
| [`disableSKAD`](#disableSKAD) | `(boolean disableSkad)` | disable or enable SKAD |
| [`setCurrentDeviceLanguage`](#setCurrentDeviceLanguage) | `(string language)` | Set the language of the device. |
| [`setAdditionalData`](#setAdditionalData) | `(Object additionalData)` | Allows you to add custom data to events sent from the SDK. |
| [`setPartnerData`](#setPartnerData) | `(partnerId, data)` | Allows sending custom data for partner integration purposes. |
| [`sendPushNotificationData`](#sendPushNotificationData) | `(Object data)` | Measure and get data from push-notification campaigns. |
| [`setDisableNetworkData`](#setDisableNetworkData) | `(boolean disable)` | Use to opt-out of collecting the network operator name (carrier) and sim operator name from the device. |
| [`setConsentData`](#setConsentData) | `(boolean disable)` | Use to manually collecting the consent data from the user. |
| [`enableTCFDataCollection`](#enableTCFDataCollection) | `(boolean enable)` | instruct the SDK to collect the TCF data from the device. |

@@ -70,11 +73,13 @@

| name | type | default | description |
| -----------|---------|---------|------------------------|
| `devKey` |`string` | | [Appsflyer Dev key](https://support.appsflyer.com/hc/en-us/articles/207032126-AppsFlyer-SDK-Integration-Android) |
| `appId` |`string` | | [Apple Application ID](https://support.appsflyer.com/hc/en-us/articles/207032066-AppsFlyer-SDK-Integration-iOS) (for iOS only) |
| `isDebug` |`boolean`| `false` | debug mode (optional)|
| `useUninstallSandbox` |`boolean`| `false` | For iOS only, to test uninstall in Sandbox environment (optional)|
| `collectIMEI` | `boolean` | `false` |opt-out of collection of IMEI |
| `collectAndroidID` | `boolean` | `false` |opt-out of collection of collectAndroidID |
| `onInstallConversionDataListener` |`boolean`| `false` | Accessing AppsFlyer Attribution / Conversion Data from the SDK (Deferred Deeplinking). Read more: [Android](http://support.appsflyer.com/entries/69796693-Accessing-AppsFlyer-Attribution-Conversion-Data-from-the-SDK-Deferred-Deep-linking-), [iOS](http://support.appsflyer.com/entries/22904293-Testing-AppsFlyer-iOS-SDK-Integration-Before-Submitting-to-the-App-Store-). AppsFlyer plugin will return attribution data in `onSuccess` callback.
| name | type | default | description |
|-----------------------------------|---------|---------|------------------------|
| `devKey` |`string` | | [Appsflyer Dev key](https://support.appsflyer.com/hc/en-us/articles/207032126-AppsFlyer-SDK-Integration-Android) |
| `appId` |`string` | | [Apple Application ID](https://support.appsflyer.com/hc/en-us/articles/207032066-AppsFlyer-SDK-Integration-iOS) (for iOS only) |
| `isDebug` |`boolean`| `false` | debug mode (optional)|
| `useUninstallSandbox` |`boolean`| `false` | For iOS only, to test uninstall in Sandbox environment (optional)|
| `collectIMEI` | `boolean` | `false` |opt-out of collection of IMEI |
| `collectAndroidID` | `boolean` | `false` |opt-out of collection of collectAndroidID |
| `onInstallConversionDataListener` |`boolean`| `false` | Accessing AppsFlyer Attribution / Conversion Data from the SDK (Deferred Deeplinking). Read more: [Android](http://support.appsflyer.com/entries/69796693-Accessing-AppsFlyer-Attribution-Conversion-Data-from-the-SDK-Deferred-Deep-linking-), [iOS](http://support.appsflyer.com/entries/22904293-Testing-AppsFlyer-iOS-SDK-Integration-Before-Submitting-to-the-App-Store-). AppsFlyer plugin will return attribution data in `onSuccess` callback. |
| `shouldStartSdk` |`boolean`| `true` | Prevents from the SDK from sending the launch request after using appsFlyer.initSdk(...). When using this property, the apps needs to manually trigger the appsFlyer.startSdk() API to report the app launch. read more here. (Optional, default=true)|
.

@@ -104,2 +109,13 @@ *Example:*

##### <a id="startSdk"> **`startSdk(): void`**
Starts the SDK
*Example:*
```javascript
window.plugins.appsFlyer.initSdk(options, onSuccess, onError);
window.plugins.appsFlyer.startSdk();
```
---
##### <a id="trackEvent"> **`logEvent(eventName, eventValues, onSuccess, onError): void`** (optional)

@@ -748,2 +764,43 @@

---
##### <a id="setConsentData"> **`setConsentData(appsFlyerConsent): void`**
When GDPR applies to the user and your app does not use a CMP compatible with TCF v2.2, use this API to provide the consent data directly to the SDK.
The AppsFlyerConsent object has 2 methods:
AppsFlyerConsent.forNonGDPRUser: Indicates that GDPR doesn’t apply to the user and generates nonGDPR consent object. This method doesn’t accept any parameters.
AppsFlyerConsent.forGDPRUser: create an AppsFlyerConsent object with 2 parameters:
| parameter | type | description |
| ----------- |-----------------------------|--------------|
| `hasConsentForDataUsage` | `boolean` | Indicates whether the user has consented to use their data for advertising purposes |
| `hasConsentForAdsPersonalization` | `boolean` | Indicates whether the user has consented to use their data for personalized advertising |
*Example:*
```javascript
window.plugins.appsFlyer.setConsentData(AppsFlyerConsent.forGDPRUser(true, true));
// OR
window.plugins.appsFlyer.setConsentData(AppsFlyerConsent.forNonGDPRUser());
```
---
##### <a id="enableTCFDataCollection"> **`enableTCFDataCollection(enable): void`**
instruct the SDK to collect the TCF data from the device.
| parameter | type | description |
| ---------- |-----------------------------|----------------------------------------------------------------------------------------|
| `enable` | `boolean` | enable/disable TCF data collection |
*Example:*
```javascript
window.plugins.appsFlyer.enableTCFDataCollection(true);
```
---
### <a id="deep-linking-tracking"> Deep linking Tracking

@@ -750,0 +807,0 @@

{
"name": "cordova-plugin-appsflyer-sdk",
"version": "6.12.10",
"version": "6.13.0-rc1",
"description": "Cordova AppsFlyer SDK Plugin",

@@ -5,0 +5,0 @@ "cordova": {

@@ -45,4 +45,4 @@

- iOS AppsFlyerSDK **v6.12.0**
- Android AppsFlyerSDK **v6.12.1**
- iOS AppsFlyerSDK **v6.12.1**
- Android AppsFlyerSDK **v6.12.2**

@@ -49,0 +49,0 @@ ### <a id="breakingChanges"> ❗v6 Breaking Changes

@@ -0,1 +1,12 @@

## 6.13.0
Release date: *2024-02-25*
- Cordova >> Update Plugin to v6.13.0 (DMA)
- Cordova > Android > registerDeepLink API works only once on MFE architecture due to null check
## 6.12.2
Release date: *2023-08-23*
- Cordova plugin >> Update Plugin to v6.12.2
## 6.12.10

@@ -2,0 +13,0 @@ Release date: *2023-07-17*

@@ -18,2 +18,24 @@ var exec = require('cordova/exec'),

// Expose AppsFlyerConsent to the global scope
global.AppsFlyerConsent = (function () {
// Private constructor
function AppsFlyerConsent(isUserSubjectToGDPR, hasConsentForDataUsage, hasConsentForAdsPersonalization) {
this.isUserSubjectToGDPR = isUserSubjectToGDPR;
this.hasConsentForDataUsage = hasConsentForDataUsage;
this.hasConsentForAdsPersonalization = hasConsentForAdsPersonalization;
}
return {
// Factory method for GDPR user
forGDPRUser: function(hasConsentForDataUsage, hasConsentForAdsPersonalization) {
return new AppsFlyerConsent(true, hasConsentForDataUsage, hasConsentForAdsPersonalization);
},
// Factory method for non GDPR user
forNonGDPRUser: function() {
return new AppsFlyerConsent(false, null, null);
}
};
})();
/**

@@ -54,2 +76,10 @@ * initialize the SDK.

/**
* starts the SDK.
*
*/
AppsFlyer.prototype.startSdk = function () {
exec(null, null, 'AppsFlyerPlugin', 'startSdk', []);
};
/**
* onAppOpenAttributionSuccess: Success callback - called after receiving data on App Open Attribution.

@@ -399,4 +429,21 @@ * onAppOpenAttributionError: Error callback - called when error occurs.

/**
* Use to manually collecting the consent data from the user.
* @param appsFlyerConsent - object of AppsFlyerConsent that holds three values when GDPR is applies to the user, and one value when It's not.
* when GDPR applies to the user and your app does not use a CMP compatible with TCF v2.2, use this API to provide the consent data directly to the SDK.<br>
*/
AppsFlyer.prototype.setConsentData = function (appsFlyerConsent){
exec(null, null, 'AppsFlyerPlugin', 'setConsentData', [appsFlyerConsent]);
};
/**
* set collect tcf data or not.
*
* @param enable - boolean value that represent if enables to collect or not.
*/
AppsFlyer.prototype.enableTCFDataCollection = function (enable) {
exec(null, null, 'AppsFlyerPlugin', 'enableTCFDataCollection', [enable]);
};
module.exports = new AppsFlyer();
})(window);
})(window);

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc