metalx1000

JSON Formatted Address from Google Maps API

Apr 3rd, 2017
519
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.34 KB | None | 0 0
  1. #Get Formatted Address from Google Maps API JSON
  2. wget -O- -q "http://maps.google.com/maps/api/geocode/json?address=123 pine street&sensor=false"|jq -r '.results[0]|{"formatted_address"}'
  3.  
  4. #or just result
  5. wget -O- -q "http://maps.google.com/maps/api/geocode/json?address=123 pine street&sensor=false"|jq -r '.results[0]|.formatted_address'
Add Comment
Please, Sign In to add comment