Skip to content

Instantly share code, notes, and snippets.

@neilfws
Created August 29, 2017 06:39
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 neilfws/ced954067ac08a4c024532065bd03323 to your computer and use it in GitHub Desktop.
Save neilfws/ced954067ac08a4c024532065bd03323 to your computer and use it in GitHub Desktop.
Mappify API in R example
library(httr)
req <- POST("http://mappify.io/api/rpc/address/geocode/",
body = list(streetAddress = "252 Botany St",
suburb = "Sydney",
postCode = "2000",
state = "NSW"),
encode = "json")
res <- content(req, "parsed")
res$result$location$lat
# [1] -33.86414
res$result$location$lon
# [1] 151.2081
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment