Skip to content

Instantly share code, notes, and snippets.

@Shaked
Created August 20, 2017 15:24
Show Gist options
  • Select an option

  • Save Shaked/5b982418b51569fab09244900f366abd to your computer and use it in GitHub Desktop.

Select an option

Save Shaked/5b982418b51569fab09244900f366abd to your computer and use it in GitHub Desktop.
Messenger list template possible bug with Webview
[
{
"template_type": "list",
"elements": [
{
"title": "TEST - CHAIN",
"subtitle": "227 קל׳\n7 ג׳ חלבון\n10 שומן\n28 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=19",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
},
{
"title": "TEST - CHAIN",
"subtitle": "82.2 קל׳\n6.8 ג׳ חלבון\n2.1 שומן\n8.9 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=298",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
},
{
"title": "TEST - CHAIN",
"subtitle": "266 קל׳\n6.7 ג׳ חלבון\n1.3 שומן\n55.9 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=284",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
},
{
"title": "TEST - CHAIN",
"subtitle": "190 קל׳\n6 ג׳ חלבון\n14.8 שומן\n9 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=146",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
}
],
"buttons": null,
"top_element_style": "compact"
}
]
[
{
"template_type": "list",
"elements": [
{
"title": "TEST - CHAIN",
"subtitle": "227 קל׳\n7 ג׳ חלבון\n10 שומן\n28 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=19",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
},
{
"title": "TEST - CHAIN",
"subtitle": "82.2 קל׳\n6.8 ג׳ חלבון\n2.1 שומן\n8.9 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=298",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
},
{
"title": "TEST - CHAIN",
"subtitle": "266 קל׳\n6.7 ג׳ חלבון\n1.3 שומן\n55.9 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=284",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
},
{
"title": "TEST - CHAIN",
"subtitle": "190 קל׳\n6 ג׳ חלבון\n14.8 שומן\n9 פחמ׳",
"image_url": "https://dummyimage.com/600x400/000/fff",
"buttons": null,
"default_action": {
"type": "web_url",
"url": "https://2e21920c.ngrok.io/facebook/dish?id=146",
"webview_height_ratio": "tall",
"messenger_extensions": true
}
}
],
"buttons": [
{
"type": "postback",
"title": "Test Main Button",
"payload": "{\"handler\":\"ff\\\\bot\\\\messenger\\\\flows\\\\mvpWebView\\\\replyHandler\\\\SetYourPreferencesHandler\",\"value\":\"VALUE_IRRELEVANT\"}"
}
],
"top_element_style": "compact"
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment