#Zashs
1 messages · Page 1 of 1 (latest)
Hi there 👋 let's take this bit by bit.
- Payment Intents don't directly expire. You can make a request to cancel a Payment Intent if you no longer want to use it to process a payment.
https://stripe.com/docs/api/payment_intents/cancel
You mentioned car rentals specifically, which tend to authorize a payment up front, but then actually collect the payment later. Is that what you intend to do?
Yes it is
Alright, so your concern isn't the Payment Intent expiring, it's the authorization from the issuing bank that may expire.
Yes probably
It is, that's the primary concern with a flow where you separate the confirmation (authorization) step and the capture (collecting the funds) step of processing a payment. Our flow for that is discussed here:
https://stripe.com/docs/payments/place-a-hold-on-a-payment-method
The other factor here, is that you said you also want to increment what you want to charge, so you would need the functionality discussed here as well:
https://stripe.com/docs/payments/incremental-authorization
This feature is available if you're on certain pricing plans already. If you aren't on that, you will likely need to reach out and request access via the email address provided near the top of the page.
Sorry, i don't want to increment, i want from the 300€, demand 200€ and return 100€ as canceling the payment intent
Oh, sorry about that, in that case you just need the first flow I linked.
I want the first feature place-a-hold
Yes
It says expires after 7 days by default, but i didn't understand how to change that time
Gotcha, longer authorization windows are also a feature that are available to specific pricing plans or need to be requested, but it's discussed here:
https://stripe.com/docs/payments/extended-authorization
To explain, i use a wisePOS E to do the payment, example of the code to create payment intent
$intent = $stripe->paymentIntents->create([
'amount' => $json_obj->amount,
'currency' => 'eur',
'payment_method_types' => [
'card_present',
],
'capture_method' => 'manual'
]);
And in thi way
$stripe->paymentIntents->create([
'amount' => 1099,
'currency' => 'usd',
'payment_method' => 'pm_card_visa',
'confirm' => true,
'capture_method' => 'manual',
'expand' => ['latest_charge'],
'payment_method_options' => [
'card' => ['request_extended_authorization' => 'if_available'],
],
]);
I can extend the bank authorization until the limits of each card, is that it?
This is server-driven
I use the terminal to get the card information and create the payment intent, sorry didn't ssaid sooner.
What does it change, how can i do it?
Sorry, the server is busy at the moment, I was in another thread. I'm trying to find the docs specific to separating authorization and capture for Terminal payments, the flows I was providing you with before were for online payments rather than in person payments.
This is the guide for extended authorizations with Terminal:
https://stripe.com/docs/terminal/features/extended-authorizations
So with this code:
$stripe->paymentIntents->create([
'amount' => 1000,
'currency' => 'usd',
'payment_method_types' => ['card_present'],
'capture_method' => 'manual',
'payment_method_options' => [
'card_present' => ['request_extended_authorization' => true],
],
]);
I can do it and it will extend until the bank card limit, right? Do i need to specify the time?
Correct
Thank you very much for your help, just on point.