Merging duplicate Stripe customers

14,899 views
Skip to first unread message

Eugenia

unread,
Jun 12, 2015, 3:53:18 PM6/12/15
to api-d...@lists.stripe.com
We're looking to troubleshoot an issue where there are multiple Stripe customer objects that in fact represent one unique customer. Is there a way to collapse or copy data across these?

Remi J.

unread,
Jun 12, 2015, 4:10:20 PM6/12/15
to api-d...@lists.stripe.com
Hey there,

There's unfortunately no way to merge or copy data from one customer
to another in Stripe like their card details or the charges history if
you already charged them in the past. You'd need to make sure that
from now on you don't duplicate customers so that you always have all
the cards and charges history in the same place. On Stripe's end we
don't ensure unicity of customer by cards or email addresses and
that's something you'd need to do on your end first.

To ensure card unicity, you should look at the `fingerprint` property
on the Token [1] or Card [2] object which uniquely identifies a
specific card number in your account. You'd store this along with the
expiration date (not used when calculating the fingerprint) so that
whenever you get a new card token you can try to match that card to an
existing customer in your account.

I hope this helps but please do not hesitate to get back to me if you
need more details.
All the best,
Remi

[1] https://stripe.com/docs/api#token_object
[2] https://stripe.com/docs/api#card_object
> --
> You received this message because you are subscribed to the Google Groups
> "Stripe API Discussion" group.
> To post to this group, send email to api-d...@lists.stripe.com.
> Visit this group at
> http://groups.google.com/a/lists.stripe.com/group/api-discuss/.
>
> To unsubscribe from this group and stop receiving emails from it, send an
> email to api-discuss...@lists.stripe.com.

Keybee Hosting

unread,
Dec 6, 2017, 10:09:31 AM12/6/17
to Stripe API Discussion
Hello,
I was looking to merge 2 stripe accounts of the same client and I come across this old thread. I was wondering if anything has changed.
Thank you.
Nadia

Remi J.

unread,
Dec 6, 2017, 10:11:53 AM12/6/17
to api-d...@lists.stripe.com
Hello Nadia,

If you are speaking of customers in Stripe then the logic has not changed and what I described at the time still holds today! If you meant merging two separate Stripe accounts by moving all customers from one to the other, then this is something the support team can help you with here: https://support.stripe.com/email

Hope this helps!
Remi

To unsubscribe from this group and stop receiving emails from it, send an email to api-discuss+unsubscribe@lists.stripe.com.
To post to this group, send email to api-d...@lists.stripe.com.

Aaron Michal

unread,
Dec 6, 2017, 12:19:40 PM12/6/17
to api-d...@lists.stripe.com
Not sure it helps but we do generally is "retire" one of the IDs by adding a "merged_into_stripe_id" in our models and then have a link in the UI to view the older history by searching for all customers that were "merged" into (really just linked) to the current one. Quick  and easy and doesn't modify history. 



To unsubscribe from this group and stop receiving emails from it, send an email to api-discuss+unsubscribe@lists.stripe.com.

To post to this group, send email to api-d...@lists.stripe.com.

Gabrielle Muzel

unread,
Nov 10, 2020, 1:53:18 PM11/10/20
to Stripe API Discussion, ami...@greenriver.org
Hey Aaron, 

Would you be able to send any sort of links to FAQs or steps on how to: ""retire" one of the IDs by adding a "merged_into_stripe_id" in our models and then have a link in the UI to view the older history by searching for all customers that were "merged" into (really just linked) to the current one."

Thank you!
Gabrielle
To unsubscribe from this group and stop receiving emails from it, send an email to api-d...@lists.stripe.com.

Remi J.

unread,
Nov 10, 2020, 2:07:40 PM11/10/20
to Stripe API Discussion
Hello Gabrielle,

Replying quickly since this email thread is quite old and I'm not sure if Aaron will be able to chime in, hope it's okay.

How to set this up is really dependent on your own application though so I'm not sure a FAQ would really fit your needs here and I don't know of a specific one. Our recommendation here is to have one customer be the canonical one and then have a separate column or link in your database to old/deprecated customers which maps to what Aaron was describing. The idea is that you have cus_ABC represent John Doe but you also have a link to cus_111 and cus_2B2 so that you can for example aggregate their past charges if needed. On legacy customers, you could set custom metadata to link to the canonical one so that in the Dashboard you can quickly find the real customer to use.

I'm sorry that this is a bit vague but hopefully it puts you in the right direction!
Best,
Remi

--
Reply all
Reply to author
Forward
0 new messages