I enforced Firebase AppCheck for Firestore.
Now, when I try to access data, I get an error:
firebase .firestore() .doc(firestoreRoot.configs.priceIds._pathUrl) .get() .then((v) => console.log(v.data()));
In Firebase, it says all my requests are unverified:
This only happens for firestore.
Is there something else I must do?
I enabled AppCheck in my app using:
const appCheck = firebase.appCheck(); appCheck.activate("MY_SITE_KEY", true);
I tried disabling AppCheck in the firebase console, and now all my requests are accepted.
Advertisement
Answer
The firebase documentation says:
Important: Cloud Firestore support is currently available only for Android and iOS clients. If your project has a web app, don’t enable Cloud Firestore enforcement until web client support is available.
Therefore, appcheck cannot be used with firestore for web applications.