Search code examples
firebasefirebase-cli

Firebase CLI database:get request always return null


I am the owner of the firebase project from which I am trying to fetch the data, e.g., firebase database:get /orders. However, the request always returns null. I tried to set up different roles https://console.cloud.google.com/iam-admin/iam?project=[myproject] with no luck. I have only one firebase project and it is selected as I can see in firebase list. I can deploy functions and app from the Firebase CLI.


Solution

  • You should check that your /orders path exists in Realtime Database and not Firestore. The command firebase database:get is for interacting with Firebase Realtime Database only, not Firestore.