Firebase Auth-Basic

Last Updated: 06/10/2021

ACTIONS

Global

Applies to all three plugin types-BASIC, PRO & Mobile PRO

  • Sign Out
    Signs/Logs out the currently signed in User.

Error

Manage errors

  • Clear Error Expressions
    Clears the last data of expressions that are used to get error messages or codes such as:
    errorCode, errorMessage, errorActionCode, errorCodeAt, errorMessageAt.

OAuth-Popup

OAuth service that opens a popup window

NOTE: This works in Browser HTML5 Export only. Refer to Firebase Auth-Pro for iOS/Android Exports.


  • Sign in with OAuth (Popup)
    Sign in using a Popup Window to authenticate with service providers such as Google, Facebook, Apple, Twitter, GitHub, Microsoft or Yahoo.
    NOTES:
    1.
    This action creates a new user account if an account for the user does not exist. If user account exists, it will simply sign in.
    2
    . If an email of a service provider already exists, you can't Sign up with another service provider having the same email. For eg., let's take you have Google and Facebook having the same email address. Once created an account with Google, you can't create an account with Facebook. In this case, you need to Link service providers. To Link an new service provider to an old one, you will need Firebase Auth-Pro.

    PARAMETERS (1):

      • {Provider: combo-list} - Choose an OAuth Provider from list.

Password Auth

Authentication services that require passwords

  • Send Reset Password Email
    Send an email to the user containing a link that would allow the user to reset his/her password.

    PARAMETERS (1):

      • {Email: string} - Enter an email.


  • Send Verification Email
    Send an email to the user containing a link that would allow the user to verify his/her email.


  • Sign Up (Email & Password)
    Sign up/Create a new user account using an email and a password.

    PARAMETERS (2):

      • {Email: string} - Enter an email.

      • {Password: string} - Enter a password.


  • Sign In (Email & Password)
    Sign in an existing user using an email and a password.

    PARAMETERS (2):

      • {Email: string} - Enter an email.

      • {Password: string} - Enter a password.


  • Sign Up (Username & Password)
    Sign up/Create a new user account using an username and a password.
    NOTE: This action is originally built using the Email & Password Auth provider. So it can be used with other ACEs related to email & password Auth will work with Username & Password. For eg.- Expressions such as email will return value- username@anydomain.com

    PARAMETERS (3):

      • {Username: string} - Enter username.

      • {Password: string} - Enter a password.

      • {Any Domain: string} - Enter any domain name. Must be in the format anydomain.com (For eg.- sparsha.com)


  • Sign In (Username & Password)
    Sign in an existing user using an username and a password.
    NOTE: This action is originally built using the Email & Password Auth provider. So it can be used with other ACEs related to email & password Auth will work with Username & Password. For eg.- Expressions such as email will return value- username@anydomain.com

    PARAMETERS (3):

      • {Username: string} - Enter username.

      • {Password: string} - Enter a password.

      • {Any Domain: string} - Enter any domain name. Must be in the format anydomain.com (For eg.- sparsha.com)


  • Update Password
    Change user's current password.
    NOTE: This requires recent Sign In. If an error occurs, let the user Sign In again just before updating password.

    PARAMETERS (1):

      • {New Password: string} - Enter a different password.

Phone Auth

Authentication service using Phone OTP messaging.

NOTE: This works in Browser HTML5 Export only. Refer to Firebase Auth-Pro for iOS/Android Exports.


  • Get OTP
    Get an OTP message for Signing in with Phone. Firebase sends this message to the user's device.
    NOTE: reCAPTCHA must be Verified before this action can be used.

    PARAMETERS (1):

      • {Phone Number: string} - Enter a phone number. Must include Country Phone Code


  • Submit OTP
    Submits the OTP message received by user to Firebase Server, and Signs in after verification.
    NOTE: This action creates a new user account if an account for the user does not exist. If user account exists, it will simply sign in.

    PARAMETERS (1):

      • {Phone Number: string} - Enter a phone number. Must include Country Phone Code


  • Verify reCAPTCHA
    This starts the process of verification of reCAPTCHA, necessary before OTP can be sent to mobile device.

    PARAMETERS (1):

      • {Theme: combo-list} - Choose Light or Dark Theme According to your Project.


User Profile/Account

