Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"This device can make payments but has no supported cards" but Stripe test cards have been added #10

Closed
Graham-C opened this issue Dec 13, 2016 · 4 comments

Comments

@Graham-C
Copy link

Hi,
Trying to test this with a stripe payment gateway but getting "This device can make payments but has no supported cards" message when checking availability yet a few test cards have been added and are visible in the wallet. Sample cards have been selected from this page https://developer.apple.com/support/apple-pay-sandbox/ in accordance with the setup instructions from here: https://stripe.com/docs/apple-pay/web.
Device is iPhone 6 running iOS 10.2

@samkelleher
Copy link
Owner

Thanks for stopping by @Graham-C.

On the readme this error is described.

If in your catch you get the message This device can make payments but has no supported cards - you can decide if you want to handle this by showing the 'Setup Apple Pay' buttons instead of the normal 'Pay with Apple Bay' buttons as per the Apple Guidelines.

It means that Apple Pay doesn't find a supported card as described in their docs:

If canMakePayments returns YES but canMakePaymentsUsingNetworks: returns NO, the device supports Apple Pay, but the user has not added a card for any of the requested networks. You can, optionally, display a payment setup button, prompting the user to set up his or her card. As soon as the user taps this button, initiate the process of setting up a new card (for example, by calling the openPaymentSetup method).

The supported payment methods can be defined in code: see https://github.com/samkelleher/cordova-plugin-applepay/blob/master/src/ios/CDVApplePay.m#L14

I would try make the sandbox accounts again, can you see them for example in another Apple Pay apps?

@Graham-C
Copy link
Author

Hi @samkelleher, thanks for your quick reply.

When navigating to https://stripe.com/docs/apple-pay/web on the device the Apple Pay button near the top of the page becomes enabled and tapping this brings up the payment sheet with the 2 test cards I have in my wallet available.

img_0059

img_0060

Does the plugin work for yourself when you have only test cards in the wallet?

@Graham-C
Copy link
Author

Fixed this now by registering a merchant ID via apple developer and stripe and then including this ID in Apple pay capabilities for my app via Xcode (https://stripe.com/docs/apple-pay/apps). Don't think this is mentioned in the readme which might be worth updating. Thanks

@Jamesmallon1
Copy link

Hi Graham,

Okay so I followed the stripe guide now I am stuck as I am developing in cordova for this which is HTML and CSS etc so how do I use that in xcode?

James

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants