Home > Software engineering >  Error: HTTP Error: 400, Invalid JSON payload received. Unknown name "skipLog": Cannot find
Error: HTTP Error: 400, Invalid JSON payload received. Unknown name "skipLog": Cannot find

Time:04-21


I'm trying to setup firebase functions for the first time. I followed the steps in the docs, but when I run firebase init functions I run into this error :

Error: HTTP Error: 400, Invalid JSON payload received. Unknown name "skipLog": Cannot find field.

Here is the extract from the firebase-debug.log file:

[debug] [2022-04-20T08:53:35.659Z] <<< [apiv2][body] POST https://serviceusage.googleapis.com/v1/projects/<my_project_name>/services/cloudfunctions.googleapis.com:enable {"error":{"code":400,"message":"Invalid JSON payload received. Unknown name \"skipLog\": Cannot find field.","status":"INVALID_ARGUMENT","details":[{"@type":"type.googleapis.com/google.rpc.BadRequest","fieldViolations":[{"description":"Invalid JSON payload received. Unknown name \"skipLog\": Cannot find field."}]}]}}
[error] 
[error] Error: HTTP Error: 400, Invalid JSON payload received. Unknown name "skipLog": Cannot find field.
[debug] [2022-04-20T08:53:35.670Z] Error Context: {
  "body": {
    "error": {
      "code": 400,
      "message": "Invalid JSON payload received. Unknown name \"skipLog\": Cannot find field.",
      "status": "INVALID_ARGUMENT",
      "details": [
        {
          "@type": "type.googleapis.com/google.rpc.BadRequest",
          "fieldViolations": [
            {
              "description": "Invalid JSON payload received. Unknown name \"skipLog\": Cannot find field."
            }
          ]
        }
      ]
    }
  },
  "response": {
    "statusCode": 400
  }
}

CodePudding user response:

I had the same problem, managed to init functions with older version (10.6.0) of firebase-tools

CodePudding user response:

To uninstall and reinstall using version 10.6.0:

npm uninstall -g firebase-tools
npm install -g [email protected]
  • Related