#rohailkamran
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.
- rohailkamran, 1 hour ago, 5 messages
- rohailkamran, 16 hours ago, 11 messages
- rohailkamran, 21 hours ago, 11 messages
- rohailkamran, 1 day ago, 104 messages
- rohailkamran, 2 days ago, 50 messages
- rohail-checkout-embedded, 2 days ago, 5 messages
Hello
Yes
We don't de-duplicate Customers (or any objects really) by default
You would want to pass the already-created Customer into the customer parameter if you don't want a new one created
I see, so to de-duplicate customers, I would have to do:
const session = await stripe.checkout.sessions.create({
payment_method_types: ["card"],
mode: "payment",
success_url: req.body.success_url,
cancel_url: req.body.cancel_url,
payment_intent_data: {
setup_future_usage: 'off_session'
},
customer_creation: 'always',
line_items: req.body.items,
metadata:req.body.metadata,
customer: req.body.customer_id
})
Please note, I am still using the always flag.
Is this correct?
You can't use both customer and customer_creation
You use one or the other
So remove customer_creation
And then yes, you have it correct.
I see, gotcha. Thanks!!