This library requires B4A v6+.
It allows the users to sign in to your app with their Google account (more identity providers will be added in the future).
		
		
	
	
		 
	
Like all Firebase services it is quite simple to integrate this service in your app.
1. Follow this tutorial and make sure to add the Firebase Auth manifest snippet: https://www.b4x.com/android/forum/threads/integrating-firebase-services.67692/
2. This service requires that the signing key SHA1 signature is set in the Firebase project settings:
	
	
	
		
		
		
		
	
	
		 
	
You can find this value under Tools - Private Sign Key, in the signature field:
	
	
	
		
		
		
		
	
	
		 
	
Initialize the FirebaseAuth object and call SignInWithGoogle to sign in. Note that the user will be signed in automatically when the program restarts.
	
	
	
	
	
	
	
		
			
			
			
			
			
		
	
	
	
		
	
	
		
	
Next:
- Combine Google and Facebook: https://www.b4x.com/android/forum/t...seauth-to-support-facebook.67954/#post-430482
- Server verification of signed in users: https://www.b4x.com/android/forum/t...end-authentication-for-signed-in-users.68672/
FirebaseAuth is an internal library now. It is preinstalled with the IDE.
Updates:
v3.22 - Adds missing dependency: androidx.tracing:tracing
			
			It allows the users to sign in to your app with their Google account (more identity providers will be added in the future).
Like all Firebase services it is quite simple to integrate this service in your app.
1. Follow this tutorial and make sure to add the Firebase Auth manifest snippet: https://www.b4x.com/android/forum/threads/integrating-firebase-services.67692/
2. This service requires that the signing key SHA1 signature is set in the Firebase project settings:
 
	You can find this value under Tools - Private Sign Key, in the signature field:
 
	Initialize the FirebaseAuth object and call SignInWithGoogle to sign in. Note that the user will be signed in automatically when the program restarts.
			
				B4X:
			
		
		
		Sub Process_Globals
   Private auth As FirebaseAuth
End Sub
Sub Globals
   Private lblName As Label
End Sub
Sub Activity_Create(FirstTime As Boolean)
   If FirstTime Then
     auth.Initialize("auth")
   End If
   Activity.LoadLayout("1")
   If auth.CurrentUser.IsInitialized Then Auth_SignedIn(auth.CurrentUser)
End Sub
Sub btnSignIn_Click
   auth.SignInWithGoogle
End Sub
Sub btnSignOut_Click
   auth.SignOutFromGoogle
   lblName.Text = "Goodbye!"
End Sub
Sub Auth_SignedIn (User As FirebaseUser)
   Log("SignedIn: " & User.DisplayName)
   lblName.Text = "Hello: " & User.DisplayName
End SubNext:
- Combine Google and Facebook: https://www.b4x.com/android/forum/t...seauth-to-support-facebook.67954/#post-430482
- Server verification of signed in users: https://www.b4x.com/android/forum/t...end-authentication-for-signed-in-users.68672/
FirebaseAuth is an internal library now. It is preinstalled with the IDE.
Updates:
v3.22 - Adds missing dependency: androidx.tracing:tracing
Attachments
			
				Last edited: 
			
		
	
							 
				 
 
		 
 
		 
 
		 
	 
 
		 
 
		 
			 
 
		 
 
		 
 
		 
 
		