#nacho_446

1 messages · Page 1 of 1 (latest)

foggy escarpBOT
ancient meadow
#

Hi there!

#

What's your end goal here? What are you trying to do?

#

If you need a test payment method, then direclty use pm_card_visa. For example create a PaymentIntent and set payment_method: 'pm_card_visa' and it will work directly.

next steeple
#

I’m trying to attach a payment method to a stripe user without making a payment

ancient meadow
next steeple
#

A setup intent now how can I add the payment method to it

ancient meadow
#

I told you above: when you create the SetupIntent, set payment_method: 'pm_card_visa'.

next steeple
#

Ok

#

When I try to retrieve customer payment methods it empty

ancient meadow
#

Can you share the customer ID (cus_xxx)?

next steeple
#

cus_OlKe0usivesmtQ

ancient meadow
#

that's expected, this customer has no payment method set. Can you share the SetupIntent ID (seti_xxx) you created?

next steeple
#

No I didn’t save it

#

So how can I add the payment method now after the intent

ancient meadow
#

I'm sorry I don't understand.
Step 1: create a customer
Step 2: create a SetupIntent with payment_method: 'pm_card_visa' and the customer property and confirm:true
Step 3: now the customer has a Payment Method saved

#

If you forgot step 2, then it's expected to not work.

next steeple
#

I did not add confirm true

#

And return_url

#

It worked thanks

ancient meadow
#

Happy to help 🙂

next steeple
#

So if my Frontend is doing this will he need to do the setup intent and the rest, or he just uses the sdk and do a payment method create to store it and send the id to the backend so I attach with the customer