Posts tagged with android

I'm need to get GCLID value inside my android app. What i found is Play Install Referrer Library, that returns me a utm tags, but i'm not sure that GCLID value will be inside val referrer = response.installReferrer

Code sample:

 fun getGCLID(){         referrerClient = InstallReferrerClient.newBuilder(this).build()         referrerClient.startConnection(object : InstallReferrerStateListener {             override fun onInstallReferrerSetupFinished(responseCode: Int) {                 when (responseCode) {                     InstallReferrerClient.InstallReferrerResponse.OK -> {                         // Connection established.                         val response: ReferrerDetails = referrerClient.installReferrer                         val referrer = response.installReferrer                         val clickTimestamp = response.referrerClickTimestampSeconds                         val installTimestamp = response.installBeginTimestampSeconds                         Log.d("TagGCLID", "onInstallReferrerSetupFinished: 1")                         if ("gclid" in referrer) {                             Log.d("TagGCLID", "GCLID is detected in referrer // is $referrer")                             //report to Firebase Analytics                         } else {                             Log.d("TagGCLID", "no GCLID is detected in referrer\n" +                                     "$referrer")                             //do something else                         }                     }                     InstallReferrerClient.InstallReferrerResponse.FEATURE_NOT_SUPPORTED -> {                         Log.d("TagGCLID", "InstallReferrerResponse: -1")                         // API not available on the current Play Store app.                     }                     InstallReferrerClient.InstallReferrerResponse.SERVICE_UNAVAILABLE -> {                         Log.d("TagGCLID", "InstallReferrerResponse: -2")                         // Connection couldn't be established.                     }                 }             }             override fun onInstallReferrerServiceDisconnected() {                 Log.d("TagGCLID", "onInstallReferrerServiceDisconnected: -3")                 // Try to restart the connection on the next request to                 // Google Play by calling the startConnection() method.             }         })     } 

What i'm suppose to do to get GCLID value?

When user don't have an internet connection i want to show a black fullscreen popup that include like

"you should open your internet to use this app"

or

"no internet connection found please open it"

every minutes for show my google ads; and popup will countdown from 5 second for close the popup.

And i don't want to be banned from google ads because of illegal behaviours.

Is it forbidden or illegal with google ads policy, i didn't see any information about this on google ads docs?

RewardedVideoAd is deprecated. What is the new alternative?

    void loadAds(){         RewardedVideoAd mRewardedVideoAd;         mRewardedVideoAd.loadAd(rewarded_id, new AdRequest.Builder().build());         mRewardedVideoAd = MobileAds.getRewardedVideoAdInstance(this);         mRewardedVideoAd.setRewardedVideoAdListener(new RewardedVideoAdListener() {         @Override         public void onRewardedVideoAdLoaded() {             AppUtils.showLog("REWARDED", "onRewardedVideoAdLoaded");         }         .....         .....     } 

It was my first time to do app download campaign via google ads. I created a Universal app campaign and has no idea how to add in my tracking parameter on my campaign level. I have tried to append the tracking parameters with final url suffix, however, I've been informed there was no eligible ads found while all my 3 ads are approved.

- The app store link is : https://play.google.com/store/apps/details?id=com.yuurewards.app

- The part I tried to append via final url suffix but failed: referrer=utm_source%3DSCMP%26utm_medium%3DEM%26utm_content%3DPerformance_EM_IG_v2_app_store%26utm_campaign%3Dapps-launch%26anid%3Dadmob

- What I expect to have for the final url: https://play.google.com/store/apps/details?id=com.yuurewards.app&referrer=utm_source%3DSCMP%26utm_medium%3DEM%26utm_content%3DPerformance_EM_IG_v2_app_store%26utm_campaign%3Dapps-launch%26anid%3Dadmob

Would you please let me know how to append the utm parameters for my app download campaign so that my client can differentiate the downloads are coming from my campaign?

Created App Campaign for an Android app that has Firebase(Google) Analytics SDK added. We're generating a couple of events and we're able to get conversions based on user usage.

Example of conversion:

  • User clicks on ad
  • Is redirected on try-app landing page on our website
  • Clicks on google play store
  • Installs app
  • Do a certain action for N times
  • Success: we have a conversion.

Everything works as expected for App Campaigns. The problem that I've encountered is with Video and Display Campaigns. I can't seem to replicate the same behaviour as for app campaigns. I'm not recording any conversions.

Has anyone run into the same problem? I've been struggling for two weeks now and I don't see the light at the end of the tunnel.