Search code examples
node.jsfirebasefirebase-authenticationnestjsprisma

How to create a user in Prisma database on firebase auth sign up?


I want to use firebase auth for handling authentication in my React native app, but I already have a REST API implemented in NestJS using prisma as an ORM. Is there a way to create users in my own database when using firebase auth?


Solution

  • The easiest way to do this would be through Cloud Functions, which can be triggered when a user is created. From your implementation of that Cloud Function you'd then call your own REST API to add the user to your database.