paypal / paypal-here-sdk-ios-distribution

Add credit card (tap, insert, swipe & key-in) capabilities to your iOS app
Other
81 stars 91 forks source link

PPH iOS SDK: Account is not mpa enabled #337

Closed maulikpat closed 3 years ago

maulikpat commented 3 years ago

I am testing transactions in Live mode.

When I create PPRetailInvoice, I was getting below error

Number is too long

the number should be unique. What if I don't have unique invoice numbers or I don't want this? Can I ignore this? What is the char limit for this property?

After assigning the unique numbers, I am getting below error:

Account is not mpa enabled

Response from SDK:

CompletedTxDueToFailure { "appId": "com.**.****", "appVersion": "5.0", "appBuild": "5.0.0", "appName": "--------", "osName": "iOS", "sdkVersion": "2.1.0320094000", "partnerType": "NOREF", "isSideloader": false, "partnerId": "NA", "softDescriptor": "NA", "storeId": "NA", "firmwareImageClientType": "sdk", "currency": "USD", "total": "1", "tip": 0, "discount": "0", "tax": "0", "charityEnabled": false, "skipReceipt": false, "isRefund": false, "qChipEnabled": false, "refundType": "None", "readerType": "M010", "cvm": "None", "paymentType": "Contactless", "saleType": "Sale", "vaultType": "pay", "id": "tx-1647390468326", "state": { "paymentState": "inProgress", "tippingState": "notStarted", "endState": "invoked", "connectedDevices": 1, "selectedDevice": "PayPal 277", "activeFormFactors": "SecureManualEntry" }, "activeCRs": 1, "invokeHandler": true, "error": { "code": "580022", "domain": "retail", "debugId": "7fb33a8600e20" } }

I have tried 3 different cards.

How can I resolve this error? (same question:https://www.paypal-community.com/t5/SDKs/PayPal-Here-Account-is-not-mpa-enabled/td-p/1895046#)

Am I missing anything?

maulikpat commented 3 years ago

@ppmtscory any help here?

ppmtscory commented 3 years ago

The number parameter is outlined in our documentation stating that it has to be unique per transaction attempt and has a 25 char limit. If you don't want to supply your own invoice number then you don't have to and the SDK will simply increment +1 off of the last one used so you'll want to make sure that it's a low character alphanumeric value that can be incremented.

Account not MPA enabled means that PPH is not enabled on the account you're using to receive the funds. PayPal Here is not automatically enabled on any business account, you have to sign up for it. You can login to your account online and apply for it or you can click here and login with your account to go through the signup process. Again, all of this is outlined in our documentation on https://developer.paypal.com

maulikpat commented 3 years ago

@ppmtscory thanks for the info. The documentation is confusing and it's hard to find such info. I have signup from the given URL and now it says Your application is being reviewed. How many days it would take?

ppmtscory commented 3 years ago

It can take up to 3 days but if it's longer than that you can call customer service by clicking Contact Us at the bottom of any PayPal page.

maulikpat commented 3 years ago

@ppmtscory The account is activated now and I did run 1st live test transaction successfully. I am not usingPPRetailInvoice's number is this fine or will it create any issue?

Also, I am adding more details by PPRetailInvoiceBillingInfo like the first name, last name, etc. but I could not found that info in the invoice or at the Transaction details page at Paypal.com Where can I see that info?

ppmtscory commented 3 years ago

Providing your own invoice number is recommended but not required. As for the billing info, that's simply tied to the invoice you create so you'd see that if you made an invoice details call via the invoicing REST API. The payment information you see within the transaction details are pulled from the card that's used for the payment.