question

moises avatar image
moises asked

Getting UnkownOfferId when trying to Redeem Google Play items

Hello,

I'm implementing Economy V2 real money transactions, and I'm getting an error when redeeming the items with the receipt received. I'm using Unity IAP and after a successful purchase I am calling RedeemGooglePlayInventoryItems using the receipt, but the items are not being redeemed.

This is part of the response I'm getting: "FailureCode":"UnknownOfferId" "FailureDetails":"Failed to redeem offer mygame_100_coins because it is not setup or empty in the catalog. Please add or update a bundle with the alternate id Type=GooglePlay Value=mygame_100_coins and try again later."

I do have a bundle with GooglePlay and mygame_100_coins as Marketplace and MarketplaceID in PlayFab and I also have the product with that ID active in Google Play.

Any help is welcome.

Cheers, Moisés

In-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.

moises avatar image
moises answered

Okay, so I ended up fixing the issue after a few days.

The problem was that I was calling RedeemGooglePlayInventoryItems passing an EntityKey to RedeemGooglePlayInventoryItemsRequest. I was using "title_account_id" and the PlayFab ID I received when logging in. I did that because I was writing Azure cloud functions to communicate with the Economy V2 API, and in that case we need to provide the EntityKey since there's no logged in user.

When I removed the EntityKey argument it worked as expected.

The error message is very misleading and I hope it gets fixed in the future. I find this whole entity stuff very confusing, maybe I need to spend some time to really understand how it all works.

Cheers.

10 |1200

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

Neils Shi avatar image
Neils Shi answered

According to the Failure Details, you should add or update a bundle with the alternate id. For more information, you can refer to Economy V2 - Real money purchase.

5 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.

moises avatar image moises commented ·

I understood this is achieved by adding it to "Marketplace Mapping", which I already did, I'm using the same ID:

5438-screenshot-2023-01-30-at-130537.png

0 Likes 0 ·
moises avatar image moises commented ·

Hi Neils Shi, any update about this? I could not figure out what I'm doing wrong.

Thanks.

0 Likes 0 ·
Neils Shi avatar image Neils Shi moises commented ·

Can you provide us the title ID and item ID, so we can do some research?

0 Likes 0 ·
moises avatar image moises Neils Shi commented ·

Hi Neils,

I could finally make it work, I will write an answer to explain and maybe help someone that faces the same issue.

Thanks for your help!

0 Likes 0 ·
Show more comments

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.