Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

182
Vistas
firebase authentication for google provider and Authorization Error 401

I try to test signin process with firebase/identity platform from GCP for firebase.auth.GoogleAuthProvider with a simple static website.

When I deploy the website I get

Authorization Error Error 401: deleted_client The OAuth client was deleted.

My webpage with javascript code looks like:

<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>Sample FirebaseUI App</title>
    <script src="https://www.gstatic.com/firebasejs/8.0/firebase.js"></script>
    <script>
      var config = {
        apiKey: "<secret-key>",
        authDomain: "<my-gcp-project>.firebaseapp.com",
      };
      firebase.initializeApp(config);
    </script>

    <script src="https://www.gstatic.com/firebasejs/ui/6.0.0/firebase-ui-auth.js"></script>
    <link type="text/css" rel="stylesheet" href="https://www.gstatic.com/firebasejs/ui/6.0.0/firebase-ui-auth.css"/>
    <script type="text/javascript">
      // FirebaseUI config.
      var uiConfig = {
        signInSuccessUrl: 'https://<my-url-after-success-login>',
        signInOptions: [
          // Leave the lines as is for the providers you want to offer your users.
          firebase.auth.GoogleAuthProvider.PROVIDER_ID
        ],
        // tosUrl and privacyPolicyUrl accept either url string or a callback
        // function.
        // Terms of service url/callback.
        tosUrl: 'https://<my-url-after-success-login>',
        // Privacy policy url/callback.
        privacyPolicyUrl: function () {
          window.location.assign('https://<my-url-after-success-login>');
        }
      };

      // Initialize the FirebaseUI Widget using Firebase.
      var ui = new firebaseui.auth.AuthUI(firebase.auth());
      // The start method will wait until the DOM is loaded.
      ui.start('#firebaseui-auth-container', uiConfig);
    </script>
</head>
<body>
<!-- The surrounding HTML is left untouched by FirebaseUI.
       Your app may use that space for branding, controls and other customizations.-->
<h1>Welcome to My Awesome App</h1>
<div id="firebaseui-auth-container"></div>
</body>
</html>

When I call the deployed web-page I have this "Sign in with Google" button. But when I click it this 401 error appears.

The values for apiKey: "", authDomain: ".firebaseapp.com",

I copied from the GCP console under "APPLICATION SETUP DETAILS" Google is the only provider enabled in "Identity Platform".

Any hint is welcome. https://github.com/firebase/firebaseui-web seems a more systematic intro to this topic I just thought I get it running with minimal effort.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

My setup process was not complete. Now it is working.

https://firebase.google.com/docs/web/setup I got also 4 additional lines for the config variable now.

projectId: "<my_project_id>",
storageBucket: "<my_value>",
messagingSenderId: "<my_id>",
appId: "<my_app_id>"
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda