Skip to content

Instantly share code, notes, and snippets.

@paulomcnally
Forked from clarkbw/datasources.json
Last active August 29, 2015 14:22
Show Gist options
  • Save paulomcnally/a385d36bf1b21315526f to your computer and use it in GitHub Desktop.
Save paulomcnally/a385d36bf1b21315526f to your computer and use it in GitHub Desktop.
"google": {
"name": "google",
"debug": true,
"connector": "rest",
"operations": [
{
"template": {
"doc": "The Google Time Zone API",
"method": "GET",
"url": "https://maps.googleapis.com/maps/api/timezone/{format=json}",
"headers": {
"content-type": "application/json",
"accept": "application/json"
},
"query": {
"location": "{!lat},{!lng}",
"timestamp": "{!timestamp:number}",
"key": "{appKey:string}",
"language": "{language:string}"
},
"variables": {
"lat": {
"type": "number",
"format": "double",
"required": true,
"doc": "Latitude"
},
"lng": {
"type": "number",
"format": "double",
"required": true,
"doc": "Longitude"
},
"timestamp": {
"type": "number",
"required": true,
"doc": "Time as seconds since midnight, January 1, 1970 UTC to determine daylight savings"
}
}
},
"functions": {
"timezone": [
"lat",
"lng",
"timestamp"
]
}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment