Use Async Functions in DialogFlow WebHook

后端 未结 2 861
北恋
北恋 2020-12-06 14:01

Referring to the solution posted here (DialogFlow V2 Webhook - Expects Speech responses Immediately and not after async requests)
What I want to achieve is that the web

2条回答
  •  悲&欢浪女
    2020-12-06 14:34

    You didn't state what environment you were running in, but given your code, and the agent.parameters change I outlined above, I was able to duplicate your problem using Firebase Cloud Functions with node.js 6.14.

    I was able to get it to work by using the request-promise-native package instead of request-promise. As the name suggests, this uses native Promises instead of the Bluebird Promise package, but otherwise the calls you're making are identical.

提交回复
热议问题