#RiderFx3-authentication
1 messages · Page 1 of 1 (latest)
Hello
Lot of customers get a payment decline before I can create the payment intent
When I try to attach the source to the customer I get this error : card_error_authentication_required
Did you build your integration in a way that allows a customer to provide authentication?
But I can't trying to authenticate before creating payment intent ....
To clarify - using sources is a really old integration path, and so if you're building a net new integration I wouldn't expect you to be using Sources
Is this an older integration that has suddenly started breaking? Or is this a new integration?
Yep this is my worflow :
- Get Stripe token
- Retrieve or Create user
- Attach the source to the customer
- Create Payment Intent
- Confirm payment or go to 3DS validation
- Confirm or Fail
You here ?
Sorry I'm talking to multiple folks at once
and again, is this a new integration, or an old one?
Is there a reason you haven't fully moved over to Payment Intents + Payment Methods?
Yes it is an old integration and the client don't want to pay for update but since this year we have errors we didn't have last year
I actually use Stripe.js with Card Element is this a problem ?.
No, that's not a problem - give me a few minutes while I think through a solution for you
Everything works great except for some client who get their card decline for no reason
The problem is that the card is declined BEFORE trying the Payment intent
Gotcha - I'd recommend fully moving to Payment Methods, but in the mean time if you want to guarantee no authentication is needed for attaching a source I think you can pass 'validate: false' when you attach it to the customer
This tips is not writed in the API Docs
Yes, it's undocumented
On this endpoint right ?
When I update the customer by passing the source
And just to know, if I want to use payment method, Stripe.js will prompt the authentication popup BEFORE I can charge the payment on server-side ?
Yes, that's where you'd use validate: false
and if you were to fully move over to payment methods you wouldn't even create a payment method separately - it would be created for you when the payment intent is confirmed and can be automatically attached to the customer
public function updateCustomer( $customer_id, $source ){
$datas = [
'source' => $source,
'validate' => 'false'
];
$url = 'https://api.stripe.com/v1/customers/'.$customer_id;
return $this->curl( $url, $datas );
}
OK I had to write like this
👍
The only problem is I can't reproduce the card_error_authentication_required error
Is there any way to reproduce it for testing ?
No, I don't believe there's a way to reliably reproduce it for testing
How can I be sure that the argument validate: false have any effect ?
There isn't a good way - this is just a workaround. That's why the better solution is really just to upgrade your integration to properly use Payment Methods
The problem with Payment Method is that I have a lot of custom logic server-side before validate payment
You should still be able to find a solution that works with Payment Methods though
Okay thanks I will work on that