3

I want to implement "refer and earn" concept using https://firebase.google.com/docs/dynamic-links/use-cases/rewarded-referral in my application.

When I'm creating dynamic links with user id

FirebaseUser user = mAuth.getInstance().getCurrentUser(); 

get current user always returns null.

My questions are:

  1. If I want to implement "refer and earn" using dynamic links, I have to make user sign up or sign in with Firebase login system (Firebase email login, fb login...e.t.c).

  2. If I have my own database for signup and I'm storing credentials and validating user from server. So I'm not using the firebase login system. Is it still possible to implement "refer and earn" using firebase?

  3. How to track the people who installed or not and how should I give him rewards.

Please give me some example or sample links if any one implemented "refer and earn"

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
prakash421
  • 139
  • 1
  • 8
  • note: if your app lets the user delete their account (eg for privacy reasons) in app, *and* you implement the referral guide in the link above, then it's possible to sign in using a link, giving the referrer a reward, delete the account, sign in (a new user event = new `uid`), and can repeat giving the referrer unlimited rewards. To avoid this the `providerUid` should be stored in the backend instead of the FirebaseAuth `uid`. – g2server Oct 27 '20 at 05:32

1 Answers1

1

Please find below are my answers to your question.

  1. Yes. Absolutely! You need to implement Firebase database to implement refer and earn using firebase.
  2. No. You cannot reward users using Fireabase implementations if you are using your own server. You may need to look into other service providers like www.invitereferrals.com, https://github.com/appvirality etc.
  3. Please go through the complete details in below link. They have explained end to end implementaion from referring to crediting users.

https://firebase.google.com/docs/dynamic-links/use-cases/rewarded-referral

Hope this helps.

Varun A M
  • 1,103
  • 2
  • 14
  • 29