请求的操作:声明您的广告 ID 权限

发布于 2025-01-14 02:07:48 字数 633 浏览 3 评论 0 原文

今天我收到这封电子邮件:

去年 7 月,我们宣布了广告政策变更,以帮助加强 安全和隐私。我们对使用的标识符添加了新的限制 针对儿童的应用程序。当用户选择删除他们的 广告 ID 以选择退出个性化广告, 如果满足以下条件,开发人员将收到一串零而不是标识符 他们尝试访问标识符。这种行为将延伸至 从 2022 年 4 月 1 日开始,手机、平板电脑和 Android TV。我们还 宣布更新时需要声明AD_ID权限 您的应用的目标 API 级别为 31 (Android 12)。今天我们分享的是 我们将给予开发者更多的时间来缓解过渡。我们将 当您的应用程序能够定位时需要此权限声明 Android 13 而不是从 Android 12 开始。

操作项如果您使用广告 ID,则必须声明 AD_ID 当您的应用面向 Android 13 或更高版本时的权限。不支持的应用程序 声明权限将得到一串零。注意:你会 能够在今年晚些时候针对 Android 13。如果您的应用程序使用 SDK 已声明Ad ID权限的,将获取该权限 通过清单合并进行声明。如果您的应用程序的目标受众 包括儿童,您不得传输 Android 广告 ID (AAID) 来自儿童或未知年龄的用户。

我的应用程序未使用广告 ID。我是否应该在清单中声明 AD_ID 权限?

Today i have got this email:

Last July, we announced Advertising policy changes to help bolster
security and privacy. We added new restrictions on identifiers used by
apps that target children. When users choose to delete their
advertising ID in order to opt out of personalization advertising,
developers will receive a string of zeros instead of the identifier if
they attempt to access the identifier. This behavior will extend to
phones, tablets, and Android TV starting April 1, 2022. We also
announced that you need to declare an AD_ID permission when you update
your app targeting API level to 31 (Android 12). Today, we are sharing
that we will give developers more time to ease the transition. We will
require this permission declaration when your apps are able to target
Android 13 instead of starting with Android 12.

Action Items If you use an advertising ID, you must declare the AD_ID
Permission when your app targets Android 13 or above. Apps that don’t
declare the permission will get a string of zeros. Note: You’ll be
able to target Android 13 later this year. If your app uses an SDK
that has declared the Ad ID permission, it will acquire the permission
declaration through manifest merge. If your app’s target audience
includes children, you must not transmit Android Advertising ID (AAID)
from children or users of unknown age.

My app is not using the Advertising ID. Should i declare the AD_ID Permission in Manifest or not?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(13

心是晴朗的。 2025-01-21 02:07:48

情况 1:应用不包含任何广告:

您只需在 AndroidManifest.xml 中添加 tools:node="remove" 即可删除/忽略它 文件。

<uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove" />

确保您在 AndroidManifest.xml 文件顶部有 xmlns:tools

<manifest xmlns:tools="http://schemas.android.com/tools" ... />

即使另一个第三方库请求此特定权限,构建也将被迫不这样做将其合并到您的最终清单文件中。
您可以从此答案中获取更多信息。


案例2:应用程序包含广告:

将以下内容添加到AndroidManifest 之前的.xml

<uses-permission android:name="com.google.android.gms.permission.AD_ID" />

可以获取更多信息来自此页面。

Case 1: The app doesn't contain any Ads:

You can simply remove/ignore it by adding tools:node="remove" in the AndroidManifest.xml file.

<uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove" />

Make sure you have xmlns:tools at the top of AndroidManifest.xml file :

<manifest xmlns:tools="http://schemas.android.com/tools" ... />

Even if another third-party library asks for this specific permission, the build will be forced not to merge it in your final Manifest file.
You can get more info from this SO answer.


Case 2: The app contains Ads:

Add the following to AndroidManifest.xml before </manifest>:

<uses-permission android:name="com.google.android.gms.permission.AD_ID" />

You can get more information from this page.

慕烟庭风 2025-01-21 02:07:48

情况 1:您的应用有广告

之前的 AndroidManifest.xml 中添加以下内容:

<uses-permission android:name="com.google.android.gms.permission.AD_ID"/>

情况 2:您的应用没有

广告AndroidManifest.xml 确保 > 上有 xmlns:tools。 (感谢这个答案)例如

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    package="com.mycompany.myapp">

然后,在页面底部的 标签:

    <uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/>

来源:

Case 1: Your App has Ads

Add the following to AndroidManifest.xml before </manifest>:

<uses-permission android:name="com.google.android.gms.permission.AD_ID"/>

Case 2: Your App Doesn't have Ads

At the top of your AndroidManifest.xml make sure you have xmlns:tools on the <manifest ...>. (kudos to this answer) e.g.

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    package="com.mycompany.myapp">

Then, add the following at the bottom of the page, before </manifest> tag:

    <uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/>

Source:

温柔女人霸气范 2025-01-21 02:07:48

就我而言,我仅将 Firebase Analytics 用于崩溃报告等。

您可以将应用设置为使用广告 ID。

在此处输入图像描述

并使用仅分析。

在此处输入图像描述

In my case, I used Firebase Analytics only for crash reports etc.

You can set your app to use advertising ID.

enter image description here

And use Analytics only.

enter image description here

真心难拥有 2025-01-21 02:07:48

如果您的应用使用 Google 移动广告 SDK(Admob) 版本20.4.0或更高版本,您可以跳过手动设置权限,因为 SDK 会自动声明该权限

更多信息请参见:

https://developers.google.com/admob/android/quick-start

If your app uses the Google Mobile Ads SDK(Admob) version 20.4.0 or higher, you can skip setting up the permission manually since the SDK automatically declares it

More informations here:

https://developers.google.com/admob/android/quick-start

我的痛♀有谁懂 2025-01-21 02:07:48

如果您的应用不包含广告,请务必完成关于应用内容< Play 管理中心中的 /a> 页面(政策 > 应用内容)。

只需选择选项:不,我的应用不包含广告

如果您不这样做,您将无法将新版本的应用上传到 Google Play。

Google Play 管理中心广告选择器位置

If your app doesn't contain ads, make sure you complete the survey on App content page (Policy > App content) in Play Console.

Just select the option: No, my app does not contain ads.

If you don't do that, you won't be able to upload new releases of your app to Google Play.

Google Play Console Ad Selector Location

白云悠悠 2025-01-21 02:07:48

Google 在此处描述了如何解决

https://support.google.com /googleplay/android-developer/answer/6048248?hl=en

添加到清单中

<uses-permission android:name="com.google.android.gms.permission.AD_ID"/>

Google describe here how to solve

https://support.google.com/googleplay/android-developer/answer/6048248?hl=en

Add in manifest

<uses-permission android:name="com.google.android.gms.permission.AD_ID"/>
所有深爱都是秘密 2025-01-21 02:07:48

首先,
com.google.android.gms.permission.AD_ID 可以通过其他第三方 SDK 添加,例如

  • Play Services-ads
  • firebase-analytics 等< br>

因此,如果您尚未手动添加permission.AD_ID,请通过检查合并清单文件确保它未被任何其他 SDK 添加。

合并清单路径:
项目> 应用程序> 构建> 中级 > merged_manifest > > 发布> AndroidManifest.xml

现在转到您的播放控制台> 应用内容 > 广告 ID

  • 选择 NO(如果您的合并清单不包含 AD_ID),否则
  • 选择 YES 并完成下一个选项。

First of all,
com.google.android.gms.permission.AD_ID can be added by other third party SDK like

  • Play Services-ads
  • firebase-analytics etc

So, if you haven't added permission.AD_ID manually, make sure it is not added by any other SDK by checking merged manifest file.

merged-manifest path:
project > app > build > intermediate > merged_manifest > release > AndroidManifest.xml

Now go to your play console > app content > Adverstising ID and

  • Select NO if your merged manifest doesn't contain AD_ID, else
  • Select YES and complete next option.
灼疼热情 2025-01-21 02:07:48

不用担心。所有使用 Admob 进行广告的开发者都会收到此警告。只需确保您在 build.gradle最新 Google 移动广告 SDK(Admob) 或 AdMob SDK 版本高于或等于 20.4.0 > 文件。在这种情况下,SDK 会自动管理它

否则对于低于 20.4.0 的旧版 sdk,我们需要在 AndroidManifest.xml 中手动提及以下行

<uses-permission android:name="com.google.android.gms.permission.AD_ID"/>

Don't worry. All developer who uses Admob for advertisement received this warning. Just make sure you are using Latest Google Mobile Ads SDK(Admob) OR AdMob SDK version higher or equal to 20.4.0 in your build.gradle file. In that case SDK automatically manage it.

Otherwise for older sdk below 20.4.0, we need to manually mention below line in our AndroidManifest.xml

<uses-permission android:name="com.google.android.gms.permission.AD_ID"/>
椒妓 2025-01-21 02:07:48

如果这是由使用广告 ID 的 Firebase 分析等引起的,请勿使用 如许多其他答案所示,因为分析可能无法正常工作。而是更新 Play 商店控制台中的声明,表明您的应用使用广告 ID 并选择 Analytics 作为原因。这不会在 Play 商店中为您的应用添加“应用包含添加”句子。

In case this is caused by for example firebase analytics which uses Advertising ID do not use <uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/> as shown in many other answers because analytics may not work correctly. Rather update declaration in Play Store Console that your app uses Advertising ID and select Analytics as reason. This will not add "App contains add" sentence for your app in Play Store.

拧巴小姐 2025-01-21 02:07:48

有两种不同的形式:

  1. 广告
  2. 广告 ID

最初,我陷入困境,因为我没有注意到另一个。所以你的应用程序可以是任意组合,例如,没有广告,但有广告 ID。

文档解释了 Google 服务可以包含以下广告 ID:非广告的其他原因:分析。

Google Play 服务 4.0 版引入了新的 API 和 ID,供广告和分析提供商使用。使用此 ID 的条款如下。

在另一份文档,在示例部分很清楚,ads理解为一般理解的广告:banners,弹出窗口、列表中间的图块等。

分析合并的清单,我们可以看到库 play-services-measurement-api 正在添加权限并且与 Analytics 相关。库清单如下所示:

    <uses-permission android:name="com.google.android.gms.permission.AD_ID" />

    <application>
        <service
            android:name="com.google.firebase.components.ComponentDiscoveryService"
            android:exported="false" >
            <meta-data
                android:name="com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar"
                android:value="com.google.firebase.components.ComponentRegistrar" />
        </service>
    </application>

请注意,库正在注册analytics.connector.internal.AnalyticsConnectorRegistrar

在这种情况下,广告表单必须标记为“否”,但广告 ID 表单必须标记为“是”,然后是“分析”选项。

我见过有人建议强制清单不合并permission.AD_ID,但这会破坏分析。

There are two different forms:

  1. Ads
  2. Advertising ID

Initially, I got stuck because I did not notice the other. So your app can be in any combination, for example, no ads, but yes, advertising ID.

In this documentation it is explained that Google services can include the advertising ID for other reasons that are not ads: Analytics.

Google Play Services version 4.0 introduced new APIs and an ID for use by advertising and analytics providers. Terms for the use of this ID are below.

And in this other documentation, in the examples section is very clear that ads are understood as what is commonly understood as ads: banners, pop-ups, a tile in the middle of a list, etc.

Analyzing the merged manifest we can see that the library play-services-measurement-api is adding the permission and is related to Analytics. The library manifest looks like this:

    <uses-permission android:name="com.google.android.gms.permission.AD_ID" />

    <application>
        <service
            android:name="com.google.firebase.components.ComponentDiscoveryService"
            android:exported="false" >
            <meta-data
                android:name="com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar"
                android:value="com.google.firebase.components.ComponentRegistrar" />
        </service>
    </application>

Please notice that library is registering analytics.connector.internal.AnalyticsConnectorRegistrar.

In this case the Ads form must be mark with no but the Adverising ID form must be mark with yes and then the Analytics option.

I have seen people recommending force the manifest to not merge the permission.AD_ID but that would break the Analytics.

凉宸 2025-01-21 02:07:48

当您设置 targetSdkVersion 33 时,您必须在清单文件中添加以下行(

<uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/>

如果未设置此行),则在生产时会在播放控制台上显示警告。

when you set targetSdkVersion 33 you must need to add the below line in the manifest file

<uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove"/>

if you are not set this, show a warning on the play console when your is in production.

百合的盛世恋 2025-01-21 02:07:48

我还收到了 PlayStore 团队今天发给所有开发者的邮件。要求声明AD_ID权限。
由于我们使用 Flutter 开发并发布了我们的应用程序,Android 目标为 API 级别 31。我使用 advertising_identifier: ^0.1.1 插件来获取广告客户端 ID。我尚未在清单文件中声明 AD_ID 权限。

此外,将目标 API 级别更新为 31 (Android 12) 并使用广告标识符/广告 ID 客户端信息获取的应用程序需要在清单文件中声明 Google Play 服务正常权限,如下所示:

已引用,

https://support.google.com/googleplay/android-developer/答案/6048248?hl=zh-CN

I also received today's mail from the PlayStore team to all developers. Asking to declare AD_ID permission.
Since we developed and released our application using Flutter with android targeting to API level 31. I'm using the advertising_identifier: ^0.1.1 plugin to get the advertising client ID. I haven't declared AD_ID permission in my manifest file.

Additionally, apps updating their target API level to 31 (Android 12) and using advertise identifier / advertise id client info fetch will need to declare a Google Play services normal permission in the manifest file as follows:

<uses-permission android:name="com.google.android.gms.permission.AD_ID"/>

Refered,

https://support.google.com/googleplay/android-developer/answer/6048248?hl=en

若无相欠,怎会相见 2025-01-21 02:07:48

应用程序中的权限原因我使用颤振分析包
在 mainandroidfest.xml 中添加此行

<使用权限 android:name="com.google.android.gms.permission.AD_ID" 工具:node="删除" />

Reason of permission in app i use flutter analyst package
add this line in the mainandroidfest.xml

< uses-permission android:name="com.google.android.gms.permission.AD_ID" tools:node="remove" />

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文