Firestore - How to Create 2 document with same document reference id in 2 separate collections

Hi.

I have 2 collections users & subscriptions .

users -> this is created on user sign up

subscriptions -> this is created once i generate a customer id in stripe through their api

I want both of these documents to have the same document reference no. for ex: in the screenshot you can see that the uid (which is the doc reference no of users doc) & document reference no (auto generated) are different . I want the document reference no to be: owSxGZl11Lfg4pNVVJ5IdWjmP5y1

How do i assign a custom document reference no. while creating a new document ?

2
4 replies