文章目录

  • 一、广告权限申请要求
  • 二、添加广告权限

一、广告权限申请要求


今天收到 Google Play 邮件 , 要求添加

邮件原文 :

Hello Google Play Developer,

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. Learn more.

机翻内容 ( 仅做参考 ) :

你好,谷歌游戏开发者,
去年7月,我们宣布改变广告政策,以帮助加强安全和隐私。我们对针对儿童的应用程序使用的标识符增加了新的限制。
当用户选择删除他们的广告ID以退出个性化广告时,如果开发者试图访问标识符,他们将收到一个由零组成的字符串,而不是标识符。这种行为将从2022年4月1日起扩展到手机、平板电脑和安卓电视。
我们还宣布,当您将应用程序目标API级别更新为31(Android 12)时,您需要声明AD_ID权限。今天,我们分享我们将给开发者更多的时间来简化过渡。当你的应用能够以安卓13为目标,而不是以安卓12为起点时,我们将需要此权限声明。
行动项目
如果你使用广告ID,当你的应用针对Android 13或更高版本时,你必须声明广告ID权限。未声明权限的应用程序将得到一串零。注:今年晚些时候,你将能够瞄准Android 13。
如果你的应用程序使用的SDK已经声明了Ad ID权限,它将通过清单合并获取权限声明。
如果你的应用程序的目标受众包括儿童,你不能从儿童或未知年龄的用户那里传输Android广告ID(AAID)。了解更多。

二、添加广告权限


对应的文档地址 : https://support.google.com/googleplay/android-developer/answer/6048248

在 AndroidManifest.xml 中声明

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

权限即可 ;

完整清单文件参考 :

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"package="com.example.ad_id_test"><uses-permission android:name="com.google.android.gms.permission.AD_ID"/><applicationandroid:allowBackup="true"android:icon="@mipmap/ic_launcher"android:label="@string/app_name"android:roundIcon="@mipmap/ic_launcher_round"android:supportsRtl="true"android:theme="@style/Theme.AD_ID_Test"><activity android:name=".MainActivity"><intent-filter><action android:name="android.intent.action.MAIN" /><category android:name="android.intent.category.LAUNCHER" /></intent-filter></activity></application></manifest>

完整 build.gradle 参考 : 核心是 targetSdkVersion 31 ;

plugins {id 'com.android.application'
}android {compileSdkVersion 30buildToolsVersion "30.0.3"defaultConfig {applicationId "com.example.ad_id_test"minSdkVersion 18targetSdkVersion 31versionCode 1versionName "1.0"testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"}buildTypes {release {minifyEnabled falseproguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'}}compileOptions {sourceCompatibility JavaVersion.VERSION_1_8targetCompatibility JavaVersion.VERSION_1_8}
}dependencies {implementation 'androidx.appcompat:appcompat:1.4.1'implementation 'com.google.android.material:material:1.5.0'implementation 'androidx.constraintlayout:constraintlayout:2.1.3'testImplementation 'junit:junit:4.+'androidTestImplementation 'androidx.test.ext:junit:1.1.3'androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
}

【Google Play】声明广告权限 ( you must declare the AD_ID Permission when your app targets Android 13 )相关推荐

  1. 重塑 Google 搜索、Android 13 新版发布,这届 I/O 大会为开发者带来了什么?

    作者 | 屠敏 出品 | CSDN(ID:CSDNnews) 如果说每年的 9.10 月是科技产品发布的高峰期,那么一年中的 5.6 月则是开发者.程序员.技术人享受饕餮盛宴的时光. 2022 这一年 ...

  2. 如何把 Google adsense 的广告放到博客的Banner位置

    今天申请了一个 Google adsense 的广告放到我的博客上,发现放到公告的侧栏很影响整体的感觉,想放到上头那个Banner的位置.要放到那个位置就只能用 css 来弄了.写个固定位置的层估计一 ...

  3. 什么是Google AdWords关键字广告?

    什么是 Google AdWords关键字广告? Google推出的 AdWords关键字广告已经成为风靡全球的网络营销产品,它位于Google Web 搜索.Google 论坛.Google 目录的 ...

  4. Google Adwords关键词广告须注意的7个问题

    Google Adwords关键词广告须注意的7个问题 Google的Adwords关键词广告不愧为一个特别棒的工具!使用得当的话可以吸引大批高度定向的客户,并让他们疯狂采购你的产品.但另一方面,如果 ...

  5. Google Pixel获取root权限的方法【完整版】

    Google Pixel获取root权限的方法[完整版] 由于原作者部分表述不够详尽,操作过程中遇到几个非常大的问题:解决过程太痛苦了!!一并加入教程中!! 原文地址 https://chen.sn/ ...

  6. Google Adwords的广告特点

    Google Adwords的广告特点 ·不点击不收费 ·费用低廉 ·设定每月预算 ·锁定某种语言潜在客户 ·锁定某个国家或地区潜在客户 ·即时开通 ·随时编辑您的广告词 不点击,不收费 与百度的竞价 ...

  7. android播放音乐权限,android开发播放音乐需要声明什么权限

    android开发播放音乐需要声明什么权限以下文字资料是由(历史新知网www.lishixinzhi.com)小编为大家搜集整理后发布的内容,让我们赶快一起来看一下吧! android开发播放音乐需要 ...

  8. Google Ads搜索广告如何搭建广告系列?

    谷歌竞价广告系列类型包含搜索广告系列.展示广告系列.视频广告系列.购物广告系列.智能广告系列和发现广告系列. 今天我们要讲的主要是谷歌Ads搜索广告,目前搜索广告是机械类产品快速获取询盘的主要营销渠道 ...

  9. 关于Google Play的广告投放

    如果我们的APP需要获取大量的新用户,那么我们可以在Google现有的渠道上投放广告,从而鼓励潜在用户来安装我们的APP,促进下载量. 注意控制广告预算,仔细考虑选择采用哪种出价策略,可以选择通过每日 ...

最新文章

  1. 投稿2877篇,EMNLP 2019公布4篇最佳论文
  2. [20180806]tune2fs调整保留块百分比.txt
  3. 安装tomcat出现failed to install tomcat8 service错误及解决方法
  4. Fedora开启FTP服务
  5. 【DIY】废物利用,最简单粗暴便宜的DIY定时器方法,没有之一
  6. Struts2之路第一天
  7. 分享一个近期遇到的逻辑漏洞案例
  8. 使用 jQuery 查询属性不包含 disabled 的 input radio
  9. LeetCode(700)——二叉搜索树中的搜索(JavaScript)
  10. Linux:红帽操作系统介绍
  11. 论文写作---matlab符号运算之求解方程组
  12. 【敏捷开发模式的介绍】
  13. 【转】《Unity Shader入门精要》冯乐乐 随书彩图
  14. 嵌入式_cpu微架构、互连结构与总线
  15. GTX1060安装gpu版tensorflow经验分享
  16. [项目管理]关于风险管理的问题和可能过早的幼儿教育
  17. 广告联盟源码java_Android启动页广告(腾讯广告联盟)解决方法及源码下载
  18. 人头识别与计数_基于人头检测的人数统计算法研究
  19. 解决SendMessage函数向QQ好友发送中文消息时出现乱码
  20. 【基于UML软件建模的教材管理系统 】

热门文章

  1. ActiveMQ简单使用介绍
  2. Gamma校正及其OpenCV实现
  3. 为iframe添加鼠标事件
  4. shell如何将标准错误输出重定向为标准输出
  5. phpmyadmin 安装
  6. Python机器学习基础教程-第2章-监督学习之K近邻
  7. 8. American Friendship 美国式的友谊
  8. 序列化流与反序列化流
  9. 关于js里的document.compatmode
  10. WebDataMenu做工具栏程序代码