Reputation: 91
I am currently trying to create a DB on Firebase and I am getting the following error:
{"error":{"code":400,"message":"CONFIGURATION_NOT_FOUND","errors":[{"message":"CONFIGURATION_NOT_FOUND","domain":"global","reason":"invalid"}]}}
I know this is sensible but my code for setting up the database is the following:
<script src="https://www.gstatic.com/firebasejs/8.3.1/firebase-auth.js"></script>
<script src="https://www.gstatic.com/firebasejs/8.3.1/firebase-firestore.js"></script>
<script>
// Your web app's Firebase configuration
// For Firebase JS SDK v7.20.0 and later, measurementId is optional
var firebaseConfig = {
apiKey: "AIzaSyAI6HD2Fa35nSL3wqT1u98TgdykPoU1Vvc",
authDomain: "todo-ca9f2.firebaseapp.com",
databaseURL: "https://todo-ca9f2-default-rtdb.firebaseio.com/",
projectId: "todo-ca9f2",
storageBucket: "todo-ca9f2.appspot.com",
messagingSenderId: "787961698428",
appId: "1:787961698428:web:c2af07085cdd3c9ab491f9",
measurementId: "G-SGPXZS4XET"
};
// Initialize Firebase
firebase.initializeApp(firebaseConfig);
const auth = firebase.auth();
const db = firebase.firestore();
//firebase.analytics();
</script>
<script src="app.js"></script>
I am invoking Firebase in code on the image:
Upvotes: 9
Views: 12784
Reputation: 31
yes goto firebase console and enable your google, facebook and email/password fields
Upvotes: 3
Reputation: 141
Go to the firebase console, navigate to authentication and enable Email/Password. It should work just fine.
Upvotes: 14
Reputation: 3348
Error 400 is related to the client-side.
Your code should work correctly so most likely the issue is that you have not yet enabled the Sign-in method under Authentication in firebase console.
Upvotes: 22