That sounds like you're attempting to use the StartPurchase flow, which is for non-receipt validation purchases. For games running on Android devices, you would generally have to use the appropriate receipt validation call (https://blog.playfab.com/blog/show-me-money-receipt-validation-ios-and-android/). If you're trying to do a non-receipt purchase though, can you clarify which payment provider you're trying to use, and what parameters you passed into the calls?
Hmm I'm not sure I get what you mean..
This is my set up in my Adobe AIR game:
(FlashDevelop 5 + Adobe AIR 23 + Starling 1.7 + Milkman's Android Billing Extension)
playfabManager.validatePurchase({ReceiptJson:e.jsonData, Signature:e.signature})
the actual call inside validatePurchase() is:
public function validatePurchase(data:Object):void { var purchaseReq:ValidateGooglePlayPurchaseRequest = new ValidateGooglePlayPurchaseRequest(data); PlayFabClientAPI.ValidateGooglePlayPurchase(purchaseReq, onPfValidatePurchaseComplete, onPfValidatePurchaseError); }
And the callback:
public function onPfValidatePurchaseError(e:PlayFabError):void { // show Window validate Error Global.getInstance().windowManager.showWindow(WPurchaseValidationFailed, {errorCode: e.errorCode} ); } public function onPfValidatePurchaseComplete():void { // validate successful! now handle the purchase! WrapperClass.HandlePurchaseSuccess(WrapperClass.justPurchasedID); }
Then I'm not really sure where you're getting that result. From a quick review of the service code, the InvalidPaymentProvide is only returned from a call to GetPaymentToken, which is currently only valid for Xsolla purchases. Are you saying you're getting that error on a call to ValidateGooglePlayPurchase? Can you get us a Wireshark capture of that exchange?
On my test yesterday, I got this #1063 InvalidPaymentProvider error. I'm not quite sure what I changed today and it says different error:
ArgumentError: Error #1063 at MethodInfo-5812() at MethodInfo-10177() at flash.events::EventDispatcher/dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent() at flash.net::URLLoader/onComplete()
I'm thinking I wrote the callback wrong. I think I got the validate Error callback right already
public function onPfValidatePurchaseError(e:PlayFabError):void
I'm not sure what event/param I should include in the Success callback. I suspect the argument error could be related to this
public function onPfValidatePurchaseSuccess():void
I'm not familiar with Wireshark. Let me check on that first
Error 1063 in our service is "InvalidPaymentProvider" - we don't have an "ArgumentError" error message (though we do have an "InvalidParams"). And correction to the above - there are specifically two ways to get InvalidPaymentProvider - via GetPaymentToken, but also by calling PayForPurchase with a bad payment provider. Can you search through your project for those two calls? It would have to be one of them being called.
2 People are following this question.