Geocoding
Using the Geocoding API
4 min
making a request to geocode an address, make a post request to the https //docs getos1 com/locateone reference/geocode address with the address details in the request body request body the request body should contain the data object with the following fields true left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type example request { "data" { "address" "delhivery corporate office, sector 44, gurugram", "pincode" "122003", "city" "gurgaon", "state" "haryana" } } understanding the response the geocoding api will return a json response with the geocoded coordinates of the address response schema true left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type example response { "success" true, "status code" 200, "message" "request has been processed", "request id" "ax34687667877689", "result" { "geocode" { "lat" 28 454736, "lng" 77 070171 }, "confidence radius" 24 // unit is in meters } } in the result object, you'll find the geocoded coordinates ( lat and lng ) and the confidence radius , which indicates the accuracy of the geocoded location