#NEWJOSSY
1 messages · Page 1 of 1 (latest)
hi! what's the problem exactly?
I can have 2 the same cards, only thing which is different is payment_method.id
Like I can add two cards with same card number, expire date and other info and they will be added as different payment methods
yep, we don't enforce that cards have to be unique
there's a fingerprint field : https://stripe.com/docs/api/payment_methods/object#payment_method_object-card-fingerprint which identifies when two pm_xxxs are the same underlying card
it depends overall how you integrate but you can check that value on a customer's existing payment methods before adding one
Can you give more detailed info about this fingerprint? How it should be used?
sure, what specific question do you have about it?
Finger print should only be used when I am getting list of payment methods, right ?
not sure what you mean. It's a field returned on the PaymentMethod object
if you list PaymentMethods, each one will have a fingerprint
depending on how yur integration works, you might create a new PaymentMethod from the input the customer enters, and you can compare the fingerprint on that PaymentMehod to the ones you get from listing other PaymentMethods on a certain Customer object.
Ok, I think I understood. So I need to compare finger print of existing payment method and the newly created, is it right?