Closed philipboomy closed 1 year ago
@philipboomy Commerce stripe plugin only supports credit card payments for now. We have plan to add more payment integration but can't give a specific timeline.
As mentioned in my email as well then I am not happy about this.
Every competitor to Craft Commerce has supported Apple Pay for years. Woocommerce SnipCart Foxy Cart Shopify and so on.
I believe this is something the Stripe plugin should support since Stripe provides this payment type. With the amount of mobile shoppers it is not good that Craft Commerce does not support this instead of for example doing a Shopify integration.
+1
This is a problem for us too.
I managed to integrate Google pay with some custom code but that last bit I can't get over.
The key payment_method
is hardcoded there https://github.com/craftcms/commerce-stripe/blob/develop/src/gateways/PaymentIntents.php#L498 and we can't change it.
Until google pay is supported can you add an event to modify the requestData
before it's sent to Stripe ?
For others that may need this, I managed to get this working by cloning the plugin and replacing this line 498 by :
if (substr($paymentMethodId, 0, 4) == 'tok_') {
$requestData['payment_method_data'] = [
'type' => 'card',
'card' => [
'token' => $paymentMethodId
]
];
} else {
$requestData['payment_method'] = $paymentMethodId;
}
For others that may need this, I managed to get this working by cloning the plugin and replacing this line 498 by :
if (substr($paymentMethodId, 0, 4) == 'tok_') { $requestData['payment_method_data'] = [ 'type' => 'card', 'card' => [ 'token' => $paymentMethodId ] ]; } else { $requestData['payment_method'] = $paymentMethodId; }
Thanks for sharing this. I am still waiting for core team to sort this out. They have promised it several times and over many months so I am sure it will come soon.
We've been wanting this too. It would be great if the plugin was upgraded to support the newer Payment Element approach
+1 eager to have this also.
+1
We had to go with WP for apply pay due to timing and I hated every minute of it.
Good news! See our announcement:
👏 Awesome news
Description
I am trying to get Apple Pay working but when I pass in the token I get from Stripe to commerce/payments/pay I am getting this error:
A token may not be passed in as a PaymentMethod. Instead, use payment_method_data with type=card and card[token]=tok_xxxxxxxxxLIVKdQECvF.
I am wondering if the Commerce Stripe plugin is supporting Apple Pay?
A quick search shows this: https://stackoverflow.com/questions/72043013/a-token-may-not-be-passed-in-as-a-paymentmethod-instead-use-payment-method-da
Additional info