1

How to set using node engine version 10 in dialogflow inline fulfilment package.json?

I try to set it in package.json

"engines": {
    "node": "10"
}

But in my Firebase project, deployed fulfilment cloud function remains use 'Node.js 8'.

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
Jatu Tung
  • 79
  • 6

2 Answers2

2

As of a few days ago, the Dialogflow inline fulfillment uses Node 10 (and you cannot switch back to Node 8). The downside of this is that you must have billing enabled for the GCP project your dialogflow agent is associated with, as under-the-hood the inline fulfillment uses Cloud Build to deploy.

If you want a free way to deploy your functions in Node 10, then I suggest using Firebase Functions, and using the engines: { node: 10; } as you identified in your initial question to request the Node 10 runtime.

James King
  • 465
  • 4
  • 12
  • I know the answer is already 2 years old. This still aplies today? How do you mange to do that on Firebase? – Joao May 26 '22 at 09:36
1

Don't use the Inline editor, it has some bugs as of now. You can use Firebase CLI to host the fulfillment code.

Satish Pandey
  • 335
  • 2
  • 8