#sir-paymentmethod-update

1 messages · Page 1 of 1 (latest)

lavish stormBOT
tight wren
#

sir-paymentmethod-update

marble furnace
#

But that would require me to send the address to my backend and process it there, correct?

tight wren
#

correct not other way than doing that

marble furnace
tight wren
#

I think you might be mixing up multiple completely separate concepts here. A Token, a Card, a PaymentMethod are all completely separate API Resources and all work differently.
If you are using PaymentMethod (the pm_123456) in the API, then Card and Token are completely unrelated/separate

marble furnace
#

Aren't tokens supposed to be used to attach new credit card information to a payment method without processing any sensitive data on non stripe servers?

tight wren
#

Not really no, that's a vocabulary mix up I think. Yes a Token can be created client-side to collect card details securely and get a Card Token tok_123. But so can a PaymentMethod (pm_123).

If you are using PaymentMethods and PaymentIntents then you would never look at Card Tokens.

#

@marble furnace does that make sense?

marble furnace
#

Yes, I guess. Its just confusing that the web elements do not provide an update functionality but just a create functionality for payment methods. It looks like the correct flow to update the card or address for an active subscription is to create a new payment method and detach the old one I guess?

tight wren
#

If you are collecting brand new card details from scratch then yes that's what I would do. If you are just updating the address then I would use the Update PaymentMethod API I mentioned earlier, where you send the address to your server and then call that API to set the new one

marble furnace
#

Okay, and what would be the flow to update payment information? I dont want to break PCI compliance by sending any credit card information to my server.

tight wren
#

What you were saying earlier. In that case you create a new PaymentMethod pm_123 and attach it to the Customer for future payments and detach the old one (or keep both)

marble furnace
#

Okay, many thanks for your patience and explanation. I will try my best at implementing it. Have a nice day 👍

tight wren
#

Sure thing, have a great day too!