question

moonbasedesign avatar image
moonbasedesign asked

How to clear player tranaction history

I'm testing IAP transactions through a Unity IOS/Android app in the sandbox environment.

I'm wondering how I can clear my previous transaction history.

Since I can't do it directly through the Playfab dashboard I've gone to great lengths of deleting and rebuilding the app. I've tried deleting the title player. but the previous transaction history keeps getting triggered (which interrupts my purchase tests. This is strange because I'm testing consumable purchases, so any previous purchase history should be irrelevant.

Has anyone done this with a cloudscript? That looks possible.

apisCloudScript
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

·
Neils Shi avatar image
Neils Shi answered

Currently, PlayFab does not provide a feature to clear player’s transaction history. Could you tell us why the previous transaction history will interrupt your purchase test? And what do you mean “the previous transaction history keeps getting triggered”?

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.

moonbasedesign avatar image moonbasedesign commented ·

I am testing IAP code for consumable items. I would think I should be able to repetitively test the transactions numerous time for the same item. For a period of time this is indeed the case but after a period (an hour or so?) I start hitting "Validation failed: Receipt Already Used" from the PlayFab.ValidateIOSReceipt API call. I'm not storing any receipt data, so obviously knowing a receipt has been used must be from a cache or transaction history. Transaction performance continues to degrade, until validation fails on 100%of my attempts. A message which occasionally appears is: Validation failed: /Client/ValidateIOSReceipt: A conflict occurred trying to make multiple edits to the same data at the same time. This often indicates that there are multiple concurrent requests to the same API for the same player. My purchase flow code is very "boilerpllate" based on this reference: https://github.com/nekojoker/UnityIAPForPlayFab/blob/master/Assets/Scripts/IAPExample.cs

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

As mentioned before, PlayFab does not provide a feature to clear player’s transaction history. In addition, if you trigger "Restore previous purchases", it will also result in the error "Receipt Already Used". For more info, please refer to Receipt validation (iOS/Android) after restore purchase - Playfab Community. And as @Brendan mentions in this post, the conflict error occurs when you're making multiple calls without waiting on the responses. You may need to wait for receiving the response from the first call before you make the second call.

0 Likes 0 ·

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.