I have a use case in which 1 app will be used by multiple separate companies (franchises) that will have their own marketing and management teams. I need the user to select
It's possible to have multiple Firebase instance in your apps
FirebaseOptions options = new FirebaseOptions.Builder()
.setApplicationId("Your AppId") // Required for Analytics.
.setApiKey("You ApiKey") // Required for Auth.
.setDatabaseUrl("Your DB Url") // If you wanted to
.build();
FirebaseApp.initializeApp(context, options, "CompanyA");
Which you can get Firebase instances by
FirebaseApp appCompanyA = FirebaseApp.getInstance("CompanyA");
You can see the full example use of Auth and Realtime Database using multiple Firebase instance here
I'll leave this solution here which may duplicate with another answers for someone who might need this
Hope this help :)