我尝试使用dialogflow实现,并在dialogflow测试控制台上对其进行了测试,这是可行的。当我在facebook messenger上尝试它时,它响应时没有实现消息,并且它是空响应,因为响应是由dialogflow实现实现的。有人可以帮我解决这个问题吗?
{
"responseId": "8caa8e7d-21b2-4b65-a38c-00a1edea22f4",
"queryResult": {
"queryText": "televisions",
"parameters": {},
"allRequiredParamsPresent": true,
"fulfillmentMessages": [
{
"card": {
"title": "A1 4K HDR OLED TV with Acoustic Surface™",
"subtitle": "OLED delivers unprecedented black, contrast and colour, 4K HDR Processor X1 Extreme for outstanding realism",
"imageUri": "//www.sony.com/is/image/gwtprod/2d57ef22242802e0df749d4939e37192?fmt=png-alpha",
"buttons": [
{
"text": "View",
"postback": "View"
}
]
},
"platform": "FACEBOOK"
}
],
"outputContexts": [
{
"name": "projects/sony-personal-assistance/agent/sessions/102be1aa-643d-ae85-4044-ff80763d7d85/contexts/products-tvshomecinema-followup",
"lifespanCount": 1
}
],
"intent": {
"name": "projects/sony-personal-assistance/agent/intents/ef4f598c-04ff-433a-b9f3-3f5e43dc6394",
"displayName": "Products - Tv's & Home Cinema - Televisions"
},
"intentDetectionConfidence": 1,
"diagnosticInfo": {
"webhook_latency_ms": 381
},
"languageCode": "en"
},
"webhookStatus": {
"message": "Webhook execution successful"
}
}
我希望响应是一张卡片,但实际输出为空(我没有在dialogflow中放置任何响应,如果我放置了响应,那么facebook仅显示我在dialogflow中编写的响应,而不是来自实现)
答案 0 :(得分:0)
您是否已将dialogflow代理与Facebook Messenger正确连接? 下面的视频可以帮助您。
我创建了这些视频,以帮助您与Facebook集成并通过Dialogflow在facebook Messenger中发送丰富消息。
将Dialogflow与Facebook连接: https://www.youtube.com/watch?v=fJ4HoYxoKl8
发送卡片等丰富信息: https://www.youtube.com/watch?v=JC9Y-AmcL6A