I want to implement a refer-a-friend kind of functionality onto my application such that every user will have a unique link directing to the apk and the user can share the link via different mediums. I am done with the generating link part, now I wanted to know how to identify the user hitting the link and also check whether or not the app was installed/downloaded. If it was installed, then I need to add some credits onto the link owner's account. And my issue needs to be resolved without the use of API's. Any help would be appreciated.
How do I implement a referral module onto my android application?
4.9k views Asked by Sumit Shetty At
2
There are 2 answers
8
On
You can achieve this without api. Create one Label which consist some data. Now add Scheme for that at your application (Manifest). After that write code at First screen which get value from that label.
https://developer.android.com/training/basics/intents/filters.html
FYI :
<a href="your.custom.scheme://some/UniqueNumber/">Myapp</a>
For every user you need to have a unique code stored on your server, like
A
hasFOO766
,A
hasBAR456
.You can use
Google
'sreferrer
feature. In this method, when youA
shares your app to another user, you need to append aA
's unique code with your app'sPlay store
link. And when another user installs your app, aBroadcastReceiver
of your app will be called, containing the code; with which you can verify referral. More info Google Campaigns.Or you can do it manually. Whenever a user installs your app, ask him for the
referral
code, and you can verify the referral condition's over the server & can determine is it valid or not.