Skip to content

Instantly share code, notes, and snippets.

@wircho
Last active July 29, 2016 17:02
Show Gist options
  • Save wircho/87f090ed85d4d3e25654 to your computer and use it in GitHub Desktop.
Save wircho/87f090ed85d4d3e25654 to your computer and use it in GitHub Desktop.
{
"id": "news",
"title": "LATEST NEWS",
"icon_url": "https://s3.amazonaws.com/s3.dashbook.co/dash_icons/news_large_icon.png",
"summary": "Description of news dash.",
"credits": "Google News",
"settings_type": "SELECT",
"settings_options": [
{
"key": "top",
"value": "Top Stories"
},
{
"key": "tech",
"value": "Technology"
},
{
"key": "sports",
"value": "Sports"
}
],
"_MAIN": {
"_LOAD": {
"url": {
"_IF":{"_EQUAL":["tech",{"_PATH":["_SETTINGS","key"]}]},
"_THEN":"https://www.kimonolabs.com/api/6hjkxuve?apikey=<MY_API_KEY>",
"_ELSE":{
"_IF":{"_EQUAL":["sports",{"_PATH":["_SETTINGS","key"]}]},
"_THEN":"https://www.kimonolabs.com/api/9ywprdkk?apikey=<MY_API_KEY>",
"_ELSE":"https://www.kimonolabs.com/api/2li96jtg?apikey=<MY_API_KEY>"
}
},
"json": {
"_URL": "{url}"
},
"_RETURN": {
"_LOOP": {
"_ARRAY": {"_PATH":["json","results","data"]},
"_EACH": [
{"actions":[
{
"_ICON":"source-icon",
"_DO":{"_WEBVIEW":{"_PATH":["_ITEM","source","href"]}}
}
]
},
{
"profile": {
"image": {"_PATH":["_ITEM","image","src"]},
"caption": {"_PATH":["_ITEM","header","text"]},
"type": "cell"
}
},
{
"footer": {
"align": "right",
"caption": {"_PATH":["_ITEM","source","text"]}
}
},
{
"sectional": true
}
]
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment