getAuth(apiKey, tenantId) {
    if (!this.configs_.hasOwnProperty(apiKey)) {
      throw new Error('Invalid project configuration: API key is invalid!');
    }
    // The name of the firebase app. For tenant flow, use tenant ID, for
    // top-level project flow, use the default name "[DEFAULT]".
    const appName = tenantId || undefined;
    // Validates that the UI configuration is available. If tenant ID is null,
    // the top-level project UI configuration key TOP_LEVEL_CONFIG_KEY should
    // be available.
    this.configs_[apiKey].validateTenantId(
        tenantId || UiHandlerConfig.ConfigKeys.TOP_LEVEL_CONFIG_KEY);
    try {
      this.signedInAuth_ = firebase.app(appName).auth();
    } catch (e) {
      const options = {
        'apiKey': apiKey,
        'authDomain': this.configs_[apiKey].getAuthDomain(),
      };
      const app = firebase.initializeApp(options, appName);
      app.auth()['tenantId'] = tenantId;
      this.signedInAuth_ = app.auth();
    }
    return this.signedInAuth_;
  }
Returns the Auth instance for the corresponding project/tenant pair.
@param {string} apiKey The API key.
@param {?string} tenantId The tenant ID, null for top-level project flow.
@return {!firebase.auth.Auth} The Auth instance for the given API key and
    tenant ID.
@override