#chibidragoon
1 messages · Page 1 of 1 (latest)
Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- chibidragoon, 4 days ago, 15 messages
Hi, what do you mean by 'it's not possible'? You can still pass the default payment method id when you create the invoice, https://stripe.com/docs/api/invoices/create#create_invoice-default_payment_method. What are you really looking to do here? What part of Checkout Session is not solving your business use case? Can you add a bit more details?
I do not have a payment method since the user wishes to create a new card to add to his account.
👋 stepping in
the issue with checkout session is that my invoice has alot of line items and i do not wish to create new poducts for each line ( i talked with someone a long time ago and was told that that's how it works)
So you can always just collect a PaymentMethod without charging via a Checkout Session using mode: setup
However I still don't really understand the limitation here
yes that's what i did to get my card manually in another page
I am creating a air bnb clone and when the user is about to make an order, he might now have a card available already. Because he already entered everything in the form, I cannot leave the page to go to a checkout session because when i come back, i will have lost everything to finish the transaction.
Okay so you already collected the PaymentMethod previously?
i have another page where i do a checkout session to get the card but my user could add a card while he's trying to make a transation also. My issue is that i cannot create a card while remaining in the page
You can if you use Elements instead of Checkout, or use Embedded Checkout.
There are ways to collect without redirecting for sure
ok, all i need is to have the payment method available when i create my invoice basically
everything is made, it's just because i upgraded my api version so the way i was adding it is now blocked
Alright well you mostly want to look at https://stripe.com/docs/payments/save-and-reuse which shows you how you can collect a PaymentMethod
It lays out the two options above
i checked that page a long time ago, guess it was the way all along then
the issue with what was sent, is that checkout session needs redirection urls
when i check the embedded option, I see a return_url also
i found this, could be my answer
https://stripe.com/docs/payments/checkout/custom-redirect-behavior?locale=fr-CA
Yep you can control it in that way if you desire