Can't connect to Firebase Database temporarily - firebase

Sometimes when I load my app, I just can't seem to connect to Realtime Database using REST APIs. This is only a problem I have been having very recently; it mostly always works but sometimes, randomly, just cannot resolve the destination host.
During one of these times, I have tried using my browser to go to the Firebase Realtime Database page manually: https://project-id.firebaseio.com/
This page should redirect me to my project console. Instead, it just returned a 404.
So I think the problem has nothing to do with my code but it is something Firebase Server-side... what could be the problem?

Related

How to connect fitbit sdk to firestore database?

I'm trying to set up an app using the Fitbit SDK, which I want to use to pull data down from my firestore database to the companion app in the fitbit application. However I am encountering an issue. The code is returning the following errors:
[15:29:50] Companion: Uncaught (in promise) TypeError: Cannot read property 'getEntriesByType' of undefined
new dn at node_modules/#firebase/webchannel-wrapper/dist/index.js:66,585
new Gn at node_modules/#firebase/webchannel-wrapper/dist/index.js:82,64
new gr at node_modules/#firebase/webchannel-wrapper/dist/index.js:95,30
pr.g at node_modules/#firebase/webchannel-wrapper/dist/index.js:94,385
Ao.ho at node_modules/#firebase/firestore/dist/index.esm2017.js:12548,19
Oo.Ko at node_modules/#firebase/firestore/dist/index.esm2017.js:13025,9
Oo.Uo at node_modules/#firebase/firestore/dist/index.esm2017.js:12978,23
? at node_modules/#firebase/firestore/dist/index.esm2017.js:12968,13
[15:30:00] Companion: [2022-08-04T14:30:00.245Z]
#elixr firebase
/firestore: Firestore (9.9.1): Could not reach Cloud Firestore backend. Backend didn't respond within 10 seconds.
This typically indicates that your device does not have a healthy Internet connection at the moment. The client will operate in offline mode until it is able to successfully connect to the backend. (node_modules/#firebase/logger/dist/esm/index.esm2017.js:78,9).
Which I can't seem to find a fix for online. The added complexity is with the environment for developing the code for this app is somewhere between node.js and web 9, so when looking at the docs on the website I have to use a mixture of the two guides to try figure out how to get it to work. The additional awkard part about this is that firestore doesn't enable app check for something that's neither iOS, Android or Web, while this could technically pass as a web app, I would need to somehow register a website just to get the recaptcha key from to then enable app check. But would have no way to verify the user each time using app check.
Is this even possible to do, as there's no docs on either end of fitbit or firebase to help in this sort of situation. I had though of potentially using direct websockets but don't know the restrictions on that kind of data transfer.
Does anyone know a work around/ how to remedy this?

Flutter StreamBuilder shows Firebase data even when I'm offline

This is not a problematic question, it was asked because just wanted to know what's actually going on behind it, I can't find an answer in any documentation.
When i open the app without internet it shows the data from firebase, i try to restart then it also shows, i try to clear the cache but it shows the data like it shows from the local database, Why is this happening, is there a built-in local storage or something in Firebase Flutter?
Firestore SDKs cache any data that they've recently seen, as well as any pending writes from the local client that haven't been synchronized to the server yet. On mobile clients (iOS and Android) this cache is enabled by default, while on web you can enable it with an API call.
For more on this, see the Firebase documentation on accessing Firestore data while you're offline.

ERR_CERT_DATE_INVALID errors on Firebase Real Time Database

We got a weird case where some users are reporting being blocked from being able to connect to our website which has a Firebase backend.
When the users look at there dev console it firing out ERR_CERT_DATE_INVALID attached to the database point which doesn't make a lot of sense to us why the database would be having what I though is SSL error and only for some users.
I've attached the users are seeing about but haven't been able to repo the issue ourselves

Retrieve error ERR_NAME_NOT_RESOLVED from firebaseio.com

Network Firebase Error
Hi, I got some problem with firebase realtime database. When I try my firebase configuration (prod) on local or staging (same server as production), it's not show this error. But when I deploy it to production, error occurs when I try hit firebaseio.com. Can someone explain it?
The server I use is AWS CloudFront (staging and production).
Firebase I use is here https://www.npmjs.com/package/firebase with Vue 3
In the screenshots there's an additional %27%2C after firebaseio.com in the URL, which is not supposed to be there. So it looks like you have a ', in the database URL that you initialize Firebase with, which are not supposed to be there. Remove those and this problem should disappear.

Single page application with Firebase security

I'm sorry if it's a duplicate question, but I haven't found any answers that answer my question.
I use firebaseConfig to initialize firebase in my app. As far as I know, there's no way to secure keys when using only client-side code so anyone may access my firebase config.
I've read about security rules. But what prevents bad guys from siging up in my app, copying my config, and starting local server, logining in and accessing database data?
I thought about authDomain, but it allows using localhost, even if I can prevent from sending requests from localhost, the app needs maintaining so it's required to use localhost from time to time.
So the questions is how to prevent from signin-up, and using firebase key on localhost.
By the way, is it secure enough to use stripe API payments without in my single page app?

Resources