类型 库 版本 版本 2024.3703 关键词 分析, 归因, AppsFlyer 平台 Android, iOS
AppsFlyer 是世界领先的移动归因和营销分析平台,帮助全球的应用营销人员做出更好的决策。
查看 init 参数 hasUserConsent
以及 setHasUserConsent
方法以启用 GDPR 数据收集限制。
在使用此插件之前,您需要先在 注册 AppsFlyer 以获取应用 ID 和开发者密钥。
local appsflyer = require( "plugin.appsflyer" )
要使用此插件,请在 build.settings
的 plugins
表中添加以下条目。添加后,构建服务器将在构建阶段集成该插件。
settings = { plugins = { ["plugin.appsflyer"] = { publisherId = "com.coronalabs" }, }, }
“严格模式 SDK 完全移除 IDFA 收集功能和 AdSupport 框架依赖项(例如,在开发儿童应用时)”
要在 iOS 上使用严格模式,请在 build.settings
中包含以下内容来代替上述内容。严格模式版本的插件包含适用于 Android 的常规 plugin.appsflyer
,因此无需同时包含两个插件。
settings = { plugins = { ["plugin.appsflyer.strict"] = { publisherId = "com.coronalabs" }, }, }
最后,您需要调整 require 函数的模块名称
local appsflyer = require( "plugin.appsflyer.strict" )
对于 iOS,在将您的应用提交到 App Store 时,请遵循以下准则
对于 Android,使用此插件时会自动添加以下权限/功能
"android.permission.INTERNET"
"android.permission.ACCESS_NETWORK_STATE"
"android.permission.ACCESS_WIFI_STATE"
"com.google.android.gms.permission.AD_ID"
要移除 "com.google.android.gms.permission.AD_ID"
,请将以下内容添加到您的 build.settings 中
settings = { android = { manifestChildElements = { [[ <uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/> ]], }, }, }