#tushar-PaymentIntents+Customers
1 messages · Page 1 of 1 (latest)
👋 Welcome! Let's start at the beginning and step through here... are you using Checkout, or are you using PaymentIntent directly? If you want to use Checkout, you don't have to create the PaymentIntent or Customer manually.
Hi. I am using CardField UI component provided by the SDK
I am following this documentation: https://stripe.com/docs/payments/save-during-payment
OK, but that would be later in the flow. Sounds like you aren't using Checkout though so you'd want to use https://stripe.com/docs/api/customers/list#list_customers-email to list any Customers with that email and if you have one, use it when creating a PaymentIntent (https://stripe.com/docs/api/payment_intents/create#create_payment_intent-customer)
If you don't have an existing Customer, you'd create one with the given email first and then use it when creating the PaymentIntent.
Thanks.
Also if I need to save multiple cards, I have to use the SetupIntents, correct?
You'd use a SetupIntent if you're saving a card without making a payment before saving it. You use a PaymentIntent if you are making a payment at the time.