Reputation: 33
i have a Question about how Firebase handles the in-app-purchase Event, so i can know if it ise usable for Handling purchases.
My Questions are:
Does this work on the Client?
FirebaseAnalytics.LogEvent("in-app-purchase");
If yes,
How can I validate this data on the server (Cloud Functions), so that I can secure this process, so that I can be sure that every purchase is valid?
If the in-app-purchase event is not safe, how can i use an other option and which?
Upvotes: 2
Views: 2142
Reputation: 5169
Short answer is no, the Firebase analytics event is not a validation that a real purchase was made. If you have subscription IAPs then it will be wildly inaccurate as well. The correct way to validate a purchase was made is through server-side receipt validation.
Upvotes: 3