question

szilagyimatyas444 avatar image
szilagyimatyas444 asked

GetInAppPurchasesFailure Error

Hello, I am trying to implement Economy v2 and I have tried everything to set it up but I cannot get PlayFabEconomyAPI.RedeemGooglePlayInventoryItems to work. I am giving it the correct token and product id. I also created a service account key and gave it owner permissions. I have set also the google app package id and the app license key.

I have no clue what else I could do and all I get in return is

2023/11/17 12:28:09.480 28002 28438 Info Unity Validation failed: {"ApiEndpoint":"/Inventory/RedeemGooglePlayInventoryItems","HttpCode":400,"HttpStatus":"BadRequest","Error":1071,"ErrorMessage":"Marketplace returned HTTP status code 'GetInAppPurchasesFailure', error code 'BadRequest', and error message 'Unknown error'."}

unity3dIn-Game Economy
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Infer Wang avatar image
Infer Wang answered

Please check if you follow this document. Also you may try reinstalling Google Addon, refilling and double-checking the keys (such as the service account key), then calling the RedeemGooglePlayInventoryItems API to see if the problem persists.

2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

szilagyimatyas444 avatar image szilagyimatyas444 commented ·

I have tried and have been looking at this for quite some time. I looked through the document once more but it is outdated and doesn't say much about the exact correct way to set up the service account key. I just keep getting the same error no matter what I really try.

0 Likes 0 ·
Infer Wang avatar image Infer Wang szilagyimatyas444 commented ·

You may try to follow Use a service account to create a service account. And then follow Create and delete service account keys to add a Service Account Key. In this process, you can create a private key. The private key is downloaded to your machine and is the only copy of this key. This private key is what we need. Please enter the whole JSON into Service Account Key section. When it is saved successfully, you should be able to see the private key id in Game Manager.

-1 Like -1 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.