Google Play Install Referrer API vs. INSTALL_REFERRER broadcast

7.7k Views Asked by At

Recently Google released Google Play Install Referrer API (announcement).

Comparing to the INSTALL_REFERRER broadcast from Google Play, it provides extra information like click and installs time in addition to referrer itself.

First question: is it a complete replacement for INSTALL_REFERRER broadcast? Should we just drop the broadcast receiver and start using a new API?

Second: is there any information in what particular cases new API is more reliable then INSTALL_REFERRER broadcast?

1

There are 1 best solutions below

10
On BEST ANSWER

It's all about SECURITY and SIMPLICITY. As the doc implies, you can use the Google Play Store's Install Referrer API to securely retrieve more accurate and reliable referral content from Google Play and also you can consider switch to Install Referrer API Client Library to simplify your development process. and as u mentioned in the query it returns ReferrerDetails object that hold extra info related to the install with the below three methods.

ReferrerDetails response = mReferrerClient.getInstallReferrer();
response.getInstallReferrer();
response.getReferrerClickTimestampSeconds();
response.getInstallBeginTimestampSeconds();

The API works only from Play Store version 8.3.73 onwards. Any developers that would like to begin using it can start right away, but a connection must be established between their app and the Play Store.

Also, check an article from Adjust that explains how new API can prevent click injection fraud for mobile ads.

P.S. You need to keep track with the latest API levels to be able to deliver the best solutions to the problems you face in your projects.