Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TypeError: handler is not a function using Firebase and DialogFlow with Google Actions

I keep getting this error message in Firebase functions/logs

dialogflowFirebaseFulfillment
 TypeError: handler is not a function
    at cloudFunction (/srv/node_modules/firebase-functions/lib/providers/https.js:57:9)
    at /worker/worker.js:783:7
    at /worker/worker.js:766:11
    at _combinedTickCallback (internal/process/next_tick.js:132:7)
    at process._tickDomainCallback (internal/process/next_tick.js:219:9)

Originally my actions on google project was working fine, I just got mp3s playing, referencing new user or returning user, etc, everything worked then all of a sudden this error started appearing though I never edited https.js, I have no idea why this error just started anyone familiar with this?

like image 471
Steven Avatar asked Oct 21 '25 04:10

Steven


1 Answers

For others encountering this error: For me it was an incorrect function registration. I registered my function as a standard https-function with onRequest and tried calling it as a callable function. Changing the registration to use onCall solved this issue.

like image 62
nilsqwertz Avatar answered Oct 24 '25 14:10

nilsqwertz



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!