Questions tagged [firebase-tools]

The Firebase CLI provide a variety of tools for managing, viewing, and deploying Firebase projects, as well as a set of emulators for Firebase products. It's available via the npm module firebase-tools.

The Firebase Command Line (CLI) Tools can be used to:

  • Administer your Firebase account

  • Interact with Firebase Hosting, our product to host your static HTML, JS, CSS, images, etc.

  • Interact with the Firebase Database, to read and write JSON data and deploy security rules

  • Interact with Firebase Storage, to read and write files and deploy security rules

  • Deploy your code to Cloud Functions for Firebase

  • Emulate Cloud Functions, Realtime Database, and Cloud Firestore locally for use in development and testing.

See also:

Related tags

903 questions
3
votes
2 answers

Create and configure Firebase project programmatically

I am building an automation process for my app, which includes creating several new Firebase projects. (After a lot of investigation, I am sure that several projects are needed, and that it cannot be done with just one project). I am looking for a…
3
votes
1 answer

Why firebase emulator function says request body is missing data?

I'm running my local emulator suite and I'm constantly getting error messages for my curl requests. The following command: curl -X POST http://localhost:5001/my-project/us-central1/myFunction \ -H "Content-Type: application/json" \ -d…
Mr.Drew
  • 939
  • 2
  • 9
  • 30
3
votes
3 answers

How to emulate Firebase authentication without an API key

I'm building an open-source project using Firebase's JS SDK. My goal is to allow contributors to run the project locally using the Firebase emulator so that they don't need any real credentials. The Firebase emulator docs specify that "you can run…
3
votes
0 answers

Firebase auth emulator was blocked

I got this error when I using local firebase emulator. blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Private-Network' header was present in the preflight response for this private…
Kaname
  • 51
  • 5
3
votes
0 answers

Firestore Local Emulator not working with Firebase 9 Compat

I recently started the process of upgrading my application to use Firebase 9. I started the process (as recommended here https://firebase.google.com/docs/web/modular-upgrade), by updating all my imports to the Firebase 9 compat modules. That all…
3
votes
1 answer

Firebase Function Emulator Unsupported function type on functionName., Expected either httpsTrigger or eventTrigger

I juste update node 14 to 16. But now i have a Warning in my firebase emulator suite logs for cloud_functions Unsupported function type on functionName., Expected either httpsTrigger or eventTrigger there is the dependancies for the nodejs's…
3
votes
1 answer

Jest useFakeTimers() blocks when used with firebase emulators

I'm trying to use jest.useFakeTimers() to make my firebase + jest tests stable when working with dates and timeouts. However, if I try to read anything from the emulated database the test times out and throws Exceeded timeout of 5000 ms for a test.…
samurai jack
  • 401
  • 1
  • 7
  • 10
3
votes
1 answer

How to Run & Connect to Emulators with Cypress CI on GitHub Actions?

I am trying to run e2e Cypress tests on Github actions. I build functions, run an emulator and start cypress like to: npx nx build functions | firebase emulators:start | nx e2e frontend-e2e --watch This works well on localhost, but fails on GitHub…
3
votes
1 answer

Implementation of Distributed-Counter-Extension for local emulator

The firebase extension for a distributed counter can be directly installed for the cloud and works just fine. To develop new features for an app I need to do this on the emulator to not interrupt the running server. As the firebase extensions simply…
3
votes
1 answer

Firebase Auth emulator does not work after updating version to 9.6.3

We have recently updated firebase to version 9.6.3 from 8.10.0 (also expo from sdk 41 to 44). After the update the app throws this error when using the auth emulator. Uncaught FirebaseError: Firebase: Error (auth/argument-error). at…
roivasot
  • 53
  • 1
  • 4
3
votes
1 answer

Firebase onFinalize doesn't trigger for functions emulator

I'm setting up the env for local development and just testing to see if the emulators are working but my simple test is failing without any errors. // functions/index.js exports.pdftoimg = functions.storage.object().onFinalize(async (object) => { …
3
votes
2 answers

Firebase Functions Initial Hello World Doesn't Compile in TS

I have an existing webapp project hosted in Firebase, and I want to add cloud functions to it. But when I just functions with the command firebase init functions the initial hello-world template it generates doesn't compile in TypeScript because of…
3
votes
2 answers

Firebase Functions Emulator Not Reloading Upon Typescript Transpile

I'm using the firebase emulator suite including the cloud functions emulator, on an angular/fire project. firebase tools 9.23.1. Typescript version 4.5.4. In package.json the main property is "main": "lib/index.js", Development environment is MacOS…
3
votes
1 answer

Firebase Emulator never fires up

I have the following versions npm - 8.1.0 java - openjdk 11.0.13 2021-10-19 LTS I'm on a M1 Mac. I have selected only the firestore emulator to run, successfully logged in, etc. I do firebase emulators:start Here is my output i emulators: Starting…
Kevin McQuown
  • 1,277
  • 2
  • 9
  • 13
3
votes
1 answer

Is credential necessary when running Firebase Admin with Firebase Emulator?

I'm running Firebase Admin SDK on python through functions-framework with Firebase emulator set up on different terminal and I have a question. While this works on shell(zsh)...: # python import firebase_admin from firebase_admin import auth as…