Skip to content

Instantly share code, notes, and snippets.

@gregorykremler
Created May 26, 2015 20:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gregorykremler/91351ea80743682757e8 to your computer and use it in GitHub Desktop.
Save gregorykremler/91351ea80743682757e8 to your computer and use it in GitHub Desktop.
geocod.io parse v geocode return objects
# For sample invalid address of:
# "ROYSE CITY TX 75189-, TX 75189-4214"
# parse method return object
# http://api.geocod.io/v1/parse?q=ROYSE%20CITY%20TX%2075189-,%20TX%2075189-4214&api_key=
# {
# address_components: {
# number: "75189-",
# street: "Tx",
# zip: "75189"
# },
# formatted_address: "75189- Tx, 75189"
# }
# geocode method return object
# http://api.geocod.io/v1/geocode?q=ROYSE%20CITY%20TX%2075189-,%20TX%2075189-4214&api_key=
# {
# input: {
# address_components: {
# city: "Royse City",
# state: "TX",
# zip: "75189"
# },
# formatted_address: "Royse City, TX 75189"
# },
# results: [
# {
# address_components: {
# city: "Royse City",
# county: "Rockwall County",
# state: "TX",
# zip: "75189"
# },
# formatted_address: "Royse City, TX 75189",
# location: {
# lat: 32.919754,
# lng: -96.35631
# },
# accuracy: 1,
# accuracy_type: "place",
# source: "TIGER/Line® dataset from the US Census Bureau"
# }
# ]
# }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment