How to stop sending AAID in Google Families-Policy

120 views
Skip to first unread message

S.L.

unread,
Sep 26, 2022, 1:00:44 AM9/26/22
to Google Mobile Ads SDK Developers
Hello.

Goole has informed me that my app is in violation of the Family Policy.

Family Policy:
https://support.google.com/googleplay/android-developer/answer/9893335#families-policy

Violation items:
Device identifier that was confirmed to be sent ... Android Ad ID

<<<< Premises >>>>
In order to comply with this policy, I need to stop sending Android Ad Identifier (AAID) by including the following code.

[How to respond]
https://developers.google.com/admob/android/targeting?hl=en

[Description code]
RequestConfiguration requestConfiguration = MobileAds.getRequestConfiguration()
    .toBuilder()
    .setTagForChildDirectedTreatment(RequestConfiguration.TAG_FOR_CHILD_DIRECTED_TREATMENT_TRUE)
    .build();
MobileAds.setRequestConfiguration(requestConfiguration);

<<<< question >>>>
1. Is AppActivity.java the right place to put the [Description code]?
   I have searched several sites and found that it is supposed to be in MainActivity.java.
   In my app building environment, I have AppActivity.java, but I could not find MainActivity.java.

 My environment:.
  Implementation of ads:     SDK + Admob
  App building environment:  Android Studio + cocos2d-x

【Path of AppActivity.java】
C:\App\TouhouTNA02\proj.android\app\src\org\cocos2dx\cpp\AppActivity.java


2. If it is correct in AppActivity.java, where should the [Description code] be placed in the following [// DO OTHER INITIALIZATION BELOW]?

[Contents of AppActivity.java]
---- start ----
package org.cocos2dx.cpp;

import android.os.Bundle;
import org.cocos2dx.lib.Cocos2dxActivity;

public class AppActivity extends com.sdkbox.plugin.SDKBoxActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.setEnableVirtualButton(false);
        super.onCreate(savedInstanceState);
        // Workaround in https://stackoverflow.com/questions/16283079/re-launch-of-activity-on-home-button-but-only-the-first-time/16447508
        if (!isTaskRoot()) {
            // Android launched another instance of the root activity into an existing task
            //  so just quietly finish and go away, dropping the user back into the activity
            //  at the top of the stack (ie: the last state of this task)
            // Don't need to finish it again since it's finished in super.onCreate .
            return;
        }
        // DO OTHER INITIALIZATION BELOW
       
    }

}
---- end ----

Please contact me with any other information needed for verification.

Regards,
S.L.

Mobile Ads SDK Forum Advisor

unread,
Sep 26, 2022, 9:56:14 AM9/26/22
to app.4...@gmail.com, google-adm...@googlegroups.com
Hi SL,

Thank you for reaching out to us.

With regard to your concern, you will need to use Android 20.6.0 GMA SDK or later, then set your ad request with TAG_FOR_CHILD_DIRECTED_TREATMENT_TRUE. We would recommend to check this developer guide which contains detailed information for your implementation use case.

Regards,
Google Logo
Teejay Wennie
Mobile Ads SDK Team
 
 

ref:_00D1U1174p._5004Q2egHKb:ref

S.L.

unread,
Sep 26, 2022, 9:46:37 PM9/26/22
to Google Mobile Ads SDK Developers
Hello.

Thank you for the informational response.

I understand about using Android 20.6.0 GMA SDK and setting tags.
I will try this method.

Regards,

2022年9月26日月曜日 22:56:14 UTC+9 mobileadssdk:
Reply all
Reply to author
Forward
0 new messages