cancel
Showing results for 
Search instead for 
Did you mean: 

How to get IAP working in Unreal Engine?

Anonymous
Not applicable
I'm trying to get IAP up and running in an Unreal Engine project (4.19), and struggling to figure it out from the documentation. There's a full example for Unity (https://developer.oculus.com/documentation/platform/latest/concepts/dg-iap/) but nothing really for Unreal.

Can anyone share working code for Unreal for the following actions:

- GetViewerPurchases
- GetProductsBySKU
- LaunchCheckoutFlow

Any help massively appreciated!
5 REPLIES 5

OzanHas
Explorer
We're also investigating how to get IAP up and running with Unreal. Hope you get a good response to the question. 

Anonymous
Not applicable
I've made some slight progress with this, but one key thing I don't understand.

In the documentation it explains how to launch the checkout flow, but I can't find anything about handling the result with a callback etc.

I've found people discussing this in the Unity forums using something like this:

IAP.LaunchCheckoutFlow(temp).OnComplete(LaunchCheckoutFlowCallback);

But I can't find how to do this with the native C APIs.

How do I know if a successful purchase has been made?

I would also like any help for IAP in Unreal, specifically using blueprints-only. I have tried everything and have reached a wall. The SDK Box plugin seems hopeful, but is specially catered to iOS and Android. There is no specific IAP method for Oculus, other than "VR Monkey". I have not done too much research into this, but the developer says the code needs slight adjustments (which you can email them about) as is crashes on load for me.

I am creating custom structures for storing products, using the same product ID's which 'I've setup through the Oculus' developer company page. Then, I'm connecting it to a "make inApp Purchase" node through Unreal's blueprint. It always fails, though, when testing from a test user and the downloaded RC version of the app.

The 'Make an In-App Purchase v2" node fails.  The error from the headset Device Output log reads: Error: OSS: FOnlinePurchaseNull::Checkout failed, Could not find corresponding offer.  

 

Verify Entitlement and Get Oculus Identity both work but no action from in app purchase.  Is this not possible via blueprint?  I have gotten In App Purchases working on through blueprint on android phones without much problem, I was hoping it would be relatively the same on the Quest.   Am I missing something or is it just not possible to do via blueprint?

Did you ever get in app purchase to work on Quest with an Unreal project?