#thefyrewire-PMs
1 messages ยท Page 1 of 1 (latest)
๐ happy to help
- as per our docs https://stripe.com/docs/api/payment_methods/detach:
Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.meaning that once you detach a PM it's useless in Stripe. - Elements by itself wouldn't allow that, but you can build your app in a way to use Elements with custom flows that you would have to create to show PMs and give your customer the possibility to delete (detach), add or replace (detach then add)
Ah thanks! So with the detach and add method, is there any option to pre-fill Elements to give the experience of "editing"? Or is there a way I can show my own form but then pass the data to Elements in the background and send that way?
you wouldn't have access to the card info
it's not PCI Compliant
you would leave the Elements component empty and they'd have to fill in new card details
Gotcha gotcha. It almost feels like we'd need an "EditIntent" that you create by passing the payment method ID, then passing the client secret to Elements so it can securely load the card details back only for that customer's eyes, then they could adjust as needed and re-save
In any case the other method should be fine for now, thanks! ๐
that you create by passing the payment method ID, then passing the client secret to Elements so it can securely load the card details back only for that customer's eyes, then they could adjust as needed and re-save
that would never happen, because it would mean that Stripe would have to send the card details to the customer's browser which is again non compliant to PCI standards and in all cases Stripe doesn't save the card number it saves something else (some sort of a token) that we'd use for later payments
In any case the other method should be fine for now, thanks! ๐
let me know if you need any more help
Sorry, another question. From this - https://stripe.com/docs/api/payment_methods/update - does this mean I am able to update specific parts of the payment method like address?
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
you can always edit stuff on the payment method that are available for you
meaning exp_month, exp_year is editable
in the card object
so all of the parameters you see in that page you could use to update a payment method
but we wouldn't touch the initial card info
you could simply show the last4 digits to help your customer identify their card
Ah that's great, thank you!