#Mathieu-checkoutsession
1 messages · Page 1 of 1 (latest)
Hi! Can you clarify what you mean by "set the name of the payment method on the payment form"?
I'm talking about the card holder name
this field is empty compare to the email which is set by the customer email
can't do the same with name ? set it with the customer name by default but leave it editable so that user can still change it if he wants to ?
Got it! Unfortunately this field cannot be set programatically.
Note that this is not the customer's name, but the name associated with the payment method, which may be different.
ok got it
and also, what are the best practice with session cancellation/retaking session ? is it best to retrieve an existing one from the customer or to recreate a new one ?
That's completely up to you, but there's no downside of creating a new session.
ok i'm asking this because i saw on the documentation api that there are expire, list and retrieve action for this ressource. I was wondering, since creating a new session everytime works well, what use case/benefit could we have from theses actions ?
Also i'm trying to customize the session confirmation page but the parameter CHECKOUT_SESSION_ID isn't being replace properly as mention here https://stripe.com/docs/payments/checkout/custom-success-page#modify-success-url
sorry false alert the braket was encoded on my end with %7B and %7D fix it and it works now
occasionally if you got use case of other developer utilizing the other actions for the checkout session, I'm more than interrested!
Hi there 👋 jumping in as soma needed to step away
This is largely going to depend on the flow that you're trying to achieve. Some users like to forcibly expire past sessions when creating new ones to avoid there being two sessions that a customer could use. Some users also find it beneficial to look at the details of a checkout session later, perhaps to see what products were purchased.
Hi @icy light thanks for your response, at least if as soma said it has no downside to create new one each time, i don't think we are gonna use those actions for now and maybe incorporate them later on with practice.