User Authentication by Firebase

This Authentication component makes it easy to allow users to sign in/up to your app using email address and password, and manage events (access, progression) based on user data.

You need to create a Firebase account to use this component.

Sign in/register to the Firebase console and follow the instructions below.

Configure Firebase console 

Create new project

Follow these instructions to create your application in the Firebase interface. Some of these informations will be required for configuring the component within PandaSuite Studio.




Enable Email / Password Sign in

In the Firebase console, go to Authentication and the tab "Sign-In Method". Enable Email/Password as shown below.


Add Authentication component

In PandaSuite Studio, click Components and choose Authentication. Open the Properties window and copy/paste informations from the Firebase console. 




Options of the Authentication component 

These are the options of the Authentication component.

Force authentification after (hours)

Force authentification after (hours) is the number of hours after identification where the session remains valid (even without an internet connection). After this number of hours, an internet connection will be required to continue.

If the session is still valid, the user won't need to re-login. By default, the value of 0 creates an infinite session.

Force email verification

Force email verification is an additional step of email validation where the person receives an email with a validation web link. This step will be required before accessing the application.

Advanced user fields 

Advanced user fields are other fields required for the user registration (position and company).

If you choose this option, you need additional configuration steps in Firebase. Because these fields are stored in a specific Firebase database that you must create beforehand.

Go to Database and Create new database.


Choose test mode.



Go to Rules tab and update the security rules so that you are not blocked after 30 day. Copy-paste the code below:

<span style="font-weight:400">rules_version = '2';<br>service cloud.firestore {<br>  match /databases/{database}/documents {<br><br>   // This rule allows anyone on the internet to view, edit, and delete<br>   // all data in your Firestore database. It is useful for getting<br>   // leaves your app open to attackers. At that time, all client<br>   // requests to your Firestore database will be denied.<br>   //<br>   // Make sure to write security rules for your app before that time, or else<br>   // your app will lose access to your Firestore database<br>   match /users/{userId} {<br>    allow read, write: if request.auth.uid == userId<br>  }<br> }<br>}</span>


Show communication and usage terms 

Show communications and usage terms are the addition of a checkbox for the validation of the conditions of use. A new event is exposed (onTermsClicked) to display them in the studio.

Create events based on user data

Associate data with users as a trait from the studio. Traits are related to the concept of markers and can be useful for a very large number of uses such as saving a progression or managing accesses.

One advantage is that data can be modified outside the application by another system. You just have to use the Firebase APIs. And it works in real time.

First start by adding a marker, it automatically creates a new trait.


Be careful when defining the name of the trait since it is used in the database storage. Be sure to rename it to match your usage. You can ignore the ID, it just has to be unique.


Checkboxes are related to the triggering behaviour of your marker. In our example, it will be triggered at its creation or at its initialisation. You need to add another one with the same trait name to manage deletion for example.

Action is also available on this marker. It corresponds to its triggering and/or suppression depending on its configuration.


Still need help? Contact Us Contact Us