A Flutter plugin that provides a Google Geocoding API.
The Geocoding API is a service that provides geocoding and reverse geocoding of addresses.
The following requests are available:
- Geocoding is the process of converting addresses (like a street address) into geographic coordinates (like latitude and longitude), which you can use to place markers on a map, or position the map.
- Reverse geocoding is the process of converting geographic coordinates into a human-readable address.
You can also use the Geocoding API to find the address for a given place ID.
To use this plugin, add google_geocoding as a dependency in your pubspec.yaml file.
- Get an API key at https://cloud.google.com/maps-platform/.
- Go to Google Developers Console.
- Choose the project that you want to enable Google Geocoding on.
- Geocoding
var googleGeocoding = GoogleGeocoding("Your-Key");
var risult = await googleGeocoding.geocoding.get("1600 Amphitheatre",null);
- Reverse geocoding
var googleGeocoding = GoogleGeocoding("Your-Key");
var risult = await googleGeocoding.geocoding.getReverse(LatLon(40.714224,-73.961452));