如何使Dialogflow代理识别用户名和用户ID?

时间:2019-10-16 04:59:52

标签: dialogflow

我们正在使用Flask和Dialogflow构建一个聊天机器人。当前,我们使用flask_login来检测当前登录用户的名称和ID,并且我们希望Dialogflow代理知道当前登录用户的信息,因此我们尝试将current_user.name作为参数提供给装饰器下的responses函数。 '@application.route('/webhook',methods=['GET', 'POST'])', 但这给了我们这个错误。 我不知道为什么current_user.name不存在。

enter image description here

这是我们的回复功能

enter image description here

这是错误

enter image description here

0 个答案:

没有答案