1
메신저 봇 webview 옵션을 선택할 수있는 양식이 있습니다. beginShareFlow를 사용하여 스레드에 메시지 문제가 있습니다. Webview 용 Messenger Extensions JS SDK를 추가했습니다. 어떻게 구현합니까? 모든 현실 세계의 예가 도움이됩니다.메신저 봇 Webview beginShareFlow가 작동하지 않습니다.
메신저 봇 webview 옵션을 선택할 수있는 양식이 있습니다. beginShareFlow를 사용하여 스레드에 메시지 문제가 있습니다. Webview 용 Messenger Extensions JS SDK를 추가했습니다. 어떻게 구현합니까? 모든 현실 세계의 예가 도움이됩니다.메신저 봇 Webview beginShareFlow가 작동하지 않습니다.
스레드로 다시 보내려면 JSON 메시지를 작성한 다음 사용자 공유 단추를 클릭하거나 원하는 이벤트를 실행하고 MessengerExtensions.startShareFlow를 실행하고 성공 이벤트와 오류 이벤트, 작성한 메시지 및 메시지 공유 유형. 더 찾기 : the docs
<script>
var messageToShare = {
"attachment":{
"type":"template",
"payload":{
"template_type":"generic",
"elements": [{
"title":"I took Peter's 'Which Hat Are You?' Quiz",
"image_url": "https://bot.peters-hats.com/img/hats/fez.jpg",
"subtitle": "My result: Fez",
"default_action":{
"type":"web_url",
"url": "https://bot.peters-hats.com/view_quiz_results.php?user=24601"
},
"buttons":[{
"type":"web_url",
"url":"https://bot.peters-hats.com/hatquiz.php?referer=24601",
"title":"Take the Quiz"
}]
}]
}
}
};
MessengerExtensions.beginShareFlow(function success(response) {
// Share successful
}, function error(errorCode, errorMessage) {
// The user was not able to share
},
messageToShare,
"broadcast");
</script>
일부 코드주세요. –