The documentation for Firestore batch writes lists only set()
, update()
and delete()
as permitted operations.
Is there no way
Create the reference to the collection in which you are going to add the batch data We loop over the req.body using forEach and set the each data to be added in to the collection using the set method
We commit the data and save the data to the collection using the commit method and on success ,send a success response.
cloud firestore