What's the difference between the firebase and

2020-05-19 04:37发布

问题:

I want to build a Node.js web app using Firebase (authentication, database and storage). But I get confused on which module should I use, firebase or firebase-admin (or both).

回答1:

The admin SDK runs your code with administrative permissions. This means it bypasses the security rules of your Firebase Database. It also has functionality to manage users and mint custom tokens and can be used to send FCM messages.

If you use the regular (non-admin) Firebase module, you're running as a regular Firebase client and don't have these expanded capabilities.