Forum Discussion
MiguelOdders
1 year agoHonored Guest
Where can I obtain In app purchase receipt and price amount & currency for analytics?
Hi! I'm adding in app purchases in a Oculus app using Unity Oculus plugin. In order to measure monetization, I want to log purchases in some third party analytics services. Most of them request the price amount and the price currency in ISO 4217 format ("USD", "EUR", "GBP", etc.).
I don't know how can I obtain this values using the Unity API. I found this methods:
- CAPI.ovr_Price_GetAmountInHundredths(IntPtr o)
- CAPI.ovr_Price_GetCurrency(IntPtr o)
The problem is that I don't know what I need to pass as "IntPtr o" parameter. I tried to use the native message used to construct Product and Purchase classes, but it didn't work. It looks like there are not implemented as Price class doesn't exist.
In other way, maybe I could take some json receipt than it can be deserialize with this information, but I don't know where in Purchase class I can get it (any the json format if it exists).
I don't know what Purchase.DeveloperPayload and Purchase.ReportingId fields are, as they are always empty (at least using test purchases) and there is no documentation about it.
I appreciate in advance any help :).
Replies have been turned off for this discussion
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 2 months ago
- 2 months ago
- 4 years agoAnonymous
- 6 months ago