Manage User Profile Data

  • Delete User Account
    Deletes an user account from the Firebase Authentication Server.
    NOTE: Any user generated data stored in the Realtime Database Server won't be deleted.


  • Update Profile
    Update profile data

    PARAMETERS (
    2):

      • {New Username: string} - Enter a new username. (Leave blank "" if you don't want to update this field)

      • {New Display Pic Url: string} - Enter url of the new profile picture. (Leave blank "" if you don't want to update this field)


  • Update Email
    Change user's current email.
    NOTE: This requires recent Sign In. If an error occurs, let the user Sign In again just before updating email.

    PARAMETERS (1):

      • {New Email: string} - Enter a different email.


CONDITIONS

Global

Applies to all three plugin types-BASIC, PRO & Mobile PRO

  • Is Signed In
    Checks if any user is currently Signed In


  • On Signed Out
    Triggers when an user Signs Out successfully.

Common

Applies to only this plugin. Related to all Auth Service Providers available in the plugin.

  • On Signed In (Implicit)
    Triggers when an user Signs In implicitly using actions such as:
    Sign in with OAuth (Popup),
    Sign Up (Email & Password),
    Sign In (Email & Password),
    Sign Up (Username & Password),
    Sign In (Username & Password),
    Submit OTP

Error

Manage errors

  • On Any Error
    Triggers when an error occurs at any action.


  • On Error At
    Triggers when an error occurs at a specified action.

    PARAMETERS (1):

      • {ActionCode: combo} - The code name of the action where the error occurred.

Password Auth

Authentication services that require passwords

  • On Reset Password Email Sent
    Triggers when a reset-password email has been sent successfully to the user.


  • On Signed Up
    Triggers when user Signs Up with either Email & Password or Username & Password methods.


  • On Update Password
    Triggers when the password has been updated successfully.

Phone Auth

Authentication service using Phone OTP messaging

  • On OTP Sent
    Triggers when
    the OTP has been successfully sent to the mobile number.
    NOTE: It might need to a few seconds or minutes to receive the SMS.


  • On reCAPTCHA Verified
    Triggers when reCAPTCHA has been verified successfully.

User Profile/Account

Manage User Profile Data

  • Is Email Verified
    Checks whether the email address provided by the user is verified.


  • On Email Verification Sent
    Triggers when a verification email has been sent successfully to the user.


  • On Update Email
    Triggers when the Email has been updated successfully.


  • On Profile Updated
    Triggers when either Username or Profile Pic URL or both has been updated successfully.


  • On User Account Deleted
    Triggers when the user's account has been deleted successfully.


EXPRESSIONS

Error

Manage errors

NOTE: Here's the List of all ActionCodes:
"sign-up-email"
"sign-in-email"
"sign-up-name"
"sign-in-name"
"update-email"
"update-password"
"verify-email"
"reset-password"
"render-recaptcha"
"get-otp"
"submit-otp"
"popup-google"
"popup-facebook"
"popup-apple"
"popup-twitter"
"popup-github"
"popup-microsoft"
"popup-yahoo"
"update-profile"
"delete-user"
"sign-out"


  • errorActionCode
    Get the ActionCode of the last occurred error.


  • errorCode
    Get the Error Code of the last occurred error.


  • errorCodeAt
    Get the Error Code of the last occurred error at an ActionCode.

    PARAMETERS (1):

      • {ActionCode: string} - The code name of the action where the error occurred.


  • errorMessage
    Get the Error Message of the last occurred error.


  • errorMessageAt
    Get the Error Message of the last occurred error at an ActionMessage .

    PARAMETERS (1):

      • {ActionCode: string} - The code name of the action where the error occurred.

User Profile/Account

Manage User Profile Data

  • email
    Email of the current user stored in the Firebase Authentication Server.


  • picURL
    Display Picture URL of the current user stored in the Firebase Authentication Server.


  • provider
    Auth Provider ID the user has been currently signed in with.
    NOTE: Here's a list of all available Provider IDs:
    "password"
    "phone"
    "google.com"
    "facebook.com"
    "twitter.com"
    "github.com"
    "apple.com"
    "yahoo.com"
    "hotmail.com"


  • userID
    Auth ID of current user stored in the Firebase Authentication Server.


  • userName
    Username of the current user stored in the Firebase Authentication Server.


  • userPhoneNumber
    Phone number of the current user stored in the Firebase Authentication Server.


PROPERTIES

General

  • Choose SDK
    Choose the Firebase SDK Plugin Object you want the Firebase Auth Plugin to connect with